LLVM API Documentation

Classes | Public Member Functions | Static Public Member Functions
llvm::EVT Struct Reference

#include <ValueTypes.h>

List of all members.

Classes

struct  compareRawBits

Public Member Functions

 EVT ()
 EVT (MVT::SimpleValueType SVT)
 EVT (MVT S)
bool operator== (EVT VT) const
bool operator!= (EVT VT) const
EVT changeVectorElementTypeToInteger () const
bool isSimple () const
bool isExtended () const
bool isFloatingPoint () const
 isFloatingPoint - Return true if this is a FP, or a vector FP type.
bool isInteger () const
 isInteger - Return true if this is an integer, or a vector integer type.
bool isVector () const
 isVector - Return true if this is a vector value type.
bool is16BitVector () const
 is16BitVector - Return true if this is a 16-bit vector type.
bool is32BitVector () const
 is32BitVector - Return true if this is a 32-bit vector type.
bool is64BitVector () const
 is64BitVector - Return true if this is a 64-bit vector type.
bool is128BitVector () const
 is128BitVector - Return true if this is a 128-bit vector type.
bool is256BitVector () const
 is256BitVector - Return true if this is a 256-bit vector type.
bool is512BitVector () const
 is512BitVector - Return true if this is a 512-bit vector type.
bool is1024BitVector () const
 is1024BitVector - Return true if this is a 1024-bit vector type.
bool isOverloaded () const
 isOverloaded - Return true if this is an overloaded type for TableGen.
bool isByteSized () const
 isByteSized - Return true if the bit size is a multiple of 8.
bool isRound () const
 isRound - Return true if the size is a power-of-two number of bytes.
bool bitsEq (EVT VT) const
 bitsEq - Return true if this has the same number of bits as VT.
bool bitsGT (EVT VT) const
 bitsGT - Return true if this has more bits than VT.
bool bitsGE (EVT VT) const
 bitsGE - Return true if this has no less bits than VT.
bool bitsLT (EVT VT) const
 bitsLT - Return true if this has less bits than VT.
bool bitsLE (EVT VT) const
 bitsLE - Return true if this has no more bits than VT.
MVT getSimpleVT () const
EVT getScalarType () const
EVT getVectorElementType () const
unsigned getVectorNumElements () const
unsigned getSizeInBits () const
 getSizeInBits - Return the size of the specified value type in bits.
unsigned getScalarSizeInBits () const
unsigned getStoreSize () const
unsigned getStoreSizeInBits () const
EVT getRoundIntegerType (LLVMContext &Context) const
EVT getHalfSizedIntegerVT (LLVMContext &Context) const
EVT widenIntegerVectorElementType (LLVMContext &Context) const
 Return a VT for an integer vector type with the size of the elements doubled. The typed returned may be an extended type.
bool isPow2VectorType () const
 isPow2VectorType - Returns true if the given vector is a power of 2.
EVT getPow2VectorType (LLVMContext &Context) const
std::string getEVTString () const
TypegetTypeForEVT (LLVMContext &Context) const
intptr_t getRawBits () const

Static Public Member Functions

static EVT getFloatingPointVT (unsigned BitWidth)
static EVT getIntegerVT (LLVMContext &Context, unsigned BitWidth)
static EVT getVectorVT (LLVMContext &Context, EVT VT, unsigned NumElements)
static EVT getEVT (Type *Ty, bool HandleUnknown=false)

Detailed Description

EVT - Extended Value Type. Capable of holding value types which are not native for any processor (such as the i12345 type), as well as the types a MVT can represent.

Definition at line 31 of file ValueTypes.h.


Constructor & Destructor Documentation

llvm::EVT::EVT ( ) [inline]

Definition at line 37 of file ValueTypes.h.

Referenced by getHalfSizedIntegerVT(), and getRoundIntegerType().

Definition at line 39 of file ValueTypes.h.

llvm::EVT::EVT ( MVT  S) [inline]

Definition at line 40 of file ValueTypes.h.


Member Function Documentation

bool llvm::EVT::bitsEq ( EVT  VT) const [inline]

bitsEq - Return true if this has the same number of bits as VT.

Definition at line 172 of file ValueTypes.h.

References getSizeInBits().

bool llvm::EVT::bitsGE ( EVT  VT) const [inline]

bitsGE - Return true if this has no less bits than VT.

Definition at line 184 of file ValueTypes.h.

References getSizeInBits().

Referenced by getCopyToPartsVector(), getMemcpyLoadsAndStores(), and llvm::AMDGPUTargetLowering::LowerLOAD().

bool llvm::EVT::bitsGT ( EVT  VT) const [inline]
bool llvm::EVT::bitsLE ( EVT  VT) const [inline]
bool llvm::EVT::bitsLT ( EVT  VT) const [inline]
EVT EVT::getEVT ( Type Ty,
bool  HandleUnknown = false 
) [static]

getEVT - Return the value type corresponding to the specified type. This returns all pointers as iPTR. If HandleUnknown is true, unknown types are returned as Other, otherwise they are invalid.

getEVT - Return the value type corresponding to the specified type. This returns all pointers as MVT::iPTR. If HandleUnknown is true, unknown types are returned as Other, otherwise they are invalid.

Definition at line 275 of file ValueTypes.cpp.

References getBitWidth(), llvm::Type::getContext(), llvm::SequentialType::getElementType(), getIntegerVT(), llvm::VectorType::getNumElements(), llvm::Type::getTypeID(), getVectorVT(), llvm::MVT::getVT(), llvm::Type::IntegerTyID, and llvm::Type::VectorTyID.

Referenced by llvm::ARMTargetLowering::allowTruncateForTailCall(), llvm::Intrinsic::getName(), llvm::FastISel::getRegForGEPIndex(), llvm::TargetLoweringBase::getValueType(), INITIALIZE_PASS(), isNoopBitcast(), llvm::HexagonTargetLowering::isTruncateFree(), llvm::FastISel::selectBinaryOp(), and SinkShiftAndTruncate().

std::string EVT::getEVTString ( ) const

getEVTString - This function returns value type as a string, e.g. "i32".

Definition at line 106 of file ValueTypes.cpp.

References llvm::MVT::f128, llvm::MVT::f16, llvm::MVT::f32, llvm::MVT::f64, llvm::MVT::f80, getEVTString(), getSizeInBits(), getVectorElementType(), getVectorNumElements(), llvm::MVT::Glue, llvm::MVT::i1, llvm::MVT::i128, llvm::MVT::i16, llvm::MVT::i32, llvm::MVT::i64, llvm::MVT::i8, isInteger(), isVector(), llvm::MVT::isVoid, llvm_unreachable, llvm::MVT::Metadata, llvm::MVT::Other, llvm::MVT::ppcf128, llvm::MVT::SimpleTy, llvm::MVT::Untyped, llvm::utostr(), llvm::MVT::v16f32, llvm::MVT::v16i1, llvm::MVT::v16i16, llvm::MVT::v16i32, llvm::MVT::v16i64, llvm::MVT::v16i8, llvm::MVT::v1f32, llvm::MVT::v1f64, llvm::MVT::v1i16, llvm::MVT::v1i32, llvm::MVT::v1i64, llvm::MVT::v1i8, llvm::MVT::v2f16, llvm::MVT::v2f32, llvm::MVT::v2f64, llvm::MVT::v2i1, llvm::MVT::v2i16, llvm::MVT::v2i32, llvm::MVT::v2i64, llvm::MVT::v2i8, llvm::MVT::v32i1, llvm::MVT::v32i16, llvm::MVT::v32i8, llvm::MVT::v4f16, llvm::MVT::v4f32, llvm::MVT::v4f64, llvm::MVT::v4i1, llvm::MVT::v4i16, llvm::MVT::v4i32, llvm::MVT::v4i64, llvm::MVT::v4i8, llvm::MVT::v64i1, llvm::MVT::v64i8, llvm::MVT::v8f16, llvm::MVT::v8f32, llvm::MVT::v8f64, llvm::MVT::v8i1, llvm::MVT::v8i16, llvm::MVT::v8i32, llvm::MVT::v8i64, llvm::MVT::v8i8, and llvm::MVT::x86mmx.

Referenced by llvm::Hexagon_CCState::AnalyzeCallOperands(), llvm::CCState::AnalyzeCallOperands(), llvm::MipsTargetLowering::MipsCC::analyzeCallOperands(), llvm::Hexagon_CCState::AnalyzeCallResult(), llvm::CCState::AnalyzeCallResult(), llvm::Hexagon_CCState::AnalyzeFormalArguments(), llvm::CCState::AnalyzeFormalArguments(), llvm::MipsTargetLowering::MipsCC::analyzeFormalArguments(), llvm::Hexagon_CCState::AnalyzeReturn(), llvm::CCState::AnalyzeReturn(), getEVTString(), llvm::Intrinsic::getName(), and llvm::SDNode::print_types().

static EVT llvm::EVT::getFloatingPointVT ( unsigned  BitWidth) [inline, static]

getFloatingPointVT - Returns the EVT that represents a floating point type with the given number of bits. There are two floating point types with 128 bits - this returns f128 rather than ppcf128.

Definition at line 56 of file ValueTypes.h.

Referenced by lowerFP_TO_SINT_STORE(), and LowerVECTOR_SHUFFLE().

EVT llvm::EVT::getHalfSizedIntegerVT ( LLVMContext Context) const [inline]

getHalfSizedIntegerVT - Finds the smallest simple value type that is greater than or equal to half the width of this EVT. If no simple value type can be found, an extended integer value type of half the size (rounded up) is returned.

Definition at line 271 of file ValueTypes.h.

References EVT(), llvm::MVT::FIRST_INTEGER_VALUETYPE, getIntegerVT(), getSizeInBits(), isInteger(), isVector(), and llvm::MVT::LAST_INTEGER_VALUETYPE.

Referenced by ExpandUnalignedStore(), and llvm::R600TargetLowering::ReplaceNodeResults().

static EVT llvm::EVT::getIntegerVT ( LLVMContext Context,
unsigned  BitWidth 
) [inline, static]
EVT llvm::EVT::getPow2VectorType ( LLVMContext Context) const [inline]

getPow2VectorType - Widens the length of the given vector EVT up to the nearest power of 2 and returns that type.

Definition at line 299 of file ValueTypes.h.

References getVectorElementType(), getVectorNumElements(), getVectorVT(), isPow2VectorType(), and llvm::Log2_32_Ceil().

Referenced by llvm::TargetLoweringBase::getTypeConversion().

intptr_t llvm::EVT::getRawBits ( ) const [inline]
EVT llvm::EVT::getRoundIntegerType ( LLVMContext Context) const [inline]

getRoundIntegerType - Rounds the bit-width of the given integer EVT up to the nearest power of two (and at least to eight), and returns the integer EVT with that number of bits.

Definition at line 259 of file ValueTypes.h.

References EVT(), getIntegerVT(), getSizeInBits(), llvm::MVT::i8, isInteger(), isVector(), and llvm::Log2_32_Ceil().

Referenced by llvm::TargetLoweringBase::getTypeConversion().

EVT llvm::EVT::getScalarType ( ) const [inline]

getScalarType - If this is a vector type, return the element type, otherwise return this.

Definition at line 211 of file ValueTypes.h.

References getVectorElementType(), and isVector().

Referenced by llvm::SelectionDAG::computeKnownBits(), llvm::AArch64TargetLowering::computeKnownBitsForTargetNode(), llvm::ARMTargetLowering::computeKnownBitsForTargetNode(), llvm::SelectionDAG::ComputeNumSignBits(), llvm::SelectionDAG::EVTToAPFloatSemantics(), llvm::SelectionDAG::FoldConstantArithmetic(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getConstantFP(), getCopyFromPartsVector(), llvm::SelectionDAG::getLoad(), llvm::SelectionDAG::getLogicalNOT(), getMemsetValue(), llvm::SelectionDAG::getNode(), llvm::SelectionDAG::getNOT(), llvm::SITargetLowering::getPreferredVectorAction(), llvm::NVPTXTargetLowering::getPreferredVectorAction(), getScalarSizeInBits(), llvm::SDValue::getScalarValueSizeInBits(), llvm::SelectionDAG::getTruncStore(), getUsefulBits(), llvm::SelectionDAG::getZeroExtendInReg(), getZeroVector(), isConstOrConstSplat(), llvm::SITargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::SystemZTargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::AArch64TargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::PPCTargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::AMDGPUTargetLowering::isFPImmLegal(), llvm::AMDGPUTargetLowering::isLoadBitCastBeneficial(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), LowerExtendedLoad(), LowerIntVSETCC_AVX512(), llvm::AMDGPUTargetLowering::LowerLOAD(), LowerZERO_EXTEND_AVX512(), llvm::PPCTargetLowering::PerformDAGCombine(), PerformFMACombine(), PerformISDSETCCCombine(), PerformLOADCombine(), PerformSELECTCombine(), PerformSTORECombine(), llvm::AMDGPUTargetLowering::ShouldShrinkFPConstant(), llvm::SelectionDAG::SignBitIsZero(), llvm::TargetLowering::SimplifyDemandedBits(), tryToFoldExtendOfConstant(), ValueHasExactlyOneBitSet(), and WidenMaskArithmetic().

MVT llvm::EVT::getSimpleVT ( ) const [inline]

getSimpleVT - Return the SimpleValueType held in the specified simple EVT.

Definition at line 204 of file ValueTypes.h.

References isSimple().

Referenced by AddCombineToVPADDL(), llvm::MipsSETargetLowering::allowsMisalignedMemoryAccesses(), llvm::ARMTargetLowering::allowsMisalignedMemoryAccesses(), llvm::PPCTargetLowering::allowsMisalignedMemoryAccesses(), changeVectorElementTypeToInteger(), llvm::AArch64TargetLowering::computeKnownBitsForTargetNode(), llvm::SelectionDAG::EVTToAPFloatSemantics(), FindOptimalMemOpLowering(), llvm::SelectionDAG::FoldSetCC(), getExtensionTo64Bits(), llvm::TargetLoweringBase::getLoadExtAction(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getNumRegisters(), llvm::TargetLoweringBase::getOperationAction(), llvm::AArch64TargetLowering::getPreferredVectorAction(), llvm::FastISel::getRegForGEPIndex(), llvm::FastISel::getRegForValue(), llvm::TargetLoweringBase::getRegisterType(), llvm::SDValue::getSimpleValueType(), llvm::SDNode::getSimpleValueType(), llvm::TargetLoweringBase::getSimpleValueType(), llvm::TargetLoweringBase::getTruncStoreAction(), llvm::TargetLoweringBase::getTypeConversion(), llvm::TargetLoweringBase::getTypeLegalizationCost(), llvm::SelectionDAG::getValueType(), llvm::TargetLoweringBase::getVectorTypeBreakdown(), llvm::Hexagon_CCState::HandleByVal(), llvm::ISD::InputArg::InputArg(), is32Bit(), llvm::SITargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::SystemZTargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::AArch64TargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::PPCTargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::TargetLoweringBase::isIndexedLoadLegal(), llvm::TargetLoweringBase::isIndexedStoreLegal(), isLegalAddressImmediate(), llvm::ARMTargetLowering::isLegalAddressingMode(), isLegalT1AddressImmediate(), isLegalT2AddressImmediate(), llvm::ARMTargetLowering::isLegalT2ScaledAddressingMode(), llvm::TargetLoweringBase::isLoadExtLegal(), llvm::HexagonTargetLowering::isTruncateFree(), llvm::TargetLoweringBase::isTruncStoreLegal(), llvm::TargetLoweringBase::isTypeLegal(), isValidIndexedLoad(), llvm::XCoreTargetLowering::isZExtFree(), llvm::ARMTargetLowering::isZExtFree(), llvm::SystemZTargetLowering::LowerFormalArguments(), matchIntegerMINMAX(), NarrowVector(), WidenVector::operator()(), llvm::ISD::OutputArg::OutputArg(), performBitcastCombine(), performConcatVectorsCombine(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), llvm::FastISel::selectBinaryOp(), llvm::FastISel::selectBitCast(), llvm::FastISel::selectCast(), llvm::FastISel::selectExtractValue(), llvm::FastISel::selectFNeg(), llvm::TargetLowering::SimplifySetCC(), llvm::SelectionDAGBuilder::visitBitTestHeader(), WidenVector(), X86ChooseCmpImmediateOpcode(), X86ChooseCmpOpcode(), and XFormVExtractWithShuffleIntoLoad().

unsigned llvm::EVT::getSizeInBits ( ) const [inline]

getSizeInBits - Return the size of the specified value type in bits.

Definition at line 234 of file ValueTypes.h.

References llvm::MVT::getSizeInBits(), and isSimple().

Referenced by AddRequiredExtensionForVMULL(), bitsEq(), bitsGE(), bitsGT(), bitsLE(), bitsLT(), BuildVectorFromScalar(), CalculateTailCallArgDest(), CombineBaseUpdate(), llvm::SelectionDAG::computeKnownBits(), llvm::AArch64TargetLowering::computeKnownBitsForTargetNode(), llvm::ARMTargetLowering::computeKnownBitsForTargetNode(), llvm::SelectionDAG::ComputeNumSignBits(), llvm::FunctionLoweringInfo::ComputePHILiveOutRegInfo(), EltsFromConsecutiveLoads(), llvm::XCoreSelectionDAGInfo::EmitTargetCodeForMemcpy(), llvm::X86SelectionDAGInfo::EmitTargetCodeForMemset(), EmitVectorComparison(), llvm::TargetLowering::expandFP_TO_SINT(), llvm::TargetLowering::expandMUL(), ExpandUnalignedLoad(), ExpandUnalignedStore(), ExtractSubVector(), FindMemType(), FindOptimalMemOpLowering(), genConstMult(), GeneratePerfectShuffle(), GenerateTBL(), llvm::SelectionDAG::getAnyExtendVectorInReg(), llvm::SelectionDAG::getConstant(), getCopyFromParts(), getCopyFromPartsVector(), getCopyToParts(), getCopyToPartsVector(), getEVTString(), getExtensionTo64Bits(), getExtFactor(), getHalfSizedIntegerVT(), getLeftShift(), llvm::SelectionDAG::getLogicalNOT(), getMemcpyLoadsAndStores(), getMemmoveLoadsAndStores(), getMemsetStores(), getMemsetStringVal(), getMemsetValue(), llvm::SelectionDAG::getNode(), llvm::SelectionDAG::getNOT(), llvm::TargetLoweringBase::getNumRegisters(), llvm::HexagonTargetLowering::getPostIndexedAddressParts(), getRoundIntegerType(), getScalarSizeInBits(), llvm::SDValue::getScalarValueSizeInBits(), llvm::SelectionDAG::getSignExtendVectorInReg(), getStoreSize(), getTargetShuffleMask(), llvm::TargetLoweringBase::getTypeConversion(), getUsefulBits(), llvm::SDValue::getValueSizeInBits(), llvm::SDNode::getValueSizeInBits(), llvm::TargetLoweringBase::getVectorTypeBreakdown(), llvm::SelectionDAG::getZeroExtendInReg(), llvm::SelectionDAG::getZeroExtendVectorInReg(), llvm::AArch64TargetLowering::hasPairedLoad(), InsertSubVector(), isBitfieldDstMask(), isBitfieldExtractOpFromShr(), isBitfieldPositioningOp(), llvm::ISD::isBuildVectorAllOnes(), llvm::ISD::isBuildVectorAllZeros(), isByteSized(), isConcatMask(), isConditionalZeroOrAllOnes(), llvm::SelectionDAG::isConsecutiveLoad(), isConsecutiveLSLoc(), llvm::BuildVectorSDNode::isConstantSplat(), isConstantSplatVector(), isExtendedBUILD_VECTOR(), isI24(), llvm::AMDGPUTargetLowering::isLoadBitCastBeneficial(), isMOVLMask(), IsMulWideOperandDemotable(), llvm::AMDGPUTargetLowering::isNarrowingProfitable(), isREVMask(), isRound(), llvm::AArch64TargetLowering::isShuffleMaskLegal(), llvm::ARMTargetLowering::isShuffleMaskLegal(), isSimpleShift(), llvm::MSP430TargetLowering::isTruncateFree(), llvm::AMDGPUTargetLowering::isTruncateFree(), llvm::SystemZTargetLowering::isTruncateFree(), llvm::AArch64TargetLowering::isTruncateFree(), llvm::PPCTargetLowering::isTruncateFree(), isU24(), isVREVMask(), isVShiftLImm(), isVShiftRImm(), isVTRN_v_undef_Mask(), isVTRNMask(), isVUZP_v_undef_Mask(), isVUZPMask(), isVZIP_v_undef_Mask(), isVZIPMask(), llvm::AArch64TargetLowering::isZExtFree(), llvm::NVPTXTargetLowering::LowerCall(), llvm::TargetLowering::LowerCallTo(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), LowerExtendedLoad(), LowerEXTRACT_VECTOR_ELT(), llvm::SystemZTargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), LowerIntVSETCC_AVX512(), llvm::AMDGPUTargetLowering::LowerLOAD(), lowerMSABitClearImm(), llvm::NVPTXTargetLowering::LowerReturn(), LowerShift(), LowerVAARG(), LowerVECTOR_SHUFFLE(), LowerVectorBroadcast(), LowerVectorFP_TO_INT(), LowerVectorINT_TO_FP(), LowerVSETCC(), MatchingStackOffset(), NormalizeBuildVector(), performANDCombine(), PerformAndCombine(), PerformARMBUILD_VECTORCombine(), performConcatVectorsCombine(), llvm::SystemZTargetLowering::PerformDAGCombine(), llvm::PPCTargetLowering::PerformDAGCombine(), performDSPShiftCombine(), performExtendCombine(), performIntegerAbsCombine(), PerformINTRINSIC_WO_CHAINCombine(), performIntToFpCombine(), PerformLOADCombine(), performNEONPostLDSTCombine(), performORCombine(), PerformOrCombine(), performSelectCombine(), PerformSELECTCombine(), PerformSExtCombine(), performShiftToAllZeros(), PerformSIGN_EXTEND_INREGCombine(), performSRACombine(), performSTORECombine(), PerformSTORECombine(), PerformVDUPLANECombine(), performVectorCompareAndMaskUnaryOpCombine(), performVSelectCombine(), PerformVZEXT_MOVLCombine(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), llvm::R600TargetLowering::ReplaceNodeResults(), resolveBuildVector(), llvm::SelectionDAGISel::SelectCodeCommon(), llvm::FastISel::selectFNeg(), llvm::SelectionDAG::SignBitIsZero(), llvm::TargetLowering::SimplifyDemandedBits(), simplifyI24(), llvm::TargetLowering::SimplifySetCC(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), tryCombineFixedPointConvert(), tryCombineToBSL(), tryCombineToEXTR(), tryFormConcatFromShuffle(), tryLowerToSLI(), TryMULWIDECombine(), tryToFoldExtendOfConstant(), ValueHasExactlyOneBitSet(), VerifySDNode(), llvm::SelectionDAGBuilder::visitBitTestHeader(), widenIntegerVectorElementType(), and WidenMaskArithmetic().

unsigned llvm::EVT::getStoreSize ( ) const [inline]

getStoreSizeInBits - Return the number of bits overwritten by a store of the specified value type.

Definition at line 252 of file ValueTypes.h.

References getStoreSize().

Referenced by llvm::SelectionDAG::CreateStackTemporary(), llvm::AMDGPUTargetLowering::getEquivalentLoadRegType(), llvm::AMDGPUTargetLowering::getEquivalentMemType(), and llvm::NVPTXTargetLowering::LowerCall().

Type * EVT::getTypeForEVT ( LLVMContext Context) const

getTypeForEVT - This method returns an LLVM type corresponding to the specified EVT. For integer types, this returns an unsigned type. Note that this will abort for types that cannot be represented.

Definition at line 180 of file ValueTypes.cpp.

References llvm::MVT::f128, llvm::MVT::f16, llvm::MVT::f32, llvm::MVT::f64, llvm::MVT::f80, llvm::IntegerType::get(), llvm::VectorType::get(), llvm::Type::getDoubleTy(), llvm::Type::getFloatTy(), llvm::Type::getFP128Ty(), llvm::Type::getHalfTy(), llvm::Type::getInt16Ty(), llvm::Type::getInt1Ty(), llvm::Type::getInt32Ty(), llvm::Type::getInt64Ty(), llvm::Type::getInt8Ty(), llvm::Type::getMetadataTy(), llvm::Type::getPPC_FP128Ty(), llvm::Type::getVoidTy(), llvm::Type::getX86_FP80Ty(), llvm::Type::getX86_MMXTy(), llvm::MVT::i1, llvm::MVT::i128, llvm::MVT::i16, llvm::MVT::i32, llvm::MVT::i64, llvm::MVT::i8, isExtended(), llvm::MVT::isVoid, llvm::MVT::Metadata, llvm::MVT::ppcf128, llvm::MVT::SimpleTy, llvm::MVT::v16f32, llvm::MVT::v16i1, llvm::MVT::v16i16, llvm::MVT::v16i32, llvm::MVT::v16i64, llvm::MVT::v16i8, llvm::MVT::v1f32, llvm::MVT::v1f64, llvm::MVT::v1i16, llvm::MVT::v1i32, llvm::MVT::v1i64, llvm::MVT::v1i8, llvm::MVT::v2f16, llvm::MVT::v2f32, llvm::MVT::v2f64, llvm::MVT::v2i1, llvm::MVT::v2i16, llvm::MVT::v2i32, llvm::MVT::v2i64, llvm::MVT::v2i8, llvm::MVT::v32i1, llvm::MVT::v32i16, llvm::MVT::v32i8, llvm::MVT::v4f16, llvm::MVT::v4f32, llvm::MVT::v4f64, llvm::MVT::v4i1, llvm::MVT::v4i16, llvm::MVT::v4i32, llvm::MVT::v4i64, llvm::MVT::v4i8, llvm::MVT::v64i1, llvm::MVT::v64i8, llvm::MVT::v8f16, llvm::MVT::v8f32, llvm::MVT::v8f64, llvm::MVT::v8i1, llvm::MVT::v8i16, llvm::MVT::v8i32, llvm::MVT::v8i64, llvm::MVT::v8i8, and llvm::MVT::x86mmx.

Referenced by canFoldInAddressingMode(), llvm::SelectionDAG::CreateStackTemporary(), llvm::SelectionDAG::getEVTAlignment(), llvm::SelectionDAG::getMemset(), getMemsetStringVal(), llvm::TargetLoweringBase::getValueType(), llvm::NVPTXTargetLowering::LowerCall(), llvm::TargetLowering::LowerCallTo(), llvm::SparcTargetLowering::LowerF128_LibCallArg(), llvm::SparcTargetLowering::LowerF128Op(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), LowerFSINCOS(), llvm::NVPTXTargetLowering::LowerReturn(), llvm::TargetLowering::makeLibCall(), llvm::PPCTargetLowering::PerformDAGCombine(), ReplaceLoadVector(), and XFormVExtractWithShuffleIntoLoad().

getVectorElementType - Given a vector type, return the type of each element.

Definition at line 217 of file ValueTypes.h.

References llvm::MVT::getVectorElementType(), isSimple(), and isVector().

Referenced by AddCombineToVPADDL(), ComputePTXValueVTs(), EltsFromConsecutiveLoads(), EmitVectorComparison(), ExtractSubVector(), llvm::SelectionDAG::ExtractVectorElements(), FindMemType(), GeneratePerfectShuffle(), GenerateTBL(), getCopyFromPartsVector(), getCopyToPartsVector(), getEVTString(), getExtFactor(), getMemsetStringVal(), llvm::SelectionDAG::getNode(), getPow2VectorType(), getScalarType(), getShuffleScalarElt(), llvm::SelectionDAG::GetSplitDestVTs(), getTargetShuffleMask(), llvm::TargetLoweringBase::getTypeConversion(), llvm::TargetLoweringBase::getVectorTypeBreakdown(), InsertSubVector(), llvm::ISD::isBuildVectorAllOnes(), llvm::ISD::isBuildVectorAllZeros(), llvm::BuildVectorSDNode::isConstantSplat(), isConstantSplatVector(), isExtendedBUILD_VECTOR(), isMOVLMask(), isREVMask(), llvm::ARMTargetLowering::isShuffleMaskLegal(), isVREVMask(), isVShiftLImm(), isVShiftRImm(), isVTRN_v_undef_Mask(), isVTRNMask(), isVUZP_v_undef_Mask(), isVUZPMask(), isVZIP_v_undef_Mask(), isVZIPMask(), llvm::NVPTXTargetLowering::LowerCall(), LowerCTPOP(), LowerExtendedLoad(), LowerEXTRACT_VECTOR_ELT(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::NVPTXTargetLowering::LowerFormalArguments(), LowerIntVSETCC_AVX512(), lowerMSABitClearImm(), lowerMSACopyIntr(), llvm::NVPTXTargetLowering::LowerReturn(), LowerVECTOR_SHUFFLE(), lowerVECTOR_SHUFFLE_VSHF(), LowerVectorFP_TO_INT(), LowerVectorINT_TO_FP(), LowerVSETCC(), NarrowVector(), NormalizeBuildVector(), WidenVector::operator()(), PerformARMBUILD_VECTORCombine(), PerformBUILD_VECTORCombine(), performConcatVectorsCombine(), performDSPShiftCombine(), performExtendCombine(), PerformInsertEltCombine(), PerformINTRINSIC_WO_CHAINCombine(), PerformOrCombine(), performPostLD1Combine(), PerformSELECTCombine(), performShiftToAllZeros(), PerformShuffleCombine(), performSTORECombine(), PerformSTORECombine(), PerformVDUPLANECombine(), performVSelectCombine(), PerformVZEXT_MOVLCombine(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), llvm::AMDGPUTargetLowering::ScalarizeVectorLoad(), llvm::AMDGPUTargetLowering::ScalarizeVectorStore(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), tryCombineToBSL(), tryFormConcatFromShuffle(), tryLowerToSLI(), llvm::SelectionDAG::UnrollVectorOp(), VerifySDNode(), widenIntegerVectorElementType(), and WidenVector().

getVectorNumElements - Given a vector type, return the number of elements it contains.

Definition at line 226 of file ValueTypes.h.

References llvm::MVT::getVectorNumElements(), isSimple(), and isVector().

Referenced by AddCombineToVPADDL(), AddNodeIDCustom(), BuildSplatI(), changeVectorElementTypeToInteger(), CombineBaseUpdate(), ComputePTXValueVTs(), ConvertSelectToConcatVector(), ExpandBITCAST(), ExpandHorizontalBinOp(), ExtractSubVector(), llvm::SelectionDAG::ExtractVectorElements(), llvm::SelectionDAG::FoldConstantArithmetic(), llvm::SelectionDAG::getAnyExtendVectorInReg(), getBuildVectorSplat(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getConstantFP(), getCopyFromPartsVector(), getCopyToPartsVector(), getEVTString(), llvm::SelectionDAG::getLoad(), llvm::ShuffleVectorSDNode::getMask(), getMemsetStringVal(), getMOVL(), llvm::SelectionDAG::getNode(), getPow2VectorType(), llvm::SITargetLowering::getPreferredVectorAction(), llvm::TargetLoweringBase::getPreferredVectorAction(), llvm::NVPTXTargetLowering::getPreferredVectorAction(), llvm::SITargetLowering::getSetCCResultType(), llvm::HexagonTargetLowering::getSetCCResultType(), llvm::NVPTXTargetLowering::getSetCCResultType(), getShuffleScalarElt(), llvm::SelectionDAG::getSignExtendVectorInReg(), llvm::ShuffleVectorSDNode::getSplatIndex(), llvm::SelectionDAG::GetSplitDestVTs(), llvm::SelectionDAG::getTruncStore(), llvm::TargetLoweringBase::getTypeConversion(), getVectorMaskingNode(), llvm::SelectionDAG::getVectorShuffle(), llvm::TargetLoweringBase::getVectorTypeBreakdown(), llvm::SelectionDAG::getZeroExtendVectorInReg(), getZeroVector(), hasNormalLoadOperand(), isAllConstantBuildVector(), isConcatMask(), isConstVecPow2(), isEXTMask(), isHorizontalBinOp(), isMOVLMask(), isPow2VectorType(), isReverseMask(), isREVMask(), isShuffleHigh128VectorInsertLow(), isShuffleLow128VectorInsertHigh(), llvm::AArch64TargetLowering::isShuffleMaskLegal(), llvm::ARMTargetLowering::isShuffleMaskLegal(), isSingletonEXTMask(), isSingletonVEXTMask(), llvm::ShuffleVectorSDNode::isSplatMask(), isTRN_v_undef_Mask(), isTRNMask(), isUZP_v_undef_Mask(), isUZPMask(), isVEXTMask(), isVREVMask(), isVTRN_v_undef_Mask(), isVTRNMask(), isVUZP_v_undef_Mask(), isVUZPMask(), isVZIP_v_undef_Mask(), isVZIPMask(), isZeroShuffle(), isZIP_v_undef_Mask(), isZIPMask(), llvm::NVPTXTargetLowering::LowerCall(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), llvm::NVPTXTargetLowering::LowerFormalArguments(), lowerMSASplatZExt(), llvm::NVPTXTargetLowering::LowerReturn(), LowerScalarVariableShift(), LowerVECTOR_SHUFFLE(), lowerVECTOR_SHUFFLE_ILVEV(), lowerVECTOR_SHUFFLE_ILVL(), lowerVECTOR_SHUFFLE_ILVOD(), lowerVECTOR_SHUFFLE_ILVR(), lowerVECTOR_SHUFFLE_VSHF(), LowerVectorAllZeroTest(), LowerVectorFP_TO_INT(), LowerVectorINT_TO_FP(), matchAddSub(), NarrowVector(), NormalizeBuildVector(), WidenVector::operator()(), partitionShuffleOfConcats(), PerformARMBUILD_VECTORCombine(), performBitcastCombine(), PerformBUILD_VECTORCombine(), performConcatVectorsCombine(), llvm::R600TargetLowering::PerformDAGCombine(), llvm::PPCTargetLowering::PerformDAGCombine(), performExtendCombine(), PerformInsertEltCombine(), performNEONPostLDSTCombine(), PerformSELECTCombine(), PerformShuffleCombine(), PerformShuffleCombine256(), performSTORECombine(), PerformSTORECombine(), PerformVCVTCombine(), PerformVDIVCombine(), PerformVECTOR_SHUFFLECombine(), performVSelectCombine(), llvm::AArch64TargetLowering::ReconstructShuffle(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), replaceSplatVectorStore(), llvm::AMDGPUTargetLowering::ScalarizeVectorLoad(), llvm::AMDGPUTargetLowering::ScalarizeVectorStore(), llvm::SelectionDAG::SplitVector(), llvm::AMDGPUTargetLowering::SplitVectorLoad(), llvm::AMDGPUTargetLowering::SplitVectorStore(), tryCombineToBSL(), tryFormConcatFromShuffle(), VerifySDNode(), widenIntegerVectorElementType(), WidenMaskArithmetic(), WidenVector(), and XFormVExtractWithShuffleIntoLoad().

static EVT llvm::EVT::getVectorVT ( LLVMContext Context,
EVT  VT,
unsigned  NumElements 
) [inline, static]
bool llvm::EVT::is1024BitVector ( ) const [inline]

is1024BitVector - Return true if this is a 1024-bit vector type.

Definition at line 151 of file ValueTypes.h.

References llvm::MVT::is1024BitVector(), and isSimple().

bool llvm::EVT::is128BitVector ( ) const [inline]
bool llvm::EVT::is16BitVector ( ) const [inline]

is16BitVector - Return true if this is a 16-bit vector type.

Definition at line 121 of file ValueTypes.h.

References llvm::MVT::is16BitVector(), and isSimple().

bool llvm::EVT::is256BitVector ( ) const [inline]
bool llvm::EVT::is32BitVector ( ) const [inline]

is32BitVector - Return true if this is a 32-bit vector type.

Definition at line 126 of file ValueTypes.h.

References llvm::MVT::is32BitVector(), and isSimple().

bool llvm::EVT::is512BitVector ( ) const [inline]

is512BitVector - Return true if this is a 512-bit vector type.

Definition at line 146 of file ValueTypes.h.

References llvm::MVT::is512BitVector(), and isSimple().

Referenced by Extract128BitVector(), Extract256BitVector(), getZeroVector(), and LowerVSETCC().

bool llvm::EVT::is64BitVector ( ) const [inline]
bool llvm::EVT::isByteSized ( ) const [inline]

isByteSized - Return true if the bit size is a multiple of 8.

Definition at line 161 of file ValueTypes.h.

References getSizeInBits().

bool llvm::EVT::isExtended ( ) const [inline]

isExtended - Test if the given EVT is extended (as opposed to being simple).

Definition at line 101 of file ValueTypes.h.

References isSimple().

Referenced by llvm::TargetLoweringBase::getLoadExtAction(), llvm::TargetLoweringBase::getOperationAction(), llvm::TargetLoweringBase::getTruncStoreAction(), getTypeForEVT(), and llvm::SelectionDAG::getValueType().

bool llvm::EVT::isFloatingPoint ( ) const [inline]
bool llvm::EVT::isInteger ( ) const [inline]

isInteger - Return true if this is an integer, or a vector integer type.

Definition at line 111 of file ValueTypes.h.

References llvm::MVT::isInteger(), and isSimple().

Referenced by AddCombineToVPADDL(), llvm::SelectionDAG::ComputeNumSignBits(), ExpandUnalignedLoad(), ExpandUnalignedStore(), llvm::SelectionDAG::FoldSetCC(), llvm::SelectionDAG::getConstant(), getCopyFromParts(), getCopyToParts(), getEVTString(), getHalfSizedIntegerVT(), llvm::SelectionDAG::getLoad(), getMemcpyLoadsAndStores(), getMemsetStringVal(), getMemsetValue(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getNumRegisters(), llvm::TargetLoweringBase::getRegisterType(), llvm::GetReturnInfo(), getRoundIntegerType(), llvm::TargetLoweringBase::getShiftAmountTy(), getTargetShuffleMask(), llvm::SelectionDAG::getTruncStore(), llvm::TargetLoweringBase::getTypeConversion(), llvm::AArch64TargetLowering::hasPairedLoad(), llvm::MSP430TargetLowering::isTruncateFree(), llvm::SystemZTargetLowering::isTruncateFree(), llvm::AArch64TargetLowering::isTruncateFree(), llvm::PPCTargetLowering::isTruncateFree(), llvm::XCoreTargetLowering::isZExtFree(), llvm::ARMTargetLowering::isZExtFree(), llvm::AArch64TargetLowering::isZExtFree(), LowerBR_CC(), llvm::NVPTXTargetLowering::LowerCall(), LowerMUL(), LowerSELECT_CC(), LowerVectorBroadcast(), llvm::TargetLowering::LowerXConstraint(), OptimizeConditionalInDecrement(), OptimizeNoopCopyExpression(), PerformADDCombineWithOperands(), llvm::R600TargetLowering::PerformDAGCombine(), performIntegerAbsCombine(), performSELECTCombine(), PerformSELECTCombine(), performVSELECTCombine(), performXORCombine(), llvm::TargetLowering::SimplifySetCC(), and VerifySDNode().

bool llvm::EVT::isOverloaded ( ) const [inline]

isOverloaded - Return true if this is an overloaded type for TableGen.

Definition at line 156 of file ValueTypes.h.

References llvm::MVT::fAny, llvm::MVT::iAny, llvm::MVT::iPTRAny, and llvm::MVT::vAny.

bool llvm::EVT::isPow2VectorType ( ) const [inline]

isPow2VectorType - Returns true if the given vector is a power of 2.

Definition at line 292 of file ValueTypes.h.

References getVectorNumElements().

Referenced by getPow2VectorType(), and llvm::TargetLoweringBase::getTypeConversion().

bool llvm::EVT::isRound ( ) const [inline]

isRound - Return true if the size is a power-of-two number of bytes.

Definition at line 166 of file ValueTypes.h.

References getSizeInBits().

Referenced by llvm::TargetLowering::SimplifySetCC().

bool llvm::EVT::isSimple ( ) const [inline]

isSimple - Test if the given EVT is simple (as opposed to being extended).

Definition at line 95 of file ValueTypes.h.

References llvm::MVT::SimpleTy.

Referenced by llvm::SITargetLowering::allowsMisalignedMemoryAccesses(), llvm::PPCTargetLowering::allowsMisalignedMemoryAccesses(), changeVectorElementTypeToInteger(), getExtensionTo64Bits(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getNumRegisters(), getRawBits(), llvm::FastISel::getRegForValue(), llvm::TargetLoweringBase::getRegisterType(), getSimpleVT(), getSizeInBits(), llvm::TargetLoweringBase::getTypeConversion(), llvm::SelectionDAG::getValueType(), getVectorElementType(), getVectorMaskingNode(), getVectorNumElements(), llvm::AArch64TargetLowering::hasPairedLoad(), is1024BitVector(), is128BitVector(), is16BitVector(), is256BitVector(), is32BitVector(), is512BitVector(), is64BitVector(), isExtended(), isFloatingPoint(), llvm::SITargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::SystemZTargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::AArch64TargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::PPCTargetLowering::isFMAFasterThanFMulAndFAdd(), llvm::TargetLoweringBase::isIndexedLoadLegal(), llvm::TargetLoweringBase::isIndexedStoreLegal(), isInteger(), isLegalAddressImmediate(), llvm::ARMTargetLowering::isLegalAddressingMode(), llvm::TargetLoweringBase::isLoadExtLegal(), llvm::HexagonTargetLowering::isTruncateFree(), llvm::TargetLoweringBase::isTruncStoreLegal(), llvm::TargetLoweringBase::isTypeLegal(), isVector(), llvm::XCoreTargetLowering::isZExtFree(), llvm::ARMTargetLowering::isZExtFree(), llvm::AArch64TargetLowering::isZExtFree(), performExtendCombine(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), llvm::FastISel::selectBinaryOp(), llvm::FastISel::selectCast(), llvm::FastISel::selectExtractValue(), and llvm::TargetLowering::SimplifyDemandedBits().

bool llvm::EVT::isVector ( ) const [inline]

isVector - Return true if this is a vector value type.

Definition at line 116 of file ValueTypes.h.

References isSimple(), and llvm::MVT::isVector().

Referenced by llvm::SelectionDAG::computeKnownBits(), llvm::SelectionDAG::ComputeNumSignBits(), ComputePTXValueVTs(), ExpandBITCAST(), ExpandUnalignedLoad(), ExpandUnalignedStore(), FindOptimalMemOpLowering(), llvm::SelectionDAG::FoldConstantArithmetic(), FoldOperand(), llvm::SelectionDAG::getAnyExtendVectorInReg(), llvm::TargetLoweringBase::getBooleanContents(), llvm::SelectionDAG::getConstant(), llvm::SelectionDAG::getConstantFP(), getCopyFromParts(), getCopyFromPartsVector(), getCopyToParts(), getCopyToPartsVector(), getEVTString(), getHalfSizedIntegerVT(), llvm::SelectionDAG::getLoad(), getMemcpyLoadsAndStores(), getMemsetStores(), getMemsetStringVal(), llvm::SelectionDAG::getNode(), llvm::TargetLoweringBase::getNumRegisters(), llvm::AMDGPUTargetLowering::getOriginalFunctionArgs(), llvm::PPCTargetLowering::getPreIndexedAddressParts(), llvm::TargetLoweringBase::getRegisterType(), getRoundIntegerType(), getScalarType(), llvm::ARMTargetLowering::getSchedulingPreference(), llvm::SelectionDAG::getSelect(), llvm::SelectionDAG::getSetCC(), llvm::R600TargetLowering::getSetCCResultType(), llvm::SparcTargetLowering::getSetCCResultType(), llvm::SITargetLowering::getSetCCResultType(), llvm::HexagonTargetLowering::getSetCCResultType(), llvm::SystemZTargetLowering::getSetCCResultType(), llvm::MipsTargetLowering::getSetCCResultType(), llvm::ARMTargetLowering::getSetCCResultType(), llvm::AArch64TargetLowering::getSetCCResultType(), llvm::TargetLoweringBase::getSetCCResultType(), llvm::PPCTargetLowering::getSetCCResultType(), llvm::NVPTXTargetLowering::getSetCCResultType(), llvm::SelectionDAG::getShiftAmountOperand(), llvm::TargetLoweringBase::getShiftAmountTy(), getShuffleScalarElt(), llvm::SelectionDAG::getSignExtendVectorInReg(), llvm::SelectionDAG::GetSplitDestVTs(), getTargetShuffleMask(), llvm::SelectionDAG::getTruncStore(), llvm::TargetLoweringBase::getTypeConversion(), llvm::TargetLoweringBase::getTypeToExpandTo(), getVectorElementType(), getVectorNumElements(), llvm::SelectionDAG::getZeroExtendInReg(), llvm::SelectionDAG::getZeroExtendVectorInReg(), getZeroVector(), llvm::BuildVectorSDNode::isConstantSplat(), isHorizontalBinOp(), llvm::AArch64TargetLowering::isTruncateFree(), isVShiftLImm(), isVShiftRImm(), llvm::AArch64TargetLowering::isZExtFree(), llvm::TargetLowering::LowerCallTo(), llvm::AMDGPUTargetLowering::LowerDIVREM24(), LowerExtendedLoad(), llvm::R600TargetLowering::LowerFormalArguments(), llvm::AMDGPUTargetLowering::LowerLOAD(), llvm::NVPTXTargetLowering::LowerReturn(), LowerShift(), llvm::AMDGPUTargetLowering::LowerSTORE(), LowerVectorBroadcast(), matchIntegerMINMAX(), PerformADDCombineWithOperands(), performBitcastCombine(), llvm::AMDGPUTargetLowering::PerformDAGCombine(), llvm::PPCTargetLowering::PerformDAGCombine(), performExtendCombine(), PerformINTRINSIC_WO_CHAINCombine(), performMULCombine(), PerformORCombine(), performSelectCombine(), PerformSELECTCombine(), PerformSExtCombine(), PerformSHLCombine(), PerformShuffleCombine(), PerformSIGN_EXTEND_INREGCombine(), PerformSINT_TO_FPCombine(), performSTORECombine(), PerformSTORECombine(), PerformVCVTCombine(), PerformVDIVCombine(), performVectorCompareAndMaskUnaryOpCombine(), ReplaceINTRINSIC_W_CHAIN(), ReplaceLoadVector(), llvm::TargetLowering::TargetLoweringOpt::ShrinkDemandedOp(), llvm::SelectionDAG::SignBitIsZero(), llvm::TargetLowering::SimplifyDemandedBits(), tryCombineToBSL(), tryFoldToZero(), tryLowerToSLI(), tryToFoldExtendOfConstant(), llvm::SelectionDAG::UnrollVectorOp(), and VerifySDNode().

bool llvm::EVT::operator!= ( EVT  VT) const [inline]

Definition at line 45 of file ValueTypes.h.

References llvm::MVT::SimpleTy.

bool llvm::EVT::operator== ( EVT  VT) const [inline]

Definition at line 42 of file ValueTypes.h.

Return a VT for an integer vector type with the size of the elements doubled. The typed returned may be an extended type.

Definition at line 285 of file ValueTypes.h.

References getIntegerVT(), getSizeInBits(), getVectorElementType(), getVectorNumElements(), and getVectorVT().


The documentation for this struct was generated from the following files: