llvm.org GIT mirror llvm / 02b73b4
[X86] Add CMOV_VK2/VK4 pseudos and remove lowering code that turned v2i1/v4i1 SELECT into v8i1. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@343713 91177308-0d34-0410-b5e6-96231b3b80d8 Craig Topper 1 year, 9 months ago
2 changed file(s) with 6 addition(s) and 10 deletion(s). Raw diff Collapse all Expand all
1934019340 return DAG.getNode(ISD::EXTRACT_SUBVECTOR, DL, VT, ExtVec,
1934119341 DAG.getIntPtrConstant(0, DL));
1934219342 }
19343 }
19344
19345 if (VT == MVT::v4i1 || VT == MVT::v2i1) {
19346 SDValue zeroConst = DAG.getIntPtrConstant(0, DL);
19347 Op1 = DAG.getNode(ISD::INSERT_SUBVECTOR, DL, MVT::v8i1,
19348 DAG.getUNDEF(MVT::v8i1), Op1, zeroConst);
19349 Op2 = DAG.getNode(ISD::INSERT_SUBVECTOR, DL, MVT::v8i1,
19350 DAG.getUNDEF(MVT::v8i1), Op2, zeroConst);
19351 SDValue newSelect = DAG.getSelect(DL, MVT::v8i1, Cond, Op1, Op2);
19352 return DAG.getNode(ISD::EXTRACT_SUBVECTOR, DL, VT, newSelect, zeroConst);
1935319343 }
1935419344
1935519345 if (Cond.getOpcode() == ISD::SETCC) {
2746727457 case X86::CMOV_VR256:
2746827458 case X86::CMOV_VR256X:
2746927459 case X86::CMOV_VR512:
27460 case X86::CMOV_VK2:
27461 case X86::CMOV_VK4:
2747027462 case X86::CMOV_VK8:
2747127463 case X86::CMOV_VK16:
2747227464 case X86::CMOV_VK32:
2906529057 case X86::CMOV_VR256:
2906629058 case X86::CMOV_VR256X:
2906729059 case X86::CMOV_VR512:
29060 case X86::CMOV_VK2:
29061 case X86::CMOV_VK4:
2906829062 case X86::CMOV_VK8:
2906929063 case X86::CMOV_VK16:
2907029064 case X86::CMOV_VK32:
598598 defm _VR256X : CMOVrr_PSEUDO;
599599 }
600600 defm _VR512 : CMOVrr_PSEUDO;
601 defm _VK2 : CMOVrr_PSEUDO;
602 defm _VK4 : CMOVrr_PSEUDO;
601603 defm _VK8 : CMOVrr_PSEUDO;
602604 defm _VK16 : CMOVrr_PSEUDO;
603605 defm _VK32 : CMOVrr_PSEUDO;