[PATCH] D101847: [AMDGPU] Fix function pointer argument bug in AMDGPU Propagate Attributes pass.

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 12 16:57:51 PDT 2021


arsenm added a comment.

I think at this point I'd prefer to just not worry about the cast stripping case and go back to just handling the direct callee.

This pass should not be required for correctness, and is only because opencl is still not linking the device libraries correctly such that the linked in functions have the correct subtarget/subtarget features. Long term I would like to move this pass into a form that does conservative merges of attributes, which can safely give up on anything indirect looking



================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUPropagateAttributes.cpp:259
+          assert(U->hasOneUser());
+          U = *U->users().begin();
+        }
----------------
This doesn't consider if there could be multiple users. It's a whole expression tree. It still feels wrong to be doing this style of search for this. 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D101847



More information about the llvm-commits mailing list