diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2013-08-12 23:27:20 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2013-08-12 23:27:20 -0700 |
commit | fcfafb06017e50144966cd4d56dfac77123ae03c (patch) | |
tree | 19530feac7ee2d1cd912939dc5d46af3bfd1571b /src/aig/gia | |
parent | ae27704c13b8b964ec5e82d685693a2c782744d0 (diff) | |
download | abc-fcfafb06017e50144966cd4d56dfac77123ae03c.tar.gz abc-fcfafb06017e50144966cd4d56dfac77123ae03c.tar.bz2 abc-fcfafb06017e50144966cd4d56dfac77123ae03c.zip |
Enabling additional matching feature in the LUT mapper.
Diffstat (limited to 'src/aig/gia')
-rw-r--r-- | src/aig/gia/giaIf.c | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/aig/gia/giaIf.c b/src/aig/gia/giaIf.c index 278381cb..583e178a 100644 --- a/src/aig/gia/giaIf.c +++ b/src/aig/gia/giaIf.c @@ -235,6 +235,34 @@ void Gia_ManPrintMappingStats( Gia_Man_t * p ) Abc_Print( 1, "lev =%5d ", LevelMax ); Abc_Print( 1, "mem =%5.2f MB", 4.0*(Gia_ManObjNum(p) + 2*nLuts + nFanins)/(1<<20) ); Abc_Print( 1, "\n" ); + + { + char * pFileName = "stats_map.txt"; + static char FileNameOld[1000] = {0}; + static int nNodesOld, nAreaOld, nDelayOld; + static abctime clk = 0; + FILE * pTable = fopen( pFileName, "a+" ); + if ( strcmp( FileNameOld, p->pName ) ) + { + sprintf( FileNameOld, "%s", p->pName ); + fprintf( pTable, "\n" ); + fprintf( pTable, "%s ", p->pName ); + fprintf( pTable, "%d ", Gia_ManCiNum(p) ); + fprintf( pTable, "%d ", Gia_ManCoNum(p) ); + fprintf( pTable, "%d ", Gia_ManAndNum(p) ); + fprintf( pTable, "%d ", nLuts ); + fprintf( pTable, "%d ", LevelMax ); + clk = Abc_Clock(); + } + else + { + fprintf( pTable, " " ); + fprintf( pTable, "%d ", nLuts ); + fprintf( pTable, "%d ", LevelMax ); +// fprintf( pTable, "%.2f", 1.0*(Abc_Clock() - clk)/CLOCKS_PER_SEC ); + } + fclose( pTable ); + } } /**Function************************************************************* @@ -344,6 +372,7 @@ void Gia_ManChoiceLevel_rec( Gia_Man_t * p, Gia_Obj_t * pObj ) if ( LevelMax < Gia_ObjLevel(p, pNext) ) LevelMax = Gia_ObjLevel(p, pNext); LevelMax++; + assert( LevelMax > 0 ); // get the level of the nodes in the choice node if ( (pNext = Gia_ObjSiblObj(p, Gia_ObjId(p, pObj))) ) |