[llvm] [AMDGPU] Cgscc amdgpu attributor boilerplate NFC (PR #179719)
Yoonseo Choi via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 5 09:48:59 PST 2026
yoonseoch wrote:
< Parts of old description for recording purpose >
> Lit tests running amdgpu-attributor were made to run amdgpu-attributor-cgscc as well. The same prefix for FileCheck is used to compare the module and the cgscc passes.
Fails from CGSCC passes are expected as shown by github-actions.
> I looked over a couple of failed tests.
`propagate-waves-per-eu.ll` failed in updating invalid waves-per-eu attributes at the kernel, which has one device callee. When CGSCC pass was running on the SCC of the device function, its caller, kernel's attributes couldn't be updated as the SCC doesn't contain the kernel (`Functions` doesn't contain kernel) and `AttributorConfig.IsModulePass = false`. When SCC pass was running on the SCC of the kernel, it stopped right away as attributor is not assuming a closed world.
> `uniform-work-group-multistep.ll` failed similarly. A call graph looks like kernel->internal1->internal2. SCC0, SCC1, SCC2 contains kernel, internal1, and internal2, respectively. CGSCC pass runs three times at SCC2, then SCC1, and finally SCC0. internel2's uniform-work-group-size attribute cannot be updated as while CGSCC pass runs for its SCC2, because CGSCC pass cannot update attributes of internal1 (Attributor's `Functions` only contains internal2 and configured as non-module pass). Without internal1's attribute, internal2's attribute is not changed. Next CGSCC passes on internal1 doesn't look at its callee, internal2, but only look at its caller, kernel.
https://github.com/llvm/llvm-project/pull/179719
More information about the llvm-commits
mailing list