diff options
-rw-r--r-- | src/aig/gia/giaMan.c | 7 | ||||
-rw-r--r-- | src/base/abci/abcPrint.c | 12 | ||||
-rw-r--r-- | src/map/scl/sclSize.c | 8 |
3 files changed, 22 insertions, 5 deletions
diff --git a/src/aig/gia/giaMan.c b/src/aig/gia/giaMan.c index d0048f6a..710886ae 100644 --- a/src/aig/gia/giaMan.c +++ b/src/aig/gia/giaMan.c @@ -384,8 +384,15 @@ void Gia_ManPrintChoiceStats( Gia_Man_t * p ) void Gia_ManPrintStats( Gia_Man_t * p, Gps_Par_t * pPars ) { extern float Gia_ManLevelAve( Gia_Man_t * p ); +#ifdef WIN32 + SetConsoleTextAttribute( GetStdHandle(STD_OUTPUT_HANDLE), 15 ); // bright if ( p->pName ) Abc_Print( 1, "%-8s : ", p->pName ); + SetConsoleTextAttribute( GetStdHandle(STD_OUTPUT_HANDLE), 7 ); // normal +#else + 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_ManPoNum(p) ); if ( Gia_ManConstrNum(p) ) Abc_Print( 1, "(c=%d)", Gia_ManConstrNum(p) ); diff --git a/src/base/abci/abcPrint.c b/src/base/abci/abcPrint.c index 52556d6d..8717c1ed 100644 --- a/src/base/abci/abcPrint.c +++ b/src/base/abci/abcPrint.c @@ -27,6 +27,10 @@ #include "map/if/if.h" #include "misc/extra/extraBdd.h" +#ifdef WIN32 +#include <windows.h> +#endif + ABC_NAMESPACE_IMPL_START @@ -229,7 +233,13 @@ void Abc_NtkPrintStats( Abc_Ntk_t * pNtk, int fFactored, int fSaveBest, int fDum // if ( Abc_NtkIsStrash(pNtk) ) // Abc_AigCountNext( pNtk->pManFunc ); - Abc_Print( 1,"%-13s:", pNtk->pName ); +#ifdef WIN32 + SetConsoleTextAttribute( GetStdHandle(STD_OUTPUT_HANDLE), 15 ); // bright + Abc_Print( 1,"%-13s:", pNtk->pName ); + SetConsoleTextAttribute( GetStdHandle(STD_OUTPUT_HANDLE), 7 ); // normal +#else + Abc_Print( 1,"%s%-13s:%s", "\033[1;37m", pNtk->pName, "\033[0m" ); // bright +#endif Abc_Print( 1," i/o =%5d/%5d", Abc_NtkPiNum(pNtk), Abc_NtkPoNum(pNtk) ); if ( Abc_NtkConstrNum(pNtk) ) Abc_Print( 1,"(c=%d)", Abc_NtkConstrNum(pNtk) ); diff --git a/src/map/scl/sclSize.c b/src/map/scl/sclSize.c index ea7c552d..affe0652 100644 --- a/src/map/scl/sclSize.c +++ b/src/map/scl/sclSize.c @@ -162,13 +162,13 @@ void Abc_SclTimeNtkPrint( SC_Man * p, int fShowAll, int fPrintPath ) printf( " \n" ); #else Abc_Print( 1, "WireLoad = \"%s\" ", p->pWLoadUsed ? p->pWLoadUsed->pName : "none" ); - Abc_Print( 1, "%sGates =%7d%s ", "\033[1;33m", Abc_NtkNodeNum(p->pNtk), "\033[1;36m" ); // yellow + Abc_Print( 1, "%sGates =%7d%s ", "\033[1;33m", Abc_NtkNodeNum(p->pNtk), "\033[0m" ); // yellow Abc_Print( 1, "(%5.1f %%) ", 100.0 * Abc_SclGetBufInvCount(p->pNtk) / Abc_NtkNodeNum(p->pNtk) ); - Abc_Print( 1, "%sCap =%5.1f ff%s ", "\033[1;32m", p->EstLoadAve, "\033[1;36m" ); // green + Abc_Print( 1, "%sCap =%5.1f ff%s ", "\033[1;32m", p->EstLoadAve, "\033[0m" ); // green Abc_Print( 1, "(%5.1f %%) ", Abc_SclGetAverageSize(p->pNtk) ); - Abc_Print( 1, "%sArea =%12.2f%s ", "\033[1;36m", Abc_SclGetTotalArea(p->pNtk), "\033[1;35m" ); // blue + Abc_Print( 1, "%sArea =%12.2f%s ", "\033[1;36m", Abc_SclGetTotalArea(p->pNtk), "\033[0m" ); // blue Abc_Print( 1, "(%5.1f %%) ", 100.0 * Abc_SclCountMinSize(p->pLib, p->pNtk, 0) / Abc_NtkNodeNum(p->pNtk) ); - Abc_Print( 1, "%sDelay =%9.2f ps%s ", "\033[1;35m", maxDelay, "\033[1;35m" ); // magenta + Abc_Print( 1, "%sDelay =%9.2f ps%s ", "\033[1;35m", maxDelay, "\033[0m" ); // magenta Abc_Print( 1, "(%5.1f %%) ", 100.0 * Abc_SclCountNearCriticalNodes(p) / Abc_NtkNodeNum(p->pNtk) ); Abc_Print( 1, " \n" ); #endif |