[PATCH] D95748: AMDGPU: Fix dbg_value handling when forming soft clause bundles

Scott Linder via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 1 10:29:21 PST 2021


scott.linder added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/SIFormMemoryClauses.cpp:326
 
+  SmallVector<MachineInstr *, 8> DbgInstrs;
+
----------------
Since https://reviews.llvm.org/D92522, if you don't have a strong reason for choosing 8


================
Comment at: llvm/lib/Target/AMDGPU/SIFormMemoryClauses.cpp:390-392
+      auto BundleNext = I;
+      for (auto BI = I; BI != Next; BI = BundleNext) {
+        BundleNext = std::next(BI);
----------------
When does `Next != BundleNext` after this `for` terminates? It seems like you should be able to just use `Next` below when re-inserting the DBG instructions?


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

https://reviews.llvm.org/D95748



More information about the llvm-commits mailing list