Closed usr-sse2 closed 3 years ago
Possible duplicate of #4604, #4600, #930
variable names influence search behavior, so does sat.random_seed. Try just running with sat.random_seed=1, ..., 10 and with -st set. Then you will see that z3 uses different number of restarts, decisions, etc.
A common mistake in benchmarking SAT/SMT/ATP solvers is to assume that it suffices to test a benchmark with a particular setting. The real measure is whether the solver is stable over a range of seeds/scrambles of inputs. So you should not only perform more than one run to average out overhead from the OS, but also scramble and seed search to understand whether the solver behaves in a stable way.
For a fixed input and fixed random seed, Z3 should behave deterministically in common use cases (exceptions are when Z3 tries some time-bounded strategies to solve arithmetical formulas and when you use parallel solving). Only OS overhead should influence wall-clock time.
Z3 4.8.8 is run using the following command:
./z3 rlimit=5000000 tactic.solve_eqs.context_solve=false req.z3
and this unsatisfiable request produces resultunknown
:The minimum sufficient
rlimit
value for this request is 5283401.unsat
ifm_2_0
is renamed tom_2
. Why can variable names influence the resource number required to solve a request?bv18
is replaced withbv19
, the formula is still unsatisfiable for the same reason (the remainder of division by 10 can't be ≥10), but Z3 is able to solve it within the 5000000 limit even without renaming.