diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2019-04-05 21:08:46 -1000 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2019-04-05 21:08:46 -1000 |
commit | 362b2d9d08f4dbc8dfc751b68ddf7bd3f9c4ed54 (patch) | |
tree | 1b530ec6aaf1242abc6f94022106a547c91381ff /src/base/wln | |
parent | 0739bd7f03eacdb11034d166e5b799f2e59796fc (diff) | |
download | abc-362b2d9d08f4dbc8dfc751b68ddf7bd3f9c4ed54.tar.gz abc-362b2d9d08f4dbc8dfc751b68ddf7bd3f9c4ed54.tar.bz2 abc-362b2d9d08f4dbc8dfc751b68ddf7bd3f9c4ed54.zip |
Supporting LUT in NDR and WLC.
Diffstat (limited to 'src/base/wln')
-rw-r--r-- | src/base/wln/wlnRetime.c | 9 | ||||
-rw-r--r-- | src/base/wln/wlnWriteVer.c | 9 |
2 files changed, 16 insertions, 2 deletions
diff --git a/src/base/wln/wlnRetime.c b/src/base/wln/wlnRetime.c index 7045527c..ff8e0839 100644 --- a/src/base/wln/wlnRetime.c +++ b/src/base/wln/wlnRetime.c @@ -503,12 +503,17 @@ void Wln_NtkRetimeCreateDelayInfo( Wln_Ntk_t * pNtk ) printf( "The design has no delay information.\n" ); Wln_NtkCleanInstId(pNtk); Wln_NtkForEachObj( pNtk, iObj ) - if ( Wln_ObjIsFf(pNtk, iObj) ) + { + if ( Wln_ObjIsFf(pNtk, iObj) || Wln_ObjType(pNtk, iObj) == ABC_OPER_SLICE || Wln_ObjType(pNtk, iObj) == ABC_OPER_CONCAT ) Wln_ObjSetInstId( pNtk, iObj, 1 ); else if ( !Wln_ObjIsCio(pNtk, iObj) && Wln_ObjFaninNum(pNtk, iObj) > 0 ) Wln_ObjSetInstId( pNtk, iObj, 10 ); + } Wln_NtkForEachCo( pNtk, iObj, i ) - Wln_ObjSetInstId( pNtk, Wln_ObjFanin0(pNtk, iObj), 1 ); + { + if ( Wln_ObjType(pNtk, Wln_ObjFanin0(pNtk, iObj)) != ABC_OPER_LUT ) + Wln_ObjSetInstId( pNtk, Wln_ObjFanin0(pNtk, iObj), 1 ); + } printf( "Assuming user-specified delays for internal nodes.\n" ); } } diff --git a/src/base/wln/wlnWriteVer.c b/src/base/wln/wlnWriteVer.c index e0849bf4..e2af56bb 100644 --- a/src/base/wln/wlnWriteVer.c +++ b/src/base/wln/wlnWriteVer.c @@ -184,6 +184,15 @@ void Wln_WriteVerInt( FILE * pFile, Wln_Ntk_t * p ) fprintf( pFile, " s%d_Index(%s, ", iObj, Wln_ObjName(p, Wln_ObjFanin0(p, iObj)) ); fprintf( pFile, "%s)", Wln_ObjName(p, iObj) ); } + else if ( Wln_ObjType(p, iObj) == ABC_OPER_LUT ) + { + // wire [3:0] s4972; LUT lut4972_Index(s4971, s4972); + fprintf( pFile, "%s ; LUT", Wln_ObjName(p, iObj) ); + fprintf( pFile, " lut%d (%s, ", iObj, Wln_ObjName(p, Wln_ObjFanin0(p, iObj)) ); + for ( k = 1; k < Wln_ObjFaninNum(p, iObj); k++ ) + fprintf( pFile, "%s, ", Wln_ObjName(p, Wln_ObjFanin(p, iObj, k)) ); + fprintf( pFile, "%s)", Wln_ObjName(p, iObj) ); + } else if ( Wln_ObjIsConst(p, iObj) ) fprintf( pFile, "%-16s = %s", Wln_ObjName(p, iObj), Wln_ObjConstString(p, iObj) ); else if ( Wln_ObjType(p, iObj) == ABC_OPER_SHIFT_ROTR || Wln_ObjType(p, iObj) == ABC_OPER_SHIFT_ROTL ) |