Re: [PATCH] tree-vect-patterns: Fix up ICE in upper_bound [PR109115]

2023-03-14 Thread Richard Biener via Gcc-patches
On Tue, 14 Mar 2023, Jakub Jelinek wrote: > Hi! > > As mentioned in the PR, range_of_expr returns false if the type > of the expression isn't suitable for corresponding range type, > but doesn't if the range is undefined for other reasons. Still, > lower/upper_bound is defined only for ranges wh

[PATCH] tree-vect-patterns: Fix up ICE in upper_bound [PR109115]

2023-03-14 Thread Jakub Jelinek via Gcc-patches
Hi! As mentioned in the PR, range_of_expr returns false if the type of the expression isn't suitable for corresponding range type, but doesn't if the range is undefined for other reasons. Still, lower/upper_bound is defined only for ranges which actually have at least one pair of subranges, VR_UN