Skip to content

Commit

Permalink
fix #4575 - correction set resolution only works with uniform weights
Browse files Browse the repository at this point in the history
Signed-off-by: Nikolaj Bjorner <[email protected]>
  • Loading branch information
NikolajBjorner committed Jul 20, 2020
1 parent ebce0b3 commit 1d8d85a
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions src/opt/maxres.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -535,14 +535,19 @@ class maxres : public maxsmt_solver_base {
trace();
if (m_c.num_objectives() == 1 && m_pivot_on_cs && m_csmodel.get() && m_correction_set_size < core.size()) {
exprs cs;
TRACE("opt", tout << "cs " << m_correction_set_size << " " << core.size() << "\n";);
get_current_correction_set(m_csmodel.get(), cs);
m_correction_set_size = cs.size();
if (m_correction_set_size < core.size()) {
process_sat(cs);
TRACE("opt", tout << "cs " << m_correction_set_size << " " << core.size() << "\n";);
if (m_correction_set_size >= core.size())
return;
rational w(0);
for (expr* a : m_asms) {
rational w1 = m_asm2weight[a];
if (w != 0 && w1 != w) return;
w = w1;
}
}
process_sat(cs);
}
}

bool get_mus_model(model_ref& mdl) {
Expand Down

0 comments on commit 1d8d85a

Please sign in to comment.