[PATCH] D133484: [AArch64][SVE] Fix AArch64_SVE_VectorCall calling convention

Peter Waller via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 22 02:06:59 PDT 2022


peterwaller-arm accepted this revision.
peterwaller-arm added inline comments.
This revision is now accepted and ready to land.


================
Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:6751
+        if (EVT RegVT = ArgLocs[i].getLocVT(); RegVT.isScalableVector())
+          CallConv = CallingConv::AArch64_SVE_VectorCall;
+      }
----------------
You could also break once the CallConv is set.


================
Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:6754
+    }
     bool CalleeInSVE = any_of(Ins, [](ISD::InputArg &In){
       return In.VT.isScalableVector();
----------------
I can't think of a way that you can get a returned scalable type which doesn't go in a register, but it doesn't seem inconceivable it may be possible in the distant future. Since we're leaving a subtlety here it seems worth a brief comment of this form:

  // Check the types of the returned values. For the time being it is sufficient to check the VT as the RegVT is not known at this point.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D133484



More information about the llvm-commits mailing list