-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathminisat.cc.patch
31 lines (28 loc) · 1.02 KB
/
minisat.cc.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
diff -Naur minisat/minisat/core/Solver.cc minisat-mod/minisat/core/Solver.cc
--- minisat/minisat/core/Solver.cc 2018-09-10 15:01:12.898158196 +0200
+++ minisat-mod/minisat/core/Solver.cc 2018-09-10 15:36:44.781998060 +0200
@@ -56,6 +56,7 @@
// Parameters (user settable):
//
verbosity (0)
+ , learnedClsCallback(0)
, var_decay (opt_var_decay)
, clause_decay (opt_clause_decay)
, random_var_freq (opt_random_var_freq)
@@ -716,6 +717,11 @@
learnt_clause.clear();
analyze(confl, learnt_clause, backtrack_level);
+
+ if (learnedClsCallback != 0) {
+ learnedClsCallback(learnt_clause, issuer);
+ }
+
cancelUntil(backtrack_level);
if (learnt_clause.size() == 1){
@@ -779,6 +785,7 @@
// New variable decision:
decisions++;
next = pickBranchLit();
+ lastDecision = var(next);
if (next == lit_Undef)
// Model found: