3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-27 10:55:50 +00:00

retain default configuration between calls to SMT tactic so that values are not overwritten between calls to smt-setup. Fixes bug #196

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2015-08-25 11:09:10 -07:00
parent 8c11299be6
commit 7639eff29b
3 changed files with 7 additions and 3 deletions

View file

@ -161,9 +161,11 @@ public:
struct scoped_init_ctx {
smt_tactic & m_owner;
smt_params m_params; // smt-setup overwrites parameters depending on the current assertions.
scoped_init_ctx(smt_tactic & o, ast_manager & m):m_owner(o) {
smt::kernel * new_ctx = alloc(smt::kernel, m, o.fparams());
m_params = o.fparams();
smt::kernel * new_ctx = alloc(smt::kernel, m, m_params);
TRACE("smt_tactic", tout << "logic: " << o.m_logic << "\n";);
new_ctx->set_logic(o.m_logic);
if (o.m_callback) {
@ -199,7 +201,8 @@ public:
<< " PREPROCESS: " << fparams().m_preprocess << "\n";
tout << "RELEVANCY: " << fparams().m_relevancy_lvl << "\n";
tout << "fail-if-inconclusive: " << m_fail_if_inconclusive << "\n";
tout << "params_ref: " << m_params_ref << "\n";);
tout << "params_ref: " << m_params_ref << "\n";
tout << "nnf: " << fparams().m_nnf_cnf << "\n";);
TRACE("smt_tactic_detail", in->display(tout););
TRACE("smt_tactic_memory", tout << "wasted_size: " << m.get_allocator().get_wasted_size() << "\n";);
scoped_init_ctx init(*this, m);
@ -239,7 +242,6 @@ public:
else
r = m_ctx->check(assumptions.size(), assumptions.c_ptr());
m_ctx->collect_statistics(m_stats);
switch (r) {
case l_true: {
if (m_fail_if_inconclusive && !in->sat_preserved())