mirror of
https://github.com/Z3Prover/z3
synced 2025-04-23 09:05:31 +00:00
debugging opt
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
90bd02b5f7
commit
af55088b78
8 changed files with 92 additions and 34 deletions
|
@ -31,7 +31,7 @@ struct theory_pb_params {
|
|||
m_pb_conflict_frequency(0),
|
||||
m_pb_learn_complements(true),
|
||||
m_pb_enable_compilation(true),
|
||||
m_pb_enable_simplex(false)
|
||||
m_pb_enable_simplex(false)
|
||||
{}
|
||||
|
||||
void updt_params(params_ref const & p);
|
||||
|
|
|
@ -388,16 +388,13 @@ namespace smt {
|
|||
}
|
||||
}
|
||||
|
||||
// m_simplex.display(std::cout);
|
||||
literal_vector lits;
|
||||
for (unsigned i = 0; i < explains.size(); ++i) {
|
||||
literal lit(explains[i]);
|
||||
if (lit != null_literal) {
|
||||
//std::cout << lit << " ";
|
||||
lits.push_back(~lit);
|
||||
}
|
||||
}
|
||||
//std::cout << "\n";
|
||||
|
||||
m_stats.m_num_conflicts++;
|
||||
justification* js = 0;
|
||||
|
@ -799,8 +796,11 @@ namespace smt {
|
|||
unsigned slack = info.m_slack;
|
||||
if (is_true) {
|
||||
update_bound(slack, literal(v), true, coeff);
|
||||
if (c->is_eq()) {
|
||||
update_bound(slack, literal(v), false, coeff);
|
||||
}
|
||||
}
|
||||
else {
|
||||
else if (c->is_ge()) {
|
||||
m_mpq_inf_mgr.sub(coeff, std::make_pair(mpq(1),mpq(0)), coeff);
|
||||
update_bound(slack, ~literal(v), false, coeff);
|
||||
}
|
||||
|
@ -1678,10 +1678,14 @@ namespace smt {
|
|||
if (!conseq.sign() && j->get_from_theory() == get_id()) {
|
||||
pbj = dynamic_cast<pb_justification*>(j);
|
||||
}
|
||||
if (pbj && pbj->get_ineq().is_ge()) {
|
||||
if (pbj && pbj->get_ineq().is_eq()) {
|
||||
// only resolve >= that are positive consequences.
|
||||
pbj = 0;
|
||||
}
|
||||
if (pbj && pbj->get_ineq().lit() == conseq) {
|
||||
// can't resolve against literal representing inequality.
|
||||
pbj = 0;
|
||||
}
|
||||
if (pbj) {
|
||||
// weaken the lemma and resolve.
|
||||
TRACE("pb", display(tout << "resolve with inequality", pbj->get_ineq(), true););
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue