[llvm] 21711f8 - [LegalizeVectorOps] Move VP_STORE legalization from LegalizeDAG to LegalizeVectorOps.

Craig Topper via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 5 12:29:50 PDT 2024


Author: Craig Topper
Date: 2024-06-05T12:23:24-07:00
New Revision: 21711f89b9d85028160611f725bd33d7832d1d46

URL: https://github.com/llvm/llvm-project/commit/21711f89b9d85028160611f725bd33d7832d1d46
DIFF: https://github.com/llvm/llvm-project/commit/21711f89b9d85028160611f725bd33d7832d1d46.diff

LOG: [LegalizeVectorOps] Move VP_STORE legalization from LegalizeDAG to LegalizeVectorOps.

705636a1130551ab105aec95b909a35a0305fc9f moved reductions from
LegalizeVectorOps to LegalizeDAG, but the way it was done inadvertently
moved stores from LegalizeVectorOps to LegalizeDAG too. This was
not intended or desired.

Found when this was pulled into my downstream which has other changes
that make the distinction important.

Added: 
    

Modified: 
    llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp b/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
index 5c5347b7f314e..042684a434fd5 100644
--- a/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
@@ -507,7 +507,8 @@ SDValue VectorLegalizer::LegalizeOp(SDValue Op) {
         break;                                                                 \
     }                                                                          \
     /* Defer non-vector results to LegalizeDAG. */                             \
-    if (!Node->getValueType(0).isVector()) {                                   \
+    if (!Node->getValueType(0).isVector() &&                                   \
+        Node->getValueType(0) != MVT::Other) {                                 \
       Action = TargetLowering::Legal;                                          \
       break;                                                                   \
     }                                                                          \


        


More information about the llvm-commits mailing list