mirror of
https://github.com/Z3Prover/z3
synced 2025-04-23 09:05:31 +00:00
fixes to build warnings
This commit is contained in:
parent
2ac6f8bb06
commit
826835fd7c
21 changed files with 20 additions and 65 deletions
|
@ -569,6 +569,7 @@ public:
|
|||
void traverse_neg_cycle2(bool try_relax, Functor & f) {
|
||||
static unsigned num_conflicts = 0;
|
||||
++num_conflicts;
|
||||
(void)num_conflicts;
|
||||
SASSERT(!is_feasible(m_edges[m_last_enabled_edge]));
|
||||
vector<numeral> potentials;
|
||||
svector<edge_id> edges;
|
||||
|
|
|
@ -294,7 +294,6 @@ namespace smt {
|
|||
|
||||
void dyn_ack_manager::gc() {
|
||||
TRACE("dyn_ack", tout << "dyn_ack GC\n";);
|
||||
unsigned num_deleted = 0;
|
||||
m_to_instantiate.reset();
|
||||
m_qhead = 0;
|
||||
svector<app_pair>::iterator it = m_app_pairs.begin();
|
||||
|
@ -318,7 +317,6 @@ namespace smt {
|
|||
// SASSERT(num_occs > 0);
|
||||
num_occs = static_cast<unsigned>(num_occs * m_params.m_dack_gc_inv_decay);
|
||||
if (num_occs <= 1) {
|
||||
num_deleted++;
|
||||
TRACE("dyn_ack", tout << "2) erasing:\n" << mk_pp(p.first, m) << "\n" << mk_pp(p.second, m) << "\n";);
|
||||
m_app_pair2num_occs.erase(p.first, p.second);
|
||||
m.dec_ref(p.first);
|
||||
|
@ -337,7 +335,6 @@ namespace smt {
|
|||
// app_pair_lt is not a total order on pairs of expressions.
|
||||
// So, we should use stable_sort to avoid different behavior in different platforms.
|
||||
std::stable_sort(m_to_instantiate.begin(), m_to_instantiate.end(), f);
|
||||
// IF_VERBOSE(10, if (num_deleted > 0) verbose_stream() << "dynamic ackermann GC: " << num_deleted << "\n";);
|
||||
}
|
||||
|
||||
class dyn_ack_clause_del_eh : public clause_del_eh {
|
||||
|
@ -519,7 +516,6 @@ namespace smt {
|
|||
|
||||
void dyn_ack_manager::gc_triples() {
|
||||
TRACE("dyn_ack", tout << "dyn_ack GC\n";);
|
||||
unsigned num_deleted = 0;
|
||||
m_triple.m_to_instantiate.reset();
|
||||
m_triple.m_qhead = 0;
|
||||
svector<app_triple>::iterator it = m_triple.m_apps.begin();
|
||||
|
@ -544,7 +540,6 @@ namespace smt {
|
|||
// SASSERT(num_occs > 0);
|
||||
num_occs = static_cast<unsigned>(num_occs * m_params.m_dack_gc_inv_decay);
|
||||
if (num_occs <= 1) {
|
||||
num_deleted++;
|
||||
TRACE("dyn_ack", tout << "2) erasing:\n" << mk_pp(p.first, m) << "\n" << mk_pp(p.second, m) << "\n";);
|
||||
m_triple.m_app2num_occs.erase(p.first, p.second, p.third);
|
||||
m.dec_ref(p.first);
|
||||
|
@ -563,7 +558,6 @@ namespace smt {
|
|||
app_triple_lt f(m_triple.m_app2num_occs);
|
||||
// app_triple_lt is not a total order
|
||||
std::stable_sort(m_triple.m_to_instantiate.begin(), m_triple.m_to_instantiate.end(), f);
|
||||
// IF_VERBOSE(10, if (num_deleted > 0) verbose_stream() << "dynamic ackermann GC: " << num_deleted << "\n";);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -3030,7 +3030,7 @@ namespace smt {
|
|||
template<typename Ext>
|
||||
void theory_arith<Ext>::propagate_bounds() {
|
||||
TRACE("propagate_bounds_detail", display(tout););
|
||||
unsigned num_prop = 0, count = 0;
|
||||
unsigned count = 0;
|
||||
for (unsigned r_idx : m_to_check) {
|
||||
row & r = m_rows[r_idx];
|
||||
if (r.get_base_var() != null_theory_var) {
|
||||
|
@ -3039,34 +3039,19 @@ namespace smt {
|
|||
int upper_idx;
|
||||
is_row_useful_for_bound_prop(r, lower_idx, upper_idx);
|
||||
|
||||
++num_prop;
|
||||
if (lower_idx >= 0)
|
||||
count += imply_bound_for_monomial(r, lower_idx, true);
|
||||
else if (lower_idx == -1)
|
||||
count += imply_bound_for_all_monomials(r, true);
|
||||
else
|
||||
--num_prop;
|
||||
|
||||
++num_prop;
|
||||
if (upper_idx >= 0)
|
||||
count += imply_bound_for_monomial(r, upper_idx, false);
|
||||
else if (upper_idx == -1)
|
||||
count += imply_bound_for_all_monomials(r, false);
|
||||
else
|
||||
--num_prop;
|
||||
|
||||
// sneaking cheap eq detection in this loop
|
||||
propagate_cheap_eq(r_idx);
|
||||
}
|
||||
|
||||
#if 0
|
||||
theory_var v = r.get_base_var();
|
||||
if (!is_int(v) || get_value(v).is_int()) {
|
||||
// If an integer value is not assigned to an integer value, then
|
||||
// bound propagation can diverge.
|
||||
m_in_to_check.remove(v);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1988,6 +1988,7 @@ namespace smt {
|
|||
while (curr != v);
|
||||
|
||||
zero_one_bits const & _bits = m_zero_one_bits[v];
|
||||
(void)num_bits;
|
||||
SASSERT(_bits.size() == num_bits);
|
||||
bool_vector already_found;
|
||||
already_found.resize(bv_sz, false);
|
||||
|
|
|
@ -3495,10 +3495,8 @@ public:
|
|||
|
||||
bool validate_eq(enode* x, enode* y) {
|
||||
static bool s_validating = false;
|
||||
static unsigned s_count = 0;
|
||||
if (s_validating)
|
||||
return true;
|
||||
++s_count;
|
||||
flet<bool> _svalid(s_validating, true);
|
||||
context nctx(m, ctx().get_fparams(), ctx().get_params());
|
||||
add_background(nctx);
|
||||
|
|
|
@ -2127,9 +2127,9 @@ namespace smt {
|
|||
tout << "sum: " << sum << " " << maxsum << " ";
|
||||
tout << ctx.get_assignment(c.lit()) << "\n";);
|
||||
|
||||
SASSERT(sum <= maxsum);
|
||||
SASSERT((sum >= c.k()) == (ctx.get_assignment(c.lit()) == l_true));
|
||||
SASSERT((maxsum < c.k()) == (ctx.get_assignment(c.lit()) == l_false));
|
||||
VERIFY(sum <= maxsum);
|
||||
VERIFY((sum >= c.k()) == (ctx.get_assignment(c.lit()) == l_true));
|
||||
VERIFY((maxsum < c.k()) == (ctx.get_assignment(c.lit()) == l_false));
|
||||
}
|
||||
|
||||
void theory_pb::validate_final_check(ineq& c) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue