[llvm] [AMPGPU] Emit s_singleuse_vdst instructions when a register is used multiple times in the same instruction. (PR #89601)

Jay Foad via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 29 08:09:15 PDT 2024


================
@@ -114,6 +102,22 @@ class AMDGPUInsertSingleUseVDST : public MachineFunctionPass {
           for (const MCRegUnit &Unit : RegUnits)
             RegisterUseCount.erase(Unit);
         }
+
+        for (const auto &Operand : MI.all_uses()) {
----------------
jayfoad wrote:

I guess you should disable all optimization across a call, like you do across exec mask changes, but that can be a separate patch.

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


More information about the llvm-commits mailing list