diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2013-05-27 12:07:26 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2013-05-27 12:07:26 -0700 |
commit | 446cfcf8a6f4f15df46a973737a5280dea43cb14 (patch) | |
tree | c0adbe9a38b27cafbbde041573081e8f1997dd48 /src/sat/bsat | |
parent | c27556c5692f41d2ac4fb7c1705c574c0337b684 (diff) | |
download | abc-446cfcf8a6f4f15df46a973737a5280dea43cb14.tar.gz abc-446cfcf8a6f4f15df46a973737a5280dea43cb14.tar.bz2 abc-446cfcf8a6f4f15df46a973737a5280dea43cb14.zip |
Changing how often timeout is checked in the SAT solver and several application packages.
Diffstat (limited to 'src/sat/bsat')
-rw-r--r-- | src/sat/bsat/satSolver.c | 2 | ||||
-rw-r--r-- | src/sat/bsat/satSolver2.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/sat/bsat/satSolver.c b/src/sat/bsat/satSolver.c index 50df6a84..d1310c81 100644 --- a/src/sat/bsat/satSolver.c +++ b/src/sat/bsat/satSolver.c @@ -1576,7 +1576,7 @@ static lbool sat_solver_search(sat_solver* s, ABC_INT64_T nof_conflicts) int next; // Reached bound on number of conflicts: - if (nof_conflicts >= 0 && conflictC >= nof_conflicts){ + if ((nof_conflicts >= 0 && conflictC >= nof_conflicts) || (s->nRuntimeLimit && clock() > s->nRuntimeLimit)){ s->progress_estimate = sat_solver_progress(s); sat_solver_canceluntil(s,s->root_level); veci_delete(&learnt_clause); diff --git a/src/sat/bsat/satSolver2.c b/src/sat/bsat/satSolver2.c index a3dad126..12d74c0d 100644 --- a/src/sat/bsat/satSolver2.c +++ b/src/sat/bsat/satSolver2.c @@ -1037,7 +1037,7 @@ static lbool solver2_search(sat_solver2* s, ABC_INT64_T nof_conflicts) // NO CONFLICT int next; - if (nof_conflicts >= 0 && conflictC >= nof_conflicts){ + if ((nof_conflicts >= 0 && conflictC >= nof_conflicts) || (s->nRuntimeLimit && clock() > s->nRuntimeLimit)){ // Reached bound on number of conflicts: s->progress_estimate = solver2_progress(s); solver2_canceluntil(s,s->root_level); |