[PATCH] D106393: [PowerPC][AIX] Add support for varargs for complex types on AIX

Hubert Tong via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 20 21:07:31 PDT 2021


hubert.reinterpretcast added inline comments.


================
Comment at: clang/lib/CodeGen/TargetInfo.cpp:4577-4583
+  // If we have a complex type and the base type is smaller than 8 bytes,
+  // the ABI calls for the real and imaginary parts to be right-adjusted
+  // in separate doublewords. However, Clang expects us to produce a
+  // pointer to a structure with the two parts packed tightly. So generate
+  // loads of the real and imaginary parts relative to the va_list pointer,
+  // and store them to a temporary structure. We do the same as the PPC64ABI
+  // here.
----------------
The 32-bit tests suggest that the "8 bytes"/"doublewords" in the above are not always so.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D106393/new/

https://reviews.llvm.org/D106393



More information about the cfe-commits mailing list