[llvm] [AMDGPU][SIInsertWaitcnts][NFC] Introduce Counter class (PR #190271)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 13 08:33:20 PDT 2026
vporpo wrote:
> I have a concern with the piecemeal approach being taken to fix what ain't broke.
These are two different arguments:
- The piecemeal approach: This is the preferred way of development in upstream LLVM, one small patch at a time.
- "fix what ain't broke". The current pass doesn't provide basic encapsulation for the counters, this is being fixed by this series of patches.
> There was a document that we reviewed internally, but even the solution in the proposal does not actually solve the problem it describes, instead only provides an intermediate state. Functions like getUB() and setUB() don't clean up anything since they do not represent true encapsulation. And setUBNoLBClamp() is a clear indicator that the design is far from done.
As is clearly stated in the code these are temporary functions and will be removed after the rest of the API is introduced. This is the whole goal of this patch series, to remove the raw access to the internals of the counters and provide a high-level API.
https://github.com/llvm/llvm-project/pull/190271
More information about the llvm-commits
mailing list