问题
I have an instance which could be very efficiently solved by old version of Z3(version 2.18). It return SAT in a few seconds. However, when I try it on the current version of Z3(version 4.3.1). It does not return any result after 10 minutes.
Here are some details about the experiment. Could anybody give some advice?
there are 4000 Bool variables and 200 Int variables
all the constraint are in propositional logic with comparison between integers like a < b
platform: open suse linux 12.3@thinkpad T400s
Z3 v2.18 was downloaded as a linux binary last year (I cannot find the link now)
Z3 v4.3.1 was downloaded as source code, and I compile it on my laptop by using the default setting
There are about 50,000 lines in the smt file, so I can not post it here. I would be happy to send the file by email if anybody are interested. Thanks.
回答1:
Z3 is a portfolio of solvers. The default configuration changes from version to version. Progress is never monotonic. That is, a new version may solve more problems, but may be slower and fail in some problems.
Remark: the author has sent his benchmark by email to the Z3 authors.
In the “work-in-progress” branch, I managed to reproduce the Z3 2.19 performance by using
(set-option :smt.auto-config false)
Here are instructions on how to download the “work-in-progress” branch.
To get the same behavior, we also have to replace (check-sat) with (check-sat-using smt)
BTW, in the official release, we have to use
(set-option :auto-config false)
instead of
(set-option :smt.auto-config false)
来源:https://stackoverflow.com/questions/19032647/old-vs-new-version-of-z3