mirror of
https://github.com/Z3Prover/z3
synced 2025-06-06 22:23:22 +00:00
fix bound miss-computation, include sporadic nra check for #4913
This commit is contained in:
parent
8546cf97d7
commit
21c626e3ee
1 changed files with 7 additions and 2 deletions
|
@ -1470,7 +1470,7 @@ void core::check_weighted(unsigned sz, std::pair<unsigned, std::function<void(vo
|
||||||
if (n < checks[i].first) {
|
if (n < checks[i].first) {
|
||||||
seen.insert(i);
|
seen.insert(i);
|
||||||
checks[i].second();
|
checks[i].second();
|
||||||
bound -= n;
|
bound -= checks[i].first;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
n -= checks[i].first;
|
n -= checks[i].first;
|
||||||
|
@ -1523,9 +1523,14 @@ lbool core::check(vector<lemma>& l_vec) {
|
||||||
{ 2, check2 },
|
{ 2, check2 },
|
||||||
{ 1, check3 }};
|
{ 1, check3 }};
|
||||||
check_weighted(3, checks);
|
check_weighted(3, checks);
|
||||||
|
|
||||||
|
if (!conflict_found() && m_nla_settings.run_nra() && random() % 30 == 0) {
|
||||||
|
ret = m_nra.check();
|
||||||
|
m_stats.m_nra_calls++;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (l_vec.empty() && !done() && m_nla_settings.run_nra()) {
|
if (l_vec.empty() && !done() && m_nla_settings.run_nra() && ret == l_undef) {
|
||||||
ret = m_nra.check();
|
ret = m_nra.check();
|
||||||
m_stats.m_nra_calls++;
|
m_stats.m_nra_calls++;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue