[PATCH] D65448: [AArch64] Implement initial SVE calling convention support
Oliver Stannard (Linaro) via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 30 09:40:49 PDT 2019
ostannard added a comment.
Out of interest, why does the ABI allow functions which don't have SVE args/returns to clobber the P registers? For Z registers, we've got to be compatible with old code which only needed to save the bottom half of v8-v15, but there should be no existing code which uses P registers, so we could enforce a mixture of callee- and caller-saved P registers for all code. Existing code is already compliant with this, because it doesn't touch the P regs.
================
Comment at: lib/Target/AArch64/AArch64ISelLowering.cpp:3968
+ // SVE mask....
+ if (CallConv == CallingConv::C) {
----------------
Comments should be complete sentences.
================
Comment at: test/CodeGen/AArch64/sve-calling-convention.ll:9
+; CHECK: name: sve_signature_vec
+; CHECK-DAG: [[RES:%[0-9]+]]:zpr = COPY $z1
+; CHECK-DAG: $z0 = COPY [[RES]]
----------------
These must be in this order, so shouldn't be CHECK-DAG.
================
Comment at: test/CodeGen/AArch64/sve-calling-convention.ll:32
+; CHECK: name: sve_signature_vec_caller
+; CHECK-DAG: $z0 = COPY %1
+; CHECK-DAG: $z1 = COPY %0
----------------
These should use a regex for the vreg number on the right.
================
Comment at: test/CodeGen/AArch64/sve-calling-convention.ll:34
+; CHECK-DAG: $z1 = COPY %0
+; CHECK-NEXT: BL @sve_signature_vec, csr_aarch64_sve_aapcs
+; CHECK: RET_ReallyLR implicit $z0
----------------
Can we check that the return value is pulled out of the right register?
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65448/new/
https://reviews.llvm.org/D65448
More information about the llvm-commits
mailing list