Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
// -*- C++ -*-
//
// This file is part of the Coriolis Software.
2016-01-20 17:41:19 -06:00
// Copyright (c) UPMC 2006-2016, All Rights Reserved
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
//
// +-----------------------------------------------------------------+
2008-03-06 10:46:43 -06:00
// | C O R I O L I S |
// | I s o b a r - Hurricane / Python Interface |
// | |
// | Author : Jean-Paul CHAPUT |
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
// | E-mail : Jean-Paul.Chaput@lip6.fr |
2008-03-06 10:46:43 -06:00
// | =============================================================== |
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
// | C++ Module : "./PyInstance.cpp" |
// +-----------------------------------------------------------------+
2008-03-06 10:46:43 -06:00
2008-05-21 17:46:29 -05:00
# include "hurricane/isobar/PyBox.h"
# include "hurricane/isobar/PyTransformation.h"
# include "hurricane/isobar/PyLibrary.h"
# include "hurricane/isobar/PyCell.h"
# include "hurricane/isobar/PyInstance.h"
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
# include "hurricane/isobar/PyPlacementStatus.h"
2008-05-21 17:46:29 -05:00
# include "hurricane/isobar/PyNet.h"
# include "hurricane/isobar/PyPlug.h"
2008-10-17 12:27:20 -05:00
# include "hurricane/isobar/PyPlugCollection.h"
2008-03-06 10:46:43 -06:00
namespace Isobar {
2008-03-28 04:48:47 -05:00
using namespace Hurricane ;
2008-03-06 10:46:43 -06:00
extern " C " {
# undef ACCESS_OBJECT
# undef ACCESS_CLASS
# define ACCESS_OBJECT _baseObject._object
# define ACCESS_CLASS(_pyObject) &(_pyObject->_baseObject)
# define METHOD_HEAD(function) GENERIC_METHOD_HEAD(Instance,instance,function)
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
# define LOAD_CONSTANT(CONSTANT_VALUE,CONSTANT_NAME) \
2008-03-06 10:46:43 -06:00
constant = PyInt_FromLong ( ( long ) CONSTANT_VALUE ) ; \
PyDict_SetItemString ( dictionnary , CONSTANT_NAME , constant ) ; \
Py_DECREF ( constant ) ;
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
// +=================================================================+
2008-03-06 10:46:43 -06:00
// | "PyInstance" Python Module Code Part |
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
// +=================================================================+
2008-03-06 10:46:43 -06:00
# if defined(__PYTHON_MODULE__)
static Instance : : PlacementStatus PyInt_AsPlacementStatus ( PyObject * object )
{
Correction in plugins to support msxlib compatible pads.
* New: In CRL Core, in helpers & alliance.conf, set and read a "PAD"
variable to define the pad model name extension ("px" for "sxlib
and "pxr" for vsxlib, this is provisional).
* New: In CRL Core, in plugin.conf, add parameters to define the name
of used for power & clock supply. We may remove the extention in
the future (to be more coherent with the previous modification).
* New: In Cumulus, in chip.Configuration.GaugeConf._rpAccess(), no
longer place the accessing contact *at the center* of the
RoutingPad. It works under sxlib because buffers & registers all
have same size terminals. But this is not true under vsxlib,
leading to misaligned contacts & wires. Now systematically place
on the slice midlle track (maybe with one pitch above or below).
This is still very weak as we do not check if the terminal
reach were the contact is being put. Has to be strenthened in
the future.
* New: In Cumulus, in chip.Configuration.ChipConf, read the new
clock & power pad parameters.
* Change: In Isobar (and all other Python wrappers), uses PyLong instead
of PyInt for DbU conversions. In PyHurricane argument converter,
automatically check for both PyLong and then PyInt.
* Change: In Cumulus, in chip.PadsCorona, more accurate error message
in case of discrepency in global net connections (i.e. no net
of the same name in instance model and instance model owner.
* Change: In Kite, in BuildPowerRails, when looking up at the pads
model name to find "pck_" or "pvddeck_", do not compare the
extension part. But we still use hard-coded stem pad names,
maybe we shouldn't.
* Bug: In Katabatic, in GCellConfiguration::_do_xG_xM1_xM3(), there
was a loop in the search of the best N/E initial RoutingPad.
* Bug: In Kite, in KiteEngine::protectRoutingPads(), *do not* protect
RoutingPads of fixed nets, they are already through the
BuildPowerRails stage (and it's causing scary overlap warning
messages).
* Bug: In Cumulus, in ClockTree.HTreeNode.addLeaf(), do not create
deep-plug when the core is flat (not sub-modules). All the new
nets are at core level.
* Bug: In Cumulus, in ChipPlugin.PlaceCore.doFloorplan(), ensure
that the core is aligned on the GCell grid (i.e. the slice
grid of the overall chip).
* Bug: In Kite, in GCellTopology::_do_xG_xM1_xM3(), infinite loop
while looking for the bigger N-E RoutingPad. Forgot to decrement
the index...
2014-09-13 10:45:30 -05:00
switch ( PyAny_AsLong ( object ) ) {
2008-03-06 10:46:43 -06:00
case Instance : : PlacementStatus : : UNPLACED : return ( Instance : : PlacementStatus ( Instance : : PlacementStatus : : UNPLACED ) ) ;
case Instance : : PlacementStatus : : PLACED : return ( Instance : : PlacementStatus ( Instance : : PlacementStatus : : PLACED ) ) ;
case Instance : : PlacementStatus : : FIXED : return ( Instance : : PlacementStatus ( Instance : : PlacementStatus : : FIXED ) ) ;
}
return ( Instance : : PlacementStatus ( Instance : : PlacementStatus : : UNPLACED ) ) ;
}
// Standart Accessors (Attributes).
2008-03-17 08:54:33 -05:00
// Standart destroy (Attribute).
DBoDestroyAttribute ( PyInstance_destroy , PyInstance )
2008-03-06 10:46:43 -06:00
2008-12-11 06:25:02 -06:00
GetNameMethod ( Instance , instance )
2008-03-06 10:46:43 -06:00
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_create ( PyObject * , PyObject * args )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_create() " < < endl ;
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
Instance * instance = NULL ;
Corrections in C-Python interface required by Analagic (CHAMS).
* Change: In Hurricane, in PyHurricane.h, in all DirectSet*() macros,
suppress the third parameter giving the function name. It is now
build from stringification of other parameters.
The various macros calls are also modificated all througout
Isobar.
Added PyAny_AsInt() to convert a Python Int or Long into an int.
Maybe we should manage only long, because the type difference seems
ambiguous in Python itself.
* Change: In Hurricane, in PyHurricane.h, in DirectGetBoolAttribute()
deduce the function name to display in messages from the arguments.
Idem for DirectIsAFromCStringAttribute(), DirectGetIntAttribute(),
DirectGetUIntAttribute(), DirectGetDoubleAttribute() and
DirectGetStringAttribute().
* New: In Hurricane, in PyHurricane.h, new macro DirectGetNameAttribute()
to build accessors for method returning a Name.
* New: In Hurricane, in PyHurricane.h, new macro DirectSetIntAttribute()
to build modificators taking int arguments.
* Bug: In Hurricane, in PyHurricane.h, in macro DirectSetBoolAttribute(),
the check for a boolean PyObject was wrong, leading the macro to
systematically emit a Python exception.
* Bug: In Hurricane, in PyInstance method table, PyLibrary_create() was
registered as a NOARGS function, but it *do* have arguments, change
to VARARGS.
2016-05-01 08:50:27 -05:00
PyObject * arg0 = NULL ;
PyObject * arg1 = NULL ;
PyObject * arg2 = NULL ;
PyObject * arg3 = NULL ;
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
HTRY
Corrections in C-Python interface required by Analagic (CHAMS).
* Change: In Hurricane, in PyHurricane.h, in all DirectSet*() macros,
suppress the third parameter giving the function name. It is now
build from stringification of other parameters.
The various macros calls are also modificated all througout
Isobar.
Added PyAny_AsInt() to convert a Python Int or Long into an int.
Maybe we should manage only long, because the type difference seems
ambiguous in Python itself.
* Change: In Hurricane, in PyHurricane.h, in DirectGetBoolAttribute()
deduce the function name to display in messages from the arguments.
Idem for DirectIsAFromCStringAttribute(), DirectGetIntAttribute(),
DirectGetUIntAttribute(), DirectGetDoubleAttribute() and
DirectGetStringAttribute().
* New: In Hurricane, in PyHurricane.h, new macro DirectGetNameAttribute()
to build accessors for method returning a Name.
* New: In Hurricane, in PyHurricane.h, new macro DirectSetIntAttribute()
to build modificators taking int arguments.
* Bug: In Hurricane, in PyHurricane.h, in macro DirectSetBoolAttribute(),
the check for a boolean PyObject was wrong, leading the macro to
systematically emit a Python exception.
* Bug: In Hurricane, in PyInstance method table, PyLibrary_create() was
registered as a NOARGS function, but it *do* have arguments, change
to VARARGS.
2016-05-01 08:50:27 -05:00
__cs . init ( " Instance.create " ) ;
if ( not PyArg_ParseTuple ( args , " O&O&O&|O&:Instance.create "
, Converter , & arg0
, Converter , & arg1
, Converter , & arg2
, Converter , & arg3
) ) {
PyErr_SetString ( ConstructorError , " Instance.create(): Invalid number of parameters. " ) ;
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
return NULL ;
}
Corrections in C-Python interface required by Analagic (CHAMS).
* Change: In Hurricane, in PyHurricane.h, in all DirectSet*() macros,
suppress the third parameter giving the function name. It is now
build from stringification of other parameters.
The various macros calls are also modificated all througout
Isobar.
Added PyAny_AsInt() to convert a Python Int or Long into an int.
Maybe we should manage only long, because the type difference seems
ambiguous in Python itself.
* Change: In Hurricane, in PyHurricane.h, in DirectGetBoolAttribute()
deduce the function name to display in messages from the arguments.
Idem for DirectIsAFromCStringAttribute(), DirectGetIntAttribute(),
DirectGetUIntAttribute(), DirectGetDoubleAttribute() and
DirectGetStringAttribute().
* New: In Hurricane, in PyHurricane.h, new macro DirectGetNameAttribute()
to build accessors for method returning a Name.
* New: In Hurricane, in PyHurricane.h, new macro DirectSetIntAttribute()
to build modificators taking int arguments.
* Bug: In Hurricane, in PyHurricane.h, in macro DirectSetBoolAttribute(),
the check for a boolean PyObject was wrong, leading the macro to
systematically emit a Python exception.
* Bug: In Hurricane, in PyInstance method table, PyLibrary_create() was
registered as a NOARGS function, but it *do* have arguments, change
to VARARGS.
2016-05-01 08:50:27 -05:00
if ( __cs . getObjectIds ( ) = = " :ent:string:ent " ) {
instance = Instance : : create ( PYCELL_O ( arg0 )
, Name ( PyString_AsString ( arg1 ) )
, PYCELL_O ( arg2 )
) ;
} else if ( __cs . getObjectIds ( ) = = " :ent:string:ent:transfo " ) {
instance = Instance : : create ( PYCELL_O ( arg0 )
, Name ( PyString_AsString ( arg1 ) )
, PYCELL_O ( arg2 )
, * PYTRANSFORMATION_O ( arg3 )
, Instance : : PlacementStatus : : PLACED
) ;
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
} else {
Corrections in C-Python interface required by Analagic (CHAMS).
* Change: In Hurricane, in PyHurricane.h, in all DirectSet*() macros,
suppress the third parameter giving the function name. It is now
build from stringification of other parameters.
The various macros calls are also modificated all througout
Isobar.
Added PyAny_AsInt() to convert a Python Int or Long into an int.
Maybe we should manage only long, because the type difference seems
ambiguous in Python itself.
* Change: In Hurricane, in PyHurricane.h, in DirectGetBoolAttribute()
deduce the function name to display in messages from the arguments.
Idem for DirectIsAFromCStringAttribute(), DirectGetIntAttribute(),
DirectGetUIntAttribute(), DirectGetDoubleAttribute() and
DirectGetStringAttribute().
* New: In Hurricane, in PyHurricane.h, new macro DirectGetNameAttribute()
to build accessors for method returning a Name.
* New: In Hurricane, in PyHurricane.h, new macro DirectSetIntAttribute()
to build modificators taking int arguments.
* Bug: In Hurricane, in PyHurricane.h, in macro DirectSetBoolAttribute(),
the check for a boolean PyObject was wrong, leading the macro to
systematically emit a Python exception.
* Bug: In Hurricane, in PyInstance method table, PyLibrary_create() was
registered as a NOARGS function, but it *do* have arguments, change
to VARARGS.
2016-05-01 08:50:27 -05:00
PyErr_SetString ( ConstructorError , " Instance.create(): Bad type of parameter(s). " ) ;
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
return NULL ;
}
HCATCH
Corrections in C-Python interface required by Analagic (CHAMS).
* Change: In Hurricane, in PyHurricane.h, in all DirectSet*() macros,
suppress the third parameter giving the function name. It is now
build from stringification of other parameters.
The various macros calls are also modificated all througout
Isobar.
Added PyAny_AsInt() to convert a Python Int or Long into an int.
Maybe we should manage only long, because the type difference seems
ambiguous in Python itself.
* Change: In Hurricane, in PyHurricane.h, in DirectGetBoolAttribute()
deduce the function name to display in messages from the arguments.
Idem for DirectIsAFromCStringAttribute(), DirectGetIntAttribute(),
DirectGetUIntAttribute(), DirectGetDoubleAttribute() and
DirectGetStringAttribute().
* New: In Hurricane, in PyHurricane.h, new macro DirectGetNameAttribute()
to build accessors for method returning a Name.
* New: In Hurricane, in PyHurricane.h, new macro DirectSetIntAttribute()
to build modificators taking int arguments.
* Bug: In Hurricane, in PyHurricane.h, in macro DirectSetBoolAttribute(),
the check for a boolean PyObject was wrong, leading the macro to
systematically emit a Python exception.
* Bug: In Hurricane, in PyInstance method table, PyLibrary_create() was
registered as a NOARGS function, but it *do* have arguments, change
to VARARGS.
2016-05-01 08:50:27 -05:00
return PyInstance_Link ( instance ) ;
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
}
2008-03-06 10:46:43 -06:00
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getMasterCell ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getMasterCell () " < < endl ;
2008-03-06 10:46:43 -06:00
Cell * cell = NULL ;
HTRY
2008-03-17 08:54:33 -05:00
METHOD_HEAD ( " Instance.getMasterCell() " )
cell = instance - > getMasterCell ( ) ;
2008-03-06 10:46:43 -06:00
HCATCH
return PyCell_Link ( cell ) ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getPlacementStatus ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getPlacementStatus () " < < endl ;
2008-03-06 10:46:43 -06:00
2008-03-17 08:54:33 -05:00
METHOD_HEAD ( " Instance.getPlacementStatus() " ) ;
2008-03-06 10:46:43 -06:00
PyObject * pyObject = NULL ;
HTRY
Correction in plugins to support msxlib compatible pads.
* New: In CRL Core, in helpers & alliance.conf, set and read a "PAD"
variable to define the pad model name extension ("px" for "sxlib
and "pxr" for vsxlib, this is provisional).
* New: In CRL Core, in plugin.conf, add parameters to define the name
of used for power & clock supply. We may remove the extention in
the future (to be more coherent with the previous modification).
* New: In Cumulus, in chip.Configuration.GaugeConf._rpAccess(), no
longer place the accessing contact *at the center* of the
RoutingPad. It works under sxlib because buffers & registers all
have same size terminals. But this is not true under vsxlib,
leading to misaligned contacts & wires. Now systematically place
on the slice midlle track (maybe with one pitch above or below).
This is still very weak as we do not check if the terminal
reach were the contact is being put. Has to be strenthened in
the future.
* New: In Cumulus, in chip.Configuration.ChipConf, read the new
clock & power pad parameters.
* Change: In Isobar (and all other Python wrappers), uses PyLong instead
of PyInt for DbU conversions. In PyHurricane argument converter,
automatically check for both PyLong and then PyInt.
* Change: In Cumulus, in chip.PadsCorona, more accurate error message
in case of discrepency in global net connections (i.e. no net
of the same name in instance model and instance model owner.
* Change: In Kite, in BuildPowerRails, when looking up at the pads
model name to find "pck_" or "pvddeck_", do not compare the
extension part. But we still use hard-coded stem pad names,
maybe we shouldn't.
* Bug: In Katabatic, in GCellConfiguration::_do_xG_xM1_xM3(), there
was a loop in the search of the best N/E initial RoutingPad.
* Bug: In Kite, in KiteEngine::protectRoutingPads(), *do not* protect
RoutingPads of fixed nets, they are already through the
BuildPowerRails stage (and it's causing scary overlap warning
messages).
* Bug: In Cumulus, in ClockTree.HTreeNode.addLeaf(), do not create
deep-plug when the core is flat (not sub-modules). All the new
nets are at core level.
* Bug: In Cumulus, in ChipPlugin.PlaceCore.doFloorplan(), ensure
that the core is aligned on the GCell grid (i.e. the slice
grid of the overall chip).
* Bug: In Kite, in GCellTopology::_do_xG_xM1_xM3(), infinite loop
while looking for the bigger N-E RoutingPad. Forgot to decrement
the index...
2014-09-13 10:45:30 -05:00
pyObject = ( PyObject * ) PyLong_FromLong ( ( long ) instance - > getPlacementStatus ( ) . getCode ( ) ) ;
2008-03-06 10:46:43 -06:00
HCATCH
return pyObject ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_setPlacementStatus ( PyInstance * self , PyObject * args )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_setPlacementStatus() " < < endl ;
2008-03-25 06:06:05 -05:00
METHOD_HEAD ( " Instance.setPlacementStatus() " )
2008-03-06 10:46:43 -06:00
HTRY
PyObject * arg0 ;
2008-03-25 06:06:05 -05:00
if ( ! ParseOneArg ( " Instance.setPlacementStatus() " , args , INT_ARG , ( PyObject * * ) & arg0 ) ) return ( NULL ) ;
2008-03-06 10:46:43 -06:00
2008-03-25 06:06:05 -05:00
instance - > setPlacementStatus ( PyInt_AsPlacementStatus ( arg0 ) ) ;
2008-03-06 10:46:43 -06:00
HCATCH
Py_RETURN_NONE ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getTransformation ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getTransformation () " < < endl ;
2008-03-17 08:54:33 -05:00
METHOD_HEAD ( " Instance.getTransformation() " ) ;
2008-03-06 10:46:43 -06:00
PyTransformation * resultPyTransf = PyObject_NEW ( PyTransformation , & PyTypeTransformation ) ;
if ( resultPyTransf = = NULL ) { return NULL ; }
HTRY
2008-03-17 08:54:33 -05:00
resultPyTransf - > _object = new Transformation ( instance - > getTransformation ( ) ) ;
2008-03-06 10:46:43 -06:00
HCATCH
return ( ( PyObject * ) resultPyTransf ) ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getPlug ( PyInstance * self , PyObject * args )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getPlug () " < < endl ;
2008-03-06 10:46:43 -06:00
Plug * plug = NULL ;
HTRY
2008-03-17 08:54:33 -05:00
METHOD_HEAD ( " Instance.getPlug() " )
2008-03-06 10:46:43 -06:00
PyNet * masterNet ;
2008-03-17 08:54:33 -05:00
if ( ! ParseOneArg ( " Instance.getPlug " , args , NET_ARG , ( PyObject * * ) & masterNet ) ) return ( NULL ) ;
2008-03-06 10:46:43 -06:00
2008-03-17 08:54:33 -05:00
plug = instance - > getPlug ( PYNET_O ( masterNet ) ) ;
2008-03-06 10:46:43 -06:00
HCATCH
return PyPlug_Link ( plug ) ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getPlugs ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getPlugs() " < < endl ;
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
METHOD_HEAD ( " Instance.getPlugs() " )
PyPlugCollection * pyPlugCollection = NULL ;
2008-03-06 10:46:43 -06:00
HTRY
2008-10-17 12:27:20 -05:00
Plugs * plugs = new Plugs ( instance - > getPlugs ( ) ) ;
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
pyPlugCollection = PyObject_NEW ( PyPlugCollection , & PyTypePlugCollection ) ;
if ( pyPlugCollection = = NULL ) {
return NULL ;
}
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
pyPlugCollection - > _object = plugs ;
HCATCH
return ( PyObject * ) pyPlugCollection ;
2008-03-06 10:46:43 -06:00
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getConnectedPlugs ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getConnectedPlugs () " < < endl ;
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
METHOD_HEAD ( " Instance.getConnectedPlugs() " )
PyPlugCollection * pyPlugCollection = NULL ;
2008-03-06 10:46:43 -06:00
HTRY
2008-10-17 12:27:20 -05:00
Plugs * plugs = new Plugs ( instance - > getConnectedPlugs ( ) ) ;
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
pyPlugCollection = PyObject_NEW ( PyPlugCollection , & PyTypePlugCollection ) ;
if ( pyPlugCollection = = NULL ) {
return NULL ;
}
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
pyPlugCollection - > _object = plugs ;
HCATCH
return ( PyObject * ) pyPlugCollection ;
2008-03-06 10:46:43 -06:00
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getUnconnectedPlugs ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getUnconnectedPlugs () " < < endl ;
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
METHOD_HEAD ( " Instance.getUnconnectedPlugs() " )
PyPlugCollection * pyPlugCollection = NULL ;
2008-03-06 10:46:43 -06:00
HTRY
2008-10-17 12:27:20 -05:00
Plugs * plugs = new Plugs ( instance - > getUnconnectedPlugs ( ) ) ;
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
pyPlugCollection = PyObject_NEW ( PyPlugCollection , & PyTypePlugCollection ) ;
if ( pyPlugCollection = = NULL ) {
return NULL ;
}
2008-03-06 10:46:43 -06:00
2008-10-17 12:27:20 -05:00
pyPlugCollection - > _object = plugs ;
HCATCH
return ( PyObject * ) pyPlugCollection ;
2008-03-06 10:46:43 -06:00
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getAbutmentBox ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getAbutmentBox () " < < endl ;
2008-03-17 08:54:33 -05:00
METHOD_HEAD ( " Instance.getAbutmentBox() " )
2008-03-06 10:46:43 -06:00
PyBox * pyBox = PyObject_NEW ( PyBox , & PyTypeBox ) ;
if ( pyBox = = NULL ) { return NULL ; }
HTRY
2008-03-17 08:54:33 -05:00
pyBox - > _object = new Box ( instance - > getAbutmentBox ( ) ) ;
2008-03-06 10:46:43 -06:00
HCATCH
return ( ( PyObject * ) pyBox ) ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_uniquify ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_uniquify () " < < endl ;
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
HTRY
METHOD_HEAD ( " Instance.uniquify() " )
instance - > uniquify ( ) ;
HCATCH
Py_RETURN_NONE ;
}
2008-03-06 10:46:43 -06:00
Merged QuadTrees in overlayed Cells (placed together).
* New: In Hurricane, in Cell & Instance, add the ability to merge the
QuadTree when *second level* instances of a Cell are placed in
the same space as the top Cell. This is the case of a deeply
hierarchical design made of only standard cells that are to
be placed in a "flat" manner.
The design is uniquified then the intermediate instances models,
which should be unique at that point have their QuadTree merged
through a call to Instance::slaveAbutmentBox(). That method will
make the model of the instance use the QuadTree of the Cell to
which the instance belong. The instance model no longer posseses
a dedicated QuadTree. As a corollary the abutment box of both
Cell are kept identical and the Instance has it's transformation
set to (0,0,ID).
Remark: when we talk about "QuadTree", we mean in fact the
QuadTree for the instances *and* the SliceMap (Layer+QuadTree).
Consequence in Query: when going through the resulting
"flattened" QuadTree we will find objects with an incomplete
Path du to the fact that we didn't have to explore their
Instance/Cell level to reach them. The shunted part of the
Path is stored in the Go master Cell in the _shuntedPath
attribute. This also affect the displayed depth of hierarchy,
but not too badly.
* New: In Hurricane, in Cell, new methods:
- Cell::updatePlacedFlag() : set the placement flags.
- Cell::isUnique() : one or less instance.
- Cell::isUniquified() : is the result of an uniquification.
- Cell::isUniquifyMaster() : is the reference cell of the
uniquification.
* Change: In Hurricane, in Cell::Uniquify(), uniquify a Cell only
if it is unplaced. We do not need to duplicate placed Cells
(see datapathes).
2015-06-26 11:35:11 -05:00
static PyObject * PyInstance_slaveAbutmentBox ( PyInstance * self )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_slaveAbutmentBox () " < < endl ;
Merged QuadTrees in overlayed Cells (placed together).
* New: In Hurricane, in Cell & Instance, add the ability to merge the
QuadTree when *second level* instances of a Cell are placed in
the same space as the top Cell. This is the case of a deeply
hierarchical design made of only standard cells that are to
be placed in a "flat" manner.
The design is uniquified then the intermediate instances models,
which should be unique at that point have their QuadTree merged
through a call to Instance::slaveAbutmentBox(). That method will
make the model of the instance use the QuadTree of the Cell to
which the instance belong. The instance model no longer posseses
a dedicated QuadTree. As a corollary the abutment box of both
Cell are kept identical and the Instance has it's transformation
set to (0,0,ID).
Remark: when we talk about "QuadTree", we mean in fact the
QuadTree for the instances *and* the SliceMap (Layer+QuadTree).
Consequence in Query: when going through the resulting
"flattened" QuadTree we will find objects with an incomplete
Path du to the fact that we didn't have to explore their
Instance/Cell level to reach them. The shunted part of the
Path is stored in the Go master Cell in the _shuntedPath
attribute. This also affect the displayed depth of hierarchy,
but not too badly.
* New: In Hurricane, in Cell, new methods:
- Cell::updatePlacedFlag() : set the placement flags.
- Cell::isUnique() : one or less instance.
- Cell::isUniquified() : is the result of an uniquification.
- Cell::isUniquifyMaster() : is the reference cell of the
uniquification.
* Change: In Hurricane, in Cell::Uniquify(), uniquify a Cell only
if it is unplaced. We do not need to duplicate placed Cells
(see datapathes).
2015-06-26 11:35:11 -05:00
METHOD_HEAD ( " Instance.slaveAbutmentBox() " )
HTRY
instance - > slaveAbutmentBox ( ) ;
HCATCH
Py_RETURN_NONE ;
}
2008-03-06 10:46:43 -06:00
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_getClone ( PyInstance * self , PyObject * args )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_getClone () " < < endl ;
2008-03-06 10:46:43 -06:00
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
Instance * cloneInstance = NULL ;
HTRY
METHOD_HEAD ( " Instance.getClone() " )
PyCell * pyCloneCell ;
if ( PyArg_ParseTuple ( args , " O!:Instance.getClone " , & PyTypeCell , & pyCloneCell ) ) {
cloneInstance = instance - > getClone ( PYCELL_O ( pyCloneCell ) ) ;
} else {
PyErr_SetString ( ConstructorError , " Instance.getClone(): invalid number/bad type of parameter(s). " ) ;
return NULL ;
}
HCATCH
2008-03-06 10:46:43 -06:00
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
return PyInstance_Link ( cloneInstance ) ;
}
2008-03-06 10:46:43 -06:00
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
SetNameMethod ( Instance , instance )
2008-03-06 10:46:43 -06:00
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_setTransformation ( PyInstance * self , PyObject * args )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " PyInstance_setTransformation() " < < endl ;
2008-03-25 06:06:05 -05:00
METHOD_HEAD ( " Instance.setTransformation() " )
2008-03-06 10:46:43 -06:00
HTRY
PyTransformation * transformation ;
2008-03-25 06:06:05 -05:00
if ( ! ParseOneArg ( " Instance.setTransformation " , args , TRANS_ARG , ( PyObject * * ) & transformation ) ) return ( NULL ) ;
2008-03-06 10:46:43 -06:00
2008-03-25 06:06:05 -05:00
instance - > setTransformation ( * PYTRANSFORMATION_O ( transformation ) ) ;
2008-03-06 10:46:43 -06:00
HCATCH
Py_RETURN_NONE ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
static PyObject * PyInstance_setMasterCell ( PyInstance * self , PyObject * args )
{
2016-05-17 16:00:06 -05:00
cdebug . log ( 20 ) < < " Instance.setMasterCell() " < < endl ;
2008-03-25 06:06:05 -05:00
METHOD_HEAD ( " Instance.setMasterCell() " )
2008-03-06 10:46:43 -06:00
HTRY
PyCell * masterCell ;
2008-03-25 06:06:05 -05:00
if ( ! ParseOneArg ( " Instance.setMasterCell " , args , CELL_ARG , ( PyObject * * ) & masterCell ) ) return ( NULL ) ;
2008-03-06 10:46:43 -06:00
2008-03-25 06:06:05 -05:00
instance - > setMasterCell ( PYCELL_O ( masterCell ) ) ;
2008-03-06 10:46:43 -06:00
HCATCH
Py_RETURN_NONE ;
}
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
2008-03-06 10:46:43 -06:00
// Standart Predicates (Attributes).
2008-03-25 06:06:05 -05:00
DirectGetBoolAttribute ( PyInstance_isTerminal , isTerminal , PyInstance , Instance )
DirectGetBoolAttribute ( PyInstance_isLeaf , isLeaf , PyInstance , Instance )
2008-03-06 10:46:43 -06:00
2008-03-25 06:06:05 -05:00
GetBoundStateAttribute ( PyInstance_isPyBound , PyInstance , Instance )
2008-03-06 10:46:43 -06:00
// ---------------------------------------------------------------
// PyInstance Attribute Method table.
PyMethodDef PyInstance_Methods [ ] =
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
{ { " create " , ( PyCFunction ) PyInstance_create , METH_VARARGS | METH_STATIC
, " Create a new Instance. " }
, { " getName " , ( PyCFunction ) PyInstance_getName , METH_NOARGS , " Returns the instance name. " }
2008-03-17 08:54:33 -05:00
, { " getMasterCell " , ( PyCFunction ) PyInstance_getMasterCell , METH_NOARGS , " Returns the cell model referenced by the instance. " }
, { " getTransformation " , ( PyCFunction ) PyInstance_getTransformation , METH_NOARGS , " Returns the transformation associated to the instance. " }
, { " getPlacementStatus " , ( PyCFunction ) PyInstance_getPlacementStatus , METH_NOARGS , " Returns the placement status of the instance. " }
, { " getPlug " , ( PyCFunction ) PyInstance_getPlug , METH_VARARGS , " Returns the plug associated to the <masterNet> if it exists or else NULL (if the net is not external). " }
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
, { " getPlugs " , ( PyCFunction ) PyInstance_getPlugs , METH_NOARGS , " Returns the collection of instance plugs. " }
, { " getConnectedPlugs " , ( PyCFunction ) PyInstance_getConnectedPlugs , METH_NOARGS , " Returns the collection of instance plugs which are effectively connected. " }
, { " getUnconnectedPlugs " , ( PyCFunction ) PyInstance_getUnconnectedPlugs , METH_NOARGS , " Returns the collection of instance plugs which are not connected. " }
2008-03-17 08:54:33 -05:00
, { " getAbutmentBox " , ( PyCFunction ) PyInstance_getAbutmentBox , METH_NOARGS , " Returns the abutment box of the instance, that is the abutment box of the master cell to which has been applied the instance transformation. " }
2008-03-25 06:06:05 -05:00
, { " isTerminal " , ( PyCFunction ) PyInstance_isTerminal , METH_NOARGS , " Returns true if the instance is a terminal instance. " }
, { " isLeaf " , ( PyCFunction ) PyInstance_isLeaf , METH_NOARGS , " Returns true if the instance is a leaf instance. " }
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
, { " isBound " , ( PyCFunction ) PyInstance_isPyBound , METH_NOARGS , " Returns true if the instance is bounded to the hurricane instance " }
2008-03-25 06:06:05 -05:00
, { " setName " , ( PyCFunction ) PyInstance_setName , METH_VARARGS , " Allows to change the instance name. " }
, { " setTransformation " , ( PyCFunction ) PyInstance_setTransformation , METH_VARARGS , " Allows to modify the instance transformation. " }
, { " setPlacementStatus " , ( PyCFunction ) PyInstance_setPlacementStatus , METH_VARARGS , " Allows to modify the instance placement status. " }
, { " setMasterCell " , ( PyCFunction ) PyInstance_setMasterCell , METH_VARARGS , " Allows to change the cell referenced by this instance. " }
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
, { " uniquify " , ( PyCFunction ) PyInstance_uniquify , METH_NOARGS , " Uniquify the Instance (clone it's master Cell). " }
Merged QuadTrees in overlayed Cells (placed together).
* New: In Hurricane, in Cell & Instance, add the ability to merge the
QuadTree when *second level* instances of a Cell are placed in
the same space as the top Cell. This is the case of a deeply
hierarchical design made of only standard cells that are to
be placed in a "flat" manner.
The design is uniquified then the intermediate instances models,
which should be unique at that point have their QuadTree merged
through a call to Instance::slaveAbutmentBox(). That method will
make the model of the instance use the QuadTree of the Cell to
which the instance belong. The instance model no longer posseses
a dedicated QuadTree. As a corollary the abutment box of both
Cell are kept identical and the Instance has it's transformation
set to (0,0,ID).
Remark: when we talk about "QuadTree", we mean in fact the
QuadTree for the instances *and* the SliceMap (Layer+QuadTree).
Consequence in Query: when going through the resulting
"flattened" QuadTree we will find objects with an incomplete
Path du to the fact that we didn't have to explore their
Instance/Cell level to reach them. The shunted part of the
Path is stored in the Go master Cell in the _shuntedPath
attribute. This also affect the displayed depth of hierarchy,
but not too badly.
* New: In Hurricane, in Cell, new methods:
- Cell::updatePlacedFlag() : set the placement flags.
- Cell::isUnique() : one or less instance.
- Cell::isUniquified() : is the result of an uniquification.
- Cell::isUniquifyMaster() : is the reference cell of the
uniquification.
* Change: In Hurricane, in Cell::Uniquify(), uniquify a Cell only
if it is unplaced. We do not need to duplicate placed Cells
(see datapathes).
2015-06-26 11:35:11 -05:00
, { " slaveAbutmentBox " , ( PyCFunction ) PyInstance_slaveAbutmentBox , METH_NOARGS , " Bind instance's master Cell and owner Cell together. " }
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
, { " getClone " , ( PyCFunction ) PyInstance_getClone , METH_VARARGS , " Create a clone of this Instance into the cloned Cell (placement only). " }
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
, { " destroy " , ( PyCFunction ) PyInstance_destroy , METH_NOARGS , " Destroy associated hurricane object The python object remains. " }
2008-03-06 10:46:43 -06:00
, { NULL , NULL , 0 , NULL } /* sentinel */
} ;
2009-09-30 10:11:49 -05:00
DBoDeleteMethod ( Instance )
PyTypeObjectLinkPyType ( Instance )
# else // End of Python Module Code Part.
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
// +=================================================================+
2009-09-30 10:11:49 -05:00
// | "PyInstance" Shared Library Code Part |
Support for Uniquification. Rewrite of the Blif parser.
* New: In Hurricane, In NetAlias & Net, add an AliasList collection to
iterate over all the aliases names (this *not* include the main
net name).
* New: In Hurricane, In Cell, Instance & Net add support for cloning and
uniquification (update documentation).
All Cells that are uniquified from a given model are kept in an
Uniquify relation. This relation allows to get all the clones and
generate unique clone names by adding a "_uXX" suffix.
* Bug: In Hurricane, the Cell::_isFlattenLeaf attribute was not initialized
in the constructor.
* Change: In CRL Core, in AllianceFramework::getCell(), no longer destroy
a partially loaded Cell in case of parser failure, let the incomplete
Cell be.
* New: In CRL Core, in ApParser, if all the instances are placed, sets the
Cell::Placed flag.
* Change: In CRL Core, in BlifParser, complete rewrite of the parser.
Not so good an idea afterwards...
* New: In Etesian, uniquify the design before placing.
* Change: In Kite, display the list of unrouted wired after all other
statistics.
2015-04-25 09:52:18 -05:00
// +=================================================================+
2008-03-06 10:46:43 -06:00
// Link/Creation Method.
2008-10-12 08:37:33 -05:00
DBoLinkCreateMethod ( Instance )
2008-03-06 10:46:43 -06:00
2009-09-30 10:11:49 -05:00
PyTypeInheritedObjectDefinitions ( Instance , Entity )
2008-03-06 10:46:43 -06:00
Make the Python interface closely mirroring the C++ one.
* Change: In Isobar, the Python interface was not exactly mirroring the
C++ one, now it is the case. The Python code should look likes almost
exactly like the C++ one, the only differences remaining being due
to the languages respective syntaxes. Note that in the case of
constructor functions, it leads to a slightly longer notation in
Python that it could have been (mimic the ".create()" static
member). Main modifications:
1. Mirror the static constructor syntax with create():
Cell( ... ) ==> Cell.create( ... )
2. Correct hierarchy for constants in Instance, Net, Pin
& Transformation. For example:
Hurricane.PlacementStatusFIXED
==> Hurricane.Instance.PlacementStatus.FIXED
Hurricane.OrientationID
==> Hurricane.Transformation.Orientation.ID
Hurricane.TypeLOGICAL ==> Hurricane.Net.Type.LOGICAL
Hurricane.DirectionIN ==> Hurricane.Net.Direction.IN
* Change: In CRL Core, correction to match the improved Python API
in the configutation helpers.
* Change: In Cumulus, correction to match the improved Python API.
* Change: In Stratus, correction to match the improved Python API.
* Change: In Documenation, update for the new Python interface
(both user's guide & examples).
* Note: We must port those changes into Chams for it to continue
to run.
* Change: In Documenation, update the Python script support part.
2014-06-28 10:37:59 -05:00
extern void PyInstance_postModuleInit ( )
{
PyPlacementStatus_postModuleInit ( ) ;
PyDict_SetItemString ( PyTypeInstance . tp_dict , " PlacementStatus " , ( PyObject * ) & PyTypePlacementStatus ) ;
}
2008-10-12 08:37:33 -05:00
# endif // End of Shared Library Code Part.
2008-03-06 10:46:43 -06:00
} // End of extern "C".
} // End of Isobar namespace.