[llvm] [llvm] Adding scalarization of `llvm.vector.insert` (PR #71614)

via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 10 07:24:03 PST 2023


================
@@ -5891,8 +5910,11 @@ SDValue DAGTypeLegalizer::WidenVecRes_SETCC(SDNode *N) {
     InOp1 = GetWidenedVector(InOp1);
     InOp2 = GetWidenedVector(InOp2);
   } else {
-    InOp1 = DAG.WidenVector(InOp1, SDLoc(N));
-    InOp2 = DAG.WidenVector(InOp2, SDLoc(N));
+    do {
----------------
qcolombet wrote:

> As an operation it still makes sense to scalarize it, not widen.

I agree, but could you refresh my memory: is it something we have a control on?

IIRC, the selection of a strategy for type legalization is agnostic of the particular instruction being legalized and happens before the custom lowering, but it's been a while since I touched SDISel.

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


More information about the llvm-commits mailing list