https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125250
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|[15/16/17 Regression] wrong |[15/16 Regression] wrong
|code at -O1/2/3 |code at -O1/2/3
Priority|P3 |P2
Known to work| |17.0
Known to fail| |16.1.0
--- Comment #10 from Richard Biener <rguenth at gcc dot gnu.org> ---
With this we are back to GCC 14 code generation where we already used
conditional store-motion. GCC 15 invokes UB by reading 8 into _Bool
while only with GCC 16+ we sanitize that to be defined via reading
an unsigned char and converting that to _Bool which is what truncates
the value.
So I agree it's worth fixing this for 15 as well.