#include <suifkernel/module.h>
Inheritance diagram for Module:
Public Methods | |
Module (SuifEnv* suif_env, const LString& moduleName = emptyLString ) | |
virtual | ~Module () |
virtual LString | get_module_name () const |
Retrieves the name of a module. More... | |
virtual Module* | clone () const = 0 |
generates a new copy of the current instance if necessary The implementor of a subclass is responsible for overriding this method if the implementation has a unique state the default implementation returns the current instance. | |
virtual bool | delete_me () const |
tells the system whether an instance of this Module should be deleted after it has been executed the default implementation returns false. | |
virtual bool | is_initialized () const |
returns true if the method initalize() was already executed on this instance. | |
virtual void | initialize () |
initializes the modules. More... | |
virtual bool | parse_command_line ( TokenStream* command_line_stream ) |
parses the input for this Module. | |
virtual void | execute () |
executes the Module parse_command_line should be called before this method is invoked. | |
virtual SuifEnv* | get_suif_env () const |
virtual bool | supports_interface ( const LString &interface_name ) const |
Interface required for the SUIF interface support mechanism. More... | |
virtual Address | get_interface ( const LString &interface_name ) const |
virtual void | get_supported_interface_list (list<LString> &llist) const |
write the list of interfaces this module supports to the llist. | |
virtual void | interface_registered (const LString &producer_module_name, const LString &interface_name) |
These are callbacks that the module system will give when a new module registers its support for an interface. | |
virtual void | interface_object_created (Module *producer_module, const LString &interface_name) |
virtual void | interface_object_destructed (Module *producer_module, const LString &interface_name) |
void | import_module (const char* module_name) |
virtual String | get_description () const |
get the module description. | |
virtual String | get_usage () const |
Protected Methods | |
virtual void | set_interface ( const LString &interface_name, Address interface) |
Protected Attributes | |
SuifEnv* | _suif_env |
LString | _module_name |
OptionLiteral* | _command_name |
OptionList* | _command_line |
OptionSelection* | _flags |
OptionLiteral* | _help_flag |
suif_hash_map<LString, Address>* | _interfaces |
Friends | |
class | ModuleSubSystem |
|
|
|
generates a new copy of the current instance if necessary The implementor of a subclass is responsible for overriding this method if the implementation has a unique state the default implementation returns the current instance.
Reimplemented in AddExplicitLoopLabels, AddProcedureEndLabelsPass, AddStatementListsToProcs, ArrayReferenceDismantlerPass, AvoidExternCollisions, AvoidFileScopeCollisions, AvoidLabelCollisions, BuildCppVTablesPass, CFor2ForPass, CIAnnoteStatsPass, CPrintStyleModule, CallExpressionDismantlerPass, CiCheckElimPass, CollectWalkerPass, CombinedPass, CombinedPassForCpp, ConstantFolderPass, ConvertToFortranForm, CopyPropPass, CountCallsWithIteratorPass, CountCallsWithWalkerPass, CountSuifObjectPass, CppOsuifTypeBuilderModule, CreateSuifComplexInputPass, DeadcodePass, DismantleCallArguments, DismantleCppVTablesPass, DismantleEmptyScopeStatements, DismantleMultiEntryScopeStatements, DismantleStmtsWithJumpsInside, DismantleStructuredReturns, Driver, FieldBuilderPass, FixupExplicitLoopLabels, FlattenStatementListsPass, FoldStatementsPass, FoldTable, GCSymbolTablePass, GuardAllFors, IdPrinter, IfConditionsToBinaryExprs, ImportModule, InlinePass, InstanceFieldsLayoutDriver, J2sClosurePass, ListInterfacesModule, ListModulesModule, LoadExpressionDismantlerPass, LocationModule, Lowering, LoweringPass, MCPrintStyleModule, MarkGuardedFors, MultiDimArrayDismantlerPass, NameAllSymbolsPass, NodeCount, NonConstBoundDismantlerPass, NormalizeProcedureReturns, One2MultiArrayExpressionPass, OsuifTypeBuilderModule, PaddingPass, Pass, PipelinablePass, Pipeliner, PipelinerDispatchPass, PrintDotSuifCFGraphPass, PrintModule, PrintSuifCFGraphPass, RemoveExplicitLoopLabels, RemoveIfAndLoopPass, RemoveTrashPass, RepeatValueBlockBuilderPass, RequireModule, RequireProcedureReturns, S2CPass, SBrowserModule, SaveModule, SetAddrTakenPass, SimpleModule, StripAnnotesPass, StructPaddingPass, SuifCFGraphBuilderModule, SuifCFGraphPass, SuifClonerModule, SuifPrinterModule, TestCloneModule, TestWalkerModule, TimeModule, TypeBuilderModule, TypeCheckerPass, UnconvertFromFortranForm, UnownedPass, ValidateSuifPass, VirtualTests, Vtbl, XLoadModule, build_single_vtable_pass, convertsuif1to2b, convertsuif2bto1_pass, dismantle_if_statements_pass, dismantle_if_statements_pass, globalize_class_method_symbols_pass, globalize_class_method_symbols_pass, globalize_class_variable_symbols_pass, iterator_pass, j2s_Pass, j2s_Program, md_Pass, print_pass, sup_Pass, walker_based_module, and walker_pass.
|
tells the system whether an instance of this Module should be deleted after it has been executed the default implementation returns false.
Reimplemented in CountSuifObjectPass, Driver, GCSymbolTablePass, S2CPass, SimpleModule, TimeModule, and ValidateSuifPass.
|
executes the Module parse_command_line should be called before this method is invoked.
Reimplemented in CountSuifObjectPass, Driver, FrontendPass, GCSymbolTablePass, ImportModule, InstanceFieldsLayoutDriver, ListInterfacesModule, ListModulesModule, LocationModule, Lowering, NodeCount, Pass, PipelinablePass, Pipeliner, PipelinerDispatchPass, PrintModule, Printclosure, Printloader, Printmetaloader, RequireModule, SBrowserModule, SaveModule, SimpleModule, SuifPrinterModule, TestCloneModule, TestWalkerModule, TimeModule, ValidateSuifPass, VirtualTests, Vtbl, XLoadModule, and j2s_Program.
|
|
|
Retrieves the name of a module.
This name must be unique for every kind of Module. (it may be called before calling the initialize method)
Reimplemented in TestCloneModule, and TestWalkerModule.
|
|
|
|
|
initializes the modules.
This method must/will be called before a call to parse_command_line or execute
Reimplemented in AddExplicitLoopLabels, AddProcedureEndLabelsPass, AddStatementListsToProcs, ArrayReferenceDismantlerPass, CFor2ForPass, CIAnnoteStatsPass, CPrintStyleModule, CallExpressionDismantlerPass, CiCheckElimPass, ClinitElimPass, CollectWalkerPass, ConvertToFortranForm, CopyPropPass, CountSuifObjectPass, CppOsuifTypeBuilderModule, DeadcodePass, DefinitionBlockPass, DismantleCallArguments, DismantleEmptyScopeStatements, DismantleMultiEntryScopeStatements, DismantleStmtsWithJumpsInside, DismantleStructuredReturns, Driver, FieldBuilderPass, FixupExplicitLoopLabels, FlattenStatementListsPass, FoldStatementsPass, FoldTable, FrontendPass, GCSymbolTablePass, GuardAllFors, HasClinitPass, IdPrinter, IfConditionsToBinaryExprs, ImportModule, InstanceFieldsLayoutDriver, InstanceFieldsLayoutOffsetAnnotePass, InstanceFieldsLayoutPass, InstanceMethodCallExpressionLoweringPass, InstanceMethodCallStatementLoweringPass, J2sClosurePass, JavaInstanceMethodCallExpressionLoweringPass, ListInterfacesModule, ListModulesModule, LoadExpressionDismantlerPass, LocalConstPropPass, LocalCopyPropPass, LocationModule, Lowering, LoweringPass, MCPrintStyleModule, MarkGuardedFors, MultiDimArrayDismantlerPass, NonConstBoundDismantlerPass, NormalizeProcedureReturns, One2MultiArrayExpressionPass, OsuifTypeBuilderModule, PaddingPass, Pass, PipelinablePass, PrintDotSuifCFGraphPass, PrintModule, Printclosure, Printloader, Printmetaloader, RemoveExplicitLoopLabels, RemoveIfAndLoopPass, RepeatValueBlockBuilderPass, RequireModule, RequireProcedureReturns, S2CPass, SBrowserModule, SaveModule, SetAddrTakenPass, StaticMethodCallExpressionLoweringPass, StaticMethodCallStatementLoweringPass, StripAnnotesPass, SuifCFGraphBuilderModule, SuifCFGraphPass, SuifClonerModule, SuifPrinterModule, TypeBuilderModule, UnconvertFromFortranForm, ValidateSuifPass, Vtbl, VtblAnnotePass, VtblPass, VtblSlotAnnotePass, VtblSlotCountAnnotePass, XLoadModule, convertsuif1to2b, convertsuif2bto1_pass, j2s_FrontEndPass, j2s_FrontEndPass, j2s_Pass, j2s_Program, md_Pass, sup_Pass, and walker_based_module.
|
Reimplemented in SuifPrinterModule.
|
|
These are callbacks that the module system will give when a new module registers its support for an interface.
|
returns true if the method initalize() was already executed on this instance.
|
parses the input for this Module.
Reimplemented in CIAnnoteStatsPass, CiCheckElimPass, ClinitElimPass, CollectWalkerPass, DefinitionBlockPass, Driver, HasClinitPass, InstanceFieldsLayoutDriver, InstanceFieldsLayoutOffsetAnnotePass, InstanceFieldsLayoutPass, InstanceMethodCallExpressionLoweringPass, InstanceMethodCallStatementLoweringPass, J2sClosurePass, JavaInstanceMethodCallExpressionLoweringPass, LocalConstPropPass, LocalCopyPropPass, Lowering, LoweringPass, Printclosure, SimpleModule, StaticMethodCallExpressionLoweringPass, StaticMethodCallStatementLoweringPass, Vtbl, VtblAnnotePass, VtblPass, VtblSlotAnnotePass, VtblSlotCountAnnotePass, j2s_FrontEndPass, j2s_FrontEndPass, j2s_Pass, j2s_Program, md_Pass, and sup_Pass.
|
|
Interface required for the SUIF interface support mechanism.
This can return pointers to anything. Frequently it will be a pointer to a function to call
|
|
|
|
|
|
|
|