https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113726
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|sanitizer |middle-end
Summary|sanitizer reports signed |sanitizer reports signed
|overflow but not underflow |overflow but not underflow
| |for constant folding case
Known to fail| |14.0, 5.1.0
Last reconfirmed| |2024-02-02
Ever confirmed|0 |1
Status|UNCONFIRMED |NEW
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed. It is constant folding ...
Reduced testcase:
```
int main() {
long result = (-__LONG_MAX__ - 1);
result -= 1l; // sanitizer reports this
result = (-__LONG_MAX__ - 1) - 1; // But NOT this
__builtin_printf("%ld\n", result);
}
```