[llvm] [AMDGPU] Do not print `kernel-resource-usage` information on non-kernels (PR #99720)

Joseph Huber via llvm-commits llvm-commits at lists.llvm.org
Sat Jul 20 05:22:24 PDT 2024


================
@@ -1487,6 +1487,10 @@ void AMDGPUAsmPrinter::emitResourceUsageRemarks(
   if (!Ctx.getDiagHandlerPtr()->isAnalysisRemarkEnabled(Name))
     return;
 
+  // Currently non-kernel functions have no resources to emit.
+  if (MF.getFunction().getCallingConv() != CallingConv::AMDGPU_KERNEL)
----------------
jhuber6 wrote:

```suggestion
  if (!isEntryFunctionCC(MF.getFunction().getCallingConv()))
```

https://github.com/llvm/llvm-project/pull/99720


More information about the llvm-commits mailing list