Lines Matching defs:ValueVT

159                                       MVT PartVT, EVT ValueVT, const Value *V,
165 /// larger than ValueVT then AssertOp can be used to specify whether the extra
166 /// bits are known to be zero (ISD::AssertZext) or sign extended from ValueVT
170 unsigned NumParts, MVT PartVT, EVT ValueVT, const Value *V,
177 PartVT, ValueVT, CC))
180 if (ValueVT.isVector())
181 return getCopyFromPartsVector(DAG, DL, Parts, NumParts, PartVT, ValueVT, V,
189 if (ValueVT.isInteger()) {
191 unsigned ValueBits = ValueVT.getSizeInBits();
197 ValueVT : EVT::getIntegerVT(*DAG.getContext(), RoundBits);
239 assert(ValueVT == EVT(MVT::ppcf128) && PartVT == MVT::f64 &&
244 if (TLI.hasBigEndianPartOrdering(ValueVT, DAG.getDataLayout()))
246 Val = DAG.getNode(ISD::BUILD_PAIR, DL, ValueVT, Lo, Hi);
249 assert(ValueVT.isFloatingPoint() && PartVT.isInteger() &&
251 EVT IntVT = EVT::getIntegerVT(*DAG.getContext(), ValueVT.getSizeInBits());
257 // There is now one part, held in Val. Correct it to match ValueVT.
259 // ValueVT is the type of the inline asm operation.
262 if (PartEVT == ValueVT)
265 if (PartEVT.isInteger() && ValueVT.isFloatingPoint() &&
266 ValueVT.bitsLT(PartEVT)) {
269 PartEVT = EVT::getIntegerVT(*DAG.getContext(), ValueVT.getSizeInBits());
274 if (PartEVT.getSizeInBits() == ValueVT.getSizeInBits())
275 return DAG.getNode(ISD::BITCAST, DL, ValueVT, Val);
278 if (PartEVT.isInteger() && ValueVT.isInteger()) {
279 if (ValueVT.bitsLT(PartEVT)) {
285 DAG.getValueType(ValueVT));
286 return DAG.getNode(ISD::TRUNCATE, DL, ValueVT, Val);
288 return DAG.getNode(ISD::ANY_EXTEND, DL, ValueVT, Val);
291 if (PartEVT.isFloatingPoint() && ValueVT.isFloatingPoint()) {
293 if (ValueVT.bitsLT(Val.getValueType())) {
301 DAG.getVTList(ValueVT, MVT::Other), InChain, Val,
305 return DAG.getNode(ISD::FP_ROUND, DL, ValueVT, Val, NoChange);
308 return DAG.getNode(ISD::FP_EXTEND, DL, ValueVT, Val);
313 if (PartEVT == MVT::x86mmx && ValueVT.isInteger() &&
314 ValueVT.bitsLT(PartEVT)) {
316 return DAG.getNode(ISD::TRUNCATE, DL, ValueVT, Val);
338 /// type larger than ValueVT then AssertOp can be used to specify whether the
340 /// ValueVT (ISD::AssertSext).
343 MVT PartVT, EVT ValueVT, const Value *V,
346 assert(ValueVT.isVector() && "Not a vector value");
362 *DAG.getContext(), *CallConv, ValueVT, IntermediateVT,
366 TLI.getVectorTypeBreakdown(*DAG.getContext(), ValueVT, IntermediateVT,
411 // There is now one part, held in Val. Correct it to match ValueVT.
414 if (PartEVT == ValueVT)
419 if (ValueVT.getSizeInBits() == PartEVT.getSizeInBits())
420 return DAG.getNode(ISD::BITCAST, DL, ValueVT, Val);
425 if (PartEVT.getVectorElementCount() != ValueVT.getVectorElementCount()) {
427 ValueVT.getVectorElementCount().getKnownMinValue()) &&
429 ValueVT.getVectorElementCount().isScalable()) &&
433 ValueVT.getVectorElementCount());
436 if (PartEVT == ValueVT)
438 if (PartEVT.isInteger() && ValueVT.isFloatingPoint())
439 return DAG.getNode(ISD::BITCAST, DL, ValueVT, Val);
442 if (ValueVT.getSizeInBits() == PartEVT.getSizeInBits())
443 return DAG.getNode(ISD::BITCAST, DL, ValueVT, Val);
447 return DAG.getAnyExtOrTrunc(Val, DL, ValueVT);
452 if (PartEVT.getSizeInBits() == ValueVT.getSizeInBits() &&
453 TLI.isTypeLegal(ValueVT))
454 return DAG.getNode(ISD::BITCAST, DL, ValueVT, Val);
456 if (ValueVT.getVectorNumElements() != 1) {
459 if (ValueVT.getSizeInBits() == PartEVT.getSizeInBits()) {
460 return DAG.getNode(ISD::BITCAST, DL, ValueVT, Val);
461 } else if (ValueVT.bitsLT(PartEVT)) {
462 const uint64_t ValueSize = ValueVT.getFixedSizeInBits();
466 return DAG.getBitcast(ValueVT, Val);
471 return DAG.getUNDEF(ValueVT);
475 EVT ValueSVT = ValueVT.getVectorElementType();
476 if (ValueVT.getVectorNumElements() == 1 && ValueSVT != PartEVT) {
489 Val = ValueVT.isFloatingPoint()
495 return DAG.getBuildVector(ValueVT, DL, Val);
516 EVT ValueVT = Val.getValueType();
519 if (ValueVT.isVector())
530 assert(!ValueVT.isVector() && "Vector case handled elsewhere");
532 if (PartEVT == ValueVT) {
539 if (NumParts * PartBits > ValueVT.getSizeInBits()) {
541 if (PartVT.isFloatingPoint() && ValueVT.isFloatingPoint()) {
545 if (ValueVT.isFloatingPoint()) {
548 ValueVT = EVT::getIntegerVT(*DAG.getContext(), ValueVT.getSizeInBits());
549 Val = DAG.getNode(ISD::BITCAST, DL, ValueVT, Val);
552 ValueVT.isInteger() &&
554 ValueVT = EVT::getIntegerVT(*DAG.getContext(), NumParts * PartBits);
555 Val = DAG.getNode(ExtendKind, DL, ValueVT, Val);
559 } else if (PartBits == ValueVT.getSizeInBits()) {
561 assert(NumParts == 1 && PartEVT != ValueVT);
563 } else if (NumParts * PartBits < ValueVT.getSizeInBits()) {
566 ValueVT.isInteger() &&
568 ValueVT = EVT::getIntegerVT(*DAG.getContext(), NumParts * PartBits);
569 Val = DAG.getNode(ISD::TRUNCATE, DL, ValueVT, Val);
574 // The value may have changed - recompute ValueVT.
575 ValueVT = Val.getValueType();
576 assert(NumParts * PartBits == ValueVT.getSizeInBits() &&
580 if (PartEVT != ValueVT) {
593 assert(PartVT.isInteger() && ValueVT.isInteger() &&
598 SDValue OddVal = DAG.getNode(ISD::SRL, DL, ValueVT, Val,
599 DAG.getShiftAmountConstant(RoundBits, ValueVT, DL));
609 ValueVT = EVT::getIntegerVT(*DAG.getContext(), NumParts * PartBits);
610 Val = DAG.getNode(ISD::TRUNCATE, DL, ValueVT, Val);
617 ValueVT.getSizeInBits()),
648 EVT ValueVT = Val.getValueType();
650 EVT ValueEVT = ValueVT.getVectorElementType();
652 ElementCount ValueNumElts = ValueVT.getVectorElementCount();
666 ValueVT.changeVectorElementType(MVT::f16), Val);
694 EVT ValueVT = Val.getValueType();
695 assert(ValueVT.isVector() && "Not a vector");
701 if (PartEVT == ValueVT) {
703 } else if (PartVT.getSizeInBits() == ValueVT.getSizeInBits()) {
710 ValueVT.getVectorElementType()) &&
712 ValueVT.getVectorElementCount()) {
718 ValueVT.getVectorElementType() &&
719 TLI.getTypeAction(*DAG.getContext(), ValueVT) ==
723 EVT::getVectorVT(*DAG.getContext(), ValueVT.getVectorElementType(),
731 if (ValueVT.getVectorElementCount().isScalar() &&
732 (!ValueVT.isFloatingPoint() || !PartVT.isInteger())) {
734 // ValueVT is also FP and both have a different size, otherwise we
739 Val = DAG.getBitcast(ValueVT.getScalarType(), Val);
745 uint64_t ValueSize = ValueVT.getFixedSizeInBits();
766 *DAG.getContext(), *CallConv, ValueVT, IntermediateVT, NumIntermediates,
770 TLI.getVectorTypeBreakdown(*DAG.getContext(), ValueVT, IntermediateVT,
778 assert(IntermediateVT.isScalableVector() == ValueVT.isScalableVector() &&
791 if (ValueVT == BuiltVectorTy) {
793 } else if (ValueVT.getSizeInBits() == BuiltVectorTy.getSizeInBits()) {
798 ValueVT.getVectorElementType())) {
800 ValueVT = EVT::getVectorVT(*DAG.getContext(),
802 ValueVT.getVectorElementCount());
803 Val = DAG.getNode(ISD::ANY_EXTEND, DL, ValueVT, Val);
860 for (EVT ValueVT : ValueVTs) {
863 ? TLI.getNumRegistersForCallingConv(Context, *CC, ValueVT)
864 : TLI.getNumRegisters(Context, ValueVT);
867 ? TLI.getRegisterTypeForCallingConv(Context, *CC, ValueVT)
868 : TLI.getRegisterType(Context, ValueVT);
892 EVT ValueVT = ValueVTs[Value];
956 RegisterVT, ValueVT, V, Chain, CallConv);
9668 EVT ValueVT = OpInfo.ConstraintVT;
9670 ValueVT = RegVT;
9703 OpInfo.AssignedRegs = RegsForValue(Regs, RegVT, ValueVT);