aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
diff options
context:
space:
mode:
authorLu Weining <luweining@loongson.cn>2023-10-31 21:18:06 +0800
committerGitHub <noreply@github.com>2023-10-31 21:18:06 +0800
commit9ca6bf3fb7b7df373723b3275730f101f9ff816b (patch)
tree8ab6dadd412cd8709c3435a41b25d9007178df62 /llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
parent562ce8bbd23d96ee64992bcda041bf67e7c51057 (diff)
downloadllvm-9ca6bf3fb7b7df373723b3275730f101f9ff816b.zip
llvm-9ca6bf3fb7b7df373723b3275730f101f9ff816b.tar.gz
llvm-9ca6bf3fb7b7df373723b3275730f101f9ff816b.tar.bz2
[LoongArch] Fix ABI mismatch with gcc/g++ about empty structs passing (#70320)
How empty structs (not as fields of container struct) are passed in C++ is not explicitly documented in psABI. However, this patch fixes the mismatch with g++. Note that the unnamed bitfield case `struct { int : 1; }` in C is also fixed. Previously clang regards it as an empty struct and then ignores it when passing. Now size of the struct is counted; since it's size is not 0, clang will not ignore it even in C. While https://reviews.llvm.org/D156116 fixed the handling of empty struct when considering eligibility of the container struct for the FP calling convention ('flattening'), this patch fixes the handling of passing the empty struct itself. Fix https://github.com/llvm/llvm-project/issues/70319
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp')
0 files changed, 0 insertions, 0 deletions