diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2006-12-04 08:01:00 -0800 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2006-12-04 08:01:00 -0800 |
commit | 52e5b91cbbfe587bae80984bb3672e4c1a70203c (patch) | |
tree | 0aec31b1121e4eb690f1dc17b3c76617b723fe5e /src/base/abci | |
parent | 44d220d28fa2ee56cb539e03684f021731814f17 (diff) | |
download | abc-52e5b91cbbfe587bae80984bb3672e4c1a70203c.tar.gz abc-52e5b91cbbfe587bae80984bb3672e4c1a70203c.tar.bz2 abc-52e5b91cbbfe587bae80984bb3672e4c1a70203c.zip |
Version abc61204
Diffstat (limited to 'src/base/abci')
-rw-r--r-- | src/base/abci/abc.c | 30 | ||||
-rw-r--r-- | src/base/abci/abcIf.c | 7 | ||||
-rw-r--r-- | src/base/abci/abcPrint.c | 9 |
3 files changed, 33 insertions, 13 deletions
diff --git a/src/base/abci/abc.c b/src/base/abci/abc.c index 4164f67a..dbbe9d7e 100644 --- a/src/base/abci/abc.c +++ b/src/base/abci/abc.c @@ -7090,7 +7090,7 @@ int Abc_CommandFpga( Abc_Frame_t * pAbc, int argc, char ** argv ) fRecovery = 1; fSwitching = 0; fLatchPaths = 0; - fVerbose = 1; + fVerbose = 0; DelayTarget =-1; nLutSize =-1; Extra_UtilGetoptReset(); @@ -7392,18 +7392,20 @@ int Abc_CommandIf( Abc_Frame_t * pAbc, int argc, char ** argv ) // set defaults memset( pPars, 0, sizeof(If_Par_t) ); pPars->Mode = 0; - pPars->nLutSize = 5; + pPars->nLutSize = 4; // pPars->pLutLib = Abc_FrameReadLibLut(); - pPars->nCutsMax = 10; + pPars->nCutsMax = 20; + pPars->fPreprocess = 1; pPars->fArea = 0; pPars->fFancy = 0; pPars->fLatchPaths = 0; + pPars->fExpRed = 1; pPars->fSeq = 0; pPars->nLatches = 0; pPars->DelayTarget = -1; - pPars->fVerbose = 1; + pPars->fVerbose = 0; Extra_UtilGetoptReset(); - while ( ( c = Extra_UtilGetopt( argc, argv, "MKCDaflsvh" ) ) != EOF ) + while ( ( c = Extra_UtilGetopt( argc, argv, "MKCDpaflrsvh" ) ) != EOF ) { switch ( c ) { @@ -7451,6 +7453,9 @@ int Abc_CommandIf( Abc_Frame_t * pAbc, int argc, char ** argv ) if ( pPars->DelayTarget <= 0.0 ) goto usage; break; + case 'p': + pPars->fPreprocess ^= 1; + break; case 'a': pPars->fArea ^= 1; break; @@ -7460,6 +7465,9 @@ int Abc_CommandIf( Abc_Frame_t * pAbc, int argc, char ** argv ) case 'l': pPars->fLatchPaths ^= 1; break; + case 'r': + pPars->fExpRed ^= 1; + break; case 's': pPars->fSeq ^= 1; break; @@ -7478,6 +7486,12 @@ int Abc_CommandIf( Abc_Frame_t * pAbc, int argc, char ** argv ) return 1; } + if ( pPars->fSeq ) + { + fprintf( pErr, "Sequential mapping is currently being implemented.\n" ); + goto usage; + } + if ( pPars->Mode < 0 || pPars->Mode > 4 ) { fprintf( pErr, "Incorrect mapping mode.\n" ); @@ -7547,7 +7561,7 @@ usage: sprintf( LutSize, "library" ); else sprintf( LutSize, "%d", pPars->nLutSize ); - fprintf( pErr, "usage: if [-M num] [-K num] [-C num] [-D float] [-aflsvh]\n" ); + fprintf( pErr, "usage: if [-M num] [-K num] [-C num] [-D float] [-pafrsvh]\n" ); fprintf( pErr, "\t performs FPGA mapping of the network as follows:\n" ); fprintf( pErr, "\t 1 - delay only\n" ); fprintf( pErr, "\t 2 - area only\n" ); @@ -7557,9 +7571,11 @@ usage: fprintf( pErr, "\t-K num : the number of LUT inputs (2 < num < 32) [default = %s]\n", LutSize ); fprintf( pErr, "\t-C num : the max number of cuts to use (1 < num < 2^12) [default = %d]\n", pPars->nCutsMax ); fprintf( pErr, "\t-D float : sets the delay constraint for the mapping [default = %s]\n", Buffer ); + fprintf( pErr, "\t-p : toggles preprocessing using several starting points [default = %s]\n", pPars->fPreprocess? "yes": "no" ); fprintf( pErr, "\t-a : toggles area-oriented mapping [default = %s]\n", pPars->fArea? "yes": "no" ); fprintf( pErr, "\t-f : toggles one fancy feature [default = %s]\n", pPars->fFancy? "yes": "no" ); - fprintf( pErr, "\t-l : optimizes latch paths for delay, other paths for area [default = %s]\n", pPars->fLatchPaths? "yes": "no" ); +// fprintf( pErr, "\t-l : optimizes latch paths for delay, other paths for area [default = %s]\n", pPars->fLatchPaths? "yes": "no" ); + fprintf( pErr, "\t-r : enables expansion/reduction of the best cuts [default = %s]\n", pPars->fExpRed? "yes": "no" ); fprintf( pErr, "\t-s : toggles sequential mapping [default = %s]\n", pPars->fSeq? "yes": "no" ); fprintf( pErr, "\t-v : toggles verbose output [default = %s]\n", pPars->fVerbose? "yes": "no" ); fprintf( pErr, "\t-h : prints the command usage\n"); diff --git a/src/base/abci/abcIf.c b/src/base/abci/abcIf.c index 70971952..704c8ebb 100644 --- a/src/base/abci/abcIf.c +++ b/src/base/abci/abcIf.c @@ -55,7 +55,11 @@ Abc_Ntk_t * Abc_NtkIf( Abc_Ntk_t * pNtk, If_Par_t * pPars ) // print a warning about choice nodes if ( Abc_NtkGetChoiceNum( pNtk ) ) - printf( "Performing FPGA mapping with choices.\n" ); + { +// printf( "Performing FPGA mapping with choices.\n" ); + printf( "Currently mapping with choices is not enabled.\n" ); + return NULL; + } // get timing information pPars->pTimesArr = Abc_NtkGetCiArrivalFloats(pNtk); @@ -223,7 +227,6 @@ Abc_Obj_t * Abc_NodeFromIf_rec( Abc_Ntk_t * pNtkNew, If_Man_t * pIfMan, If_Obj_t return pNodeNew; } - /**Function************************************************************* Synopsis [Recursively derives the truth table for the cut.] diff --git a/src/base/abci/abcPrint.c b/src/base/abci/abcPrint.c index 40bf30a6..002a885c 100644 --- a/src/base/abci/abcPrint.c +++ b/src/base/abci/abcPrint.c @@ -148,18 +148,18 @@ void Abc_NtkPrintStats( FILE * pFile, Abc_Ntk_t * pNtk, int fFactored ) // print the statistic into a file { FILE * pTable; - pTable = fopen( "fpga/fpga_stats.txt", "a+" ); + pTable = fopen( "a/fpga_stats.txt", "a+" ); fprintf( pTable, "%s ", pNtk->pName ); fprintf( pTable, "%d ", Abc_NtkLevel(pNtk) ); fprintf( pTable, "%d ", Abc_NtkNodeNum(pNtk) ); - fprintf( pTable, "%.2f ", (float)(s_MappingMem)/(float)(1<<20) ); - fprintf( pTable, "%.2f", (float)(s_MappingTime)/(float)(CLOCKS_PER_SEC) ); +// fprintf( pTable, "%.2f ", (float)(s_MappingMem)/(float)(1<<20) ); +// fprintf( pTable, "%.2f", (float)(s_MappingTime)/(float)(CLOCKS_PER_SEC) ); fprintf( pTable, "\n" ); fclose( pTable ); } */ - +/* // print the statistic into a file { static int Counter = 0; @@ -176,6 +176,7 @@ void Abc_NtkPrintStats( FILE * pFile, Abc_Ntk_t * pNtk, int fFactored ) fprintf( pTable, "\n" ); fclose( pTable ); } +*/ /* // print the statistic into a file |