[Bug ipa/111088] useless 'xor eax,eax' inserted when a value is not returned and icf
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111088 Martin Jambor changed: What|Removed |Added CC||jamborm at gcc dot gnu.org --- Comment #5 from Martin Jambor --- (In reply to Jan Hubicka from comment #3) > > But adds a return with a value. And then the inliner inlines foo into foo2 > > but > > we still have the return with a value around ... > I guess ICF can special case unused return value, but why this is not > taken care of by ipa-sra? Probably because none of the functions is static.
[Bug ipa/111088] useless 'xor eax,eax' inserted when a value is not returned and icf
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111088 --- Comment #4 from Richard Biener --- In C++ this would have been undefined - I don't think this particular testcase is worth "optimizing".
[Bug ipa/111088] useless 'xor eax,eax' inserted when a value is not returned and icf
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111088 --- Comment #3 from Jan Hubicka --- > But adds a return with a value. And then the inliner inlines foo into foo2 but > we still have the return with a value around ... I guess ICF can special case unused return value, but why this is not taken care of by ipa-sra?