[clang] [clang] Add clang::debug_info_type attribute for bitfields (PR #69104)
David Blaikie via cfe-commits
cfe-commits at lists.llvm.org
Sun Oct 15 09:55:27 PDT 2023
dwblaikie wrote:
> This is useful when user is forced to use the same type for all bitfields in a class to get better [layout](https://godbolt.org/z/ovWqzqv9x) and [codegen](https://godbolt.org/z/bdoqvz9e6) from MSVC
Does this issue not apply to other platforms? (I didn't think you could bitfield enums)
I'd think maybe rather than adding an attribute to workaround MSVC's missing support - code could #ifdef in a way that's ABI compatible, maybe? (though I admit that's a subtle thing to get right & the cost for getting it wrong is significant)
https://github.com/llvm/llvm-project/pull/69104
More information about the cfe-commits
mailing list