[Bug middle-end/82853] Optimize x % 3 == 0 without modulo
wilco at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Jun 3 11:11:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82853
--- Comment #36 from Wilco <wilco at gcc dot gnu.org> ---
(In reply to Orr Shalom Dvory from comment #35)
> Hi, thanks for your respond. can someone mark this bug as need to be
> improved?
> Does anyone agree/disagree with my new proposed method?
It's best to create a new bug if there are still easy cases that could be
optimized. Also it seems the constants it uses are quite complex - it may be
feasible to simplify them. Eg. long f(long x) { return x % 35 == 0; }
More information about the Gcc-bugs
mailing list