Commit 15a1c4b9 by Alan Mishchenko

g++ compiler errors.

parent 59bf6945
...@@ -105,8 +105,6 @@ static inline If_DsdObj_t * If_DsdObjFanin( Vec_Ptr_t * p, If_DsdObj_t * pObj, i ...@@ -105,8 +105,6 @@ static inline If_DsdObj_t * If_DsdObjFanin( Vec_Ptr_t * p, If_DsdObj_t * pObj, i
#define If_DsdObjForEachFaninLit( vVec, pObj, iLit, i ) \ #define If_DsdObjForEachFaninLit( vVec, pObj, iLit, i ) \
for ( i = 0; (i < If_DsdObjFaninNum(pObj)) && ((iLit) = If_DsdObjFaninLit(pObj, i)); i++ ) for ( i = 0; (i < If_DsdObjFaninNum(pObj)) && ((iLit) = If_DsdObjFaninLit(pObj, i)); i++ )
extern void Kit_DsdPrintFromTruth( unsigned * pTruth, int nVars );
//////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////
/// FUNCTION DEFINITIONS /// /// FUNCTION DEFINITIONS ///
//////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////
...@@ -404,7 +402,7 @@ void If_DsdManDump( If_DsdMan_t * p ) ...@@ -404,7 +402,7 @@ void If_DsdManDump( If_DsdMan_t * p )
Abc_TtPrintHexRev( pFile, If_DsdObjTruth(p, pObj), p->nVars ); Abc_TtPrintHexRev( pFile, If_DsdObjTruth(p, pObj), p->nVars );
fprintf( pFile, "\n" ); fprintf( pFile, "\n" );
printf( " " ); printf( " " );
Kit_DsdPrintFromTruth( (unsigned *)If_DsdObjTruth(p, pObj), p->nVars ); Dau_DsdPrintFromTruth( If_DsdObjTruth(p, pObj), p->nVars );
printf( "\n" ); printf( "\n" );
} }
fclose( pFile ); fclose( pFile );
...@@ -899,8 +897,8 @@ int If_DsdManCompute( If_DsdMan_t * p, word * pTruth, int nLeaves, unsigned char ...@@ -899,8 +897,8 @@ int If_DsdManCompute( If_DsdMan_t * p, word * pTruth, int nLeaves, unsigned char
// If_DsdManPrint( p, NULL ); // If_DsdManPrint( p, NULL );
printf( "\n" ); printf( "\n" );
printf( "Verification failed!\n" ); printf( "Verification failed!\n" );
Kit_DsdPrintFromTruth( (unsigned *)pTruth, nLeaves ); printf( "\n" ); Dau_DsdPrintFromTruth( pTruth, nLeaves ); printf( "\n" );
Kit_DsdPrintFromTruth( (unsigned *)pRes, nLeaves ); printf( "\n" ); Dau_DsdPrintFromTruth( pRes, nLeaves ); printf( "\n" );
If_DsdManPrintOne( stdout, p, Abc_Lit2Var(iDsd), pPerm ); If_DsdManPrintOne( stdout, p, Abc_Lit2Var(iDsd), pPerm );
printf( "\n" ); printf( "\n" );
} }
......
...@@ -80,7 +80,8 @@ extern unsigned Abc_TtCanonicizePhase( word * pTruth, int nVars ); ...@@ -80,7 +80,8 @@ extern unsigned Abc_TtCanonicizePhase( word * pTruth, int nVars );
/*=== dauDsd.c ==========================================================*/ /*=== dauDsd.c ==========================================================*/
extern int * Dau_DsdComputeMatches( char * p ); extern int * Dau_DsdComputeMatches( char * p );
extern int Dau_DsdDecompose( word * pTruth, int nVarsInit, int fSplitPrime, int fWriteTruth, char * pRes ); extern int Dau_DsdDecompose( word * pTruth, int nVarsInit, int fSplitPrime, int fWriteTruth, char * pRes );
extern void Dau_DsdPrintFromTruth( FILE * pFile, word * pTruth, int nVarsInit ); extern void Dau_DsdPrintFromTruthFile( FILE * pFile, word * pTruth, int nVarsInit );
extern void Dau_DsdPrintFromTruth( word * pTruth, int nVarsInit );
extern word * Dau_DsdToTruth( char * p, int nVars ); extern word * Dau_DsdToTruth( char * p, int nVars );
extern word Dau_Dsd6ToTruth( char * p ); extern word Dau_Dsd6ToTruth( char * p );
extern void Dau_DsdNormalize( char * p ); extern void Dau_DsdNormalize( char * p );
......
...@@ -1897,7 +1897,7 @@ int Dau_DsdDecompose( word * pTruth, int nVarsInit, int fSplitPrime, int fWriteT ...@@ -1897,7 +1897,7 @@ int Dau_DsdDecompose( word * pTruth, int nVarsInit, int fSplitPrime, int fWriteT
// assert( p->nSizeNonDec == 0 ); // assert( p->nSizeNonDec == 0 );
return p->nSizeNonDec; return p->nSizeNonDec;
} }
void Dau_DsdPrintFromTruth( FILE * pFile, word * pTruth, int nVarsInit ) void Dau_DsdPrintFromTruthFile( FILE * pFile, word * pTruth, int nVarsInit )
{ {
char pRes[DAU_MAX_STR]; char pRes[DAU_MAX_STR];
word pTemp[DAU_MAX_WORD]; word pTemp[DAU_MAX_WORD];
...@@ -1905,6 +1905,14 @@ void Dau_DsdPrintFromTruth( FILE * pFile, word * pTruth, int nVarsInit ) ...@@ -1905,6 +1905,14 @@ void Dau_DsdPrintFromTruth( FILE * pFile, word * pTruth, int nVarsInit )
Dau_DsdDecompose( pTemp, nVarsInit, 0, 1, pRes ); Dau_DsdDecompose( pTemp, nVarsInit, 0, 1, pRes );
fprintf( pFile, "%s\n", pRes ); fprintf( pFile, "%s\n", pRes );
} }
void Dau_DsdPrintFromTruth( word * pTruth, int nVarsInit )
{
char pRes[DAU_MAX_STR];
word pTemp[DAU_MAX_WORD];
Abc_TtCopy( pTemp, pTruth, Abc_TtWordNum(nVarsInit), 0 );
Dau_DsdDecompose( pTemp, nVarsInit, 0, 1, pRes );
fprintf( stdout, "%s\n", pRes );
}
void Dau_DsdTest44() void Dau_DsdTest44()
{ {
......
...@@ -828,7 +828,7 @@ void Dau_DecTrySets( word * pInit, int nVars ) ...@@ -828,7 +828,7 @@ void Dau_DecTrySets( word * pInit, int nVars )
assert( nVars <= 16 ); assert( nVars <= 16 );
memcpy( p, pInit, sizeof(word) * Abc_TtWordNum(nVars) ); memcpy( p, pInit, sizeof(word) * Abc_TtWordNum(nVars) );
vSets = Dau_DecFindSets( p, nVars ); vSets = Dau_DecFindSets( p, nVars );
Dau_DsdPrintFromTruth( stdout, p, nVars ); Dau_DsdPrintFromTruth( p, nVars );
printf( "This %d-variable function has %d decomposable variable sets:\n", nVars, Vec_IntSize(vSets) ); printf( "This %d-variable function has %d decomposable variable sets:\n", nVars, Vec_IntSize(vSets) );
Vec_IntForEachEntry( vSets, Entry, i ) Vec_IntForEachEntry( vSets, Entry, i )
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment