[Bug target/106701] Compiler does not take into account number range limitation to avoid subtract from immediate
rguenth at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Aug 24 10:02:50 GMT 2022
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106701
--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
I'd say all single-operation magic shouldn't happen in match.pd, this really
looks like something for RTL expansion to decide. For example some targets
might have instructions that can either do cst - a or cst ^ a with an immediate
(when integer_pow2p (cst + 1)).
match.pd should be about canonicalization here (none of the two is "simpler"),
but canonicalization based on value-range looks a bit iffy.
More information about the Gcc-bugs
mailing list