[Bug middle-end/107709] IVOPTs is introducing a non-zero assumption
amacleod at redhat dot com
gcc-bugzilla@gcc.gnu.org
Wed Nov 16 15:10:59 GMT 2022
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107709
--- Comment #2 from Andrew Macleod <amacleod at redhat dot com> ---
(In reply to Richard Biener from comment #1)
> IVOPTs is usually quite careful with this and the infer of non-NULL from
> ptr + CST is new - that introduced a new undefinedness in GIMPLE. The
> workaround would be to avoid the POINTER_PLUS_EXPR here and perform the
> increment in an unsigned type.
>
>
> Now, do we really want to introduce this new undefined behavior without
> seriously auditing the code base?
I think not. I will defer the inferred range code until next release to give us
a chance to sort this kind of thing out. I will attach the patch to PR 78655,
which when it is applied triggers the bug. That way it is easy to at least
find this one.. I can probably even attach an executable test to this PR that,
when combined with that patch, will fail. I think :-)
More information about the Gcc-bugs
mailing list