diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2012-02-13 21:10:15 -0800 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2012-02-13 21:10:15 -0800 |
commit | e0650dce0a3f5567715f60162693f693ce3fd16b (patch) | |
tree | 11becbd8d9051ac2c87167fa966132c12305b60a /src/proof/llb | |
parent | 59ea100dbff76857143df08cd07777e0882b81f8 (diff) | |
download | abc-e0650dce0a3f5567715f60162693f693ce3fd16b.tar.gz abc-e0650dce0a3f5567715f60162693f693ce3fd16b.tar.bz2 abc-e0650dce0a3f5567715f60162693f693ce3fd16b.zip |
Timeout crash fix in 'reachy'.
Diffstat (limited to 'src/proof/llb')
-rw-r--r-- | src/proof/llb/llb4Nonlin.c | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/src/proof/llb/llb4Nonlin.c b/src/proof/llb/llb4Nonlin.c index 33c6b3f7..b7ea79b8 100644 --- a/src/proof/llb/llb4Nonlin.c +++ b/src/proof/llb/llb4Nonlin.c @@ -127,13 +127,24 @@ DdNode * Llb_Nonlin4ComputeBad( DdManager * dd, Aig_Man_t * pAig, Vec_Int_t * vO bCube = Cudd_ReadOne(dd); Cudd_Ref( bCube ); Saig_ManForEachPi( pAig, pObj, i ) { - bCube = Cudd_bddAnd( dd, bTemp = bCube, (DdNode *)pObj->pData ); Cudd_Ref( bCube ); + bCube = Cudd_bddAnd( dd, bTemp = bCube, (DdNode *)pObj->pData ); + if ( bCube == NULL ) + { + Cudd_RecursiveDeref( dd, bTemp ); + Cudd_RecursiveDeref( dd, bResult ); + bResult = NULL; + break; + } + Cudd_Ref( bCube ); Cudd_RecursiveDeref( dd, bTemp ); } - bResult = Cudd_bddExistAbstract( dd, bTemp = bResult, bCube ); Cudd_Ref( bResult ); - Cudd_RecursiveDeref( dd, bTemp ); - Cudd_RecursiveDeref( dd, bCube ); - Cudd_Deref( bResult ); + if ( bResult != NULL ) + { + bResult = Cudd_bddExistAbstract( dd, bTemp = bResult, bCube ); Cudd_Ref( bResult ); + Cudd_RecursiveDeref( dd, bTemp ); + Cudd_RecursiveDeref( dd, bCube ); + Cudd_Deref( bResult ); + } } //if ( bResult ) //printf( "Bad state = %d.\n", Cudd_DagSize(bResult) ); |