summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/AVR/Disassembler/AVRDisassembler.cpp
diff options
context:
space:
mode:
authorReid Kleckner <rnk@google.com>2020-01-02 13:17:10 -0800
committerReid Kleckner <rnk@google.com>2020-01-14 17:49:13 -0800
commit8e780252a7284be45cf1ba224cabd884847e8e92 (patch)
treea17d0f820830309c97fbd651d9dd627341c4b228 /llvm/lib/Target/AVR/Disassembler/AVRDisassembler.cpp
parent0f9cf42facaf9eff47dc0b9eb7e6ed8803d3bc3b (diff)
downloadbcm5719-llvm-8e780252a7284be45cf1ba224cabd884847e8e92.tar.gz
bcm5719-llvm-8e780252a7284be45cf1ba224cabd884847e8e92.zip
[X86] ABI compat bugfix for MSVC vectorcall
Summary: Before this change, X86_32ABIInfo::classifyArgument would be called twice on vector arguments to vectorcall functions. This function has side effects to track GPR register usage, and this would lead to incorrect GPR usage in some cases. The specific case I noticed is from running out of XMM registers with mixed FP and vector arguments and no aggregates of any kind. Consider this prototype: void __vectorcall vectorcall_indirect_vec( double xmm0, double xmm1, double xmm2, double xmm3, double xmm4, __m128 xmm5, __m128 ecx, int edx, __m128 mem); classifyArgument has no effects when called on a plain FP type, but when called on a vector type, it modifies FreeRegs to model GPR consumption. However, this should not happen during the vector call first pass. I refactored the code to unify vectorcall HVA logic with regcall HVA logic. The conventions pass HVAs in registers differently (expanded vs. not expanded), but if they do not fit in registers, they both pass them indirectly by address. Reviewers: erichkeane, craig.topper Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D72110
Diffstat (limited to 'llvm/lib/Target/AVR/Disassembler/AVRDisassembler.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud