aboutsummaryrefslogtreecommitdiff
path: root/gcc/config.gcc
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2017-07-19 14:31:59 +0200
committerJakub Jelinek <jakub@gcc.gnu.org>2017-07-19 14:31:59 +0200
commit8d1628eb33d4f53832d6d4be2b0021353057a370 (patch)
treed094faeffd74258f4d93793acf99507d3bb801ad /gcc/config.gcc
parent20deef65ae6058143c29199c1aab12d94e75181c (diff)
downloadgcc-8d1628eb33d4f53832d6d4be2b0021353057a370.zip
gcc-8d1628eb33d4f53832d6d4be2b0021353057a370.tar.gz
gcc-8d1628eb33d4f53832d6d4be2b0021353057a370.tar.bz2
re PR tree-optimization/81346 (Missed constant propagation into comparison)
PR tree-optimization/81346 * fold-const.h (fold_div_compare, range_check_type): Declare. * fold-const.c (range_check_type): New function. (build_range_check): Use range_check_type. (fold_div_compare): No longer static, rewritten into a match.pd helper function. (fold_comparison): Don't call fold_div_compare here. * match.pd (X / C1 op C2): New optimization using fold_div_compare as helper function. * gcc.dg/tree-ssa/pr81346-1.c: New test. * gcc.dg/tree-ssa/pr81346-2.c: New test. * gcc.dg/tree-ssa/pr81346-3.c: New test. * gcc.dg/tree-ssa/pr81346-4.c: New test. * gcc.target/i386/umod-3.c: Hide comparison against 1 from the compiler to avoid X / C1 op C2 optimization to trigger. From-SVN: r250338
Diffstat (limited to 'gcc/config.gcc')
0 files changed, 0 insertions, 0 deletions