[Bug target/83253] -ftree-slsr causes performance regression

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Dec 15 08:36:00 GMT 2017


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83253

--- Comment #14 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Well, in theory multiplication by 3 isn't that expensive on i?86/x86_64,
because lea can do that.  But multiplication by 4 should be still cheaper or as
cheap as, because if we do * 3 by lea, we can do * 4 by lea too (or can use
shift), and if we do * 3 by mov + add + add, that is more expensive than shift
or as add + add.


More information about the Gcc-bugs mailing list