[llvm] [AMDGPU][SDAG] Legalise v2i32 or/xor/and instructions to make use of 64-bit wide instructions (PR #140694)
Chris Jackson via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 30 04:16:46 PDT 2025
================
@@ -721,6 +721,18 @@ static bool selectSupportsSourceMods(const SDNode *N) {
return N->getValueType(0) == MVT::f32;
}
+LLVM_READONLY
+static bool buildVectorSupportsSourceMods(const SDNode *N) {
+ if (N->getValueType(0) != MVT::v2f32)
+ return true;
+
+ if (N->getOperand(0)->getOpcode() != ISD::SELECT ||
+ N->getOperand(1)->getOpcode() != ISD::SELECT)
+ return true;
+
+ return false;
+}
----------------
chrisjbris wrote:
ok, I'll have hasSourceMods() return false for bUILD_VECTOR and add the necessary combines to fix the tests that this breaks.
https://github.com/llvm/llvm-project/pull/140694
More information about the llvm-commits
mailing list