Adding options to &flow.

This commit is contained in:
Alan Mishchenko
2014-09-29 14:54:55 -07:00
parent 05ee370f85
commit 4960af4e76
2 changed files with 26 additions and 21 deletions
+9 -4
View File
@@ -30921,12 +30921,13 @@ usage:
***********************************************************************/
int Abc_CommandAbc9Flow( Abc_Frame_t * pAbc, int argc, char ** argv )
{
extern void Gia_ManPerformFlow( int fIsMapped, int nAnds, int nLevels, int nLutSize, int nCutNum, int fVerbose );
extern void Gia_ManPerformFlow( int fIsMapped, int nAnds, int nLevels, int nLutSize, int nCutNum, int fMinAve, int fVerbose );
int nLutSize = 6;
int nCutNum = 8;
int fMinAve = 0;
int c, fVerbose = 0;
Extra_UtilGetoptReset();
while ( ( c = Extra_UtilGetopt( argc, argv, "KCvh" ) ) != EOF )
while ( ( c = Extra_UtilGetopt( argc, argv, "KCtvh" ) ) != EOF )
{
switch ( c )
{
@@ -30952,6 +30953,9 @@ int Abc_CommandAbc9Flow( Abc_Frame_t * pAbc, int argc, char ** argv )
if ( nCutNum < 0 )
goto usage;
break;
case 't':
fMinAve ^= 1;
break;
case 'v':
fVerbose ^= 1;
break;
@@ -30966,14 +30970,15 @@ int Abc_CommandAbc9Flow( Abc_Frame_t * pAbc, int argc, char ** argv )
Abc_Print( -1, "Abc_CommandAbc9Flow(): There is no AIG.\n" );
return 1;
}
Gia_ManPerformFlow( Gia_ManHasMapping(pAbc->pGia), Gia_ManAndNum(pAbc->pGia), Gia_ManLevelNum(pAbc->pGia), nLutSize, nCutNum, fVerbose );
Gia_ManPerformFlow( Gia_ManHasMapping(pAbc->pGia), Gia_ManAndNum(pAbc->pGia), Gia_ManLevelNum(pAbc->pGia), nLutSize, nCutNum, fMinAve, fVerbose );
return 0;
usage:
Abc_Print( -2, "usage: &flow [-KC num] [-vh]\n" );
Abc_Print( -2, "usage: &flow [-KC num] [-tvh]\n" );
Abc_Print( -2, "\t integration optimization and mapping flow\n" );
Abc_Print( -2, "\t-K num : the number of LUT inputs (LUT size) [default = %d]\n", nLutSize );
Abc_Print( -2, "\t-C num : the number of cuts at a node [default = %d]\n", nCutNum );
Abc_Print( -2, "\t-t : toggle minimizing average rather than max delay [default = %s]\n", fMinAve? "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;