[PATCH] Optimize (X >> N) {>,>=,<,<=} C in the combiner (PR tree-optimization/20517)
Eric Botcazou
ebotcazou@adacore.com
Fri Sep 10 08:54:00 GMT 2010
> 2010-09-09 Jakub Jelinek <jakub@redhat.com>
>
> PR tree-optimization/20517
> * combine.c (simplify_comparison): Optimize (X >> N) {>,>=,<,<+} C
> even if low N bits of X aren't known to be zero.
OK on principle, but can we avoid the code duplication by ORing the comparison
on low bits with !equality_comparison_p and setting the low order bits in the
shifted constant only for the appropriate codes?
--
Eric Botcazou
More information about the Gcc-patches
mailing list