[clang] [clang][PowerPC] Add flag to enable compatibility with GNU for complex arguments (PR #77732)

zhijian lin via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 26 12:11:38 PST 2024


================
@@ -372,11 +453,12 @@ Address PPC32_SVR4_ABIInfo::EmitVAArg(CodeGenFunction &CGF, Address VAList,
   if (getTarget().getTriple().isOSDarwin()) {
     auto TI = getContext().getTypeInfoInChars(Ty);
     TI.Align = getParamTypeAlignment(Ty);
+    int ArgGPRs = NumArgGPRs;
 
     CharUnits SlotSize = CharUnits::fromQuantity(4);
     return emitVoidPtrVAArg(CGF, VAList, Ty,
-                            classifyArgumentType(Ty).isIndirect(), TI, SlotSize,
-                            /*AllowHigherAlign=*/true);
+                            classifyArgumentType(Ty, ArgGPRs).isIndirect(), TI,
----------------
diggerlin wrote:

I am sure purpose the calculation the variable `ArgGPRs`, it be calculated in the function  `classifyArgumentType` , but never use it.

https://github.com/llvm/llvm-project/pull/77732


More information about the cfe-commits mailing list