From 9f6a0a868af38f4a7baa0766bae32de7af4d8754 Mon Sep 17 00:00:00 2001 From: Nikolaj Bjorner Date: Mon, 7 Dec 2020 14:57:50 -0800 Subject: [PATCH] fix #4389 fix #4859 The bugs are duplicates --- src/opt/opt_context.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/opt/opt_context.cpp b/src/opt/opt_context.cpp index f354cbb033b..8974a379aad 100644 --- a/src/opt/opt_context.cpp +++ b/src/opt/opt_context.cpp @@ -820,7 +820,14 @@ namespace opt { mk_simplify_tactic(m)); opt_params optp(m_params); tactic_ref tac1, tac2, tac3, tac4; - if (optp.elim_01() && m_logic.is_null()) { + bool has_dep = false; + for (unsigned i = 0; !has_dep && i < g->size(); ++i) { + ptr_vector deps; + expr_dependency_ref core(g->dep(i), m); + m.linearize(core, deps); + has_dep |= !deps.empty(); + } + if (optp.elim_01() && m_logic.is_null() && !has_dep) { tac1 = mk_dt2bv_tactic(m); tac2 = mk_lia2card_tactic(m); tac3 = mk_eq2bv_tactic(m);