summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/aig/gia/gia.h1
-rw-r--r--src/aig/gia/giaMan.c18
-rw-r--r--src/base/abci/abc.c13
3 files changed, 27 insertions, 5 deletions
diff --git a/src/aig/gia/gia.h b/src/aig/gia/gia.h
index 2e888130..d386f8ba 100644
--- a/src/aig/gia/gia.h
+++ b/src/aig/gia/gia.h
@@ -246,6 +246,7 @@ struct Gps_Par_t_
int fMiter;
int fSkipMap;
int fSlacks;
+ int fNoColor;
char * pDumpFile;
};
diff --git a/src/aig/gia/giaMan.c b/src/aig/gia/giaMan.c
index 25355fe3..38fb9817 100644
--- a/src/aig/gia/giaMan.c
+++ b/src/aig/gia/giaMan.c
@@ -450,6 +450,13 @@ void Gia_ManPrintStats( Gia_Man_t * p, Gps_Par_t * pPars )
Gia_ManPrintStatsMiter( p, 0 );
return;
}
+ if ( pPars->fNoColor )
+ {
+ if ( p->pName )
+ Abc_Print( 1, "%-8s : ", p->pName );
+ }
+ else
+ {
#ifdef WIN32
SetConsoleTextAttribute( GetStdHandle(STD_OUTPUT_HANDLE), 15 ); // bright
if ( p->pName )
@@ -459,6 +466,7 @@ void Gia_ManPrintStats( Gia_Man_t * p, Gps_Par_t * pPars )
if ( p->pName )
Abc_Print( 1, "%s%-8s%s : ", "\033[1;37m", p->pName, "\033[0m" ); // bright
#endif
+ }
Abc_Print( 1, "i/o =%7d/%7d",
Gia_ManPiNum(p) - Gia_ManBoxCiNum(p) - Gia_ManRegBoxNum(p),
Gia_ManPoNum(p) - Gia_ManBoxCoNum(p) - Gia_ManRegBoxNum(p) );
@@ -468,7 +476,14 @@ void Gia_ManPrintStats( Gia_Man_t * p, Gps_Par_t * pPars )
Abc_Print( 1, " ff =%7d", Gia_ManRegNum(p) );
if ( Gia_ManRegBoxNum(p) )
Abc_Print( 1, " boxff =%d(%d)", Gia_ManRegBoxNum(p), Gia_ManClockDomainNum(p) );
-
+ if ( pPars->fNoColor )
+ {
+ Abc_Print( 1, " %s =%8d", p->pMuxes? "nod" : "and", Gia_ManAndNum(p) );
+ Abc_Print( 1, " lev =%5d", Gia_ManLevelNum(p) );
+ Abc_Print( 1, " (%.2f)", Gia_ManLevelAve(p) );
+ }
+ else
+ {
#ifdef WIN32
{
HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
@@ -484,6 +499,7 @@ void Gia_ManPrintStats( Gia_Man_t * p, Gps_Par_t * pPars )
Abc_Print( 1, " %slev =%5d%s", "\033[1;35m", Gia_ManLevelNum(p), "\033[0m" ); // magenta
Abc_Print( 1, " %s(%.2f)%s", "\033[1;35m", Gia_ManLevelAve(p), "\033[0m" );
#endif
+ }
Vec_IntFreeP( &p->vLevels );
if ( pPars && pPars->fCut )
Abc_Print( 1, " cut = %d(%d)", Gia_ManCrossCut(p, 0), Gia_ManCrossCut(p, 1) );
diff --git a/src/base/abci/abc.c b/src/base/abci/abc.c
index d20eb90c..475fe7b7 100644
--- a/src/base/abci/abc.c
+++ b/src/base/abci/abc.c
@@ -13374,6 +13374,7 @@ int Abc_CommandTest( Abc_Frame_t * pAbc, int argc, char ** argv )
// Abc_NtkComputePaths( Abc_FrameReadNtk(pAbc) );
//Dau_NetworkEnumTest();
//Extra_SimulationTest( nDivMax, nNumOnes, fNewOrder );
+ //Mnist_ExperimentWithScaling( nDecMax );
return 0;
usage:
Abc_Print( -2, "usage: test [-CKDNM] [-aovwh] <file_name>\n" );
@@ -30229,7 +30230,7 @@ int Abc_CommandAbc9Ps( Abc_Frame_t * pAbc, int argc, char ** argv )
int c, fBest = 0;
memset( pPars, 0, sizeof(Gps_Par_t) );
Extra_UtilGetoptReset();
- while ( ( c = Extra_UtilGetopt( argc, argv, "Dtpcnlmaszbh" ) ) != EOF )
+ while ( ( c = Extra_UtilGetopt( argc, argv, "Dtpcnlmaszxbh" ) ) != EOF )
{
switch ( c )
{
@@ -30260,6 +30261,9 @@ int Abc_CommandAbc9Ps( Abc_Frame_t * pAbc, int argc, char ** argv )
case 'z':
pPars->fSkipMap ^= 1;
break;
+ case 'x':
+ pPars->fNoColor ^= 1;
+ break;
case 'D':
if ( globalUtilOptind >= argc )
{
@@ -30299,7 +30303,7 @@ int Abc_CommandAbc9Ps( Abc_Frame_t * pAbc, int argc, char ** argv )
return 0;
usage:
- Abc_Print( -2, "usage: &ps [-tpcnlmaszbh] [-D file]\n" );
+ Abc_Print( -2, "usage: &ps [-tpcnlmaszxbh] [-D file]\n" );
Abc_Print( -2, "\t prints stats of the current AIG\n" );
Abc_Print( -2, "\t-t : toggle printing BMC tents [default = %s]\n", pPars->fTents? "yes": "no" );
Abc_Print( -2, "\t-p : toggle printing switching activity [default = %s]\n", pPars->fSwitch? "yes": "no" );
@@ -30310,7 +30314,8 @@ usage:
Abc_Print( -2, "\t-a : toggle printing miter statistics [default = %s]\n", pPars->fMiter? "yes": "no" );
Abc_Print( -2, "\t-s : toggle printing slack distribution [default = %s]\n", pPars->fSlacks? "yes": "no" );
Abc_Print( -2, "\t-z : skip mapping statistics even if mapped [default = %s]\n", pPars->fSkipMap? "yes": "no" );
- Abc_Print( -2, "\t-b : toggle printing saved AIG statistics [default = %s]\n", fBest? "yes": "no" );
+ Abc_Print( -2, "\t-n : toggle using no color in the printout [default = %s]\n", pPars->fNoColor? "yes": "no" );
+ Abc_Print( -2, "\t-x : toggle printing saved AIG statistics [default = %s]\n", fBest? "yes": "no" );
Abc_Print( -2, "\t-D file : file name to dump statistics [default = none]\n" );
Abc_Print( -2, "\t-h : print the command usage\n");
return 1;
@@ -45558,7 +45563,7 @@ usage:
Abc_Print( -2, "\t-L num : limit below which we randomize [default = %d]\n", Limit );
Abc_Print( -2, "\t-B num : select best fanins among this many tries [default = %d]\n", nBestTries );
Abc_Print( -2, "\t-M num : the multiplier type (1=array, 2=booth) [default = %d]\n", Multi );
- Abc_Print( -2, "\t-x : toggle using XOR gates [default = %s]\n", fVerbose? "yes": "no" );
+ Abc_Print( -2, "\t-x : toggle using XOR gates [default = %s]\n", fXor? "yes": "no" );
Abc_Print( -2, "\t-v : toggle printing verbose information [default = %s]\n", fVerbose? "yes": "no" );
Abc_Print( -2, "\t-h : print the command usage\n");
return 1;