[Bug target/31263] addressing modes are not selected correcly for x86 always
pinskia at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Dec 25 21:27:29 GMT 2021
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=31263
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed| |2021-12-25
Severity|minor |enhancement
Ever confirmed|0 |1
Status|UNCONFIRMED |NEW
--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
_1 = i_10 + 500;
_2 = _1 * 2;
_3 = _2 - i_10;
_4 = _3 - i_10;
(simplify
(minus (mult:s (plus:cs @0 @1) INTEGER_CST@2) @0)
(plus (mult @0 (minus @2 { build_one_cst (type); }) (mult @1 @2))))
Will work for the above case though I don't know if it is the right thing to do
as we are trading one mult for 2 in some cases.
More information about the Gcc-bugs
mailing list