[llvm] [AMDGPU][SIInsertWaitcnts] Fix underflow in expand-waitcnt-profiling when Outstanding is 0 on Pre-GFX12 (PR #202465)

Akash Dutta via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 9 06:38:26 PDT 2026


akadutta wrote:

> Is there a reason why `EmitExpandedWaitcnt` isn't a static helper function that is used by both implementations? The lambda only seems to capture the `Modified` flag, we handle that as a return in other helper functions.

@ritter-x2a I don't see why it can't be a helper function. Simply wanted to stay as close to the GFX12+ implementation as possible. I'll update the patch with the same. Thanks.

https://github.com/llvm/llvm-project/pull/202465


More information about the llvm-commits mailing list