torc::physical::ModuleTransformer Class Reference

Utility class to modularize/flatten designs. More...

#include <ModuleTransformer.hpp>

List of all members.

Public Member Functions

 ModuleTransformer (DesignSharedPtr &inDesignPtr)
 Public constructor.
bool modularize (const InstanceSharedPtrVector &inInstances, const string &inModuleDefinitionName, const string &inModuleInstanceName, bool inKeepPlacement=false, bool inKeepRouting=false)
 Group a set of instances into a module.
bool flatten (const string &inModuleInstanceName, bool inKeepPlacement=false, bool inKeepRouting=false)
 Flatten a module instance in a design.

Protected Types

enum  ENetConnectivity { eNetConnectivityNotConnected = 0, eNetConnectivityInternal, eNetConnectivityExternal }
 Net connectivity with respect to module instance, either not connected to module, internal to module, or external to module. More...
typedef
Design::InstanceSharedPtrConstIterator 
InstanceSharedPtrConstIterator
 Imported type.
typedef
Design::NetSharedPtrIterator 
NetSharedPtrIterator
 Imported type.
typedef
Design::ModuleSharedPtrIterator 
ModuleSharedPtrIterator
 Imported type.
typedef
Design::InstanceSharedPtrIterator 
InstanceSharedPtrIterator
 Imported type.
typedef
Module::PortSharedPtrConstIterator 
PortSharedPtrConstIterator
 Imported type.
typedef
Net::InstancePinSharedPtrIterator 
InstancePinSharedPtrIterator
 Imported type.
typedef
Net::InstancePinSharedPtrConstIterator 
InstancePinSharedPtrConstIterator
 Imported type.
typedef Net::PipConstIterator PipConstIterator
 Imported type.

Protected Attributes

DesignSharedPtr mDesignPtr
 Design pointer.

Static Protected Attributes

static const string sHierarchySeparator = "/"
 Hierarchy separator.
static const string sPortIndexSeparator = "_"
 Port index separator.
static const boost::regex sValidPinNameCharactersRegEx
 Valid characters in a pin name.
static const boost::regex sInvalidPinNameFirstCharactersRegEx
 Invalid first characters in a pin name.

Private Member Functions

ENetConnectivity getNetConnectivity (InstanceSharedPtrConstIterator inInstanceSharedPtrConstBegin, InstanceSharedPtrConstIterator inInstanceSharedPtrConstEnd, NetSharedPtr inNetPtr)
 Generate net connectivity type based on module boundary.
string sanitizePinName (string inPinName)
 Sanitize a pin name.
InstanceSharedPtr cloneInstance (InstanceSharedPtr inIntancePtr, const string &inCloneInstanceName)
 Clone an instance.
NetSharedPtr cloneNet (NetSharedPtr inNetPtr, const string &inNetCloneName, const string &inModuleInstanceName)
 Clone a net.


Detailed Description

Utility class to modularize/flatten designs.

Definition at line 34 of file ModuleTransformer.hpp.


Member Typedef Documentation

Imported type.

Definition at line 39 of file ModuleTransformer.hpp.

Imported type.

Definition at line 41 of file ModuleTransformer.hpp.

Imported type.

Definition at line 43 of file ModuleTransformer.hpp.

Imported type.

Definition at line 45 of file ModuleTransformer.hpp.

Imported type.

Definition at line 47 of file ModuleTransformer.hpp.

Imported type.

Definition at line 49 of file ModuleTransformer.hpp.

Imported type.

Definition at line 51 of file ModuleTransformer.hpp.

Imported type.

Definition at line 53 of file ModuleTransformer.hpp.


Member Enumeration Documentation

Net connectivity with respect to module instance, either not connected to module, internal to module, or external to module.

Definition at line 68 of file ModuleTransformer.hpp.


Constructor & Destructor Documentation

torc::physical::ModuleTransformer::ModuleTransformer ( DesignSharedPtr inDesignPtr  )  [inline]

Public constructor.

Parameters:
inDesignPtr Pointer to the design.

Definition at line 76 of file ModuleTransformer.hpp.


Member Function Documentation

bool torc::physical::ModuleTransformer::modularize ( const InstanceSharedPtrVector inInstances,
const string &  inModuleDefinitionName,
const string &  inModuleInstanceName,
bool  inKeepPlacement = false,
bool  inKeepRouting = false 
) [inline]

Group a set of instances into a module.

Parameters:
inInstances The vector of instances to group.
inModuleDefinitionName The module definition name.
inModuleInstanceName The module instance name.
inKeepPlacement A flag specifying whether placement should be retained after modularization. Default to false.
inKeepRouting A flag specifying whether routing should be retained afer modularization. Defaults to false.

Definition at line 147 of file ModuleTransformer.hpp.

bool torc::physical::ModuleTransformer::flatten ( const string &  inModuleInstanceName,
bool  inKeepPlacement = false,
bool  inKeepRouting = false 
) [inline]

Flatten a module instance in a design.

Parameters:
inModuleInstanceName The name of the module instance to be flattened.
inKeepPlacement A flag specifying whether placement should be retained after flattening. Default to false.
inKeepRouting A flag specifying whether routing should be retained afer flattening. Defaults to false.

Definition at line 481 of file ModuleTransformer.hpp.

ENetConnectivity torc::physical::ModuleTransformer::getNetConnectivity ( InstanceSharedPtrConstIterator  inInstanceSharedPtrConstBegin,
InstanceSharedPtrConstIterator  inInstanceSharedPtrConstEnd,
NetSharedPtr  inNetPtr 
) [inline, private]

Generate net connectivity type based on module boundary.

Parameters:
inInstanceSharedPtrConstBegin A begin iterator to instances contained in module.
inInstanceSharedPtrConstEnd An end iterator to instances contained in module.
inNetPtr A pointer to a net.

Definition at line 760 of file ModuleTransformer.hpp.

string torc::physical::ModuleTransformer::sanitizePinName ( string  inPinName  )  [inline, private]

Sanitize a pin name.

Parameters:
inPinName The pin name to be sanitized.

Definition at line 840 of file ModuleTransformer.hpp.

InstanceSharedPtr torc::physical::ModuleTransformer::cloneInstance ( InstanceSharedPtr  inIntancePtr,
const string &  inCloneInstanceName 
) [inline, private]

Clone an instance.

Parameters:
inIntancePtr A pointer to the instance to be cloned.
inCloneInstanceName The name of the clone. Clone an instance and its configuration. This function does not clone the instance pins. Instance pins are handled when cloning nets, in function cloneNet.

Definition at line 872 of file ModuleTransformer.hpp.

NetSharedPtr torc::physical::ModuleTransformer::cloneNet ( NetSharedPtr  inNetPtr,
const string &  inNetCloneName,
const string &  inModuleInstanceName 
) [inline, private]

Clone a net.

Parameters:
inNetPtr A pointer to the net to be cloned.
inNetCloneName The name of the clone.
inModuleInstanceName The module instance name. Clone a net, its configuration, its sources, sinks and pips. For pips, the routethrough instances are droppped and not cloned.

Todo:
We are dropping routethrough instances.

Definition at line 916 of file ModuleTransformer.hpp.


Member Data Documentation

Design pointer.

Definition at line 56 of file ModuleTransformer.hpp.

const std::string torc::physical::ModuleTransformer::sHierarchySeparator = "/" [static, protected]

Hierarchy separator.

Definition at line 58 of file ModuleTransformer.hpp.

const std::string torc::physical::ModuleTransformer::sPortIndexSeparator = "_" [static, protected]

Port index separator.

Definition at line 60 of file ModuleTransformer.hpp.

Valid characters in a pin name.

Definition at line 62 of file ModuleTransformer.hpp.

Invalid first characters in a pin name.

Definition at line 64 of file ModuleTransformer.hpp.


The documentation for this class was generated from the following files:

Generated on Thu Oct 13 16:50:47 2011 for TORC by  doxygen 1.5.6