mirror of
https://github.com/Z3Prover/z3
synced 2025-08-08 12:11:23 +00:00
update assign to check fixed bits afterwards
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
42aad423c9
commit
a68bbb53e4
1 changed files with 24 additions and 12 deletions
|
@ -90,20 +90,31 @@ namespace polysat {
|
||||||
m_fixed_bits.init(v);
|
m_fixed_bits.init(v);
|
||||||
m_explain.reset();
|
m_explain.reset();
|
||||||
init_overlaps(v);
|
init_overlaps(v);
|
||||||
check_fixed_bits(v, value);
|
bool first = true;
|
||||||
check_disequal_lin(v, value);
|
while (true) {
|
||||||
check_equal_lin(v, value);
|
for (auto const& [w, offset] : m_overlaps) {
|
||||||
for (auto const& [w, offset] : m_overlaps) {
|
for (auto& layer : m_units[w].get_layers()) {
|
||||||
for (auto& layer : m_units[w].get_layers()) {
|
entry* e = find_overlap(w, layer, value);
|
||||||
entry* e = find_overlap(w, layer, value);
|
if (!e)
|
||||||
if (!e)
|
continue;
|
||||||
continue;
|
|
||||||
|
|
||||||
m_explain.push_back({ e, value });
|
m_explain.push_back({ e, value });
|
||||||
m_explain_kind = explain_t::assignment;
|
m_explain_kind = explain_t::assignment;
|
||||||
return false;
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
if (!first)
|
||||||
|
return true;
|
||||||
|
first = false;
|
||||||
|
if (!check_fixed_bits(v, value))
|
||||||
|
continue;
|
||||||
|
if (!check_disequal_lin(v, value))
|
||||||
|
continue;
|
||||||
|
if (!check_equal_lin(v, value))
|
||||||
|
continue;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -397,6 +408,7 @@ namespace polysat {
|
||||||
if (!intersect(v, e)) {
|
if (!intersect(v, e)) {
|
||||||
display(verbose_stream());
|
display(verbose_stream());
|
||||||
display_explain(verbose_stream() << "explain\n");
|
display_explain(verbose_stream() << "explain\n");
|
||||||
|
UNREACHABLE();
|
||||||
SASSERT(false);
|
SASSERT(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue