diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2013-05-27 15:09:23 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2013-05-27 15:09:23 -0700 |
commit | 19c25fd6aab057b2373717f996fe538507c1b1e1 (patch) | |
tree | 7aa7cd7609a5de31d11b3455b6388fd9300c8d0f /src/base/abci/abcMffc.c | |
parent | 94356f0d1fa8e671303299717f631ecf0ca2f17e (diff) | |
download | abc-19c25fd6aab057b2373717f996fe538507c1b1e1.tar.gz abc-19c25fd6aab057b2373717f996fe538507c1b1e1.tar.bz2 abc-19c25fd6aab057b2373717f996fe538507c1b1e1.zip |
Adding a wrapper around clock() for more accurate time counting in ABC.
Diffstat (limited to 'src/base/abci/abcMffc.c')
-rw-r--r-- | src/base/abci/abcMffc.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/base/abci/abcMffc.c b/src/base/abci/abcMffc.c index f55b3b52..ad55ce04 100644 --- a/src/base/abci/abcMffc.c +++ b/src/base/abci/abcMffc.c @@ -546,7 +546,7 @@ void Abc_NktMffcTestSuper( Abc_Ntk_t * pNtk ) Vec_Int_t * vCounts, * vNumbers, * vSizes, * vMarks; Vec_Int_t * vNode1, * vNode2; int i, k, Entry, nSizes; - clock_t clk = clock(); + abctime clk = Abc_Clock(); vRoots = Abc_NktMffcMarkRoots( pNtk, 1 ); vFanins = Vec_PtrStart( Abc_NtkObjNumMax(pNtk) ); vFanouts = Vec_PtrStart( Abc_NtkObjNumMax(pNtk) ); @@ -658,7 +658,7 @@ if ( Entry == 2 ) if ( Vec_IntEntry(vNumbers,31) ) printf( " n > 1000 %6d\n", Vec_IntEntry(vNumbers,30) ); printf( "Total MFFCs = %d. ", Vec_PtrSize(vRoots) ); - Abc_PrintTime( 1, "Time", clock() - clk ); + Abc_PrintTime( 1, "Time", Abc_Clock() - clk ); Vec_IntFree( vNumbers ); Vec_PtrFree( vNodes ); Vec_PtrFree( vLeaves ); @@ -894,7 +894,7 @@ Vec_Ptr_t * Abc_NktMffcDerive( Abc_Ntk_t * pNtk, Vec_Ptr_t ** pvFanins, Vec_Ptr_ Vec_Ptr_t * vRoots, * vFanins, * vFanouts, * vVolumes, * vNodes, * vLeaves; Abc_Obj_t * pObj, * pFanin; int i, k; - clock_t clk = clock(); + abctime clk = Abc_Clock(); // create roots vRoots = Abc_NktMffcMarkRoots( pNtk, 0 ); // create fanins/fanouts/volumes @@ -1208,7 +1208,7 @@ void Abc_NktMffcServerTest( Abc_Ntk_t * pNtk ) Vec_Int_t * vGlob, * vLeaves, * vRoots; double Cost, CostAll = 0.0; int i, k, Entry, nNodes = 0; - clock_t clk = clock(); + abctime clk = Abc_Clock(); vGlobs = Abc_NktMffcServer( pNtk, 18, 3 ); vLeaves = Vec_IntAlloc( 100 ); vRoots = Vec_IntAlloc( 100 ); @@ -1240,7 +1240,7 @@ void Abc_NktMffcServerTest( Abc_Ntk_t * pNtk ) Vec_PtrFree( vGlobs ); printf( "Total = %6d. Nodes = %6d. ", Abc_NtkNodeNum(pNtk), nNodes ); printf( "Cost = %6.2f ", CostAll ); - Abc_PrintTime( 1, "Time", clock() - clk ); + Abc_PrintTime( 1, "Time", Abc_Clock() - clk ); } ABC_NAMESPACE_IMPL_END |