[Bug target/105496] Comparison optimizations result in unnecessary cmp instructions
rguenth at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri May 6 06:06:48 GMT 2022
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105496
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target| |x86_64-*-*
Keywords| |missed-optimization
Ever confirmed|0 |1
Status|UNCONFIRMED |NEW
Last reconfirmed| |2022-05-06
Version|unknown |12.0
--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Confirmed. We canonicalize x < 11 to x <= 10 and on GIMPLE we don't have CC
flags and thus we cannot combine the two compares (we could maybe invent
switch (x CC_EXPR 11) { case LT: .. }). So _maybe_ compare elimination on RTL
is needed to do the job here.
More information about the Gcc-bugs
mailing list