retdec
|
A base class for creators of control-flow graphs (CFGs) from functions. More...
#include <cfg_builder.h>
Public Member Functions | |
ShPtr< CFG > | getCFG (ShPtr< Function > func) |
Returns a CFG of the given function func. More... | |
Protected Member Functions | |
CFGBuilder ()=default | |
Protected Attributes | |
ShPtr< CFG > | cfg |
A CFG that is currently being built. More... | |
ShPtr< Function > | func |
A function from which the CFG is being built. More... | |
Private Member Functions | |
void | initializeNewCFG (ShPtr< Function > func) |
Creates a new CFG and initializes it. More... | |
virtual void | buildCFG ()=0 |
Builds cfg . More... | |
![]() | |
NonCopyable (const NonCopyable &)=delete | |
NonCopyable & | operator= (const NonCopyable &)=delete |
NonCopyable ()=default | |
~NonCopyable ()=default | |
A base class for creators of control-flow graphs (CFGs) from functions.
A subclass should:
buildCFG()
function,create()
function to ease the creation of the builder.Instances of this class have reference object semantics. The class implements the NVI ("non-virtual interface") pattern.
|
protecteddefault |
|
privatepure virtual |
Builds cfg
.
When this function is called, cfg
and func
are correctly initialized.
Implemented in retdec::llvmir2hll::RecursiveCFGBuilder, and retdec::llvmir2hll::NonRecursiveCFGBuilder.
Returns a CFG of the given function func.
Creates a new CFG and initializes it.
A function from which the CFG is being built.