Otawa
0.10
|
Abstract class to represent the registered processors. More...
#include <otawa/proc/Registration.h>
Public Member Functions | |
const string & | name (void) const |
Get the name of the processor. More... | |
const Version & | version (void) const |
Get the version of the processor. More... | |
AbstractRegistration & | base (void) const |
virtual Processor * | make (void) const =0 |
Build the registered processor. More... | |
virtual bool | isFinal (void) const =0 |
bool | provides (const AbstractFeature &feature) |
Test if the current processor provides the given feature. More... | |
bool | requires (const AbstractFeature &feature) |
Test if the current processor requires the given feature. More... | |
bool | invalidates (const AbstractFeature &feature) |
Test if the current processor invalidates the given feature. More... | |
bool | uses (const AbstractFeature &feature) |
Test if the current processor uses or requires the given feature. More... | |
void | initialize (void) |
Internal. More... | |
Protected Member Functions | |
AbstractRegistration (void) | |
Build the registration. More... | |
AbstractRegistration (AbstractRegistration *base) | |
Build of a custom registration. More... | |
AbstractRegistration (string name, Version version, AbstractRegistration *base) | |
Build a new registration. More... | |
virtual | ~AbstractRegistration (void) |
void | init (cstring name, const Version &version, int tag, VarArg &args) |
Initialize a registration from an argument list. More... | |
void | setFeatures (const SLList< FeatureUsage > &features) |
Set the features. More... | |
void | setConfigs (const SLList< AbstractIdentifier * > &configs) |
Set the configurations. More... | |
void | record (void) |
Private Attributes | |
string | _name |
Version | _version |
AbstractRegistration * | _base |
SLList< AbstractIdentifier * > | configs |
SLList< FeatureUsage > | features |
Friends | |
class | declare |
class | Processor |
class | ConfigIter |
class | FeatureIter |
Abstract class to represent the registered processors.
|
protected |
Build the registration.
|
protected |
|
protected |
|
inlineprotectedvirtual |
|
inline |
Referenced by AbstractRegistration(), otawa::ConfigIter::step(), and otawa::FeatureIter::step().
|
protected |
Initialize a registration from an argument list.
name | Processor name. |
version | Processor version. |
tag | First tag. |
args | List of pair (tag, value) ended by a otawa::p::end value. |
References _base, _name, _version, otawa::p::base, otawa::p::config, configs, otawa::p::end, features, otawa::p::invalidate, otawa::FeatureUsage::invalidate, name(), elm::VarArg::next(), otawa::p::provide, otawa::FeatureUsage::provide, record(), otawa::p::require, otawa::FeatureUsage::require, otawa::p::use, otawa::FeatureUsage::use, and version().
void otawa::AbstractRegistration::initialize | ( | void | ) |
Internal.
References otawa::Registry::_, name(), otawa::Registry::procs, and elm::genstruct::HashTable< K, T, H >::put().
bool otawa::AbstractRegistration::invalidates | ( | const AbstractFeature & | feature | ) |
Test if the current processor invalidates the given feature.
feature | Tested feature. |
References otawa::FeatureUsage::invalidate.
|
pure virtual |
Implemented in otawa::p::declare, otawa::Registration< T >, otawa::Registration< otawa::GraphBBTime< G > >, otawa::Registration< otawa::SubCFGBuilder >, otawa::Registration< otawa::display::ILPSystemDisplayer >, otawa::Registration< otawa::CFGChecker >, otawa::Registration< otawa::hard::Dumper >, otawa::Registration< otawa::FixedTextDecoder >, otawa::Registration< otawa::tsim::Delta >, otawa::Registration< BHTGetter >, otawa::Registration< otawa::GraphBBTime< ParExeGraph > >, otawa::Registration< otawa::ipet::VarAssignment >, otawa::Registration< otawa::DelayedBuilder >, otawa::Registration< otawa::ipet::CachePenaltiesObjectFunctionBuilder >, otawa::Registration< otawa::tsim::BBTimeSimulator >, otawa::Registration< otawa::ipet::ConstraintLoader >, otawa::Registration< otawa::script::Script >, otawa::Registration< otawa::CAT2Builder >, otawa::MetaRegistration, and otawa::NullRegistration.
|
pure virtual |
Build the registered processor.
Implemented in otawa::p::declare, otawa::Registration< T >, otawa::Registration< otawa::GraphBBTime< G > >, otawa::Registration< otawa::SubCFGBuilder >, otawa::Registration< otawa::display::ILPSystemDisplayer >, otawa::Registration< otawa::CFGChecker >, otawa::Registration< otawa::hard::Dumper >, otawa::Registration< otawa::FixedTextDecoder >, otawa::Registration< otawa::tsim::Delta >, otawa::Registration< BHTGetter >, otawa::Registration< otawa::GraphBBTime< ParExeGraph > >, otawa::Registration< otawa::ipet::VarAssignment >, otawa::Registration< otawa::DelayedBuilder >, otawa::Registration< otawa::ipet::CachePenaltiesObjectFunctionBuilder >, otawa::Registration< otawa::tsim::BBTimeSimulator >, otawa::Registration< otawa::ipet::ConstraintLoader >, otawa::Registration< otawa::script::Script >, otawa::Registration< otawa::CAT2Builder >, otawa::MetaRegistration, and otawa::NullRegistration.
Referenced by otawa::ProcessorPlugin::getProcessor().
|
inline |
Get the name of the processor.
Referenced by init(), initialize(), and otawa::Processor::process().
bool otawa::AbstractRegistration::provides | ( | const AbstractFeature & | feature | ) |
Test if the current processor provides the given feature.
feature | Tested feature. |
References otawa::FeatureUsage::provide.
|
protected |
References otawa::Registry::_, and elm::Initializer< T >::record().
Referenced by otawa::p::declare::declare(), and init().
bool otawa::AbstractRegistration::requires | ( | const AbstractFeature & | feature | ) |
Test if the current processor requires the given feature.
feature | Tested feature. |
References otawa::FeatureUsage::require.
Referenced by otawa::AlternativeProcessor::AlternativeProcessor().
|
protected |
Set the configurations.
coll | Configures to set. |
References configs, and otawa::p::use.
Referenced by otawa::p::declare::declare().
|
protected |
Set the features.
coll | Features to set. |
References features, and otawa::p::use.
Referenced by otawa::p::declare::declare().
bool otawa::AbstractRegistration::uses | ( | const AbstractFeature & | feature | ) |
Test if the current processor uses or requires the given feature.
feature | Tested feature. |
References otawa::FeatureUsage::require, and otawa::FeatureUsage::use.
Referenced by otawa::Processor::process().
|
inline |
|
friend |
|
friend |
|
friend |
|
friend |
|
private |
Referenced by AbstractRegistration(), init(), and otawa::Processor::Processor().
|
private |
Referenced by AbstractRegistration(), init(), and otawa::Processor::Processor().
|
private |
Referenced by AbstractRegistration(), init(), and otawa::Processor::Processor().
|
private |
Referenced by init(), setConfigs(), and otawa::ConfigIter::step().
|
private |