You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Inconsistent results from pointer comparison #8161
In C, pointer-to-integer conversion is implementation-defined behaviour. That should give CBMC the freedom to choose an implementation where the condition (unsigned long)n >= (unsigned long)(-4095) never evaluates to true.
It is, however, also right to argue that CBMC should seek to model all possible implementations. The pointer-to-integer conversion in CBMC does not currently fulfil this expectation, but we will hopefully fix this in future.
Activity
tautschnig commentedon Jan 16, 2024
In C, pointer-to-integer conversion is implementation-defined behaviour. That should give CBMC the freedom to choose an implementation where the condition
(unsigned long)n >= (unsigned long)(-4095)never evaluates to true.It is, however, also right to argue that CBMC should seek to model all possible implementations. The pointer-to-integer conversion in CBMC does not currently fulfil this expectation, but we will hopefully fix this in future.
Address-based pointer equality and comparison (fixes diffblue#8200, d…
Add regression test for diffblue#8161: inconsistent pointer comparison
Address-based pointer equality and comparison (fixes diffblue#8200, d…
Add regression test for diffblue#8161: inconsistent pointer comparison
Address-based pointer equality and comparison (fixes diffblue#8200, d…
Add regression test for diffblue#8161: inconsistent pointer comparison
Add --wide-pointer-encoding: 192-bit pointers with flat addresses
Add --wide-pointer-encoding: 192-bit pointers with flat addresses
Add --wide-pointer-encoding: 192-bit pointers with flat addresses
Add --wide-pointer-encoding: 192-bit pointers with flat addresses
Add --wide-pointer-encoding: 192-bit pointers with flat addresses
Add --wide-pointer-encoding: 192-bit pointers with flat addresses
Add --wide-pointer-encoding: 192-bit pointers with flat addresses
Add --wide-pointer-encoding: 192-bit pointers with flat addresses