-
Notifications
You must be signed in to change notification settings - Fork 37
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
PK domain is sometimes less precise than int? #18
Comments
AFIK, this is not a bug. In fact, this kind of loss of precision is well known for the pk domain. Although in theory pk is strictly more precise than intervals, in practice some abstract operations (mainly widening) can cause the opposite. |
I just found a more recent paper Experimental Evaluation of Numerical Domains |
Thank you very much for the explanation and the paper recommendations. |
I have a follow-up question on that: What about the octagon domain? The two papers you mentioned afaik don't report any imprecision with the octagon domain. I am asking because I found an example where octagon is less precise than integers (https://gist.github.com/chkl/2fc864b6f0782f49cc10c62df3fbc499, It's an ugly example using auto-generated code, I tried to slice away the irrelevant parts) |
One common reason is disequalities (i.e., !=). The octagon domain usually ignores disequalities while intervals handle some. For instance, if you have the interval x = [0,10] and then the constraint x != 10 then intervals will be able to say that x = [0,9]. However, octagons probably will still say 0 <= x <= 10. |
Hi everyone,
I found a few interesting cases in which crab using the
pk
domain is less precise than when using theint
domain. One example:I invoked crab with the following parameters:
./crabllvm.py -m 32 --crab-inter --crab-check=assert --crab-dom=int
For which the output ends in
Now, if switch to the
pk
domain (--crab-dom=pk
), the output changes toIs there are a particular reason for this or this is a bug?
Thank you very much,
Chris
The text was updated successfully, but these errors were encountered: