https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83253
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |hubicka at gcc dot gnu.org, | |uros at gcc dot gnu.org --- Comment #13 from Richard Biener <rguenth at gcc dot gnu.org> --- Indeed, looks like a target issue to me. IIRC nocona (aka pentium4) had pretty absymal shift cost but then x * 3 is two adds and x * 4 is two adds as well... (would point at a expmed mult expansion issue). On x86 for SImode with -m32 you could even use lea for x * 4. Maybe x86 people want to investigate (not for nocona but for -m32, nobody cares about nocona anymore...).