|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectbyucc.edif.libraries.xilinx.Edif2XilinxName
public class Edif2XilinxName
This class is used for converting hierarchical Edif names into valid flattened Xilinx names. The rules for Xilinx Xpower names are as follows: 1) Outputs For top-level "outputs" use the top-level instance names (old names) for instances having only one output that drive the output signal ? What about instances with multiple outputs? 2) Signals A) Top-level signals: driven by ibufs/top-level instances: - use the top-level net name (old name) (not instance name) B) For names with hierarchy: - find the highest level of hierarchy for the net - find the hierachy of this level. Add net name. (IE: if any of the net's portRefs refer to top level ports, don't add the port) - append "old names" of each instance (separated by "/") - append final net name - Special case extension * driver&sinks are lower levels of hierarchy 3) Logic A) Top-level and hierarchic names: - find cell instance hierarchy - append "old names" of each instance hierarchy level (separated by "/") - Special case extensions - NOTE: "_rt" & ".WSGEN" specaial case extensions hacked 4) Inputs Use top-level instance names (old names) 5) IOs Use top-level instance names (old names) Create a "Map" between: key: List: (ordered List of EdifCellInstance objects/Nets) value: String (corresponding Xilinx String)
| Field Summary | |
|---|---|
protected java.util.Map |
_innerNetsMapCache
|
protected java.util.Map |
_nameObjectMap
This is the main Map of the object. |
protected InstanceHierarchy |
_topInstHier
|
| Constructor Summary | |
|---|---|
Edif2XilinxName(EdifCellInstance top)
|
|
Edif2XilinxName(InstanceHierarchy hier)
|
|
Edif2XilinxName(java.lang.String fileName)
|
|
| Method Summary | |
|---|---|
void |
createLogicMap(InstanceHierarchy hier)
|
void |
createSignalMap(InstanceHierarchy hier)
|
boolean |
drivesTopLevelOutputPort(NetHierarchy netHier)
|
static java.util.ArrayList |
getAllEdifNetNames(EdifNet net,
InstanceHierarchy hier,
NetHierarchy netHier,
boolean includeTop)
|
java.util.ArrayList |
getAllJHDLNetNames(NetHierarchy netHier,
boolean includeTop)
|
static java.util.ArrayList |
getAllNetNames(EdifNet net,
InstanceHierarchy hier,
NetHierarchy netHier,
boolean includeTop)
|
static java.util.ArrayList |
getAllNetNamesSimple(EdifNet net,
NetHierarchy netHier,
boolean includeTop)
|
static java.util.ArrayList |
getAllPortNames(EdifNet net,
InstanceHierarchy hier,
NetHierarchy netHier,
boolean includeTop)
|
static EdifNet |
getInnerMostNet(EdifNet net)
|
java.util.Map |
getNameObjectMap()
|
java.util.ArrayList |
getOutputPortInstances(NetHierarchy netHier,
InstanceHierarchy hier,
boolean includeTop)
|
static java.util.List |
getXilinxNameSuffix(EdifCellInstance cellinst)
For some cell instances Xilinx adds one or more extensions to the "Logic" name TODO: Describe each rule in more detail. |
static boolean |
isRTObject(EdifNet net)
Xilinx adds a "_rt" extension to some signals. |
static boolean |
isRTObject(byucc.jhdl.base.Wire wire)
|
static boolean |
isWSGENObject(EdifNet net)
Xilinx adds a ".WSGEN" extension to some signals. |
static java.io.PrintWriter |
openWriteFile(java.lang.String fileName)
This is a helper method to reduce redundant and cluttered code. |
static EdifCellInstance |
parseCell(java.lang.String fileName)
simply returns the EdifEnvironment from the EDIF file name |
void |
printMapNames()
This method prints the signal names parsed from the EDIF file |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.util.Map _nameObjectMap
protected java.util.Map _innerNetsMapCache
protected InstanceHierarchy _topInstHier
| Constructor Detail |
|---|
public Edif2XilinxName(java.lang.String fileName)
fileName - - the name of the EDIF file to parsepublic Edif2XilinxName(EdifCellInstance top)
public Edif2XilinxName(InstanceHierarchy hier)
| Method Detail |
|---|
public void createSignalMap(InstanceHierarchy hier)
hier - public void createLogicMap(InstanceHierarchy hier)
public static EdifNet getInnerMostNet(EdifNet net)
public boolean drivesTopLevelOutputPort(NetHierarchy netHier)
public java.util.ArrayList getAllJHDLNetNames(NetHierarchy netHier,
boolean includeTop)
public static java.util.ArrayList getAllNetNames(EdifNet net,
InstanceHierarchy hier,
NetHierarchy netHier,
boolean includeTop)
public static java.util.ArrayList getAllEdifNetNames(EdifNet net,
InstanceHierarchy hier,
NetHierarchy netHier,
boolean includeTop)
public static java.util.ArrayList getAllNetNamesSimple(EdifNet net,
NetHierarchy netHier,
boolean includeTop)
public static java.util.ArrayList getAllPortNames(EdifNet net,
InstanceHierarchy hier,
NetHierarchy netHier,
boolean includeTop)
public java.util.ArrayList getOutputPortInstances(NetHierarchy netHier,
InstanceHierarchy hier,
boolean includeTop)
public java.util.Map getNameObjectMap()
public static java.util.List getXilinxNameSuffix(EdifCellInstance cellinst)
cellinst -
public static boolean isRTObject(EdifNet net)
net -
public static boolean isRTObject(byucc.jhdl.base.Wire wire)
public static boolean isWSGENObject(EdifNet net)
net -
public static java.io.PrintWriter openWriteFile(java.lang.String fileName)
fileName -
public static EdifCellInstance parseCell(java.lang.String fileName)
fileName -
public void printMapNames()
names -
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||