[llvm-branch-commits] [llvm] [AMDGPU][Attributor] Make `AAAMDWavesPerEU` honor existing attribute (PR #114438)

Matt Arsenault via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Oct 31 12:47:52 PDT 2024


================
@@ -215,6 +215,19 @@ class AMDGPUInformationCache : public InformationCache {
     return ST.getWavesPerEU(F, FlatWorkGroupSize);
   }
 
+  std::optional<std::pair<unsigned, unsigned>>
+  getWavesPerEUAttr(const Function &F) {
+    Attribute Attr = F.getFnAttribute("amdgpu-waves-per-eu");
+    if (!Attr.isStringAttribute())
+      return std::nullopt;
+    auto Val = parseRangeAttribute(Attr.getValueAsString());
----------------
arsenm wrote:

I don't see where this is defined 

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


More information about the llvm-branch-commits mailing list