[llvm] [AMDGPU] Infer amdgpu-no-flat-scratch-init attribute in AMDGPUAttributor (PR #94647)

Johannes Doerfert via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 6 19:47:50 PDT 2024


================
@@ -433,6 +433,19 @@ struct AAAMDAttributesFunction : public AAAMDAttributes {
       indicatePessimisticFixpoint();
       return;
     }
+
+    bool HasAllocaOrASCast = false;
+    for (BasicBlock &BB : *F) {
----------------
jdoerfert wrote:

isn't there a `instructions(F)`? Then you don't need 2 breaks, no bool, much easier.

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


More information about the llvm-commits mailing list