https://gcc.gnu.org/g:ca582ee36820a318fbc506928503282a5e35603a
commit r17-1604-gca582ee36820a318fbc506928503282a5e35603a Author: Andrew MacLeod <[email protected]> Date: Thu Jun 11 13:16:13 2026 -0400 Pointer global ranges of nonzero are no longer invariant. TO preserve processing, the cache did not track pointer ranges any more once it was set to non-zero. With prange now tracking pointers, any conditional may provide points-to info to a nonzero range, so we must track these values now. * gimple-range-cache.cc (ranger_cache::set_global_range): Nonzero pointer ranges are no longer invariant. Diff: --- gcc/gimple-range-cache.cc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gcc/gimple-range-cache.cc b/gcc/gimple-range-cache.cc index 6fdbd012e37b..78f18a26f1b7 100644 --- a/gcc/gimple-range-cache.cc +++ b/gcc/gimple-range-cache.cc @@ -1171,8 +1171,11 @@ ranger_cache::set_global_range (tree name, const vrange &r, bool changed) // Timestamp must always be updated, or dependent calculations may // not include this latest value. PR 100774. - if (r.singleton_p () - || (POINTER_TYPE_P (TREE_TYPE (name)) && r.nonzero_p ())) + // With Points_to info in prange now, it is no longer acceptable to make + // [1, +INF] invariant, as most points to values will have that range, + // and then we lose the ability to propagate points to info. + + if (r.singleton_p ()) gori_ssa ()->set_range_invariant (name); m_temporal->set_timestamp (name); }
