diff options
author | Richard Biener <rguenther@suse.de> | 2022-06-20 13:40:50 +0200 |
---|---|---|
committer | Richard Biener <rguenther@suse.de> | 2022-06-20 15:01:57 +0200 |
commit | 713f2fd923442b1be620a44240ddf786ae0ab476 (patch) | |
tree | f2b59bec9334fd4af01d51744f815282cfd353b1 /config | |
parent | 86882d9feb6a534325d7162216696266898e36d0 (diff) | |
download | gcc-713f2fd923442b1be620a44240ddf786ae0ab476.zip gcc-713f2fd923442b1be620a44240ddf786ae0ab476.tar.gz gcc-713f2fd923442b1be620a44240ddf786ae0ab476.tar.bz2 |
middle-end/106027 - fix types in needle folding
The fold_to_nonsharp_ineq_using_bound folding ends up creating invalid
typed IL which confuses later foldings. The following fixes that.
2022-06-20 Richard Biener <rguenther@suse.de>
PR middle-end/106027
* fold-const.cc (fold_to_nonsharp_ineq_using_bound): Use the
type of the prevailing comparison for the new comparison type.
(fold_binary_loc): Use proper types for the A < X && A + 1 > Y
to A < X && A >= Y folding.
* gcc.dg/pr106027.c: New testcase.
Diffstat (limited to 'config')
0 files changed, 0 insertions, 0 deletions