mirror of
https://github.com/Z3Prover/z3
synced 2025-09-05 01:27:41 +00:00
Merge branch 'unstable' of https://git01.codeplex.com/z3 into unstable
This commit is contained in:
commit
6a3e2d0f00
301 changed files with 3699 additions and 5652 deletions
|
@ -1162,7 +1162,7 @@ public:
|
|||
: dparser(ctx, ctx.get_manager()),
|
||||
m_bool_sort(ctx.get_manager()),
|
||||
m_short_sort(ctx.get_manager()),
|
||||
m_use_map_names(ctx.get_params().get_bool(":use-map-names", true)) {
|
||||
m_use_map_names(ctx.get_params().get_bool("use_map_names", true)) {
|
||||
}
|
||||
~wpa_parser_impl() {
|
||||
reset_dealloc_values(m_sort_contents);
|
||||
|
|
|
@ -71,7 +71,7 @@ namespace datalog {
|
|||
m_ctx.set_output_predicate(m_query_pred);
|
||||
m_ctx.apply_default_transformation(mc, m_pc);
|
||||
|
||||
if (m_ctx.get_params().get_bool(":slice", true)) {
|
||||
if (m_ctx.get_params().get_bool("slice", true)) {
|
||||
datalog::rule_transformer transformer(m_ctx);
|
||||
datalog::mk_slice* slice = alloc(datalog::mk_slice, m_ctx);
|
||||
transformer.register_plugin(slice);
|
||||
|
|
|
@ -32,7 +32,7 @@ namespace datalog {
|
|||
class bmc {
|
||||
context& m_ctx;
|
||||
ast_manager& m;
|
||||
front_end_params m_fparams;
|
||||
smt_params m_fparams;
|
||||
smt::kernel m_solver;
|
||||
obj_map<func_decl, sort*> m_pred2sort;
|
||||
obj_map<sort, func_decl*> m_sort2pred;
|
||||
|
|
|
@ -33,6 +33,8 @@ Notes:
|
|||
|
||||
|
||||
class dl_context {
|
||||
// PARAM-TODO temp HACK: added m_params field because cmd_context does not have smt_params anymore
|
||||
smt_params m_params;
|
||||
cmd_context & m_cmd;
|
||||
dl_collected_cmds* m_collected_cmds;
|
||||
unsigned m_ref_count;
|
||||
|
@ -62,7 +64,7 @@ public:
|
|||
void init() {
|
||||
ast_manager& m = m_cmd.m();
|
||||
if (!m_context) {
|
||||
m_context = alloc(datalog::context, m, m_cmd.params());
|
||||
m_context = alloc(datalog::context, m, m_params);
|
||||
}
|
||||
if (!m_decl_plugin) {
|
||||
symbol name("datalog_relation");
|
||||
|
@ -210,7 +212,7 @@ public:
|
|||
datalog::context& dlctx = m_dl_ctx->dlctx();
|
||||
set_background(ctx);
|
||||
dlctx.updt_params(m_params);
|
||||
unsigned timeout = m_params.get_uint(":timeout", UINT_MAX);
|
||||
unsigned timeout = m_params.get_uint("timeout", UINT_MAX);
|
||||
cancel_eh<datalog::context> eh(dlctx);
|
||||
lbool status = l_undef;
|
||||
{
|
||||
|
@ -266,9 +268,9 @@ public:
|
|||
virtual void init_pdescrs(cmd_context & ctx, param_descrs & p) {
|
||||
m_dl_ctx->dlctx().collect_params(p);
|
||||
insert_timeout(p);
|
||||
p.insert(":print-answer", CPK_BOOL, "(default: false) print answer instance(s) to query.");
|
||||
p.insert(":print-certificate", CPK_BOOL, "(default: false) print certificate for reachability or non-reachability.");
|
||||
p.insert(":print-statistics", CPK_BOOL, "(default: false) print statistics.");
|
||||
p.insert("print_answer", CPK_BOOL, "(default: false) print answer instance(s) to query.");
|
||||
p.insert("print_certificate", CPK_BOOL, "(default: false) print certificate for reachability or non-reachability.");
|
||||
p.insert("print_statistics", CPK_BOOL, "(default: false) print statistics.");
|
||||
}
|
||||
|
||||
|
||||
|
@ -283,7 +285,7 @@ private:
|
|||
}
|
||||
|
||||
void print_answer(cmd_context& ctx) {
|
||||
if (m_params.get_bool(":print-answer", false)) {
|
||||
if (m_params.get_bool("print_answer", false)) {
|
||||
datalog::context& dlctx = m_dl_ctx->dlctx();
|
||||
ast_manager& m = ctx.m();
|
||||
expr_ref query_result(dlctx.get_answer_as_formula(), m);
|
||||
|
@ -298,7 +300,7 @@ private:
|
|||
}
|
||||
|
||||
void print_statistics(cmd_context& ctx) {
|
||||
if (m_params.get_bool(":print-statistics", false)) {
|
||||
if (m_params.get_bool("print_statistics", false)) {
|
||||
statistics st;
|
||||
datalog::context& dlctx = m_dl_ctx->dlctx();
|
||||
unsigned long long max_mem = memory::get_max_used_memory();
|
||||
|
@ -312,7 +314,7 @@ private:
|
|||
}
|
||||
|
||||
void print_certificate(cmd_context& ctx) {
|
||||
if (m_params.get_bool(":print-certificate", false)) {
|
||||
if (m_params.get_bool("print_certificate", false)) {
|
||||
datalog::context& dlctx = m_dl_ctx->dlctx();
|
||||
if (!dlctx.display_certificate(ctx.regular_stream())) {
|
||||
throw cmd_exception("certificates are not supported for the selected engine");
|
||||
|
@ -472,8 +474,10 @@ static void install_dl_cmds_aux(cmd_context& ctx, dl_collected_cmds* collected_c
|
|||
ctx.insert(alloc(dl_query_cmd, dl_ctx));
|
||||
ctx.insert(alloc(dl_declare_rel_cmd, dl_ctx));
|
||||
ctx.insert(alloc(dl_declare_var_cmd, dl_ctx));
|
||||
PRIVATE_PARAMS(ctx.insert(alloc(dl_push_cmd, dl_ctx));); // not exposed to keep command-extensions simple.
|
||||
PRIVATE_PARAMS(ctx.insert(alloc(dl_pop_cmd, dl_ctx)););
|
||||
#ifndef _EXTERNAL_RELEASE
|
||||
ctx.insert(alloc(dl_push_cmd, dl_ctx)); // not exposed to keep command-extensions simple.
|
||||
ctx.insert(alloc(dl_pop_cmd, dl_ctx));
|
||||
#endif
|
||||
}
|
||||
|
||||
void install_dl_cmds(cmd_context & ctx) {
|
||||
|
|
|
@ -226,7 +226,7 @@ namespace datalog {
|
|||
//
|
||||
// -----------------------------------
|
||||
|
||||
context::context(ast_manager & m, front_end_params& fp, params_ref const& pa):
|
||||
context::context(ast_manager & m, smt_params& fp, params_ref const& pa):
|
||||
m(m),
|
||||
m_fparams(fp),
|
||||
m_params(pa),
|
||||
|
@ -960,56 +960,56 @@ namespace datalog {
|
|||
}
|
||||
|
||||
void context::collect_params(param_descrs& p) {
|
||||
p.insert(":engine", CPK_SYMBOL, "(default: automatically configured) select 'datalog', PDR 'pdr' engine.");
|
||||
p.insert(":bit-blast", CPK_BOOL, "(default: false) bit-blast bit-vectors (for PDR engine).");
|
||||
p.insert(":default-table", CPK_SYMBOL, "default table implementation: 'sparse' (default), 'hashtable', 'bitvector', 'interval'");
|
||||
p.insert(":default-relation", CPK_SYMBOL, "default relation implementation: 'external_relation', 'pentagon'");
|
||||
p.insert("engine", CPK_SYMBOL, "(default: automatically configured) select 'datalog', PDR 'pdr' engine.");
|
||||
p.insert("bit_blast", CPK_BOOL, "(default: false) bit-blast bit-vectors (for PDR engine).");
|
||||
p.insert("default_table", CPK_SYMBOL, "default table implementation: 'sparse' (default), 'hashtable', 'bitvector', 'interval'");
|
||||
p.insert("default_relation", CPK_SYMBOL, "default relation implementation: 'external_relation', 'pentagon'");
|
||||
|
||||
p.insert(":generate-explanations", CPK_BOOL, "if true, signature of relations will be extended to contain explanations for facts");
|
||||
p.insert(":explanations-on-relation-level", CPK_BOOL, "if true, explanations are generated as history of each relation, "
|
||||
"rather than per fact (:generate-explanations must be set to true for this option to have any effect)");
|
||||
p.insert("generate_explanations", CPK_BOOL, "if true, signature of relations will be extended to contain explanations for facts");
|
||||
p.insert("explanations_on_relation_level", CPK_BOOL, "if true, explanations are generated as history of each relation, "
|
||||
"rather than per fact (generate_explanations must be set to true for this option to have any effect)");
|
||||
|
||||
p.insert(":magic-sets-for-queries", CPK_BOOL, "magic set transformation will be used for queries");
|
||||
p.insert(":unbound-compressor", CPK_BOOL, "auxiliary relations will be introduced to avoid unbound variables in rule heads");
|
||||
p.insert(":similarity-compressor", CPK_BOOL, "rules that differ only in values of constants will be merged into a single rule");
|
||||
p.insert(":similarity-compressor-threshold", CPK_UINT, "if :dl-similiaryt-compressor is on, this value determines how many "
|
||||
p.insert("magic_sets_for_queries", CPK_BOOL, "magic set transformation will be used for queries");
|
||||
p.insert("unbound_compressor", CPK_BOOL, "auxiliary relations will be introduced to avoid unbound variables in rule heads");
|
||||
p.insert("similarity_compressor", CPK_BOOL, "rules that differ only in values of constants will be merged into a single rule");
|
||||
p.insert("similarity_compressor_threshold", CPK_UINT, "if dl_similiaryt_compressor is on, this value determines how many "
|
||||
"similar rules there must be in order for them to be merged");
|
||||
|
||||
p.insert(":all-or-nothing-deltas", CPK_BOOL, "compile rules so that it is enough for the delta relation in union and widening "
|
||||
p.insert("all_or_nothing_deltas", CPK_BOOL, "compile rules so that it is enough for the delta relation in union and widening "
|
||||
"operations to determine only whether the updated relation was modified or not");
|
||||
p.insert(":compile-with-widening", CPK_BOOL, "widening will be used to compile recursive rules");
|
||||
p.insert(":eager-emptiness-checking", CPK_BOOL, "emptiness of affected relations will be checked after each instruction, "
|
||||
p.insert("compile_with_widening", CPK_BOOL, "widening will be used to compile recursive rules");
|
||||
p.insert("eager_emptiness_checking", CPK_BOOL, "emptiness of affected relations will be checked after each instruction, "
|
||||
"so that we may ommit unnecessary instructions");
|
||||
p.insert(":default-table-checked", CPK_BOOL,
|
||||
"if true, the detault table will be :default-table inside a wrapper that checks that "
|
||||
"its results are the same as of :default-table-checker table");
|
||||
p.insert("default_table_checked", CPK_BOOL,
|
||||
"if true, the detault table will be default_table inside a wrapper that checks that "
|
||||
"its results are the same as of default_table_checker table");
|
||||
|
||||
|
||||
p.insert(":initial-restart-timeout", CPK_UINT, "length of saturation run before the first restart (in ms); zero means no restarts");
|
||||
p.insert(":restart-timeout-quotient", CPK_UINT, "restart timeout will be multiplied by this number after each restart");
|
||||
p.insert(":use-map-names", CPK_BOOL, "use names from map files when displaying tuples");
|
||||
p.insert("initial_restart_timeout", CPK_UINT, "length of saturation run before the first restart (in ms); zero means no restarts");
|
||||
p.insert("restart_timeout_quotient", CPK_UINT, "restart timeout will be multiplied by this number after each restart");
|
||||
p.insert("use_map_names", CPK_BOOL, "use names from map files when displaying tuples");
|
||||
|
||||
p.insert(":output-profile", CPK_BOOL, "determines whether profile informations should be output when outputting Datalog rules or instructions");
|
||||
p.insert(":output-tuples", CPK_BOOL, "determines whether tuples for output predicates should be output");
|
||||
p.insert(":profile-timeout-milliseconds", CPK_UINT, "instructions and rules that took less than the threshold will not be printed when printed the instruction/rule list");
|
||||
p.insert("output_profile", CPK_BOOL, "determines whether profile informations should be output when outputting Datalog rules or instructions");
|
||||
p.insert("output_tuples", CPK_BOOL, "determines whether tuples for output predicates should be output");
|
||||
p.insert("profile_timeout_milliseconds", CPK_UINT, "instructions and rules that took less than the threshold will not be printed when printed the instruction/rule list");
|
||||
|
||||
p.insert(":print-with-fixedpoint-extensions", CPK_BOOL, "(default true) use SMT-LIB2 fixedpoint extensions, instead of pure SMT2, when printing rules");
|
||||
p.insert(":print-low-level-smt2", CPK_BOOL, "(default false) use (faster) low-level SMT2 printer (the printer is scalable but the result may not be as readable)");
|
||||
p.insert(":print-with-variable-declarations", CPK_BOOL, "(default true) use variable declarations when displaying rules (instead of attempting to use original names)");
|
||||
p.insert("print_with_fixedpoint_extensions", CPK_BOOL, "(default true) use SMT-LIB2 fixedpoint extensions, instead of pure SMT2, when printing rules");
|
||||
p.insert("print_low_level_smt2", CPK_BOOL, "(default false) use (faster) low-level SMT2 printer (the printer is scalable but the result may not be as readable)");
|
||||
p.insert("print_with_variable_declarations", CPK_BOOL, "(default true) use variable declarations when displaying rules (instead of attempting to use original names)");
|
||||
|
||||
PRIVATE_PARAMS(
|
||||
p.insert(":dbg-fpr-nonempty-relation-signature", CPK_BOOL,
|
||||
"if true, finite_product_relation will attempt to avoid creating inner relation with empty signature "
|
||||
"by putting in half of the table columns, if it would have been empty otherwise");
|
||||
#ifndef _EXTERNAL_RELEASE
|
||||
p.insert("dbg_fpr_nonempty_relation_signature", CPK_BOOL,
|
||||
"if true, finite_product_relation will attempt to avoid creating inner relation with empty signature "
|
||||
"by putting in half of the table columns, if it would have been empty otherwise");
|
||||
|
||||
p.insert(":smt-relation-ground-recursive", CPK_BOOL, "Ensure recursive relation is ground in union");
|
||||
);
|
||||
|
||||
p.insert(":fix-unbound-vars", CPK_BOOL, "fix unbound variables in tail");
|
||||
p.insert(":default-table-checker", CPK_SYMBOL, "see :default-table-checked");
|
||||
p.insert(":inline-linear", CPK_BOOL, "(default true) try linear inlining method");
|
||||
p.insert(":inline-eager", CPK_BOOL, "(default true) try eager inlining of rules");
|
||||
PRIVATE_PARAMS(p.insert(":inline-linear-branch", CPK_BOOL, "try linear inlining method with potential expansion"););
|
||||
p.insert("smt_relation_ground_recursive", CPK_BOOL, "Ensure recursive relation is ground in union");
|
||||
p.insert("inline_linear_branch", CPK_BOOL, "try linear inlining method with potential expansion");
|
||||
#endif
|
||||
p.insert("fix_unbound_vars", CPK_BOOL, "fix unbound variables in tail");
|
||||
p.insert("default_table_checker", CPK_SYMBOL, "see default_table_checked");
|
||||
p.insert("inline_linear", CPK_BOOL, "(default true) try linear inlining method");
|
||||
p.insert("inline_eager", CPK_BOOL, "(default true) try eager inlining of rules");
|
||||
|
||||
|
||||
pdr::dl_interface::collect_params(p);
|
||||
bmc::collect_params(p);
|
||||
|
@ -1190,7 +1190,7 @@ namespace datalog {
|
|||
};
|
||||
|
||||
void context::configure_engine() {
|
||||
symbol e = m_params.get_sym(":engine", symbol());
|
||||
symbol e = m_params.get_sym("engine", symbol());
|
||||
|
||||
if (e == symbol("datalog")) {
|
||||
m_engine = DATALOG_ENGINE;
|
||||
|
@ -1668,16 +1668,15 @@ namespace datalog {
|
|||
expr_ref fml(m);
|
||||
expr_ref_vector rules(m);
|
||||
svector<symbol> names;
|
||||
bool use_fixedpoint_extensions = m_params.get_bool(":print-with-fixedpoint-extensions", true);
|
||||
bool print_low_level = m_params.get_bool(":print-low-level-smt2", false);
|
||||
bool do_declare_vars = m_params.get_bool(":print-with-variable-declarations", true);
|
||||
bool use_fixedpoint_extensions = m_params.get_bool("print_with_fixedpoint_extensions", true);
|
||||
bool print_low_level = m_params.get_bool("print_low_level_smt2", false);
|
||||
bool do_declare_vars = m_params.get_bool("print_with_variable_declarations", true);
|
||||
|
||||
#define PP(_e_) if (print_low_level) out << mk_smt_pp(_e_, m); else ast_smt2_pp(out, _e_, env, params);
|
||||
#define PP(_e_) if (print_low_level) out << mk_smt_pp(_e_, m); else ast_smt2_pp(out, _e_, env);
|
||||
|
||||
get_rules_as_formulas(rules, names);
|
||||
|
||||
smt2_pp_environment_dbg env(m);
|
||||
pp_params params;
|
||||
mk_fresh_name fresh_names;
|
||||
collect_free_funcs(num_axioms, axioms, visited, visitor, fresh_names);
|
||||
collect_free_funcs(rules.size(), rules.c_ptr(), visited, visitor, fresh_names);
|
||||
|
@ -1719,7 +1718,7 @@ namespace datalog {
|
|||
func_decl* f = *it;
|
||||
out << "(declare-rel " << f->get_name() << " (";
|
||||
for (unsigned i = 0; i < f->get_arity(); ++i) {
|
||||
ast_smt2_pp(out, f->get_domain(i), env, params);
|
||||
ast_smt2_pp(out, f->get_domain(i), env);
|
||||
if (i + 1 < f->get_arity()) {
|
||||
out << " ";
|
||||
}
|
||||
|
@ -1796,7 +1795,6 @@ namespace datalog {
|
|||
//
|
||||
smt2_pp_environment_dbg env(m);
|
||||
var_subst vsubst(m, false);
|
||||
pp_params param;
|
||||
|
||||
expr_ref_vector fresh_vars(m), subst(m);
|
||||
expr_ref res(m);
|
||||
|
@ -1839,7 +1837,7 @@ namespace datalog {
|
|||
symbol name = fresh_names.next();
|
||||
fresh_vars.push_back(m.mk_const(name, s));
|
||||
out << "(declare-var " << name << " ";
|
||||
ast_smt2_pp(out, s, env, param);
|
||||
ast_smt2_pp(out, s, env);
|
||||
out << ")\n";
|
||||
}
|
||||
subst.push_back(fresh_vars[vars[max_var]].get());
|
||||
|
|
|
@ -24,7 +24,7 @@ Revision History:
|
|||
#undef max
|
||||
#endif
|
||||
#include"arith_decl_plugin.h"
|
||||
#include"front_end_params.h"
|
||||
#include"smt_params.h"
|
||||
#include"map.h"
|
||||
#include"th_rewriter.h"
|
||||
#include"str_hashtable.h"
|
||||
|
@ -78,7 +78,7 @@ namespace datalog {
|
|||
typedef vector<std::pair<func_decl*,relation_fact> > fact_vector;
|
||||
|
||||
ast_manager & m;
|
||||
front_end_params& m_fparams;
|
||||
smt_params& m_fparams;
|
||||
params_ref m_params;
|
||||
dl_decl_util m_decl_util;
|
||||
th_rewriter m_rewriter;
|
||||
|
@ -122,7 +122,7 @@ namespace datalog {
|
|||
|
||||
|
||||
public:
|
||||
context(ast_manager & m, front_end_params& params, params_ref const& p = params_ref());
|
||||
context(ast_manager & m, smt_params& params, params_ref const& p = params_ref());
|
||||
~context();
|
||||
void reset();
|
||||
|
||||
|
@ -149,32 +149,32 @@ namespace datalog {
|
|||
relation_manager & get_rmanager() { return m_rmanager; }
|
||||
const relation_manager & get_rmanager() const { return m_rmanager; }
|
||||
rule_manager & get_rule_manager() { return m_rule_manager; }
|
||||
front_end_params & get_fparams() const { return m_fparams; }
|
||||
smt_params & get_fparams() const { return m_fparams; }
|
||||
params_ref const& get_params() const { return m_params; }
|
||||
DL_ENGINE get_engine() { configure_engine(); return m_engine; }
|
||||
th_rewriter& get_rewriter() { return m_rewriter; }
|
||||
var_subst & get_var_subst() { return m_var_subst; }
|
||||
dl_decl_util & get_decl_util() { return m_decl_util; }
|
||||
|
||||
bool output_profile() const { return m_params.get_bool(":output-profile", false); }
|
||||
bool fix_unbound_vars() const { return m_params.get_bool(":fix-unbound-vars", false); }
|
||||
symbol default_table() const { return m_params.get_sym(":default-table", symbol("sparse")); }
|
||||
symbol default_relation() const { return m_params.get_sym(":default-relation", external_relation_plugin::get_name()); }
|
||||
symbol default_table_checker() const { return m_params.get_sym(":default-table-checker", symbol("sparse")); }
|
||||
bool default_table_checked() const { return m_params.get_bool(":default-table-checked", false); }
|
||||
bool dbg_fpr_nonempty_relation_signature() const { return m_params.get_bool(":dbg-fpr-nonempty-relation-signatures", false); }
|
||||
unsigned dl_profile_milliseconds_threshold() const { return m_params.get_uint(":profile-milliseconds-threshold", 0); }
|
||||
bool all_or_nothing_deltas() const { return m_params.get_bool(":all-or-nothing-deltas", false); }
|
||||
bool compile_with_widening() const { return m_params.get_bool(":compile-with-widening", false); }
|
||||
bool unbound_compressor() const { return m_params.get_bool(":unbound-compressor", true); }
|
||||
bool similarity_compressor() const { return m_params.get_bool(":similarity-compressor", true); }
|
||||
unsigned similarity_compressor_threshold() const { return m_params.get_uint(":similarity-compressor-threshold", 11); }
|
||||
bool output_profile() const { return m_params.get_bool("output_profile", false); }
|
||||
bool fix_unbound_vars() const { return m_params.get_bool("fix_unbound_vars", false); }
|
||||
symbol default_table() const { return m_params.get_sym("default_table", symbol("sparse")); }
|
||||
symbol default_relation() const { return m_params.get_sym("default_relation", external_relation_plugin::get_name()); }
|
||||
symbol default_table_checker() const { return m_params.get_sym("default_table_checker", symbol("sparse")); }
|
||||
bool default_table_checked() const { return m_params.get_bool("default_table_checked", false); }
|
||||
bool dbg_fpr_nonempty_relation_signature() const { return m_params.get_bool("dbg_fpr_nonempty_relation_signatures", false); }
|
||||
unsigned dl_profile_milliseconds_threshold() const { return m_params.get_uint("profile_milliseconds_threshold", 0); }
|
||||
bool all_or_nothing_deltas() const { return m_params.get_bool("all_or_nothing_deltas", false); }
|
||||
bool compile_with_widening() const { return m_params.get_bool("compile_with_widening", false); }
|
||||
bool unbound_compressor() const { return m_params.get_bool("unbound_compressor", true); }
|
||||
bool similarity_compressor() const { return m_params.get_bool("similarity_compressor", true); }
|
||||
unsigned similarity_compressor_threshold() const { return m_params.get_uint("similarity_compressor_threshold", 11); }
|
||||
unsigned soft_timeout() const { return m_fparams.m_soft_timeout; }
|
||||
unsigned initial_restart_timeout() const { return m_params.get_uint(":initial-restart-timeout", 0); }
|
||||
bool generate_explanations() const { return m_params.get_bool(":generate-explanations", false); }
|
||||
bool explanations_on_relation_level() const { return m_params.get_bool(":explanations-on-relation-level", false); }
|
||||
bool magic_sets_for_queries() const { return m_params.get_bool(":magic-sets-for-queries", false); }
|
||||
bool eager_emptiness_checking() const { return m_params.get_bool(":eager-emptiness-checking", true); }
|
||||
unsigned initial_restart_timeout() const { return m_params.get_uint("initial_restart_timeout", 0); }
|
||||
bool generate_explanations() const { return m_params.get_bool("generate_explanations", false); }
|
||||
bool explanations_on_relation_level() const { return m_params.get_bool("explanations_on_relation_level", false); }
|
||||
bool magic_sets_for_queries() const { return m_params.get_bool("magic_sets_for_queries", false); }
|
||||
bool eager_emptiness_checking() const { return m_params.get_bool("eager_emptiness_checking", true); }
|
||||
|
||||
void register_finite_sort(sort * s, sort_kind k);
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@ namespace datalog {
|
|||
a(m),
|
||||
rm(ctx.get_rule_manager()),
|
||||
m_rewriter(m, m_params){
|
||||
m_params.set_bool(":expand-select-store",true);
|
||||
m_params.set_bool("expand_select_store",true);
|
||||
m_rewriter.updt_params(m_params);
|
||||
}
|
||||
|
||||
|
|
|
@ -165,14 +165,14 @@ namespace datalog {
|
|||
m_rules(ctx.get_rule_manager()),
|
||||
m_blaster(ctx.get_manager(), m_params),
|
||||
m_rewriter(ctx.get_manager(), ctx, m_rules) {
|
||||
m_params.set_bool(":blast-full", true);
|
||||
m_params.set_bool(":blast-quant", true);
|
||||
m_params.set_bool("blast_full", true);
|
||||
m_params.set_bool("blast_quant", true);
|
||||
m_blaster.updt_params(m_params);
|
||||
}
|
||||
|
||||
rule_set * operator()(rule_set const & source, model_converter_ref& mc, proof_converter_ref& pc) {
|
||||
// TODO mc, pc
|
||||
if (!m_context.get_params().get_bool(":bit-blast", false)) {
|
||||
if (!m_context.get_params().get_bool("bit_blast", false)) {
|
||||
return 0;
|
||||
}
|
||||
if (m_context.get_engine() != PDR_ENGINE) {
|
||||
|
|
|
@ -751,7 +751,7 @@ namespace datalog {
|
|||
valid.resize(sz, true);
|
||||
|
||||
params_ref const& params = m_context.get_params();
|
||||
bool allow_branching = params.get_bool(":inline-linear-branch", false);
|
||||
bool allow_branching = params.get_bool("inline_linear_branch", false);
|
||||
|
||||
for (unsigned i = 0; i < sz; ++i) {
|
||||
|
||||
|
@ -867,7 +867,7 @@ namespace datalog {
|
|||
|
||||
scoped_ptr<rule_set> res = alloc(rule_set, m_context);
|
||||
|
||||
if (params.get_bool(":inline-eager", true)) {
|
||||
if (params.get_bool("inline_eager", true)) {
|
||||
TRACE("dl", source.display(tout << "before eager inlining\n"););
|
||||
plan_inlining(source);
|
||||
something_done = transform_rules(source, *res);
|
||||
|
@ -879,7 +879,7 @@ namespace datalog {
|
|||
TRACE("dl", res->display(tout << "after eager inlining\n"););
|
||||
}
|
||||
|
||||
if (params.get_bool(":inline-linear", true) && inline_linear(res)) {
|
||||
if (params.get_bool("inline_linear", true) && inline_linear(res)) {
|
||||
something_done = true;
|
||||
}
|
||||
|
||||
|
|
|
@ -129,7 +129,7 @@ namespace datalog {
|
|||
}
|
||||
IF_VERBOSE(10, verbose_stream() << "Checking emptiness...\n"; );
|
||||
|
||||
front_end_params& params = get_plugin().get_fparams();
|
||||
smt_params& params = get_plugin().get_fparams();
|
||||
// [Leo]: asserted_formulas do not have support for der.
|
||||
// We should use the tactics der.
|
||||
// flet<bool> flet2(params.m_der, true);
|
||||
|
@ -182,7 +182,7 @@ namespace datalog {
|
|||
expr_ref fml_free(m), fml_inst(m);
|
||||
fml_free = m.mk_and(facts, m.mk_not(get_relation()));
|
||||
instantiate(fml_free, fml_inst);
|
||||
front_end_params& params = get_plugin().get_fparams();
|
||||
smt_params& params = get_plugin().get_fparams();
|
||||
// [Leo]: asserted_formulas do not have support for qe nor der.
|
||||
// We should use the tactics qe and der.
|
||||
// BTW, qe at asserted_formulas was disabled when we moved to codeplex, but the field m_quant_elim was not deleted.
|
||||
|
@ -239,7 +239,7 @@ namespace datalog {
|
|||
|
||||
void smt_relation::display_finite(std::ostream & out) const {
|
||||
ast_manager& m = get_manager();
|
||||
front_end_params& params = get_plugin().get_fparams();
|
||||
smt_params& params = get_plugin().get_fparams();
|
||||
expr* r = get_relation();
|
||||
expr_ref tmp(m);
|
||||
expr_ref_vector values(m), eqs(m);
|
||||
|
@ -524,7 +524,7 @@ namespace datalog {
|
|||
|
||||
expr_ref rInst(m), srcInst(m), tmp(m), tmp1(m);
|
||||
expr_ref notR(m), srcGround(m);
|
||||
front_end_params& fparams = get(r).get_plugin().get_fparams();
|
||||
smt_params& fparams = get(r).get_plugin().get_fparams();
|
||||
params_ref const& params = get(r).get_plugin().get_params();
|
||||
|
||||
get(r).instantiate(get(r).get_relation(), rInst);
|
||||
|
@ -533,7 +533,7 @@ namespace datalog {
|
|||
|
||||
IF_VERBOSE(10, verbose_stream() << "Computing delta...\n"; );
|
||||
|
||||
if (params.get_bool(":smt-relation-ground-recursive", false)) {
|
||||
if (params.get_bool("smt_relation_ground_recursive", false)) {
|
||||
// ensure R is ground. Simplify S using assumption not R
|
||||
if (!is_ground(rInst)) {
|
||||
proof_ref pr(m);
|
||||
|
@ -730,8 +730,8 @@ namespace datalog {
|
|||
return symbol(m_counter++);
|
||||
}
|
||||
|
||||
front_end_params& smt_relation_plugin::get_fparams() {
|
||||
return const_cast<front_end_params&>(get_manager().get_context().get_fparams());
|
||||
smt_params& smt_relation_plugin::get_fparams() {
|
||||
return const_cast<smt_params&>(get_manager().get_context().get_fparams());
|
||||
}
|
||||
|
||||
params_ref const& smt_relation_plugin::get_params() {
|
||||
|
|
|
@ -20,7 +20,7 @@ Revision History:
|
|||
#define _DL_SMT_RELATION_H_
|
||||
|
||||
#include "dl_base.h"
|
||||
#include "front_end_params.h"
|
||||
#include "smt_params.h"
|
||||
#include "params.h"
|
||||
|
||||
namespace datalog {
|
||||
|
@ -70,7 +70,7 @@ namespace datalog {
|
|||
|
||||
symbol fresh_name();
|
||||
|
||||
front_end_params& get_fparams();
|
||||
smt_params& get_fparams();
|
||||
|
||||
params_ref const& get_params();
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ class horn_tactic : public tactic {
|
|||
struct imp {
|
||||
ast_manager& m;
|
||||
datalog::context m_ctx;
|
||||
front_end_params m_fparams;
|
||||
smt_params m_fparams;
|
||||
|
||||
imp(ast_manager & m, params_ref const & p):
|
||||
m(m),
|
||||
|
@ -168,9 +168,9 @@ class horn_tactic : public tactic {
|
|||
bool produce_proofs = g->proofs_enabled();
|
||||
|
||||
if (produce_proofs) {
|
||||
if (!m_ctx.get_params().get_bool(":generate-proof-trace", true)) {
|
||||
if (!m_ctx.get_params().get_bool("generate_proof_trace", true)) {
|
||||
params_ref params = m_ctx.get_params();
|
||||
params.set_bool(":generate-proof-trace", true);
|
||||
params.set_bool("generate_proof_trace", true);
|
||||
updt_params(params);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -72,7 +72,7 @@ namespace nlarith {
|
|||
bool m_enable_linear;
|
||||
app_ref m_zero;
|
||||
app_ref m_one;
|
||||
front_end_params m_params;
|
||||
smt_params m_params;
|
||||
basic_simplifier_plugin m_bs;
|
||||
arith_simplifier_plugin m_rw;
|
||||
arith_rewriter m_rw1;
|
||||
|
|
|
@ -1122,7 +1122,7 @@ namespace pdr {
|
|||
// context
|
||||
|
||||
context::context(
|
||||
front_end_params& fparams,
|
||||
smt_params& fparams,
|
||||
params_ref const& params,
|
||||
ast_manager& m
|
||||
)
|
||||
|
@ -1133,7 +1133,7 @@ namespace pdr {
|
|||
m_pm(m_fparams, m_params, m),
|
||||
m_query_pred(m),
|
||||
m_query(0),
|
||||
m_search(m_params.get_bool(":bfs-model-search", true)),
|
||||
m_search(m_params.get_bool("bfs_model_search", true)),
|
||||
m_last_result(l_undef),
|
||||
m_inductive_lvl(0),
|
||||
m_cancel(false)
|
||||
|
@ -1358,7 +1358,7 @@ namespace pdr {
|
|||
};
|
||||
|
||||
void context::validate() {
|
||||
if (!m_params.get_bool(":validate-result", false)) {
|
||||
if (!m_params.get_bool("validate_result", false)) {
|
||||
return;
|
||||
}
|
||||
switch(m_last_result) {
|
||||
|
@ -1449,12 +1449,12 @@ namespace pdr {
|
|||
void context::init_core_generalizers(datalog::rule_set& rules) {
|
||||
reset_core_generalizers();
|
||||
classifier_proc classify(m, rules);
|
||||
bool use_mc = m_params.get_bool(":use-multicore-generalizer", false);
|
||||
bool use_mc = m_params.get_bool("use_multicore_generalizer", false);
|
||||
if (use_mc) {
|
||||
m_core_generalizers.push_back(alloc(core_multi_generalizer, *this, 0));
|
||||
}
|
||||
if (m_params.get_bool(":use-farkas", true) && !classify.is_bool()) {
|
||||
if (m_params.get_bool(":inline-proof-mode", true)) {
|
||||
if (m_params.get_bool("use_farkas", true) && !classify.is_bool()) {
|
||||
if (m_params.get_bool("inline_proof_mode", true)) {
|
||||
m.toggle_proof_mode(PGM_FINE);
|
||||
m_fparams.m_proof_mode = PGM_FINE;
|
||||
m_fparams.m_arith_bound_prop = BP_NONE;
|
||||
|
@ -1470,13 +1470,13 @@ namespace pdr {
|
|||
m_core_generalizers.push_back(alloc(core_farkas_generalizer, *this, m, m_fparams));
|
||||
}
|
||||
}
|
||||
if (!use_mc && m_params.get_bool(":use-inductive-generalizer", true)) {
|
||||
if (!use_mc && m_params.get_bool("use_inductive_generalizer", true)) {
|
||||
m_core_generalizers.push_back(alloc(core_bool_inductive_generalizer, *this, 0));
|
||||
}
|
||||
if (m_params.get_bool(":use-interpolants", false)) {
|
||||
if (m_params.get_bool("use_interpolants", false)) {
|
||||
m_core_generalizers.push_back(alloc(core_interpolant_generalizer, *this));
|
||||
}
|
||||
if (m_params.get_bool(":inductive-reachability-check", false)) {
|
||||
if (m_params.get_bool("inductive_reachability_check", false)) {
|
||||
m_core_generalizers.push_back(alloc(core_induction_generalizer, *this));
|
||||
}
|
||||
}
|
||||
|
@ -1588,7 +1588,7 @@ namespace pdr {
|
|||
\brief Retrieve satisfying assignment with explanation.
|
||||
*/
|
||||
expr_ref context::mk_sat_answer() const {
|
||||
if (m_params.get_bool(":generate-proof-trace", false)) {
|
||||
if (m_params.get_bool("generate_proof_trace", false)) {
|
||||
proof_ref pr = get_proof();
|
||||
return expr_ref(pr.get(), m);
|
||||
}
|
||||
|
@ -1709,7 +1709,7 @@ namespace pdr {
|
|||
n.pt().add_property(ncore, uses_level?n.level():infty_level);
|
||||
}
|
||||
CASSERT("pdr",n.level() == 0 || check_invariant(n.level()-1));
|
||||
m_search.backtrack_level(!found_invariant && m_params.get_bool(":flexible-trace", false), n);
|
||||
m_search.backtrack_level(!found_invariant && m_params.get_bool("flexible_trace", false), n);
|
||||
break;
|
||||
}
|
||||
case l_undef: {
|
||||
|
@ -1731,7 +1731,7 @@ namespace pdr {
|
|||
}
|
||||
|
||||
void context::propagate(unsigned max_prop_lvl) {
|
||||
if (m_params.get_bool(":simplify-formulas-pre", false)) {
|
||||
if (m_params.get_bool("simplify_formulas_pre", false)) {
|
||||
simplify_formulas();
|
||||
}
|
||||
for (unsigned lvl = 0; lvl <= max_prop_lvl; lvl++) {
|
||||
|
@ -1750,7 +1750,7 @@ namespace pdr {
|
|||
throw inductive_exception();
|
||||
}
|
||||
}
|
||||
if (m_params.get_bool(":simplify-formulas-post", false)) {
|
||||
if (m_params.get_bool("simplify_formulas_post", false)) {
|
||||
simplify_formulas();
|
||||
}
|
||||
}
|
||||
|
@ -1798,7 +1798,7 @@ namespace pdr {
|
|||
*/
|
||||
void context::create_children(model_node& n) {
|
||||
SASSERT(n.level() > 0);
|
||||
bool use_model_generalizer = m_params.get_bool(":use-model-generalizer", false);
|
||||
bool use_model_generalizer = m_params.get_bool("use_model_generalizer", false);
|
||||
datalog::scoped_no_proof _sc(m);
|
||||
|
||||
pred_transformer& pt = n.pt();
|
||||
|
|
|
@ -290,7 +290,7 @@ namespace pdr {
|
|||
void reset() { memset(this, 0, sizeof(*this)); }
|
||||
};
|
||||
|
||||
front_end_params& m_fparams;
|
||||
smt_params& m_fparams;
|
||||
params_ref const& m_params;
|
||||
ast_manager& m;
|
||||
datalog::context* m_context;
|
||||
|
@ -348,13 +348,13 @@ namespace pdr {
|
|||
We check whether there is some reachable state of the relation checked_relation.
|
||||
*/
|
||||
context(
|
||||
front_end_params& fparams,
|
||||
smt_params& fparams,
|
||||
params_ref const& params,
|
||||
ast_manager& m);
|
||||
|
||||
~context();
|
||||
|
||||
front_end_params& get_fparams() const { return m_fparams; }
|
||||
smt_params& get_fparams() const { return m_fparams; }
|
||||
params_ref const& get_params() const { return m_params; }
|
||||
ast_manager& get_manager() const { return m; }
|
||||
manager& get_pdr_manager() { return m_pm; }
|
||||
|
|
|
@ -108,13 +108,13 @@ lbool dl_interface::query(expr * query) {
|
|||
|
||||
model_converter_ref mc = datalog::mk_skip_model_converter();
|
||||
proof_converter_ref pc;
|
||||
if (m_ctx.get_params().get_bool(":generate-proof-trace", false)) {
|
||||
if (m_ctx.get_params().get_bool("generate_proof_trace", false)) {
|
||||
pc = datalog::mk_skip_proof_converter();
|
||||
}
|
||||
m_ctx.set_output_predicate(query_pred);
|
||||
m_ctx.apply_default_transformation(mc, pc);
|
||||
|
||||
if (m_ctx.get_params().get_bool(":slice", true)) {
|
||||
if (m_ctx.get_params().get_bool("slice", true)) {
|
||||
datalog::rule_transformer transformer(m_ctx);
|
||||
datalog::mk_slice* slice = alloc(datalog::mk_slice, m_ctx);
|
||||
transformer.register_plugin(slice);
|
||||
|
@ -133,10 +133,10 @@ lbool dl_interface::query(expr * query) {
|
|||
}
|
||||
}
|
||||
|
||||
if (m_ctx.get_params().get_uint(":unfold-rules",0) > 0) {
|
||||
unsigned num_unfolds = m_ctx.get_params().get_uint(":unfold-rules", 0);
|
||||
if (m_ctx.get_params().get_uint("unfold_rules",0) > 0) {
|
||||
unsigned num_unfolds = m_ctx.get_params().get_uint("unfold_rules", 0);
|
||||
datalog::rule_transformer transformer1(m_ctx), transformer2(m_ctx);
|
||||
if (m_ctx.get_params().get_uint(":coalesce-rules", false)) {
|
||||
if (m_ctx.get_params().get_uint("coalesce_rules", false)) {
|
||||
transformer1.register_plugin(alloc(datalog::mk_coalesce, m_ctx));
|
||||
m_ctx.transform_rules(transformer1, mc, pc);
|
||||
}
|
||||
|
@ -198,7 +198,7 @@ expr_ref dl_interface::get_cover_delta(int level, func_decl* pred_orig) {
|
|||
}
|
||||
|
||||
void dl_interface::add_cover(int level, func_decl* pred, expr* property) {
|
||||
if (m_ctx.get_params().get_bool(":slice", true)) {
|
||||
if (m_ctx.get_params().get_bool("slice", true)) {
|
||||
throw default_exception("Covers are incompatible with slicing. Disable slicing before using covers");
|
||||
}
|
||||
m_context->add_cover(level, pred, property);
|
||||
|
@ -248,28 +248,30 @@ proof_ref dl_interface::get_proof() {
|
|||
}
|
||||
|
||||
void dl_interface::collect_params(param_descrs& p) {
|
||||
p.insert(":bfs-model-search", CPK_BOOL, "PDR: (default true) use BFS strategy for expanding model search");
|
||||
p.insert(":use-farkas", CPK_BOOL, "PDR: (default true) use lemma generator based on Farkas (for linear real arithmetic)");
|
||||
p.insert(":generate-proof-trace", CPK_BOOL, "PDR: (default false) trace for 'sat' answer as proof object");
|
||||
p.insert(":inline-proofs", CPK_BOOL, "PDR: (default true) run PDR with proof mode turned on and extract "
|
||||
p.insert("bfs_model_search", CPK_BOOL, "PDR: (default true) use BFS strategy for expanding model search");
|
||||
p.insert("use_farkas", CPK_BOOL, "PDR: (default true) use lemma generator based on Farkas (for linear real arithmetic)");
|
||||
p.insert("generate_proof_trace", CPK_BOOL, "PDR: (default false) trace for 'sat' answer as proof object");
|
||||
p.insert("inline_proofs", CPK_BOOL, "PDR: (default true) run PDR with proof mode turned on and extract "
|
||||
"Farkas coefficients directly (instead of creating a separate proof object when extracting coefficients)");
|
||||
p.insert(":flexible-trace", CPK_BOOL, "PDR: (default false) allow PDR generate long counter-examples "
|
||||
p.insert("flexible_trace", CPK_BOOL, "PDR: (default false) allow PDR generate long counter-examples "
|
||||
"by extending candidate trace within search area");
|
||||
p.insert(":unfold-rules", CPK_UINT, "PDR: (default 0) unfold rules statically using iterative squarring");
|
||||
p.insert(":use-model-generalizer", CPK_BOOL, "PDR: (default false) use model for backwards propagation (instead of symbolic simulation)");
|
||||
p.insert(":validate-result", CPK_BOOL, "PDR (default false) validate result (by proof checking or model checking)");
|
||||
PRIVATE_PARAMS(p.insert(":use-multicore-generalizer", CPK_BOOL, "PDR: (default false) extract multiple cores for blocking states"););
|
||||
PRIVATE_PARAMS(p.insert(":use-inductive-generalizer", CPK_BOOL, "PDR: (default true) generalize lemmas using induction strengthening"););
|
||||
PRIVATE_PARAMS(p.insert(":use-interpolants", CPK_BOOL, "PDR: (default false) use iZ3 interpolation for lemma generation"););
|
||||
PRIVATE_PARAMS(p.insert(":dump-interpolants", CPK_BOOL, "PDR: (default false) display interpolants"););
|
||||
PRIVATE_PARAMS(p.insert(":cache-mode", CPK_UINT, "PDR: use no (0 - default) symbolic (1) or explicit cache (2) for model search"););
|
||||
PRIVATE_PARAMS(p.insert(":inductive-reachability-check", CPK_BOOL,
|
||||
"PDR: (default false) assume negation of the cube on the previous level when "
|
||||
"checking for reachability (not only during cube weakening)"););
|
||||
PRIVATE_PARAMS(p.insert(":max-num-contexts", CPK_UINT, "PDR: (default 500) maximal number of contexts to create"););
|
||||
PRIVATE_PARAMS(p.insert(":try-minimize-core", CPK_BOOL, "PDR: (default false) try to reduce core size (before inductive minimization)"););
|
||||
p.insert(":simplify-formulas-pre", CPK_BOOL, "PDR: (default false) simplify derived formulas before inductive propagation");
|
||||
p.insert(":simplify-formulas-post", CPK_BOOL, "PDR: (default false) simplify derived formulas after inductive propagation");
|
||||
p.insert(":slice", CPK_BOOL, "PDR: (default true) simplify clause set using slicing");
|
||||
p.insert(":coalesce-rules", CPK_BOOL, "BMC: (default false) coalesce rules");
|
||||
p.insert("unfold_rules", CPK_UINT, "PDR: (default 0) unfold rules statically using iterative squarring");
|
||||
p.insert("use_model_generalizer", CPK_BOOL, "PDR: (default false) use model for backwards propagation (instead of symbolic simulation)");
|
||||
p.insert("validate_result", CPK_BOOL, "PDR (default false) validate result (by proof checking or model checking)");
|
||||
#ifndef _EXTERNAL_RELEASE
|
||||
p.insert("use_multicore_generalizer", CPK_BOOL, "PDR: (default false) extract multiple cores for blocking states");
|
||||
p.insert("use_inductive_generalizer", CPK_BOOL, "PDR: (default true) generalize lemmas using induction strengthening");
|
||||
p.insert("use_interpolants", CPK_BOOL, "PDR: (default false) use iZ3 interpolation for lemma generation");
|
||||
p.insert("dump_interpolants", CPK_BOOL, "PDR: (default false) display interpolants");
|
||||
p.insert("cache_mode", CPK_UINT, "PDR: use no (0 - default) symbolic (1) or explicit cache (2) for model search");
|
||||
p.insert("inductive_reachability_check", CPK_BOOL,
|
||||
"PDR: (default false) assume negation of the cube on the previous level when "
|
||||
"checking for reachability (not only during cube weakening)");
|
||||
p.insert("max_num_contexts", CPK_UINT, "PDR: (default 500) maximal number of contexts to create");
|
||||
p.insert("try_minimize_core", CPK_BOOL, "PDR: (default false) try to reduce core size (before inductive minimization)");
|
||||
#endif
|
||||
p.insert("simplify_formulas_pre", CPK_BOOL, "PDR: (default false) simplify derived formulas before inductive propagation");
|
||||
p.insert("simplify_formulas_post", CPK_BOOL, "PDR: (default false) simplify derived formulas after inductive propagation");
|
||||
p.insert("slice", CPK_BOOL, "PDR: (default true) simplify clause set using slicing");
|
||||
p.insert("coalesce_rules", CPK_BOOL, "BMC: (default false) coalesce rules");
|
||||
}
|
||||
|
|
|
@ -244,7 +244,7 @@ namespace pdr {
|
|||
}
|
||||
};
|
||||
|
||||
farkas_learner::farkas_learner(front_end_params& params, ast_manager& outer_mgr)
|
||||
farkas_learner::farkas_learner(smt_params& params, ast_manager& outer_mgr)
|
||||
: m_proof_params(get_proof_params(params)),
|
||||
m_pr(PROOF_MODE),
|
||||
p2o(m_pr, outer_mgr),
|
||||
|
@ -254,8 +254,8 @@ namespace pdr {
|
|||
m_ctx = alloc(smt::kernel, m_pr, m_proof_params);
|
||||
}
|
||||
|
||||
front_end_params farkas_learner::get_proof_params(front_end_params& orig_params) {
|
||||
front_end_params res(orig_params);
|
||||
smt_params farkas_learner::get_proof_params(smt_params& orig_params) {
|
||||
smt_params res(orig_params);
|
||||
res.m_proof_mode = PROOF_MODE;
|
||||
res.m_arith_bound_prop = BP_NONE;
|
||||
// temp hack to fix the build
|
||||
|
@ -796,7 +796,7 @@ namespace pdr {
|
|||
|
||||
|
||||
void farkas_learner::test() {
|
||||
front_end_params params;
|
||||
smt_params params;
|
||||
enable_trace("farkas_learner");
|
||||
|
||||
bool res;
|
||||
|
@ -883,7 +883,7 @@ namespace pdr {
|
|||
end = p->get_benchmark()->end_formulas();
|
||||
B = m.mk_and(static_cast<unsigned>(end-it), it);
|
||||
|
||||
front_end_params params;
|
||||
smt_params params;
|
||||
pdr::farkas_learner fl(params, m);
|
||||
expr_ref_vector lemmas(m);
|
||||
bool res = fl.get_lemma_guesses(A, B, lemmas);
|
||||
|
|
|
@ -26,7 +26,7 @@ Revision History:
|
|||
#include "smt_kernel.h"
|
||||
#include "bool_rewriter.h"
|
||||
#include "pdr_util.h"
|
||||
#include "front_end_params.h"
|
||||
#include "smt_params.h"
|
||||
#include "tactic.h"
|
||||
|
||||
namespace pdr {
|
||||
|
@ -39,12 +39,12 @@ class farkas_learner {
|
|||
|
||||
typedef obj_hashtable<expr> expr_set;
|
||||
|
||||
front_end_params m_proof_params;
|
||||
smt_params m_proof_params;
|
||||
ast_manager m_pr;
|
||||
scoped_ptr<smt::kernel> m_ctx;
|
||||
|
||||
|
||||
static front_end_params get_proof_params(front_end_params& orig_params);
|
||||
static smt_params get_proof_params(smt_params& orig_params);
|
||||
|
||||
//
|
||||
// all ast objects passed to private functions have m_proof_mgs as their ast_manager
|
||||
|
@ -72,7 +72,7 @@ class farkas_learner {
|
|||
static void test();
|
||||
|
||||
public:
|
||||
farkas_learner(front_end_params& params, ast_manager& m);
|
||||
farkas_learner(smt_params& params, ast_manager& m);
|
||||
|
||||
/**
|
||||
All ast objects have the ast_manager which was passed as
|
||||
|
|
|
@ -103,7 +103,7 @@ namespace pdr {
|
|||
// weaken predecessor.
|
||||
//
|
||||
|
||||
core_farkas_generalizer::core_farkas_generalizer(context& ctx, ast_manager& m, front_end_params& p):
|
||||
core_farkas_generalizer::core_farkas_generalizer(context& ctx, ast_manager& m, smt_params& p):
|
||||
core_generalizer(ctx),
|
||||
m_farkas_learner(p, m)
|
||||
{}
|
||||
|
|
|
@ -36,7 +36,7 @@ namespace pdr {
|
|||
class core_farkas_generalizer : public core_generalizer {
|
||||
farkas_learner m_farkas_learner;
|
||||
public:
|
||||
core_farkas_generalizer(context& ctx, ast_manager& m, front_end_params& p);
|
||||
core_farkas_generalizer(context& ctx, ast_manager& m, smt_params& p);
|
||||
virtual ~core_farkas_generalizer() {}
|
||||
virtual void operator()(model_node& n, expr_ref_vector& core, bool& uses_level);
|
||||
virtual void collect_statistics(statistics& st) const;
|
||||
|
|
|
@ -306,8 +306,7 @@ lbool interpolant_provider_impl::get_interpolant(expr * f1, expr * f2, expr_ref&
|
|||
return l_undef;
|
||||
}
|
||||
|
||||
front_end_params dummy_params;
|
||||
cmd_context cctx(&dummy_params, false, &m);
|
||||
cmd_context cctx(false, &m);
|
||||
for_each_expr(used_symbol_inserter(cctx), f1);
|
||||
|
||||
parse_smt2_commands(cctx, std::istringstream(res_text), false);
|
||||
|
@ -318,7 +317,7 @@ lbool interpolant_provider_impl::get_interpolant(expr * f1, expr * f2, expr_ref&
|
|||
throw default_exception("invalid interpolator output");
|
||||
}
|
||||
res = *ait;
|
||||
if (m_params.get_bool(":dump-interpolants", false)) {
|
||||
if (m_params.get_bool("dump_interpolants", false)) {
|
||||
interpolant_provider::output_interpolant(m, f1, f2, res);
|
||||
}
|
||||
return l_true;
|
||||
|
|
|
@ -29,7 +29,6 @@ Revision History:
|
|||
#include "model_smt2_pp.h"
|
||||
#include "model_converter.h"
|
||||
|
||||
|
||||
namespace pdr {
|
||||
|
||||
class collect_decls_proc {
|
||||
|
@ -143,11 +142,10 @@ namespace pdr {
|
|||
}
|
||||
}
|
||||
smt2_pp_environment_dbg env(m);
|
||||
pp_params params;
|
||||
func_decl_set::iterator it = aux_decls.begin(), end = aux_decls.end();
|
||||
for (; it != end; ++it) {
|
||||
func_decl* f = *it;
|
||||
ast_smt2_pp(out, f, env, params);
|
||||
ast_smt2_pp(out, f, env);
|
||||
out << "\n";
|
||||
}
|
||||
|
||||
|
@ -168,7 +166,7 @@ namespace pdr {
|
|||
return res;
|
||||
}
|
||||
|
||||
manager::manager(front_end_params& fparams, params_ref const& params, ast_manager& manager) :
|
||||
manager::manager(smt_params& fparams, params_ref const& params, ast_manager& manager) :
|
||||
m(manager),
|
||||
m_fparams(fparams),
|
||||
m_params(params),
|
||||
|
|
|
@ -78,7 +78,7 @@ namespace pdr {
|
|||
class manager
|
||||
{
|
||||
ast_manager& m;
|
||||
front_end_params& m_fparams;
|
||||
smt_params& m_fparams;
|
||||
params_ref const& m_params;
|
||||
|
||||
mutable bool_rewriter m_brwr;
|
||||
|
@ -110,11 +110,11 @@ namespace pdr {
|
|||
void add_new_state(func_decl * s);
|
||||
|
||||
public:
|
||||
manager(front_end_params& fparams, params_ref const& params,
|
||||
manager(smt_params& fparams, params_ref const& params,
|
||||
ast_manager & manager);
|
||||
|
||||
ast_manager& get_manager() const { return m; }
|
||||
front_end_params& get_fparams() const { return m_fparams; }
|
||||
smt_params& get_fparams() const { return m_fparams; }
|
||||
params_ref const& get_params() const { return m_params; }
|
||||
bool_rewriter& get_brwr() const { return m_brwr; }
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ Revision History:
|
|||
#include "ast_smt2_pp.h"
|
||||
#include "dl_util.h"
|
||||
#include "model_pp.h"
|
||||
#include "front_end_params.h"
|
||||
#include "smt_params.h"
|
||||
#include "datatype_decl_plugin.h"
|
||||
#include "bv_decl_plugin.h"
|
||||
#include "pdr_farkas_learner.h"
|
||||
|
@ -212,7 +212,7 @@ namespace pdr {
|
|||
m(pm.get_manager()),
|
||||
m_pm(pm),
|
||||
m_name(name),
|
||||
m_try_minimize_core(pm.get_params().get_bool(":try-minimize-core", false)),
|
||||
m_try_minimize_core(pm.get_params().get_bool("try_minimize_core", false)),
|
||||
m_ctx(pm.mk_fresh()),
|
||||
m_pos_level_atoms(m),
|
||||
m_neg_level_atoms(m),
|
||||
|
|
|
@ -35,7 +35,7 @@ namespace pdr {
|
|||
class prop_solver {
|
||||
|
||||
private:
|
||||
front_end_params& m_fparams;
|
||||
smt_params& m_fparams;
|
||||
ast_manager& m;
|
||||
manager& m_pm;
|
||||
symbol m_name;
|
||||
|
|
|
@ -213,7 +213,7 @@ namespace pdr {
|
|||
datalog::scoped_fine_proof _scp(m);
|
||||
|
||||
expr_ref_vector fmls(m);
|
||||
front_end_params fparams;
|
||||
smt_params fparams;
|
||||
fparams.m_proof_mode = PGM_FINE;
|
||||
fparams.m_mbqi = true;
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ namespace pdr {
|
|||
m_ctx(0),
|
||||
m_ref_holder(m),
|
||||
m_disj_connector(m),
|
||||
m_cache_mode((datalog::PDR_CACHE_MODE)params.get_uint(":cache-mode",0)) {
|
||||
m_cache_mode((datalog::PDR_CACHE_MODE)params.get_uint("cache_mode",0)) {
|
||||
if (m_cache_mode == datalog::CONSTRAINT_CACHE) {
|
||||
m_ctx = pm.mk_fresh();
|
||||
m_ctx->assert_expr(m_pm.get_background());
|
||||
|
|
|
@ -21,7 +21,7 @@ Revision History:
|
|||
#include "has_free_vars.h"
|
||||
#include "ast_pp.h"
|
||||
#include <sstream>
|
||||
#include "front_end_params.h"
|
||||
#include "smt_params.h"
|
||||
|
||||
namespace pdr {
|
||||
|
||||
|
@ -93,10 +93,10 @@ namespace pdr {
|
|||
return m_context.get_proof();
|
||||
}
|
||||
|
||||
smt_context_manager::smt_context_manager(front_end_params& fp, params_ref const& p, ast_manager& m):
|
||||
smt_context_manager::smt_context_manager(smt_params& fp, params_ref const& p, ast_manager& m):
|
||||
m_fparams(fp),
|
||||
m(m),
|
||||
m_max_num_contexts(p.get_uint(":max-num-contexts", 500)),
|
||||
m_max_num_contexts(p.get_uint("max_num_contexts", 500)),
|
||||
m_num_contexts(0),
|
||||
m_predicate_list(m) {
|
||||
}
|
||||
|
|
|
@ -88,7 +88,7 @@ namespace pdr {
|
|||
};
|
||||
|
||||
class smt_context_manager {
|
||||
front_end_params& m_fparams;
|
||||
smt_params& m_fparams;
|
||||
ast_manager& m;
|
||||
unsigned m_max_num_contexts;
|
||||
ptr_vector<smt::kernel> m_contexts;
|
||||
|
@ -96,7 +96,7 @@ namespace pdr {
|
|||
app_ref_vector m_predicate_list;
|
||||
func_decl_set m_predicate_set;
|
||||
public:
|
||||
smt_context_manager(front_end_params& fp, params_ref const& p, ast_manager& m);
|
||||
smt_context_manager(smt_params& fp, params_ref const& p, ast_manager& m);
|
||||
~smt_context_manager();
|
||||
smt_context* mk_fresh();
|
||||
void collect_statistics(statistics& st) const;
|
||||
|
|
|
@ -30,7 +30,7 @@ Notes:
|
|||
#include "bool_rewriter.h"
|
||||
#include "dl_util.h"
|
||||
#include "for_each_expr.h"
|
||||
#include "front_end_params.h"
|
||||
#include "smt_params.h"
|
||||
#include "model.h"
|
||||
#include "model_v2_pp.h"
|
||||
#include "ref_vector.h"
|
||||
|
|
|
@ -1319,7 +1319,7 @@ namespace qe {
|
|||
|
||||
public:
|
||||
|
||||
quant_elim_plugin(ast_manager& m, quant_elim& qe, front_end_params& p):
|
||||
quant_elim_plugin(ast_manager& m, quant_elim& qe, smt_params& p):
|
||||
m(m),
|
||||
m_qe(qe),
|
||||
m_rewriter(m),
|
||||
|
@ -1340,7 +1340,7 @@ namespace qe {
|
|||
m_nnf(m, get_is_relevant(), get_mk_atom())
|
||||
{
|
||||
params_ref params;
|
||||
params.set_bool(":gcd-rounding", true);
|
||||
params.set_bool("gcd_rounding", true);
|
||||
m_rewriter.updt_params(params);
|
||||
}
|
||||
|
||||
|
@ -1959,7 +1959,7 @@ namespace qe {
|
|||
|
||||
class quant_elim_new : public quant_elim {
|
||||
ast_manager& m;
|
||||
front_end_params& m_fparams;
|
||||
smt_params& m_fparams;
|
||||
expr_ref m_assumption;
|
||||
bool m_produce_models;
|
||||
ptr_vector<quant_elim_plugin> m_plugins;
|
||||
|
@ -1968,7 +1968,7 @@ namespace qe {
|
|||
bool m_eliminate_variables_as_block;
|
||||
|
||||
public:
|
||||
quant_elim_new(ast_manager& m, front_end_params& p) :
|
||||
quant_elim_new(ast_manager& m, smt_params& p) :
|
||||
m(m),
|
||||
m_fparams(p),
|
||||
m_assumption(m),
|
||||
|
@ -2010,7 +2010,7 @@ namespace qe {
|
|||
}
|
||||
|
||||
void updt_params(params_ref const& p) {
|
||||
m_eliminate_variables_as_block = p.get_bool(":eliminate-variables-as-block", m_eliminate_variables_as_block);
|
||||
m_eliminate_variables_as_block = p.get_bool("eliminate_variables_as_block", m_eliminate_variables_as_block);
|
||||
}
|
||||
|
||||
void eliminate(bool is_forall, unsigned num_vars, app* const* vars, expr_ref& fml) {
|
||||
|
@ -2165,7 +2165,7 @@ namespace qe {
|
|||
// ------------------------------------------------
|
||||
// expr_quant_elim
|
||||
|
||||
expr_quant_elim::expr_quant_elim(ast_manager& m, front_end_params const& fp, params_ref const& p):
|
||||
expr_quant_elim::expr_quant_elim(ast_manager& m, smt_params const& fp, params_ref const& p):
|
||||
m(m),
|
||||
m_fparams(fp),
|
||||
m_params(p),
|
||||
|
@ -2194,7 +2194,7 @@ namespace qe {
|
|||
}
|
||||
|
||||
void expr_quant_elim::updt_params(params_ref const& p) {
|
||||
bool r = p.get_bool(":use-neq-qe", m_use_new_qe);
|
||||
bool r = p.get_bool("use_neq_qe", m_use_new_qe);
|
||||
if (r != m_use_new_qe) {
|
||||
dealloc(m_qe);
|
||||
m_qe = 0;
|
||||
|
@ -2205,14 +2205,14 @@ namespace qe {
|
|||
}
|
||||
|
||||
void expr_quant_elim::collect_param_descrs(param_descrs& r) {
|
||||
r.insert(":eliminate-variables-as-block", CPK_BOOL,
|
||||
r.insert("eliminate_variables_as_block", CPK_BOOL,
|
||||
"(default: true) eliminate variables as a block (true) or one at a time (false)");
|
||||
// r.insert(":use-new-qe", CPK_BOOL, "(default: true) invoke quantifier engine based on abstracted solver");
|
||||
// r.insert("use_new_qe", CPK_BOOL, "(default: true) invoke quantifier engine based on abstracted solver");
|
||||
}
|
||||
|
||||
void expr_quant_elim::init_qe() {
|
||||
if (!m_qe) {
|
||||
m_qe = alloc(quant_elim_new, m, const_cast<front_end_params&>(m_fparams));
|
||||
m_qe = alloc(quant_elim_new, m, const_cast<smt_params&>(m_fparams));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2399,7 +2399,7 @@ namespace qe {
|
|||
cache_result(q, r, pr);
|
||||
}
|
||||
|
||||
expr_quant_elim_star1::expr_quant_elim_star1(ast_manager& m, front_end_params const& p):
|
||||
expr_quant_elim_star1::expr_quant_elim_star1(ast_manager& m, smt_params const& p):
|
||||
simplifier(m), m_quant_elim(m, p), m_assumption(m.mk_true())
|
||||
{
|
||||
}
|
||||
|
@ -2437,7 +2437,7 @@ namespace qe {
|
|||
|
||||
class simplify_solver_context : public i_solver_context {
|
||||
ast_manager& m;
|
||||
front_end_params m_fparams;
|
||||
smt_params m_fparams;
|
||||
app_ref_vector* m_vars;
|
||||
expr_ref* m_fml;
|
||||
ptr_vector<contains_app> m_contains;
|
||||
|
@ -2612,7 +2612,7 @@ namespace qe {
|
|||
}
|
||||
|
||||
void simplify_exists(app_ref_vector& vars, expr_ref& fml) {
|
||||
front_end_params params;
|
||||
smt_params params;
|
||||
ast_manager& m = fml.get_manager();
|
||||
simplify_solver_context ctx(m);
|
||||
ctx.solve(fml, vars);
|
||||
|
|
|
@ -22,7 +22,7 @@ Revision History:
|
|||
#define __QE_H__
|
||||
|
||||
#include "ast.h"
|
||||
#include "front_end_params.h"
|
||||
#include "smt_params.h"
|
||||
#include "statistics.h"
|
||||
#include "lbool.h"
|
||||
#include "expr_functors.h"
|
||||
|
@ -221,7 +221,7 @@ namespace qe {
|
|||
|
||||
qe_solver_plugin* mk_array_plugin(i_solver_context& ctx);
|
||||
|
||||
qe_solver_plugin* mk_arith_plugin(i_solver_context& ctx, bool produce_models, front_end_params& p);
|
||||
qe_solver_plugin* mk_arith_plugin(i_solver_context& ctx, bool produce_models, smt_params& p);
|
||||
|
||||
class def_vector {
|
||||
func_decl_ref_vector m_vars;
|
||||
|
@ -275,7 +275,7 @@ namespace qe {
|
|||
|
||||
class expr_quant_elim {
|
||||
ast_manager& m;
|
||||
front_end_params const& m_fparams;
|
||||
smt_params const& m_fparams;
|
||||
params_ref m_params;
|
||||
expr_ref_vector m_trail;
|
||||
obj_map<expr,expr*> m_visited;
|
||||
|
@ -283,7 +283,7 @@ namespace qe {
|
|||
expr* m_assumption;
|
||||
bool m_use_new_qe;
|
||||
public:
|
||||
expr_quant_elim(ast_manager& m, front_end_params const& fp, params_ref const& p = params_ref());
|
||||
expr_quant_elim(ast_manager& m, smt_params const& fp, params_ref const& p = params_ref());
|
||||
~expr_quant_elim();
|
||||
|
||||
void operator()(expr* assumption, expr* fml, expr_ref& result);
|
||||
|
@ -331,7 +331,7 @@ namespace qe {
|
|||
virtual void reduce1_quantifier(quantifier * q);
|
||||
virtual bool is_target(quantifier * q) const { return q->get_num_patterns() == 0 && q->get_num_no_patterns() == 0; }
|
||||
public:
|
||||
expr_quant_elim_star1(ast_manager & m, front_end_params const& p);
|
||||
expr_quant_elim_star1(ast_manager & m, smt_params const& p);
|
||||
virtual ~expr_quant_elim_star1() {}
|
||||
|
||||
void collect_statistics(statistics & st) const {
|
||||
|
|
|
@ -98,7 +98,7 @@ namespace qe {
|
|||
bool_rewriter m_bool_rewriter;
|
||||
arith_rewriter m_arith_rewriter;
|
||||
|
||||
arith_qe_util(ast_manager& m, front_end_params& p, i_solver_context& ctx) :
|
||||
arith_qe_util(ast_manager& m, smt_params& p, i_solver_context& ctx) :
|
||||
m(m),
|
||||
m_ctx(ctx),
|
||||
m_arith(m),
|
||||
|
@ -1511,7 +1511,7 @@ public:
|
|||
subst_cache m_subst;
|
||||
|
||||
public:
|
||||
arith_plugin(i_solver_context& ctx, ast_manager& m, front_end_params& p):
|
||||
arith_plugin(i_solver_context& ctx, ast_manager& m, smt_params& p):
|
||||
qe_solver_plugin(m, m.get_family_id("arith"), ctx),
|
||||
m_util(m, p, ctx),
|
||||
m_trail(m)
|
||||
|
@ -2562,7 +2562,7 @@ public:
|
|||
};
|
||||
|
||||
|
||||
qe_solver_plugin* mk_arith_plugin(i_solver_context& ctx, bool produce_models, front_end_params& p) {
|
||||
qe_solver_plugin* mk_arith_plugin(i_solver_context& ctx, bool produce_models, smt_params& p) {
|
||||
if (p.m_nlquant_elim) {
|
||||
return alloc(nlarith_plugin, ctx, ctx.get_manager(), produce_models);
|
||||
}
|
||||
|
|
|
@ -16,8 +16,8 @@ public:
|
|||
|
||||
virtual void init_pdescrs(cmd_context & ctx, param_descrs & p) {
|
||||
insert_timeout(p);
|
||||
p.insert(":print", CPK_BOOL, "(default: true) print the simplified term.");
|
||||
p.insert(":print-statistics", CPK_BOOL, "(default: false) print statistics.");
|
||||
p.insert("print", CPK_BOOL, "(default: true) print the simplified term.");
|
||||
p.insert("print_statistics", CPK_BOOL, "(default: false) print statistics.");
|
||||
}
|
||||
|
||||
virtual ~qe_cmd() {
|
||||
|
@ -38,18 +38,18 @@ public:
|
|||
}
|
||||
|
||||
virtual void execute(cmd_context & ctx) {
|
||||
front_end_params par;
|
||||
smt_params par;
|
||||
proof_ref pr(ctx.m());
|
||||
qe::expr_quant_elim_star1 qe(ctx.m(), par);
|
||||
expr_ref result(ctx.m());
|
||||
|
||||
qe(m_target, result, pr);
|
||||
|
||||
if (m_params.get_bool(":print", true)) {
|
||||
if (m_params.get_bool("print", true)) {
|
||||
ctx.display(ctx.regular_stream(), result);
|
||||
ctx.regular_stream() << std::endl;
|
||||
}
|
||||
if (m_params.get_bool(":print-statistics", false)) {
|
||||
if (m_params.get_bool("print_statistics", false)) {
|
||||
statistics st;
|
||||
qe.collect_statistics(st);
|
||||
st.display(ctx.regular_stream());
|
||||
|
|
|
@ -1260,13 +1260,13 @@ namespace fm {
|
|||
}
|
||||
|
||||
void updt_params(params_ref const & p) {
|
||||
m_max_memory = megabytes_to_bytes(p.get_uint(":max-memory", UINT_MAX));
|
||||
m_fm_real_only = p.get_bool(":fm-real-only", true);
|
||||
m_fm_limit = p.get_uint(":fm-limit", 5000000);
|
||||
m_fm_cutoff1 = p.get_uint(":fm-cutoff1", 8);
|
||||
m_fm_cutoff2 = p.get_uint(":fm-cutoff2", 256);
|
||||
m_fm_extra = p.get_uint(":fm-extra", 0);
|
||||
m_fm_occ = p.get_bool(":fm-occ", false);
|
||||
m_max_memory = megabytes_to_bytes(p.get_uint("max_memory", UINT_MAX));
|
||||
m_fm_real_only = p.get_bool("fm_real_only", true);
|
||||
m_fm_limit = p.get_uint("fm_limit", 5000000);
|
||||
m_fm_cutoff1 = p.get_uint("fm_cutoff1", 8);
|
||||
m_fm_cutoff2 = p.get_uint("fm_cutoff2", 256);
|
||||
m_fm_extra = p.get_uint("fm_extra", 0);
|
||||
m_fm_occ = p.get_bool("fm_occ", false);
|
||||
}
|
||||
|
||||
void set_cancel(bool f) {
|
||||
|
|
|
@ -59,7 +59,7 @@ namespace qe {
|
|||
ast_manager& m;
|
||||
expr_ref m_false;
|
||||
volatile bool m_cancel;
|
||||
front_end_params m_fparams;
|
||||
smt_params m_fparams;
|
||||
params_ref m_params;
|
||||
unsigned m_extrapolate_strategy_param;
|
||||
bool m_projection_mode_param;
|
||||
|
@ -301,17 +301,17 @@ namespace qe {
|
|||
virtual void cleanup() {}
|
||||
|
||||
virtual void updt_params(params_ref const & p) {
|
||||
m_extrapolate_strategy_param = p.get_uint(":extrapolate-strategy", m_extrapolate_strategy_param);
|
||||
m_projection_mode_param = p.get_bool(":projection-mode", m_projection_mode_param);
|
||||
m_strong_context_simplify_param = p.get_bool(":strong-context-simplify", m_strong_context_simplify_param);
|
||||
m_ctx_simplify_local_param = p.get_bool(":strong-context-simplify-local", m_ctx_simplify_local_param);
|
||||
m_extrapolate_strategy_param = p.get_uint("extrapolate_strategy", m_extrapolate_strategy_param);
|
||||
m_projection_mode_param = p.get_bool("projection_mode", m_projection_mode_param);
|
||||
m_strong_context_simplify_param = p.get_bool("strong_context_simplify", m_strong_context_simplify_param);
|
||||
m_ctx_simplify_local_param = p.get_bool("strong_context_simplify_local", m_ctx_simplify_local_param);
|
||||
}
|
||||
|
||||
virtual void collect_param_descrs(param_descrs & r) {
|
||||
r.insert(":extrapolate-strategy",CPK_UINT, "(default: 0 trivial extrapolation) 1 - nnf strengthening 2 - smt-test 3 - nnf_weakening");
|
||||
r.insert(":projection-mode", CPK_BOOL, "(default: true - full) false - partial quantifier instantiation");
|
||||
r.insert(":strong-context-simplify", CPK_BOOL, "(default: true) use strong context simplifier on result of quantifier elimination");
|
||||
r.insert(":strong-context-simplify-local", CPK_BOOL, "(default: false) use strong context simplifier locally on the new formula only");
|
||||
r.insert("extrapolate_strategy",CPK_UINT, "(default: 0 trivial extrapolation) 1 - nnf strengthening 2 - smt-test 3 - nnf_weakening");
|
||||
r.insert("projection_mode", CPK_BOOL, "(default: true - full) false - partial quantifier instantiation");
|
||||
r.insert("strong_context_simplify", CPK_BOOL, "(default: true) use strong context simplifier on result of quantifier elimination");
|
||||
r.insert("strong_context_simplify_local", CPK_BOOL, "(default: false) use strong context simplifier locally on the new formula only");
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ Revision History:
|
|||
class qe_tactic : public tactic {
|
||||
struct imp {
|
||||
ast_manager & m;
|
||||
front_end_params m_fparams;
|
||||
smt_params m_fparams;
|
||||
volatile bool m_cancel;
|
||||
qe::expr_quant_elim m_qe;
|
||||
|
||||
|
@ -36,7 +36,7 @@ class qe_tactic : public tactic {
|
|||
}
|
||||
|
||||
void updt_params(params_ref const & p) {
|
||||
m_fparams.m_nlquant_elim = p.get_bool(":qe-nonlinear", false);
|
||||
m_fparams.m_nlquant_elim = p.get_bool("qe_nonlinear", false);
|
||||
m_qe.updt_params(p);
|
||||
}
|
||||
|
||||
|
@ -113,7 +113,7 @@ public:
|
|||
|
||||
|
||||
virtual void collect_param_descrs(param_descrs & r) {
|
||||
r.insert(":qe-nonlinear", CPK_BOOL, "(default: false) enable virtual term substitution.");
|
||||
r.insert("qe_nonlinear", CPK_BOOL, "(default: false) enable virtual term substitution.");
|
||||
m_imp->collect_param_descrs(r);
|
||||
}
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@ Author:
|
|||
struct unit_subsumption_tactic : public tactic {
|
||||
ast_manager& m;
|
||||
params_ref m_params;
|
||||
front_end_params m_fparams;
|
||||
smt_params m_fparams;
|
||||
volatile bool m_cancel;
|
||||
smt::context m_context;
|
||||
expr_ref_vector m_clauses;
|
||||
|
|
|
@ -45,7 +45,7 @@ Notes:
|
|||
#include"arith_decl_plugin.h"
|
||||
#include"for_each_expr.h"
|
||||
#include"extension_model_converter.h"
|
||||
#include"params2front_end_params.h"
|
||||
#include"params2smt_params.h"
|
||||
#include"ast_smt2_pp.h"
|
||||
|
||||
class vsubst_tactic : public tactic {
|
||||
|
@ -93,8 +93,8 @@ class vsubst_tactic : public tactic {
|
|||
throw tactic_exception("there are no real variables");
|
||||
}
|
||||
|
||||
front_end_params params;
|
||||
params2front_end_params(p, params);
|
||||
smt_params params;
|
||||
params2smt_params(p, params);
|
||||
params.m_model = false;
|
||||
flet<bool> fl1(params.m_nlquant_elim, true);
|
||||
flet<bool> fl2(params.m_nl_arith_gb, false);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue