[Bug tree-optimization/57503] [6/7/8 Regression] Wrong extension of multiply operand
glisse at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Jan 15 19:07:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57503
--- Comment #19 from Marc Glisse <glisse at gcc dot gnu.org> ---
Looking at the very first testcase in this PR, assuming 16-bit int, 129*255
overflows and is thus undefined behavior. Multiply by 255u if you want the
multiplication to happen safely in an unsigned type.
More information about the Gcc-bugs
mailing list