mirror of
https://github.com/Z3Prover/z3
synced 2025-09-06 18:01:07 +00:00
Weaken evaluation for new constraints in viable lemma
This commit is contained in:
parent
be20c0d54e
commit
21ea05b31c
3 changed files with 27 additions and 17 deletions
|
@ -75,15 +75,23 @@ namespace polysat {
|
|||
m_literals.push_back(c.blit());
|
||||
}
|
||||
|
||||
void clause_builder::insert_eval(sat::literal lit, bool status) {
|
||||
insert_eval(m_solver->lit2cnstr(lit), status);
|
||||
void clause_builder::insert_eval(sat::literal lit) {
|
||||
insert_eval(m_solver->lit2cnstr(lit));
|
||||
}
|
||||
|
||||
void clause_builder::insert_eval(signed_constraint c, bool status) {
|
||||
if (c.bvalue(*m_solver) == l_undef) {
|
||||
sat::literal lit = c.blit();
|
||||
m_solver->assign_eval(status ? lit : ~lit);
|
||||
}
|
||||
void clause_builder::insert_eval(signed_constraint c) {
|
||||
if (c.bvalue(*m_solver) == l_undef)
|
||||
m_solver->assign_eval(~c.blit());
|
||||
insert(c);
|
||||
}
|
||||
|
||||
void clause_builder::insert_try_eval(sat::literal lit) {
|
||||
insert_eval(m_solver->lit2cnstr(lit));
|
||||
}
|
||||
|
||||
void clause_builder::insert_try_eval(signed_constraint c) {
|
||||
if (c.bvalue(*m_solver) == l_undef && c.is_currently_false(*m_solver))
|
||||
m_solver->assign_eval(~c.blit());
|
||||
insert(c);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue