3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-07-31 08:23:17 +00:00

fix unsoundness reported in issue #777, disable ematching on recursive function definition axioms exposed in #793

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2016-11-19 15:29:43 -08:00
parent 2ff5af7d42
commit 6a9b5ea3af
2 changed files with 43 additions and 39 deletions

View file

@ -901,8 +901,11 @@ namespace pdr {
SASSERT(m_prev);
SASSERT(children().empty());
if (this == m_next) {
SASSERT(m_prev == this);
if (root == this) {
root = 0;
}
}
else {
m_next->m_prev = m_prev;
m_prev->m_next = m_next;

View file

@ -186,7 +186,7 @@ namespace smt {
}
bool check_quantifier(quantifier* q) {
return m_context.is_relevant(q) && m_context.get_assignment(q) == l_true; // TBD: && !m_context->get_manager().is_rec_fun_def(q);
return m_context.is_relevant(q) && m_context.get_assignment(q) == l_true; // && !m_context.get_manager().is_rec_fun_def(q);
}
bool quick_check_quantifiers() {
@ -357,8 +357,6 @@ namespace smt {
}
void quantifier_manager::reset() {
#pragma omp critical (quantifier_manager)
{
context & ctx = m_imp->m_context;
smt_params & p = m_imp->m_params;
quantifier_manager_plugin * plugin = m_imp->m_plugin->mk_fresh();
@ -366,7 +364,6 @@ namespace smt {
m_imp = new (m_imp) imp(*this, ctx, p, plugin);
plugin->set_manager(*this);
}
}
void quantifier_manager::display(std::ostream & out) const {
}
@ -481,7 +478,12 @@ namespace smt {
virtual void assign_eh(quantifier * q) {
m_active = true;
if (m_fparams->m_ematching) {
if (!m_fparams->m_ematching) {
return;
}
if (m_context->get_manager().is_rec_fun_def(q) && mbqi_enabled(q)) {
return;
}
bool has_unary_pattern = false;
unsigned num_patterns = q->get_num_patterns();
for (unsigned i = 0; i < num_patterns; i++) {
@ -512,7 +514,6 @@ namespace smt {
j++;
}
}
}
bool use_ematching() const {
return m_fparams->m_ematching && !m_qm->empty();