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

Simplifying ite and extract #2479

Closed
ychen306 opened this issue Aug 9, 2019 · 1 comment
Closed

Simplifying ite and extract #2479

ychen306 opened this issue Aug 9, 2019 · 1 comment

Comments

@ychen306
Copy link

ychen306 commented Aug 9, 2019

How do you get z3 to simplify (ite (= (extract i i x) 0) 0 1) into (zeroext (extract...))?

@NikolajBjorner
Copy link
Contributor

z3 2479.smt2 rewriter.bv_ite2id=true

where 2479.smt2 is:

(declare-const x (_ BitVec 64))
(simplify (ite (= (_ bv1 1) ((_ extract 21 21) x)) (_ bv1 64) (_ bv0 64)))
(simplify (ite (= (_ bv0 1) ((_ extract 21 21) x)) (_ bv1 64) (_ bv0 64)))
(simplify (ite (= (_ bv1 1) ((_ extract 21 21) x)) (_ bv0 64) (_ bv1 64)))
(simplify (ite (= (_ bv0 1) ((_ extract 21 21) x)) (_ bv0 64) (_ bv1 64)))

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