[llvm] [AMDGPU][Attributor] Make `AAAMDFlatWorkGroupSize` honor existing attribute (PR #114357)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 12 03:21:17 PST 2024
================
@@ -168,9 +168,18 @@ class AMDGPUInformationCache : public InformationCache {
return ST.supportsGetDoorbellID();
}
- std::pair<unsigned, unsigned> getFlatWorkGroupSizes(const Function &F) {
+ std::optional<std::pair<unsigned, unsigned>>
+ getFlatWorkGroupSizeAttr(const Function &F) const {
+ auto R = AMDGPU::getIntegerPairAttribute(F, "amdgpu-flat-work-group-size");
+ if (!R)
+ return std::nullopt;
+ return std::make_pair(R->first, *(R->second));
----------------
arsenm wrote:
Extra parens?
https://github.com/llvm/llvm-project/pull/114357
More information about the llvm-commits
mailing list