[llvm] [AMDGPU][NewPass] Attempt to promote uniform ptr arguments to inreg (PR #210410)
Shilei Tian via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 30 13:46:34 PDT 2026
shiltian wrote:
> This should be done in AMDGPUAttributor and @shiltian has work in that area
We had some offline discussion about this. In its current form, this doesn't belong in `AMDGPUAttributor` because it doesn't require any iterative inference.
I previously added an AA for uniformity, but that only queried the trivial uniformity check rather than the full uniformity analysis. That PR was eventually reverted because it exposed some backend issues that I didn't have a chance to investigate.
Since we're not actually performing uniformity analysis within the Attributor framework, but are instead just querying the existing uniformity analysis, I don't think there's a good reason to put this in `AMDGPUAttributor`.
I also couldn't find an existing pass that would be a natural fit for this transformation. Given that, introducing a dedicated pass doesn't seem like the worst solution.
https://github.com/llvm/llvm-project/pull/210410
More information about the llvm-commits
mailing list