https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80292
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED CC| |jakub at gcc dot gnu.org Resolution|--- |INVALID --- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> --- No, that looks like misunderstanding what may_alias attribute is. It only does something for accesses through pointers, if the pointed type has may_alias attribute. That is not what you have in your test, the only pointers in there are long * and the pointed type does not have may_alias attribute, so it works as if there were no may_alias attributes at all.