https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65270

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
In theory comparing the object alignment with sth like

      unsigned int align1, align2;
      unsigned HOST_WIDE_INT tem;
      get_object_alignment_1 (t1, &align1, &tem);
      get_object_alignment_1 (t2, &align2, &tem);
      if (align1 != align2)
        return return_false_with_msg ("different access alignment");

should work, but in this case with variable offset we don't represent
"unknown misalign offset" and thus fail to see the difference here.
Thus we have to compare alignment of the base object here (but then
not that from ao_ref_base because that's too aggressive in stripping
MEM_REFs).

I have a patch.

Reply via email to