[all-commits] [llvm/llvm-project] 7d29a9: [CIR] Accept a union whose empty member is [[no_un...
Adam Smith via All-commits
all-commits at lists.llvm.org
Tue Sep 15 17:17:03 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 7d29a9258695cc958bd63dc70176a38cb87fe4d6
https://github.com/llvm/llvm-project/commit/7d29a9258695cc958bd63dc70176a38cb87fe4d6
Author: Adam Smith <adams at nvidia.com>
Date: 2026-09-15 (Tue, 15 Sep 2026)
Changed paths:
M clang/lib/CIR/Dialect/Transforms/CallConvLoweringPass.cpp
M clang/test/CIR/CodeGen/call-conv-lowering-x86_64-empty.cpp
M clang/test/CIR/Transforms/abi-lowering/x86_64-aggregate-nyi.cir
M clang/test/CIR/Transforms/abi-lowering/x86_64-union.cir
Log Message:
-----------
[CIR] Accept a union whose empty member is [[no_unique_address]] (#223538)
The record-wide reject for a member CIRGen marks empty is there for the
struct arm of mapCIRType, which reads such a member as an unnamed
bit-field standing for the bytes it occupies. This does not apply to a
union, so the reject moves into the struct branch.
Which variants the classifier sees then falls to the union arm, and it
now reads that from each variant's own storage rather than from its
mark. A zero-sized variant and one that is empty for the ABI are
skipped. One whose mark says empty over storage that holds data is not.
Assisted-by: Cursor / claude-opus-5
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list