7 #ifndef RETDEC_LLVMIR2HLL_SUPPORT_UNREACHABLE_CODE_IN_CFG_REMOVER_H
8 #define RETDEC_LLVMIR2HLL_SUPPORT_UNREACHABLE_CODE_IN_CFG_REMOVER_H
A visitor that visits everything in an ordered way.
Definition: ordered_all_visitor.h:44
bool visitSuccessors
Should statements' successor be accessed?
Definition: ordered_all_visitor.h:144
virtual void visit(ShPtr< GlobalVarDef > varDef) override
Definition: ordered_all_visitor.cpp:95
bool visitNestedStmts
Should nested statements be accessed?
Definition: ordered_all_visitor.h:147
Removes code that is unreachable in a CFG.
Definition: unreachable_code_in_cfg_remover.h:30
static void removeCode(ShPtr< Module > module)
Removes code from all the functions in module that is unreachable in the CFG.
Definition: unreachable_code_in_cfg_remover.cpp:56
virtual void visitStmt(ShPtr< Statement > stmt, bool visitSuccessors=true, bool visitNestedStmts=true) override
Visits the given statement, and possibly its successors or nested statements.
Definition: unreachable_code_in_cfg_remover.cpp:90
void performRemovalInFunc(ShPtr< Function > func)
Performs the removal of code in the given function.
Definition: unreachable_code_in_cfg_remover.cpp:79
ShPtr< CFG > cfg
The CFG of the current function.
Definition: unreachable_code_in_cfg_remover.h:52
void performRemoval()
Performs the removal of code.
Definition: unreachable_code_in_cfg_remover.cpp:69
UnreachableCodeInCFGRemover(ShPtr< Module > module)
Constructs a new remover.
Definition: unreachable_code_in_cfg_remover.cpp:29
ShPtr< Module > module
Module in which the code is removed.
Definition: unreachable_code_in_cfg_remover.h:49
ShPtr< CFGBuilder > cfgBuilder
The used builder of CFGs.
Definition: unreachable_code_in_cfg_remover.h:55
A mixin to make classes non-copyable.
Definition: non_copyable.h:27
A library providing API for working with back-end IR.
std::shared_ptr< T > ShPtr
An alias for a shared pointer.
Definition: smart_ptr.h:18
Definition: archive_wrapper.h:19
A mixin to make classes non-copyable.
A visitor that visits everything in an ordered way.
Declarations, aliases, macros, etc. for the use of smart pointers.