[PATCH] D92483: AMDGPU - Use MUBUF instructions for global address space access

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 2 19:38:29 PST 2020


arsenm added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp:122-124
+  if (getGeneration() == AMDGPUSubtarget::SOUTHERN_ISLANDS) {
+    FlatForGlobal = false;
+    if (FS.contains("+flat-for-global"))
----------------
This isn't a generation check, and should be the same as the above addr64 check


================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp:124
+    FlatForGlobal = false;
+    if (FS.contains("+flat-for-global"))
+       errs() << "GFX6 do not support Flat instructions for Global Address Space\n";
----------------
This string search isn't actually a reliable test but this is already used


================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp:125
+    if (FS.contains("+flat-for-global"))
+       errs() << "GFX6 do not support Flat instructions for Global Address Space\n";
+  }
----------------
I'm not sure printing a warning here is particularly helpful. It's not going to be reported in any meaningful way. A proper Diagnostic would be better, but I don't think this would be the right place to emit it. 


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D92483/new/

https://reviews.llvm.org/D92483



More information about the llvm-commits mailing list