[libcxx-commits] [PATCH] D63744: In the libc++ unstable ABI, use [[no_unique_address]] instead of __compressed_pair when available.

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Nov 2 14:37:21 PST 2020


ldionne added a comment.

In D63744#2369727 <https://reviews.llvm.org/D63744#2369727>, @zoecarver wrote:

>> If we assume that the compiler supports [[no_unique_address]], is this an ABI break? Does no_unique_address result in a different layout than the __compressed_pair?
>
> This is only enabled in the unstable ABI so I think it's OK.

The fact that it's only enabled in the unstable ABI causes all this `#ifdef` mess, which is the reason why this patch has not landed yet. I'm trying to figure out whether we can use `__attribute__((no_unique_address))` in the stable ABI too. If we don't assume the compiler supports it then we can't (because then it would break ABI between compilers), but if we require the compiler to support it, then we might be okay. That's my question :-).


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D63744



More information about the libcxx-commits mailing list