Commit 144c5be8 by Alan Mishchenko

Preserving additional AIG manager when dandling nodes are present.

parent 1485e63a
...@@ -794,6 +794,7 @@ Gia_Man_t * Gia_AigerReadFromMemory( char * pContents, int nFileSize, int fGiaSi ...@@ -794,6 +794,7 @@ Gia_Man_t * Gia_AigerReadFromMemory( char * pContents, int nFileSize, int fGiaSi
if ( !fGiaSimple && !fSkipStrash && Gia_ManHasDangling(pNew) ) if ( !fGiaSimple && !fSkipStrash && Gia_ManHasDangling(pNew) )
{ {
Tim_Man_t * pManTime; Tim_Man_t * pManTime;
Gia_Man_t * pAigExtra;
Vec_Int_t * vFlopMap, * vGateMap, * vObjMap, * vRegClasses, * vRegInits; Vec_Int_t * vFlopMap, * vGateMap, * vObjMap, * vRegClasses, * vRegInits;
vRegClasses = pNew->vRegClasses; pNew->vRegClasses = NULL; vRegClasses = pNew->vRegClasses; pNew->vRegClasses = NULL;
vRegInits = pNew->vRegInits; pNew->vRegInits = NULL; vRegInits = pNew->vRegInits; pNew->vRegInits = NULL;
...@@ -801,6 +802,7 @@ Gia_Man_t * Gia_AigerReadFromMemory( char * pContents, int nFileSize, int fGiaSi ...@@ -801,6 +802,7 @@ Gia_Man_t * Gia_AigerReadFromMemory( char * pContents, int nFileSize, int fGiaSi
vGateMap = pNew->vGateClasses; pNew->vGateClasses = NULL; vGateMap = pNew->vGateClasses; pNew->vGateClasses = NULL;
vObjMap = pNew->vObjClasses; pNew->vObjClasses = NULL; vObjMap = pNew->vObjClasses; pNew->vObjClasses = NULL;
pManTime = (Tim_Man_t *)pNew->pManTime; pNew->pManTime = NULL; pManTime = (Tim_Man_t *)pNew->pManTime; pNew->pManTime = NULL;
pAigExtra = pNew->pAigExtra; pNew->pAigExtra = NULL;
pNew = Gia_ManCleanup( pTemp = pNew ); pNew = Gia_ManCleanup( pTemp = pNew );
if ( (vGateMap || vObjMap) && (Gia_ManObjNum(pNew) < Gia_ManObjNum(pTemp)) ) if ( (vGateMap || vObjMap) && (Gia_ManObjNum(pNew) < Gia_ManObjNum(pTemp)) )
printf( "Cleanup removed objects after reading. Old gate/object abstraction maps are invalid!\n" ); printf( "Cleanup removed objects after reading. Old gate/object abstraction maps are invalid!\n" );
...@@ -811,6 +813,7 @@ Gia_Man_t * Gia_AigerReadFromMemory( char * pContents, int nFileSize, int fGiaSi ...@@ -811,6 +813,7 @@ Gia_Man_t * Gia_AigerReadFromMemory( char * pContents, int nFileSize, int fGiaSi
pNew->vGateClasses = vGateMap; pNew->vGateClasses = vGateMap;
pNew->vObjClasses = vObjMap; pNew->vObjClasses = vObjMap;
pNew->pManTime = pManTime; pNew->pManTime = pManTime;
pNew->pAigExtra = pAigExtra;
} }
if ( fHieOnly ) if ( fHieOnly )
......
...@@ -258,7 +258,7 @@ void Lpk_TryDec( word * pTruth, int nVars ) ...@@ -258,7 +258,7 @@ void Lpk_TryDec( word * pTruth, int nVars )
{ {
extern word If_Dec6Perform( word t, int fDerive ); extern word If_Dec6Perform( word t, int fDerive );
extern void If_Dec6Verify( word t, word z ); extern void If_Dec6Verify( word t, word z );
int nWords = Abc_Truth6WordNum( nVars ); //int nWords = Abc_Truth6WordNum( nVars );
assert( nVars == 8 ); assert( nVars == 8 );
printf( "%d", If_Dec6Perform(pTruth[0], 1) > 0 ); printf( "%d", If_Dec6Perform(pTruth[0], 1) > 0 );
printf( "%d", If_Dec6Perform(pTruth[1], 1) > 0 ); printf( "%d", If_Dec6Perform(pTruth[1], 1) > 0 );
......
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