[llvm] [AMDGPU] Remove SIWholeQuadMode pass early exit (PR #98450)

Carl Ritson via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 11 02:38:48 PDT 2024


================
@@ -1688,25 +1686,32 @@ bool SIWholeQuadMode::runOnMachineFunction(MachineFunction &MF) {
         BuildMI(Entry, EntryMI, DebugLoc(), TII->get(AMDGPU::COPY), LiveMaskReg)
             .addReg(Exec);
     LIS->InsertMachineInstrInMaps(*MI);
+    Changed = true;
   }
 
   LLVM_DEBUG(printInfo());
 
-  lowerLiveMaskQueries();
-  lowerCopyInstrs();
+  Changed |= lowerLiveMaskQueries();
+  Changed |= lowerCopyInstrs();
 
-  // Shader only needs WQM
-  if (GlobalFlags == StateWQM) {
+  if (!(GlobalFlags & ~StateExact)) {
+    // No wave mode execution
+    Changed |= lowerKillInstrs(false);
----------------
perlfu wrote:

No, it wasn't necessary.
We ran the whole lowering for an Exact shader with kills.
In the whole lower `lowerBlock` performs the same function as lowerKillInstrs.

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


More information about the llvm-commits mailing list