Commit 25ecc3d4 by Yen-Sheng Ho

fixed a tricky bug: property should not be assumed true in the last frame

parent 1a66a582
...@@ -99,7 +99,6 @@ int IPdr_ManCheckClauses( Pdr_Man_t * p ) ...@@ -99,7 +99,6 @@ int IPdr_ManCheckClauses( Pdr_Man_t * p )
assert( RetValue == 1 ); assert( RetValue == 1 );
} }
} }
printf( "XXX: Pass check clauses! %d frames and %d clauses checked\n", k, counter );
return 1; return 1;
} }
...@@ -149,7 +148,7 @@ Vec_Vec_t * IPdr_ManSaveClauses( Pdr_Man_t * p, int fDropLast ) ...@@ -149,7 +148,7 @@ Vec_Vec_t * IPdr_ManSaveClauses( Pdr_Man_t * p, int fDropLast )
SeeAlso [] SeeAlso []
***********************************************************************/ ***********************************************************************/
sat_solver * IPdr_ManSetSolver( Pdr_Man_t * p, int k ) sat_solver * IPdr_ManSetSolver( Pdr_Man_t * p, int k, int nTotal )
{ {
sat_solver * pSat; sat_solver * pSat;
Vec_Ptr_t * vArrayK; Vec_Ptr_t * vArrayK;
...@@ -165,7 +164,12 @@ sat_solver * IPdr_ManSetSolver( Pdr_Man_t * p, int k ) ...@@ -165,7 +164,12 @@ sat_solver * IPdr_ManSetSolver( Pdr_Man_t * p, int k )
Vec_IntPush( p->vActVars, 0 ); Vec_IntPush( p->vActVars, 0 );
// set the property output // set the property output
if ( k < nTotal - 1 )
Pdr_ManSetPropertyOutput( p, k ); Pdr_ManSetPropertyOutput( p, k );
if (k == 0)
return pSat;
// add the clauses // add the clauses
Vec_VecForEachLevelStart( p->vClauses, vArrayK, i, k ) Vec_VecForEachLevelStart( p->vClauses, vArrayK, i, k )
Vec_PtrForEachEntry( Pdr_Set_t *, vArrayK, pCube, j ) Vec_PtrForEachEntry( Pdr_Set_t *, vArrayK, pCube, j )
...@@ -194,7 +198,7 @@ int IPdr_ManRestore( Pdr_Man_t * p, Vec_Vec_t * vClauses ) ...@@ -194,7 +198,7 @@ int IPdr_ManRestore( Pdr_Man_t * p, Vec_Vec_t * vClauses )
p->vClauses = vClauses; p->vClauses = vClauses;
for ( i = 0; i < Vec_VecSize(p->vClauses); ++i ) for ( i = 0; i < Vec_VecSize(p->vClauses); ++i )
IPdr_ManSetSolver(p, i); IPdr_ManSetSolver( p, i, Vec_VecSize( p->vClauses ) );
return 0; return 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