diff options
Diffstat (limited to 'src/base')
-rw-r--r-- | src/base/abci/abcMap.c | 15 | ||||
-rw-r--r-- | src/base/abci/abcPrint.c | 1 | ||||
-rw-r--r-- | src/base/io/io.c | 2 | ||||
-rw-r--r-- | src/base/ver/verCore.c | 3 |
4 files changed, 17 insertions, 4 deletions
diff --git a/src/base/abci/abcMap.c b/src/base/abci/abcMap.c index 23ac50fe..b88ff703 100644 --- a/src/base/abci/abcMap.c +++ b/src/base/abci/abcMap.c @@ -66,13 +66,18 @@ Abc_Ntk_t * Abc_NtkMap( Abc_Ntk_t * pNtk, double DelayTarget, double AreaMulti, Vec_Int_t * vSwitching = NULL; float * pSwitching = NULL; abctime clk, clkTotal = Abc_Clock(); - Mio_Library_t * pLib; + Mio_Library_t * pLib = (Mio_Library_t *)Abc_FrameReadLibGen(); + assert( Abc_NtkIsStrash(pNtk) ); // derive library from SCL + // if the library is created here, it will be deleted when pSuperLib is deleted in Map_SuperLibFree() if ( Abc_FrameReadLibScl() ) - Abc_SclDeriveGenlib( Abc_FrameReadLibScl(), Slew, Gain, nGatesMin ); + { + pLib = Abc_SclDeriveGenlib( Abc_FrameReadLibScl(), Slew, Gain, nGatesMin ); + if ( Abc_FrameReadLibGen() ) + Mio_LibraryTransferDelays( (Mio_Library_t *)Abc_FrameReadLibGen(), pLib ); + } // quit if there is no library - pLib = (Mio_Library_t *)Abc_FrameReadLibGen(); if ( pLib == NULL ) { printf( "The current library is not available.\n" ); @@ -423,6 +428,7 @@ Abc_Obj_t * Abc_NodeFromMapPhase_rec( Abc_Ntk_t * pNtkNew, Map_Node_t * pNodeMap ***********************************************************************/ Abc_Obj_t * Abc_NodeFromMapSuper_rec( Abc_Ntk_t * pNtkNew, Map_Node_t * pNodeMap, Map_Super_t * pSuper, Abc_Obj_t * pNodePis[], int nNodePis ) { + Mio_Library_t * pLib = (Mio_Library_t *)Abc_FrameReadLibGen(); Mio_Gate_t * pRoot; Map_Super_t ** ppFanins; Abc_Obj_t * pNodeNew, * pNodeFanin; @@ -449,6 +455,7 @@ Abc_Obj_t * Abc_NodeFromMapSuper_rec( Abc_Ntk_t * pNtkNew, Map_Node_t * pNodeMap return Abc_NtkCreateNodeConst0(pNtkNew); } } + pRoot = Mio_LibraryReadGateByName( pLib, Mio_GateReadName(pRoot), NULL ); // get information about the fanins of the supergate nFanins = Map_SuperReadFaninNum( pSuper ); @@ -685,6 +692,7 @@ void Abc_NodeFromMapCutPhase( Abc_Ntk_t * pNtkNew, Map_Cut_t * pCut, int fPhase ***********************************************************************/ Abc_Obj_t * Abc_NodeFromMapSuperChoice_rec( Abc_Ntk_t * pNtkNew, Map_Super_t * pSuper, Abc_Obj_t * pNodePis[], int nNodePis ) { + Mio_Library_t * pLib = (Mio_Library_t *)Abc_FrameReadLibGen(); Mio_Gate_t * pRoot; Map_Super_t ** ppFanins; Abc_Obj_t * pNodeNew, * pNodeFanin; @@ -711,6 +719,7 @@ Abc_Obj_t * Abc_NodeFromMapSuperChoice_rec( Abc_Ntk_t * pNtkNew, Map_Super_t * p return Abc_NtkCreateNodeConst0(pNtkNew); } } + pRoot = Mio_LibraryReadGateByName( pLib, Mio_GateReadName(pRoot), NULL ); // get information about the fanins of the supergate nFanins = Map_SuperReadFaninNum( pSuper ); diff --git a/src/base/abci/abcPrint.c b/src/base/abci/abcPrint.c index 8e2f5606..907a7cd2 100644 --- a/src/base/abci/abcPrint.c +++ b/src/base/abci/abcPrint.c @@ -265,6 +265,7 @@ void Abc_NtkPrintStats( Abc_Ntk_t * pNtk, int fFactored, int fSaveBest, int fDum Abc_Print( 1," bdd =%6d", Abc_NtkGetBddNodeNum(pNtk) - nSingles ); else if ( Abc_NtkHasMapping(pNtk) ) { + assert( pNtk->pManFunc == Abc_FrameReadLibGen() ); Abc_Print( 1," area =%5.2f", Abc_NtkGetMappedArea(pNtk) ); Abc_Print( 1," delay =%5.2f", Abc_NtkDelayTrace(pNtk, NULL, NULL, 0) ); } diff --git a/src/base/io/io.c b/src/base/io/io.c index b472dac5..f6780131 100644 --- a/src/base/io/io.c +++ b/src/base/io/io.c @@ -205,7 +205,7 @@ int IoCommandRead( Abc_Frame_t * pAbc, int argc, char ** argv ) if ( !strcmp( Extra_FileNameExtension(pFileName), "genlib" ) ) sprintf( Command, "read_genlib %s", pFileName ); else if ( !strcmp( Extra_FileNameExtension(pFileName), "lib" ) ) - sprintf( Command, "read_liberty %s", pFileName ); + sprintf( Command, "read_lib %s", pFileName ); else if ( !strcmp( Extra_FileNameExtension(pFileName), "scl" ) ) sprintf( Command, "read_scl %s", pFileName ); else if ( !strcmp( Extra_FileNameExtension(pFileName), "super" ) ) diff --git a/src/base/ver/verCore.c b/src/base/ver/verCore.c index 1e103b55..875a16b4 100644 --- a/src/base/ver/verCore.c +++ b/src/base/ver/verCore.c @@ -121,6 +121,9 @@ Ver_Man_t * Ver_ParseStart( char * pFileName, Abc_Lib_t * pGateLib ) // create the design library and assign the technology library p->pDesign = Abc_LibCreate( pFileName ); p->pDesign->pLibrary = pGateLib; + // derive library from SCL +// if ( Abc_FrameReadLibScl() ) +// Abc_SclInstallGenlib( Abc_FrameReadLibScl(), 0, 0, 0 ); p->pDesign->pGenlib = Abc_FrameReadLibGen(); return p; } |