https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87561
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |missed-optimization CC| |rsandifo at gcc dot gnu.org --- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> --- Another thing is the too complicated alias check where for (gdb) p debug_data_reference (dr_a.dr) #(Data Ref: # bb: 14 # stmt: _28 = *xpqkl_172(D)[_27]; # ref: *xpqkl_172(D)[_27]; # base_object: *xpqkl_172(D); # Access function 0: {(((integer(kind=8)) mkl_203 + 1) * stride.33_148 + offset.34_149) + _480, +, stride.33_148}_6 #) $9 = void (gdb) p debug_data_reference (dr_b.dr) #(Data Ref: # bb: 14 # stmt: *xpqkl_172(D)[_50] = _65; # ref: *xpqkl_172(D)[_50]; # base_object: *xpqkl_172(D); # Access function 0: {(((integer(kind=8)) mkl_203 + 1) * stride.33_148 + offset.34_149) + _486, +, stride.33_148}_6 #) we generate (ssizetype) (((sizetype) ((((integer(kind=8)) mkl_203 + 1) * stride.33_148 + offset.34_149) + (integer(kind=8)) (_19 + jpack_161)) + (sizetype) stride.33_148) * 8) < (ssizetype) ((sizetype) ((((integer(kind=8)) mkl_203 + 1) * stride.33_148 + offset.34_149) + (integer(kind=8)) (_22 + lpack_164)) * 8) || (ssizetype) (((sizetype) ((((integer(kind=8)) mkl_203 + 1) * stride.33_148 + offset.34_149) + (integer(kind=8)) (_22 + lpack_164)) + (sizetype) stride.33_148) * 8) < (ssizetype) ((sizetype) ((((integer(kind=8)) mkl_203 + 1) * stride.33_148 + offset.34_149) + (integer(kind=8)) (_19 + jpack_161)) * 8) instead of simply _480 != _486 (well, OK, not _that_ simple). I guess we miss many of the "optimizations" we do when dealing with alias checks for constant steps. In this case sth obvious would be to special-case DR_STEP (dra) == DR_STEP (drb). Richard?