https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92486
--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
Note when changing struct s to say
struct s {
char c;
int i __attribute__((aligned(128)));
};
you can (if you disable SRA!) observe that RTL expansion copies padding
for aggregate assignments:
g:
.LFB0:
.cfi_startproc
movdqa (%rsi), %xmm0
movdqa 16(%rsi), %xmm1
movdqa 32(%rsi), %xmm2
movdqa 48(%rsi), %xmm3
movdqa 64(%rsi), %xmm4
...
movaps %xmm5, 208(%rdi)
movaps %xmm6, 224(%rdi)
movaps %xmm7, 240(%rdi)
ret
so at least there doesn't seem to be middle-end code exploiting the C standards
copy-all-elements interpretation of aggregate assignment.