[llvm] [VectorCombine] Fix crash in scalarizeVPIntrinsic (PR #72039)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Sat Nov 11 14:20:35 PST 2023
================
@@ -843,6 +843,8 @@ bool VectorCombine::scalarizeVPIntrinsic(Instruction &I) {
Value *ScalarOp0 = getSplatValue(Op0);
Value *ScalarOp1 = getSplatValue(Op1);
+ if (!ScalarOp0 || !ScalarOp1)
----------------
topperc wrote:
Should we use getSplatValue at the top where we used isSplatValue? That way we fail out before we do wasted work.
https://github.com/llvm/llvm-project/pull/72039
More information about the llvm-commits
mailing list