mirror of
https://github.com/Z3Prover/z3
synced 2025-07-19 10:52:02 +00:00
separate out search throttle
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
0d65b19c20
commit
981839ee73
2 changed files with 14 additions and 0 deletions
|
@ -88,6 +88,13 @@ namespace polysat {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
bool solver::should_search() {
|
||||||
|
return
|
||||||
|
m_lim.inc() &&
|
||||||
|
(m_stats.m_num_conflicts < m_max_conflicts) &&
|
||||||
|
(m_stats.m_num_decisions < m_max_decisions);
|
||||||
|
}
|
||||||
|
|
||||||
lbool solver::check_sat() {
|
lbool solver::check_sat() {
|
||||||
TRACE("polysat", tout << "check\n";);
|
TRACE("polysat", tout << "check\n";);
|
||||||
|
|
|
@ -17,6 +17,7 @@ Author:
|
||||||
--*/
|
--*/
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#include <limits>
|
||||||
#include "util/statistics.h"
|
#include "util/statistics.h"
|
||||||
#include "math/polysat/constraint.h"
|
#include "math/polysat/constraint.h"
|
||||||
#include "math/polysat/eq_constraint.h"
|
#include "math/polysat/eq_constraint.h"
|
||||||
|
@ -54,6 +55,9 @@ namespace polysat {
|
||||||
var_queue m_free_vars;
|
var_queue m_free_vars;
|
||||||
stats m_stats;
|
stats m_stats;
|
||||||
|
|
||||||
|
uint64_t m_max_conflicts { std::numeric_limits<uint64_t>::max() };
|
||||||
|
uint64_t m_max_decisions { std::numeric_limits<uint64_t>::max() };
|
||||||
|
|
||||||
// Per constraint state
|
// Per constraint state
|
||||||
scoped_ptr_vector<constraint> m_constraints;
|
scoped_ptr_vector<constraint> m_constraints;
|
||||||
scoped_ptr_vector<constraint> m_redundant;
|
scoped_ptr_vector<constraint> m_redundant;
|
||||||
|
@ -153,6 +157,9 @@ namespace polysat {
|
||||||
|
|
||||||
bool is_assigned(pvar v) const { return !m_justification[v].is_unassigned(); }
|
bool is_assigned(pvar v) const { return !m_justification[v].is_unassigned(); }
|
||||||
|
|
||||||
|
|
||||||
|
bool should_search();
|
||||||
|
|
||||||
void propagate(pvar v);
|
void propagate(pvar v);
|
||||||
void propagate(pvar v, rational const& val, constraint& c);
|
void propagate(pvar v, rational const& val, constraint& c);
|
||||||
void erase_watch(pvar v, constraint& c);
|
void erase_watch(pvar v, constraint& c);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue