diff options
author | Andrew MacLeod <amacleod@redhat.com> | 2025-10-07 11:56:08 -0400 |
---|---|---|
committer | Andrew MacLeod <amacleod@redhat.com> | 2025-10-15 18:22:34 -0400 |
commit | 9e04a43012be504b75217704124987d0510f7fdc (patch) | |
tree | 18656adc59a0b34cc490a8360134acc6e17c0f41 /libcpp/init.cc | |
parent | fa9008b8a791ab4978777a111bbbd9b636335750 (diff) | |
download | gcc-9e04a43012be504b75217704124987d0510f7fdc.zip gcc-9e04a43012be504b75217704124987d0510f7fdc.tar.gz gcc-9e04a43012be504b75217704124987d0510f7fdc.tar.bz2 |
Range snap bitmasks as they are set.
Range bounds adjustments based on a bitmask were lazily set. This lead
to some inconsitencies which were causing problems. Improve the bounds,
and do it every time the bitmask is adjusted.
PR tree-optimization/121468
PR tree-optimization/121206
PR tree-optimization/122200
gcc/
* value-range.cc (irange_bitmask::range_from_mask): New.
(irange::snap): Add explicit overflow flag.
(irange::snap_subranges): Use overflow flag.
(irange::set_range_from_bitmask): Use range_from_mask.
(test_irange_snap_bounds): Adjust for improved ranges.
* value-range.h (irange::range_from_mask): Add prototype.
(irange::snap): Adjust prototype.
gcc/testsuite/
* gcc.dg/pr121468.c: New.
* gcc.dg/pr122200.c: New.
Diffstat (limited to 'libcpp/init.cc')
0 files changed, 0 insertions, 0 deletions