Home | History | Annotate | Download | only in PowerPC

Lines Matching refs:MVT

75       return CurDAG->getTargetConstant(Imm, MVT::i32);
81 return CurDAG->getTargetConstant(Imm, MVT::i64);
263 if (PPCLowering.getPointerTy() == MVT::i32) {
286 if (N->getValueType(0) == MVT::i32)
300 if (N->getOpcode() == ISD::Constant && N->getValueType(0) == MVT::i32) {
310 if (N->getOpcode() == ISD::Constant && N->getValueType(0) == MVT::i64) {
361 if (N->getValueType(0) != MVT::i32)
463 return CurDAG->getMachineNode(PPC::RLWIMI, dl, MVT::i32, Ops);
476 if (LHS.getValueType() == MVT::i32) {
482 return SDValue(CurDAG->getMachineNode(PPC::CMPLWI, dl, MVT::i32, LHS,
486 return SDValue(CurDAG->getMachineNode(PPC::CMPWI, dl, MVT::i32, LHS,
498 SDValue Xor(CurDAG->getMachineNode(PPC::XORIS, dl, MVT::i32, LHS,
500 return SDValue(CurDAG->getMachineNode(PPC::CMPLWI, dl, MVT::i32, Xor,
506 return SDValue(CurDAG->getMachineNode(PPC::CMPLWI, dl, MVT::i32, LHS,
512 return SDValue(CurDAG->getMachineNode(PPC::CMPWI, dl, MVT::i32, LHS,
517 } else if (LHS.getValueType() == MVT::i64) {
523 return SDValue(CurDAG->getMachineNode(PPC::CMPLDI, dl, MVT::i64, LHS,
527 return SDValue(CurDAG->getMachineNode(PPC::CMPDI, dl, MVT::i64, LHS,
540 SDValue Xor(CurDAG->getMachineNode(PPC::XORIS8, dl, MVT::i64, LHS,
542 return SDValue(CurDAG->getMachineNode(PPC::CMPLDI, dl, MVT::i64, Xor,
549 return SDValue(CurDAG->getMachineNode(PPC::CMPLDI, dl, MVT::i64, LHS,
555 return SDValue(CurDAG->getMachineNode(PPC::CMPDI, dl, MVT::i64, LHS,
560 } else if (LHS.getValueType() == MVT::f32) {
563 assert(LHS.getValueType() == MVT::f64 && "Unknown vt!");
566 return SDValue(CurDAG->getMachineNode(Opc, dl, MVT::i32, LHS, RHS), 0);
632 static unsigned int getVCmpInst(MVT::SimpleValueType VecVT, ISD::CondCode CC) {
638 if (VecVT == MVT::v16i8)
640 else if (VecVT == MVT::v8i16)
642 else if (VecVT == MVT::v4i32)
645 else if (VecVT == MVT::v4f32)
652 if (VecVT == MVT::v16i8)
654 else if (VecVT == MVT::v8i16)
656 else if (VecVT == MVT::v4i32)
658 else if (VecVT == MVT::v4f32)
665 if (VecVT == MVT::v16i8)
667 else if (VecVT == MVT::v8i16)
669 else if (VecVT == MVT::v4i32)
673 if (VecVT == MVT::v4f32)
679 if (VecVT == MVT::v4f32)
683 if (VecVT == MVT::v4f32)
695 static unsigned int getVCmpEQInst(MVT::SimpleValueType VecVT) {
697 case MVT::v16i8:
699 case MVT::v8i16:
701 case MVT::v4i32:
703 case MVT::v4f32:
716 bool isPPC64 = (PtrVT == MVT::i64);
727 Op = SDValue(CurDAG->getMachineNode(PPC::CNTLZW, dl, MVT::i32, Op), 0);
729 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
734 SDValue(CurDAG->getMachineNode(PPC::ADDIC, dl, MVT::i32, MVT::Glue,
736 return CurDAG->SelectNodeTo(N, PPC::SUBFE, MVT::i32, AD, Op,
741 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
745 SDValue(CurDAG->getMachineNode(PPC::NEG, dl, MVT::i32, Op), 0);
746 T = SDValue(CurDAG->getMachineNode(PPC::ANDC, dl, MVT::i32, T, Op), 0);
748 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
757 Op = SDValue(CurDAG->getMachineNode(PPC::ADDIC, dl, MVT::i32, MVT::Glue,
759 return CurDAG->SelectNodeTo(N, PPC::ADDZE, MVT::i32,
761 MVT::i32,
766 Op = SDValue(CurDAG->getMachineNode(PPC::NOR, dl, MVT::i32, Op, Op), 0);
767 SDNode *AD = CurDAG->getMachineNode(PPC::ADDIC, dl, MVT::i32, MVT::Glue,
769 return CurDAG->SelectNodeTo(N, PPC::SUBFE, MVT::i32, SDValue(AD, 0),
773 SDValue AD = SDValue(CurDAG->getMachineNode(PPC::ADDI, dl, MVT::i32, Op,
775 SDValue AN = SDValue(CurDAG->getMachineNode(PPC::AND, dl, MVT::i32, AD,
778 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
782 Op = SDValue(CurDAG->getMachineNode(PPC::RLWINM, dl, MVT::i32, Ops),
784 return CurDAG->SelectNodeTo(N, PPC::XORI, MVT::i32, Op,
798 MVT::SimpleValueType VT = VecVT.getSimpleVT().SimpleTy;
854 SDValue CR7Reg = CurDAG->getRegister(PPC::CR7, MVT::i32);
860 IntCR = SDValue(CurDAG->getMachineNode(PPC::MFOCRF, dl, MVT::i32, CR7Reg,
866 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
870 SDValue(CurDAG->getMachineNode(PPC::RLWINM, dl, MVT::i32, Ops), 0);
871 return CurDAG->SelectNodeTo(N, PPC::XORI, MVT::i32, Tmp, getI32Imm(1));
886 if (N->getValueType(0) == MVT::i64) {
921 Result = CurDAG->getMachineNode(PPC::LI8, dl, MVT::i64, getI32Imm(Lo));
925 Result = CurDAG->getMachineNode(OpC, dl, MVT::i64, getI32Imm(Hi));
927 Result = CurDAG->getMachineNode(PPC::ORI8, dl, MVT::i64,
931 Result = CurDAG->getMachineNode(PPC::LIS8, dl, MVT::i64, getI32Imm(Hi));
939 Result = CurDAG->getMachineNode(PPC::RLDICR, dl, MVT::i64,
947 Result = CurDAG->getMachineNode(PPC::ORIS8, dl, MVT::i64,
951 Result = CurDAG->getMachineNode(PPC::ORI8, dl, MVT::i64,
968 unsigned Opc = N->getValueType(0) == MVT::i32 ? PPC::ADDI : PPC::ADDI8;
978 return CurDAG->getMachineNode(PPC::MFOCRF, dl, MVT::i32,
993 CurDAG->getMachineNode(PPC::SRAWI, dl, MVT::i32, MVT::Glue,
995 return CurDAG->SelectNodeTo(N, PPC::ADDZE, MVT::i32,
999 CurDAG->getMachineNode(PPC::SRAWI, dl, MVT::i32, MVT::Glue,
1002 SDValue(CurDAG->getMachineNode(PPC::ADDZE, dl, MVT::i32,
1005 return CurDAG->SelectNodeTo(N, PPC::NEG, MVT::i32, PT);
1028 if (LD->getValueType(0) != MVT::i64) {
1030 assert((!isSExt || LoadedVT == MVT::i16) && "Invalid sext update load");
1033 case MVT::f64: Opcode = PPC::LFDU; break;
1034 case MVT::f32: Opcode = PPC::LFSU; break;
1035 case MVT::i32: Opcode = PPC::LWZU; break;
1036 case MVT::i16: Opcode = isSExt ? PPC::LHAU : PPC::LHZU; break;
1037 case MVT::i1:
1038 case MVT::i8: Opcode = PPC::LBZU; break;
1041 assert(LD->getValueType(0) == MVT::i64 && "Unknown load result type!");
1042 assert((!isSExt || LoadedVT == MVT::i16) && "Invalid sext update load");
1045 case MVT::i64: Opcode = PPC::LDU; break;
1046 case MVT::i32: Opcode = PPC::LWZU8; break;
1047 case MVT::i16: Opcode = isSExt ? PPC::LHAU8 : PPC::LHZU8; break;
1048 case MVT::i1:
1049 case MVT::i8: Opcode = PPC::LBZU8; break;
1058 MVT::Other, Ops);
1062 if (LD->getValueType(0) != MVT::i64) {
1064 assert((!isSExt || LoadedVT == MVT::i16) && "Invalid sext update load");
1067 case MVT::f64: Opcode = PPC::LFDUX; break;
1068 case MVT::f32: Opcode = PPC::LFSUX; break;
1069 case MVT::i32: Opcode = PPC::LWZUX; break;
1070 case MVT::i16: Opcode = isSExt ? PPC::LHAUX : PPC::LHZUX; break;
1071 case MVT::i1:
1072 case MVT::i8: Opcode = PPC::LBZUX; break;
1075 assert(LD->getValueType(0) == MVT::i64 && "Unknown load result type!");
1076 assert((!isSExt || LoadedVT == MVT::i16 || LoadedVT == MVT::i32) &&
1080 case MVT::i64: Opcode = PPC::LDUX; break;
1081 case MVT::i32: Opcode = isSExt ? PPC::LWAUX : PPC::LWZUX8; break;
1082 case MVT::i16: Opcode = isSExt ? PPC::LHAUX8 : PPC::LHZUX8; break;
1083 case MVT::i1:
1084 case MVT::i8: Opcode = PPC::LBZUX8; break;
1093 MVT::Other, Ops);
1107 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
1116 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
1124 return CurDAG->SelectNodeTo(N, PPC::RLDICL, MVT::i64, Ops, 3);
1142 return CurDAG->getMachineNode(PPC::RLWIMI, dl, MVT::i32, Ops);
1150 if (N->getValueType(0) == MVT::i32)
1162 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
1174 return CurDAG->SelectNodeTo(N, PPC::RLWINM, MVT::i32, Ops, 4);
1183 bool isPPC64 = (PtrVT == MVT::i64);
1193 N->getValueType(0) == MVT::i32) {
1195 CurDAG->getMachineNode(PPC::ADDIC, dl, MVT::i32, MVT::Glue,
1197 return CurDAG->SelectNodeTo(N, PPC::SUBFE, MVT::i32,
1206 if (N->getValueType(0) == MVT::i32)
1208 else if (N->getValueType(0) == MVT::i64)
1210 else if (N->getValueType(0) == MVT::f32)
1212 else if (N->getValueType(0) == MVT::f64)
1228 MVT::Other, Ops, 2);
1241 return CurDAG->SelectNodeTo(N, PPC::BCC, MVT::Other, Ops, 5);
1248 return CurDAG->SelectNodeTo(N, PPC::BCC, MVT::Other, Ops, 4);
1254 unsigned Opc = Target.getValueType() == MVT::i32 ? PPC::MTCTR : PPC::MTCTR8;
1255 unsigned Reg = Target.getValueType() == MVT::i32 ? PPC::BCTR : PPC::BCTR8;
1256 Chain = SDValue(CurDAG->getMachineNode(Opc, dl, MVT::Glue, Target,
1258 MVT::Other, Chain);
1279 SDNode *Tmp = CurDAG->getMachineNode(PPC::ADDIStocHA, dl, MVT::i64,
1283 return CurDAG->getMachineNode(PPC::LDtocL, dl, MVT::i64, GA,
1300 return CurDAG->getMachineNode(PPC::LDtocL, dl, MVT::i64, GA,
1304 return CurDAG->getMachineNode(PPC::ADDItocL, dl, MVT::i64,
1323 VT = MVT::v16i8;
1328 VT = MVT::v8i16;
1334 VT = MVT::v4i32;
1517 ImmOpnd = CurDAG->getTargetGlobalAddress(GV, dl, MVT::i64, 0, Flags);
1521 ImmOpnd = CurDAG->getTargetConstantPool(C, MVT::i64,