What is the fastest way to deal with intExp and BitVecExp? #6717
Replies: 1 comment
-
We had a similar issue when model checking C programs with bit operations. The following can help to tackle the issue:
this can be converted to
This way only the necessary parts are encoded via bit-vectors. If there are many BV operations or they have deep dependency chains, then doing full BV encoding (2) might be better. |
Beta Was this translation helpful? Give feedback.
-
We are modeling our numbers as intExp, but when we are treating some bitwise operations, we convert to BitVecExp using mkInt2BV.
Then we use some bitwise operation, like mkBVAND, mkBVOR, mkBVXOR, mkBVSHL, mkBVASHR and mkBVLSHR.
And at the end we convert back to intExpr, using mkBV2Int.
But we notice that mkBV2Int is very slow.
Do we have a way to do that using intExpr directly? Or some another way to be faster?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions