[clang] [clang] Return larger CXX records in memory (PR #120670)
Pranav Kant via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 2 08:25:48 PST 2025
================
@@ -2067,6 +2081,10 @@ void X86_64ABIInfo::classify(QualType Ty, uint64_t OffsetBase, Class &Lo,
classify(I.getType(), Offset, FieldLo, FieldHi, isNamedArg);
Lo = merge(Lo, FieldLo);
Hi = merge(Hi, FieldHi);
+ if (returnCXXRecordGreaterThan128InMem(
+ Size, getContext().getTypeSize(I.getType()),
+ getNativeVectorSizeForAVXABI(AVXLevel)))
+ Lo = Memory;
----------------
pranavk wrote:
This seemed like the most appropriate location for such a check as I only want to do it for CXXRecords (`if dyn_cast<CXXRecordDecl>` ...) which is already being checked here.
https://github.com/llvm/llvm-project/pull/120670
More information about the cfe-commits
mailing list