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

Problem with arrays that use bit vectors as index sort #5593

Closed
olibeck opened this issue Oct 13, 2021 · 1 comment
Closed

Problem with arrays that use bit vectors as index sort #5593

olibeck opened this issue Oct 13, 2021 · 1 comment

Comments

@olibeck
Copy link

olibeck commented Oct 13, 2021

Dear Z3 Team,
I ran into a problem with arrays that use bit vectors as index sort. Z3 returns sat for formulas that I expected to be unsat.
The following code is an example for which the problem occurs for me:

(set-option :random-seed 0)
(set-option :produce-models true)
(set-option :produce-unsat-cores true)
; 
(set-info :status unsat)
(assert (! 
 (let ((?x277 ((as const (Array (_ BitVec 4) String)) "")))
 (let ((?x225 (store ?x277 (_ bv2 4) "a")))
 (let ((?x467 ((as const (Array (_ BitVec 4) String)) "a")))
 (let ((?x146 (store ?x467 (_ bv0 4) "")))
 (= ?x146 ?x225))))) :named a0))
(check-sat)

(get-unsat-core)
(get-info :reason-unknown)

I tested this code on the release version 4.8.12 as well as on the current master branch (96e117d) and both times Z3 returned sat.

OS: Ubuntu 20.04

NikolajBjorner added a commit that referenced this issue Oct 14, 2021
@NikolajBjorner
Copy link
Contributor

fixed

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

No branches or pull requests

2 participants