[Bug tree-optimization/96672] Missing -Wclobbered diagnostic, or: __attribute__((returns_twice)) does not inhibit constant folding across call site

amonakov at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Tue Aug 18 11:21:29 GMT 2020


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96672

Alexander Monakov <amonakov at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |amonakov at gcc dot gnu.org

--- Comment #1 from Alexander Monakov <amonakov at gcc dot gnu.org> ---
Looking at dumps, after expanding to RTL we do not have the abnormal edge from
the longjmp BB. So while on GIMPLE we preserve modifications of 'x', on RTL we
see the 'x = 6' write as dead, and the 'x = 5' write is propagated to the use.

(the -Wclobbered warning happens after all the propagation is done)

I am surprised the abnormal dispatcher block is not preserved on RTL.


More information about the Gcc-bugs mailing list