arsenm added inline comments.

================
Comment at: clang/lib/CodeGen/TargetInfo.cpp:9288
+
+  const bool IsOpenMP = M.getLangOpts().OpenMP && !FD;
+  if ((IsOpenCLKernel || IsHIPKernel || IsOpenMP) &&
----------------
JonChesterfield wrote:
> JonChesterfield wrote:
> > JonChesterfield wrote:
> > > Here, we do the amdgpu-implicitarg-num-bytes and uniform-work-group-size 
> > > assignments regardless of whether FD is true or not
> > Cancel that, there's a IsOpenMP = ...&& !FD here. Failed to follow the 
> > control flow.
> Are we looking for `if (AMDGPU::isKernel(function.getCallingConv())` instead 
> of looking at the function attributes? I don't think we want to annotate 
> non-kernels with these things
!FD seems to always be true for openmp kernels because there's no associated 
function. This isn't looking at the IR function calling convention but I 
thought about switching to check that instead, but that's a separate change. 


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

https://reviews.llvm.org/D113538

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to