Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid model for String formula (z3str3, dom-simplify unit-subsume-simplify smt) #4362

Closed
rainoftime opened this issue May 18, 2020 · 2 comments
Assignees
Labels

Comments

@rainoftime
Copy link
Contributor

rainoftime commented May 18, 2020

Hi, for the following formula, z3 commit 1c760b0 gives an invali model

(set-option :model_validate true)
(set-option :smt.string_solver z3str3)
(declare-const Str4 String)
(declare-const Str13 String)
(declare-const Str17 String)
(declare-const i10 Int)
(assert (or false false (= (str.++ Str13 Str4) (str.++ Str4 "" (int.to.str i10) Str13) Str17 "")))
(check-sat-using (then simplify dom-simplify unit-subsume-simplify smt))
@rainoftime rainoftime changed the title Invalid model for String formula (z3str3, dom-simplify unit-subsume-simplify) Invalid model for String formula (z3str3, dom-simplify unit-subsume-simplify smt) May 18, 2020
@mtrberzi mtrberzi self-assigned this May 18, 2020
@rainoftime
Copy link
Contributor Author

(set-option :model_validate true)
(set-option :smt.string_solver z3str3)
(declare-const i14 Int)
(declare-const Str1 String)
(declare-const Str7 String)
(declare-const Str8 String)
(declare-const Str9 String)
(declare-const Str10 String)
(declare-const Str17 String)
(declare-const Str18 String)
(declare-const v15 Bool)
(assert v15)
(assert (= (str.++ Str17 Str8) (str.++ Str8 (int.to.str i14) "" "" "") (str.++ Str8 (int.to.str i14) "" "" "") Str7 Str10))
(assert (= Str18 Str9 Str1 (str.++ Str18 Str7)))
(check-sat-using (then simplify dom-simplify unit-subsume-simplify qfufbv))

@rainoftime
Copy link
Contributor Author

from #4364

(set-option :model_validate true)
(set-option :smt.string_solver z3str3)
(declare-const v2 Bool)
(declare-const Str0 String)
(declare-const Str3 String)
(declare-const Str9 String)
(declare-const Str14 String)
(declare-const Str16 String)
(declare-const Str19 String)
(declare-const i7 Int)
(declare-const i8 Int)
(assert (or (= false false false false false false false v2 false false false) (= Str19 "" "" Str0 Str14)))
(assert (or (= Str19 "" Str9 Str0 Str14) v2 (>= 630 i8)))
(assert (or (>= 630 i8) (= "" (str.++ Str3 Str16) Str9 (str.++ Str14 Str3)) (= Str19 "" Str9 Str0 Str14)))
(assert (> i7 0))
(check-sat-using (then simplify unit-subsume-simplify ufbv))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants