summaryrefslogtreecommitdiffstats
path: root/src/opt/rwr/rwrUtil.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/opt/rwr/rwrUtil.c')
-rw-r--r--src/opt/rwr/rwrUtil.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/opt/rwr/rwrUtil.c b/src/opt/rwr/rwrUtil.c
index b2add2bf..8da3b6eb 100644
--- a/src/opt/rwr/rwrUtil.c
+++ b/src/opt/rwr/rwrUtil.c
@@ -78,7 +78,7 @@ void Rwr_ManWriteToArray( Rwr_Man_t * p )
Extra_PrintHex( pFile, 0, 4 );
fprintf( pFile, " \n};\n" );
fclose( pFile );
- printf( "The number of nodes saved = %d. ", nEntries ); PRT( "Saving", clock() - clk );
+ printf( "The number of nodes saved = %d. ", nEntries ); ABC_PRT( "Saving", clock() - clk );
}
/**Function*************************************************************
@@ -127,7 +127,7 @@ void Rwr_ManLoadFromArray( Rwr_Man_t * p, int fVerbose )
if ( fVerbose )
{
printf( "The number of classes = %d. Canonical nodes = %d.\n", p->nClasses, p->nAdded );
- printf( "The number of nodes loaded = %d. ", nEntries ); PRT( "Loading", clock() - clk );
+ printf( "The number of nodes loaded = %d. ", nEntries ); ABC_PRT( "Loading", clock() - clk );
}
}
@@ -151,7 +151,7 @@ void Rwr_ManWriteToFile( Rwr_Man_t * p, char * pFileName )
int i, nEntries, clk = clock();
// prepare the buffer
nEntries = p->vForest->nSize - 5;
- pBuffer = ALLOC( unsigned, nEntries * 2 );
+ pBuffer = ABC_ALLOC( unsigned, nEntries * 2 );
for ( i = 0; i < nEntries; i++ )
{
pNode = p->vForest->pArray[i+5];
@@ -164,9 +164,9 @@ void Rwr_ManWriteToFile( Rwr_Man_t * p, char * pFileName )
pFile = fopen( pFileName, "wb" );
fwrite( &nEntries, sizeof(int), 1, pFile );
fwrite( pBuffer, sizeof(unsigned), nEntries * 2, pFile );
- free( pBuffer );
+ ABC_FREE( pBuffer );
fclose( pFile );
- printf( "The number of nodes saved = %d. ", nEntries ); PRT( "Saving", clock() - clk );
+ printf( "The number of nodes saved = %d. ", nEntries ); ABC_PRT( "Saving", clock() - clk );
}
/**Function*************************************************************
@@ -196,7 +196,7 @@ void Rwr_ManLoadFromFile( Rwr_Man_t * p, char * pFileName )
return;
}
fread( &nEntries, sizeof(int), 1, pFile );
- pBuffer = ALLOC( unsigned, nEntries * 2 );
+ pBuffer = ABC_ALLOC( unsigned, nEntries * 2 );
fread( pBuffer, sizeof(unsigned), nEntries * 2, pFile );
fclose( pFile );
// reconstruct the forest
@@ -218,9 +218,9 @@ void Rwr_ManLoadFromFile( Rwr_Man_t * p, char * pFileName )
// Rwr_ManTryNode( p, p0, p1, Level, Volume );
Rwr_ManAddNode( p, p0, p1, fExor, Level, Volume + fExor );
}
- free( pBuffer );
+ ABC_FREE( pBuffer );
printf( "The number of classes = %d. Canonical nodes = %d.\n", p->nClasses, p->nAdded );
- printf( "The number of nodes loaded = %d. ", nEntries ); PRT( "Loading", clock() - clk );
+ printf( "The number of nodes loaded = %d. ", nEntries ); ABC_PRT( "Loading", clock() - clk );
}
@@ -260,7 +260,7 @@ char * Rwr_ManGetPractical( Rwr_Man_t * p )
{
char * pPractical;
int i;
- pPractical = ALLOC( char, p->nFuncs );
+ pPractical = ABC_ALLOC( char, p->nFuncs );
memset( pPractical, 0, sizeof(char) * p->nFuncs );
pPractical[0] = 1;
for ( i = 1; ; i++ )