mirror of
https://github.com/Z3Prover/z3
synced 2025-04-29 20:05:51 +00:00
propagate at the right level
This commit is contained in:
parent
40d62af796
commit
f2c79b851f
4 changed files with 23 additions and 18 deletions
|
@ -144,17 +144,19 @@ namespace polysat {
|
|||
auto it = m_saturation_premises.find_iterator(c);
|
||||
if (it == m_saturation_premises.end())
|
||||
return;
|
||||
unsigned active_level = 0;
|
||||
auto& premises = it->m_value;
|
||||
clause_builder c_lemma(*m_solver);
|
||||
for (auto premise : premises) {
|
||||
handle_saturation_premises(premise);
|
||||
c_lemma.push_literal(~premise.blit());
|
||||
active_level = std::max(active_level, m_solver->m_bvars.level(premise.blit()));
|
||||
}
|
||||
c_lemma.push_literal(c.blit());
|
||||
clause* cl = cm().store(c_lemma.build());
|
||||
if (cl->size() == 1)
|
||||
c->set_unit_clause(cl);
|
||||
m_solver->assign_bool(c.blit(), cl, nullptr);
|
||||
m_solver->propagate_bool_at(active_level, c.blit(), cl);
|
||||
}
|
||||
|
||||
/** Create fallback lemma that excludes the current search state */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue