3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-23 09:05:31 +00:00

Merge pull request #5550 from wintersteiger/cwinter_fpa_fixes

Assorted fixes for floats
This commit is contained in:
Christoph M. Wintersteiger 2021-10-12 18:24:49 +01:00 committed by GitHub
commit 58fd4fc860
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 33 additions and 32 deletions

View file

@ -38,7 +38,7 @@ namespace smt {
{
params_ref p;
p.set_bool("arith_lhs", true);
m_th_rw.updt_params(p);
m_th_rw.updt_params(p);
}
theory_fpa::~theory_fpa()
@ -284,6 +284,9 @@ namespace smt {
}
default: /* ignore */;
}
if (!ctx.relevancy())
relevant_eh(term);
}
return true;
@ -454,13 +457,9 @@ namespace smt {
expr * args[] = { bv_val_a->get_arg(0), bv_val_a->get_arg(1), bv_val_a->get_arg(2) };
cc_args = m_bv_util.mk_concat(3, args);
c = m.mk_eq(wrapped, cc_args);
// NB code review: #5454 exposes a bug in fpa_solver that
// could be latent here as well. It needs also the equality
// n == bv_val_e to be asserted such that whenever something is assigned th
// bit-vector value cc_args it is equated with n
// I don't see another way this constraint would be enforced.
assert_cnstr(c);
assert_cnstr(mk_side_conditions());
assert_cnstr(m.mk_eq(n, bv_val_e));
}
else {
expr_ref wu(m);
@ -627,7 +626,7 @@ namespace smt {
bv2fp.convert_min_max_specials(&mdl, &new_model, seen);
bv2fp.convert_uf2bvuf(&mdl, &new_model, seen);
for (func_decl* f : seen)
for (func_decl* f : seen)
mdl.unregister_decl(f);
for (unsigned i = 0; i < new_model.get_num_constants(); i++) {