On Sun, Dec 17, 2017 at 09:07:54PM -0500, David Malcolm wrote: > What do you think? > > Successfully bootstrapped®rtested on x86_64-pc-linux-gnu, as > part of the kit. > > gcc/ChangeLog: > * fold-const.c (operand_equal_p): Strip any location wrappers, > before computing hashes. > --- > gcc/fold-const.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/gcc/fold-const.c b/gcc/fold-const.c > index 0f11076..2b938900 100644 > --- a/gcc/fold-const.c > +++ b/gcc/fold-const.c > @@ -2804,6 +2804,9 @@ combine_comparisons (location_t loc, > int > operand_equal_p (const_tree arg0, const_tree arg1, unsigned int flags) > { > + STRIP_ANY_LOCATION_WRAPPER (arg0); > + STRIP_ANY_LOCATION_WRAPPER (arg1); > +
Certainly not at this spot. The checking that hashing ignores the location wrappers needs to be done first. And inchash:add_expr needs to ignore those. Jakub