From 3c9f7d2bc8180462635eda6e1c7ae5b4208f2078 Mon Sep 17 00:00:00 2001 From: Alan Mishchenko Date: Sun, 8 Nov 2015 19:59:34 -0800 Subject: Extending and improving timing manager. --- src/map/mio/mioUtils.c | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) (limited to 'src/map/mio/mioUtils.c') diff --git a/src/map/mio/mioUtils.c b/src/map/mio/mioUtils.c index 16a5502f..623b7c84 100644 --- a/src/map/mio/mioUtils.c +++ b/src/map/mio/mioUtils.c @@ -22,6 +22,7 @@ #include "exp.h" #include "misc/util/utilTruth.h" #include "opt/dau/dau.h" +#include "map/scl/sclLib.h" ABC_NAMESPACE_IMPL_START @@ -1305,6 +1306,45 @@ void Nf_ManPrepareLibraryTest2() } +/**Function************************************************************* + + Synopsis [Install library.] + + Description [] + + SideEffects [] + + SeeAlso [] + +***********************************************************************/ +void Mio_LibraryTransferCellIds() +{ + Mio_Gate_t * pGate; + Mio_Library_t * pLib = (Mio_Library_t *)Abc_FrameReadLibGen(); + SC_Lib * pScl = (SC_Lib *)Abc_FrameReadLibScl(); + int CellId; + if ( pScl == NULL ) + { + printf( "SC library cannot be found.\n" ); + return; + } + if ( pLib == NULL ) + { + printf( "Genlib library cannot be found.\n" ); + return; + } + Mio_LibraryForEachGate( pLib, pGate ) + { + if ( Mio_GateReadPinNum(pGate) == 0 ) + continue; + CellId = Abc_SclCellFind( pScl, Mio_GateReadName(pGate) ); + if ( CellId < 0 ) + printf( "Cannot find cell ID of gate %s.\n", Mio_GateReadName(pGate) ); + else + Mio_GateSetCell( pGate, CellId ); + } +} + //////////////////////////////////////////////////////////////////////// /// END OF FILE /// -- cgit v1.2.3