[llvm] [AMDGPU][MC] Function scope resource usage struct (PR #188031)
Shilei Tian via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 14 21:07:59 PDT 2026
https://github.com/shiltian commented:
I've started the upstream process for object linking and have already merged one PR: https://github.com/llvm/llvm-project/pull/191645. The next one will focus on per-function resource usage information, which is what this PR is about. We can move forward with it if you'd like.
I think we need two things:
1. A clear structure for emitting per-function resource usage information. The exact value doesn't matter much right now, but it needs to be a concrete number rather than a number plus a symbol. I think this PR already achieves that.
2. In a follow-up PR, update the resource information to be local-only when object linking is enabled (`AMDGPUTargetMachine::EnableObjectLinking`). When it's not enabled, the value can remain propagated. I already have this implemented in the object linking RFC branch, so this part should be straightforward.
In addition, we probably add more information later, such as the occupancy limit of a function. This resource information might not be just about resource.
https://github.com/llvm/llvm-project/pull/188031
More information about the llvm-commits
mailing list