diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2008-04-22 08:01:00 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2008-04-22 08:01:00 -0700 |
commit | e2e9aed11dd841801dae3cdf47db06946e7ffb28 (patch) | |
tree | 021c72bb7918dd10c3c8de87748c11ed910a2aaa /src/aig/nwk/nwkFlow.c | |
parent | 7ec48bc20de6209f311715f4b1479cb2e0a4d906 (diff) | |
download | abc-e2e9aed11dd841801dae3cdf47db06946e7ffb28.tar.gz abc-e2e9aed11dd841801dae3cdf47db06946e7ffb28.tar.bz2 abc-e2e9aed11dd841801dae3cdf47db06946e7ffb28.zip |
Version abc80422
Diffstat (limited to 'src/aig/nwk/nwkFlow.c')
-rw-r--r-- | src/aig/nwk/nwkFlow.c | 28 |
1 files changed, 18 insertions, 10 deletions
diff --git a/src/aig/nwk/nwkFlow.c b/src/aig/nwk/nwkFlow.c index 3a7e6df6..48496158 100644 --- a/src/aig/nwk/nwkFlow.c +++ b/src/aig/nwk/nwkFlow.c @@ -20,6 +20,14 @@ #include "nwk.h" +/* + This code is based on the papers: + A. Hurst, A. Mishchenko, and R. Brayton, "Fast minimum-register retiming + via binary maximum-flow", Proc. FMCAD '07, pp. 181-187. + A. Hurst, A. Mishchenko, and R. Brayton, "Scalable min-area retiming + under simultaneous delay and initial state constraints". Proc. DAC'08. +*/ + //////////////////////////////////////////////////////////////////////// /// DECLARATIONS /// //////////////////////////////////////////////////////////////////////// @@ -368,7 +376,7 @@ int Nwk_ManVerifyCut_rec( Nwk_Obj_t * pObj ) return 0; return 1; } - + /**Function************************************************************* Synopsis [Verifies the forward cut.] @@ -453,7 +461,7 @@ Vec_Ptr_t * Nwk_ManRetimeCutForward( Nwk_Man_t * pMan, int nLatches, int fVerbos Counter++; } if ( fVerbose ) - printf( "Forward: Max-flow1 = %5d. ", Counter ); + printf( "Forward: Max-flow = %4d -> ", Counter ); // continue flow computation from each LO Nwk_ManIncrementTravIdFlow( pMan ); Nwk_ManForEachLoSeq( pMan, pObj, i ) @@ -464,7 +472,7 @@ Vec_Ptr_t * Nwk_ManRetimeCutForward( Nwk_Man_t * pMan, int nLatches, int fVerbos Counter2++; } if ( fVerbose ) - printf( "Max-flow2 = %5d. ", Counter+Counter2 ); + printf( "%4d. ", Counter+Counter2 ); // repeat flow computation from each LO if ( Counter2 > 0 ) { @@ -489,10 +497,10 @@ Vec_Ptr_t * Nwk_ManRetimeCutForward( Nwk_Man_t * pMan, int nLatches, int fVerbos } } Nwk_ManCleanMarks( pMan ); - assert( Nwk_ManRetimeVerifyCutForward(pMan, vNodes) ); +// assert( Nwk_ManRetimeVerifyCutForward(pMan, vNodes) ); if ( fVerbose ) { - printf( "Min-cut = %5d. Unmoved regs = %5d. ", Vec_PtrSize(vNodes), Counter ); + printf( "Min-cut = %4d. Unmoved = %4d. ", Vec_PtrSize(vNodes), Counter ); PRT( "Time", clock() - clk ); } return vNodes; @@ -536,8 +544,8 @@ Vec_Ptr_t * Nwk_ManRetimeCutBackward( Nwk_Man_t * pMan, int nLatches, int fVerbo Nwk_ManIncrementTravIdFlow( pMan ); Counter++; } - if ( fVerbose ) - printf( "Backward: Max-flow1 = %5d. ", Counter ); + if ( fVerbose ) + printf( "Backward: Max-flow = %4d -> ", Counter ); // continue flow computation from each LI driver Nwk_ManIncrementTravIdFlow( pMan ); Nwk_ManForEachLiSeq( pMan, pObj, i ) @@ -548,7 +556,7 @@ Vec_Ptr_t * Nwk_ManRetimeCutBackward( Nwk_Man_t * pMan, int nLatches, int fVerbo Counter2++; } if ( fVerbose ) - printf( "Max-flow2 = %5d. ", Counter+Counter2 ); + printf( "%4d. ", Counter+Counter2 ); // repeat flow computation from each LI driver if ( Counter2 > 0 ) { @@ -576,10 +584,10 @@ Vec_Ptr_t * Nwk_ManRetimeCutBackward( Nwk_Man_t * pMan, int nLatches, int fVerbo if ( Nwk_ObjVisitedBotOnly( Nwk_ObjFanin0(pObj) ) ) Counter++; Nwk_ManCleanMarks( pMan ); - assert( Nwk_ManRetimeVerifyCutBackward(pMan, vNodes) ); +// assert( Nwk_ManRetimeVerifyCutBackward(pMan, vNodes) ); if ( fVerbose ) { - printf( "Min-cut = %5d. Unmoved regs = %5d. ", Vec_PtrSize(vNodes), Counter ); + printf( "Min-cut = %4d. Unmoved = %4d. ", Vec_PtrSize(vNodes), Counter ); PRT( "Time", clock() - clk ); } return vNodes; |