[PATCH] D88540: [AMDGPU] Add amdgpu_gfx_callable calling convention

Sebastian Neubauer via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 23 02:54:29 PDT 2020


Flakebi added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/SIISelLowering.cpp:2948-2954
+  if (AMDGPU::isShader(MF.getFunction().getCallingConv()) &&
+      CallConv != CallingConv::AMDGPU_Gfx) {
+    // Only allow calls with specific calling conventions.
+    return lowerUnhandledCall(CLI, InVals,
+                              "unsupported calling convention for call from "
+                              "graphics shader of function ");
   }
----------------
nhaehnle wrote:
> I assume you'll add support for calls from amdgpu_cs to amdgpu_gfx in a follow-up change?
Calls from any shader type to amdgpu_gfx should be allowed with this. Calls with any calling convention that is not amdgpu_gfx will fail.

“Fail” in this case means it silently prints a message if output is enabled and compiles successful anyway (just omitting the call).


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D88540



More information about the llvm-commits mailing list