[llvm] [AMDGPU][SDAG] Legalise v2i32 or/xor/and instructions to make use of 64-bit wide instructions (PR #140694)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Thu May 22 06:08:34 PDT 2025


================
@@ -12872,6 +12919,46 @@ SDValue SITargetLowering::performOrCombine(SDNode *N,
     }
   }
 
+  // Detect identity v2i32 OR and replace with identity source node.
+  // Specifically an Or that has operands constructed from the same source node
+  // via extract_vector_elt and build_vector.
----------------
arsenm wrote:

Probably should put this in the generic combiner, and generalize it to any vector type (and do the same for and/xor) 

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


More information about the llvm-commits mailing list