chill added inline comments.

================
Comment at: clang/test/CodeGen/aarch64-ABI-align-packed.c:34
 struct aligned_member_8 {
   uint16x8_t M0 __attribute((aligned (8))); // member alignment 16 since 
__attribute((aligned (n))) sets the minimum alignment
 };
----------------
JiruiWu wrote:
> chill wrote:
> > Don't you mean "`__attribute__((aligned(n)))` cannot decrease the minimum 
> > required alignment" ?
> > 
> > 
> I added this comment to explain that the natural alignment of the struct 
> `aligned_member_8` is 16-byte instead of 8-byte. In this test case the 
> alignment of  `M0` is 16 bytes, which is above the minimum required alignment 
> specified by `__attribute__((aligned(8)))`.
Yes, so the `__attribute__` does not actually set the minimum required 
alignment, 
it sets the member alignment to the maximum of the natural and the specified 
alignment.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D146242/new/

https://reviews.llvm.org/D146242

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to