This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [Committed] Fix 54524: Wrong code with some 64bit addition with registers as 32bits
> Hmm, like you said originally in the PR, I think generating the invalid
> PLUS is the bug here. I agree (as Richard B said) that an invalid PLUS
> shouldn't cause us to generate wrong code, but an assert seems better
> than a check. Eric, what do you think?
I think that this boils down to deciding whether (PLUS X 0) is invalid or
merely non-canonical. If the former, then I agree that an assertion is
appropriate; if the latter, then I don't think that we should stop the
compiler because of it.
No strong opinion, although I'd lean towards the latter. In any case, the
piece of code which generates this PLUS needs also to be fixed (at least on
the mainline).
--
Eric Botcazou