[PATCH] D106393: [PowerPC][AIX] Add support for varargs for complex types on AIX
Sean Fertile via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 14 11:12:38 PDT 2021
sfertile added a comment.
I suggest we separate the clang change and testing into a standalone patch, and the llvm backend tests into a standalone patch which we can commit separately.
================
Comment at: clang/lib/CodeGen/TargetInfo.cpp:4646
+ if (const ComplexType *CTy = Ty->getAs<ComplexType>()) {
+ CharUnits EltSize = TypeInfo.Width / 2;
+ if (EltSize < SlotSize) {
----------------
Minor nit: the code for PPC64 and this is almost identical, I think it should be factored into a separate helper function.
================
Comment at: clang/test/CodeGen/aix32-complex-varargs.c:2
+// REQUIRES: powerpc-registered-target
+// RUN: %clang_cc1 -triple powerpc-ibm-aix-xcoff -emit-llvm -o - %s | FileCheck %s
+
----------------
The code-gen for int and float won't change with this patch, lets pre-commit this test without the _Complex short and _Complex char portions now as an NFC patch.
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