summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlan Mishchenko <alanmi@berkeley.edu>2012-07-10 13:56:39 -0700
committerAlan Mishchenko <alanmi@berkeley.edu>2012-07-10 13:56:39 -0700
commit448eec77b74eed14d2b2e411537dd6880a517827 (patch)
tree1544ed96b327fd43bfbc29184a28f0e7a22e4f6c
parentdb6e7f97c1404e8a578184de2ac137d3f3b0ea06 (diff)
downloadabc-448eec77b74eed14d2b2e411537dd6880a517827.tar.gz
abc-448eec77b74eed14d2b2e411537dd6880a517827.tar.bz2
abc-448eec77b74eed14d2b2e411537dd6880a517827.zip
Improving print-outs of &vta and &gla.
-rw-r--r--src/aig/gia/giaAbsGla.c17
-rw-r--r--src/aig/gia/giaAbsVta.c19
2 files changed, 27 insertions, 9 deletions
diff --git a/src/aig/gia/giaAbsGla.c b/src/aig/gia/giaAbsGla.c
index 944badc4..33d34170 100644
--- a/src/aig/gia/giaAbsGla.c
+++ b/src/aig/gia/giaAbsGla.c
@@ -142,12 +142,21 @@ static inline void Gla_ObjClearRef( Rfn_Obj_t * p ) {
***********************************************************************/
static inline void Abc_PrintInt( int i )
{
+ printf( " " );
if ( i > -1000 && i < 1000 )
- printf( "%6d", i );
+ printf( " %4d", i );
+ else if ( i > -10000 && i < 10000 )
+ printf( "%4.2fk", (float)i/1000 );
+ else if ( i > -100000 && i < 100000 )
+ printf( "%4.1fk", (float)i/1000 );
else if ( i > -1000000 && i < 1000000 )
- printf( "%5dk", i/1000 );
+ printf( "%4.0fk", (float)i/1000 );
+ else if ( i > -10000000 && i < 10000000 )
+ printf( "%4.2fm", (float)i/1000000 );
+ else if ( i > -100000000 && i < 100000000 )
+ printf( "%4.1fm", (float)i/1000000 );
else if ( i > -1000000000 && i < 1000000000 )
- printf( "%5dm", i/1000000 );
+ printf( "%4.0fm", (float)i/1000000 );
}
/**Function*************************************************************
@@ -1837,7 +1846,7 @@ int Gia_GlaPerform( Gia_Man_t * pAig, Gia_ParVta_t * pPars, int fStartVta )
Abc_Print( 1, "Running gate-level abstraction (GLA) with the following parameters:\n" );
Abc_Print( 1, "FrameMax = %d ConfMax = %d LearnMax = %d Timeout = %d RatioMin = %d %%.\n",
pPars->nFramesMax, pPars->nConfLimit, pPars->nLearntMax, pPars->nTimeOut, pPars->nRatioMin );
- Abc_Print( 1, "Frame %% Abs PPI FF LUT Confl Cex Vars Clas Lrns Time Mem\n" );
+ Abc_Print( 1, "Frame %% Abs PPI FF LUT Confl Cex Vars Clas Lrns Time Mem\n" );
}
for ( f = i = iPrev = 0; !p->pPars->nFramesMax || f < p->pPars->nFramesMax; f++, iPrev = i )
{
diff --git a/src/aig/gia/giaAbsVta.c b/src/aig/gia/giaAbsVta.c
index 98f2b536..ca2b2e8f 100644
--- a/src/aig/gia/giaAbsVta.c
+++ b/src/aig/gia/giaAbsVta.c
@@ -148,12 +148,21 @@ extern void Vga_ManAddClausesOne( Vta_Man_t * p, int iObj, int iFrame );
***********************************************************************/
static inline void Abc_PrintInt( int i )
{
+ printf( " " );
if ( i > -1000 && i < 1000 )
- printf( "%6d", i );
+ printf( " %4d", i );
+ else if ( i > -10000 && i < 10000 )
+ printf( "%4.2fk", (float)i/1000 );
+ else if ( i > -100000 && i < 100000 )
+ printf( "%4.1fk", (float)i/1000 );
else if ( i > -1000000 && i < 1000000 )
- printf( "%5dk", i/1000 );
+ printf( "%4.0fk", (float)i/1000 );
+ else if ( i > -10000000 && i < 10000000 )
+ printf( "%4.2fm", (float)i/1000000 );
+ else if ( i > -100000000 && i < 100000000 )
+ printf( "%4.1fm", (float)i/1000000 );
else if ( i > -1000000000 && i < 1000000000 )
- printf( "%5dm", i/1000000 );
+ printf( "%4.0fm", (float)i/1000000 );
}
/**Function*************************************************************
@@ -1276,7 +1285,7 @@ int Vta_ManAbsPrintFrame( Vta_Man_t * p, Vec_Int_t * vCore, int nFrames, int nCo
}
else
{
- Abc_Print( 1, "%7d", pCountAll[0] );
+ Abc_PrintInt( pCountAll[0] );
/*
if ( nFrames > 7 )
{
@@ -1599,7 +1608,7 @@ int Gia_VtaPerformInt( Gia_Man_t * pAig, Gia_ParVta_t * pPars )
Abc_Print( 1, "FramePast = %d FrameMax = %d ConfMax = %d LearnMax = %d Timeout = %d RatioMin = %d %%\n",
pPars->nFramesPast, pPars->nFramesMax, pPars->nConfLimit, pPars->nLearntMax, pPars->nTimeOut, pPars->nRatioMin );
// Abc_Print( 1, "Frame %% Abs %% Confl Cex SatVar Core F0 F1 F2 ...\n" );
- Abc_Print( 1, "Frame %% Abs %% Confl Cex Vars Clas Lrns Core Time Mem\n" );
+ Abc_Print( 1, "Frame %% Abs %% Confl Cex Vars Clas Lrns Core Time Mem\n" );
}
assert( Vec_PtrSize(p->vFrames) > 0 );
for ( f = i = 0; !p->pPars->nFramesMax || f < p->pPars->nFramesMax; f++ )