Cleanup legacy_union and legacy intersect in value_range.
authorAldy Hernandez <aldyh@redhat.com>
Mon, 5 Oct 2020 15:36:13 +0000 (17:36 +0200)
committerAldy Hernandez <aldyh@redhat.com>
Mon, 5 Oct 2020 17:51:36 +0000 (19:51 +0200)
commitea6da7f50fe2adc3a09fc10a3f437902c40ebff9
tree9cdf2c422cb3bf145fd43b138b734bcd4b2a2dd9
parentbd431d26de02180d7fac1a794e2b9d3aaa4df34d
Cleanup legacy_union and legacy intersect in value_range.

These are cleanups so that multi-range union/intersect doesn't
have to deal with legacy code.  Instead, these should be done in
legacy mode.

gcc/ChangeLog:

* value-range.cc (irange::legacy_intersect): Only handle
legacy ranges.
(irange::legacy_union): Same.
(irange::union_): When unioning legacy with non-legacy,
first convert to legacy and do everything in legacy mode.
(irange::intersect): Same, but for intersect.
* range-op.cc (range_tests): Adjust for above changes.
gcc/range-op.cc
gcc/value-range.cc