[llvm] [llvm][CodeGen] respect booleanVectorContents while UnrollVSETCC (NFC) (PR #97589)

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 3 08:31:59 PDT 2024


================
@@ -2016,7 +2016,8 @@ SDValue VectorLegalizer::UnrollVSETCC(SDNode *Node) {
                          TLI.getSetCCResultType(DAG.getDataLayout(),
                                                 *DAG.getContext(), TmpEltVT),
                          LHSElem, RHSElem, CC);
-    Ops[i] = DAG.getSelect(dl, EltVT, Ops[i], DAG.getAllOnesConstant(dl, EltVT),
+    Ops[i] = DAG.getSelect(dl, EltVT, Ops[i],
+                           DAG.getBoolConstant(true, dl, EltVT, VT),
----------------
RKSimon wrote:

But this isn't NFC and we definitely need test coverage

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


More information about the llvm-commits mailing list