[llvm] [AMDGPU] Switch V_CNDMASK operands to shrink it into VOP2 (PR #135162)

Jay Foad via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 10 05:22:34 PDT 2025


================
@@ -831,6 +836,109 @@ bool SIShrinkInstructions::tryReplaceDeadSDST(MachineInstr &MI) const {
   return true;
 }
 
+unsigned SIShrinkInstructions::getInverseCompareOpcode(MachineInstr &MI) const {
----------------
jayfoad wrote:

There are more V_CMP_* opcodes and all of them can be inverted. Maybe there is some table-driven way to implement this, e.g. with a table defined in TableGen? But that can be a future improvement/.

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


More information about the llvm-commits mailing list