class MVT
Declaration
class MVT { /* full declaration omitted */ };
Description
Machine Value Type. Every type that is supported natively by some processor targeted by LLVM occurs here. This means that any legal value type can be represented by an MVT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:31
Member Variables
- public llvm::MVT::SimpleValueType SimpleTy = INVALID_SIMPLE_VALUE_TYPE
Method Overview
- public constexpr MVT(llvm::MVT::SimpleValueType SVT)
- public MVT()
- public static iota_range<llvm::MVT::SimpleValueType> all_valuetypes()
- public bool bitsGE(llvm::MVT VT) const
- public bool bitsGT(llvm::MVT VT) const
- public bool bitsLE(llvm::MVT VT) const
- public bool bitsLT(llvm::MVT VT) const
- public llvm::MVT changeTypeToInteger()
- public llvm::MVT changeVectorElementType(llvm::MVT EltVT) const
- public llvm::MVT changeVectorElementTypeToInteger() const
- public static iota_range<llvm::MVT::SimpleValueType> fixedlen_vector_valuetypes()
- public static iota_range<llvm::MVT::SimpleValueType> fp_fixedlen_vector_valuetypes()
- public static iota_range<llvm::MVT::SimpleValueType> fp_scalable_vector_valuetypes()
- public static iota_range<llvm::MVT::SimpleValueType> fp_valuetypes()
- public uint64_t getFixedSizeInBits() const
- public static llvm::MVT getFloatingPointVT(unsigned int BitWidth)
- public llvm::MVT getHalfNumVectorElementsVT() const
- public static llvm::MVT getIntegerVT(unsigned int BitWidth)
- public llvm::MVT getPow2VectorType() const
- public static llvm::MVT getScalableVectorVT(llvm::MVT VT, unsigned int NumElements)
- public uint64_t getScalarSizeInBits() const
- public uint64_t getScalarStoreSize() const
- public llvm::MVT getScalarType() const
- public llvm::TypeSize getSizeInBits() const
- public llvm::TypeSize getStoreSize() const
- public llvm::TypeSize getStoreSizeInBits() const
- public static llvm::MVT getVT(llvm::Type * Ty, bool HandleUnknown = false)
- public llvm::ElementCount getVectorElementCount() const
- public llvm::MVT getVectorElementType() const
- public unsigned int getVectorMinNumElements() const
- public unsigned int getVectorNumElements() const
- public static llvm::MVT getVectorVT(llvm::MVT VT, unsigned int NumElements)
- public static llvm::MVT getVectorVT(llvm::MVT VT, unsigned int NumElements, bool IsScalable)
- public static llvm::MVT getVectorVT(llvm::MVT VT, llvm::ElementCount EC)
- public static iota_range<llvm::MVT::SimpleValueType> integer_fixedlen_vector_valuetypes()
- public static iota_range<llvm::MVT::SimpleValueType> integer_scalable_vector_valuetypes()
- public static iota_range<llvm::MVT::SimpleValueType> integer_valuetypes()
- public bool is1024BitVector() const
- public bool is128BitVector() const
- public bool is16BitVector() const
- public bool is2048BitVector() const
- public bool is256BitVector() const
- public bool is32BitVector() const
- public bool is512BitVector() const
- public bool is64BitVector() const
- public bool isByteSized() const
- public bool isFixedLengthVector() const
- public bool isFloatingPoint() const
- public bool isInteger() const
- public bool isOverloaded() const
- public bool isPow2VectorType() const
- public bool isScalableVector() const
- public bool isScalarInteger() const
- public bool isValid() const
- public bool isVector() const
- public bool knownBitsGE(llvm::MVT VT) const
- public bool knownBitsGT(llvm::MVT VT) const
- public bool knownBitsLE(llvm::MVT VT) const
- public bool knownBitsLT(llvm::MVT VT) const
- public static iota_range<llvm::MVT::SimpleValueType> scalable_vector_valuetypes()
- public static iota_range<llvm::MVT::SimpleValueType> vector_valuetypes()
Methods
¶constexpr MVT(llvm::MVT::SimpleValueType SVT)
constexpr MVT(llvm::MVT::SimpleValueType SVT)
Declared at: llvm/include/llvm/Support/MachineValueType.h:332
Parameters
- llvm::MVT::SimpleValueType SVT
¶MVT()
MVT()
Declared at: llvm/include/llvm/Support/MachineValueType.h:331
¶static iota_range<llvm::MVT::SimpleValueType>
all_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
all_valuetypes()
Description
SimpleValueType Iteration @ {
Declared at: llvm/include/llvm/Support/MachineValueType.h:1456
¶bool bitsGE(llvm::MVT VT) const
bool bitsGE(llvm::MVT VT) const
Description
Return true if this has no less bits than VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1156
Parameters
- llvm::MVT VT
¶bool bitsGT(llvm::MVT VT) const
bool bitsGT(llvm::MVT VT) const
Description
Return true if this has more bits than VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1149
Parameters
- llvm::MVT VT
¶bool bitsLE(llvm::MVT VT) const
bool bitsLE(llvm::MVT VT) const
Description
Return true if this has no more bits than VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1170
Parameters
- llvm::MVT VT
¶bool bitsLT(llvm::MVT VT) const
bool bitsLT(llvm::MVT VT) const
Description
Return true if this has less bits than VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1163
Parameters
- llvm::MVT VT
¶llvm::MVT changeTypeToInteger()
llvm::MVT changeTypeToInteger()
Description
Return the type converted to an equivalently sized integer or vector with integer element type. Similar to changeVectorElementTypeToInteger, but also handles scalars.
Declared at: llvm/include/llvm/Support/MachineValueType.h:490
¶llvm::MVT changeVectorElementType(
llvm::MVT EltVT) const
llvm::MVT changeVectorElementType(
llvm::MVT EltVT) const
Description
Return a VT for a vector type whose attributes match ourselves with the exception of the element type that is chosen by the caller.
Declared at: llvm/include/llvm/Support/MachineValueType.h:480
Parameters
- llvm::MVT EltVT
¶llvm::MVT changeVectorElementTypeToInteger() const
llvm::MVT changeVectorElementTypeToInteger() const
Description
Return a vector with the same number of elements as this vector, but with the element type converted to an integer type with the same bitwidth.
Declared at: llvm/include/llvm/Support/MachineValueType.h:469
¶static iota_range<llvm::MVT::SimpleValueType>
fixedlen_vector_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
fixedlen_vector_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1478
¶static iota_range<llvm::MVT::SimpleValueType>
fp_fixedlen_vector_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
fp_fixedlen_vector_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1496
¶static iota_range<llvm::MVT::SimpleValueType>
fp_scalable_vector_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
fp_scalable_vector_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1508
¶static iota_range<llvm::MVT::SimpleValueType>
fp_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
fp_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1467
¶uint64_t getFixedSizeInBits() const
uint64_t getFixedSizeInBits() const
Description
Return the size of the specified fixed width value type in bits. The function will assert if the type is scalable.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1087
¶static llvm::MVT getFloatingPointVT(
unsigned int BitWidth)
static llvm::MVT getFloatingPointVT(
unsigned int BitWidth)
Declared at: llvm/include/llvm/Support/MachineValueType.h:1176
Parameters
- unsigned int BitWidth
¶llvm::MVT getHalfNumVectorElementsVT() const
llvm::MVT getHalfNumVectorElementsVT() const
Description
Return a VT for a vector type with the same element type but half the number of elements.
Declared at: llvm/include/llvm/Support/MachineValueType.h:498
¶static llvm::MVT getIntegerVT(
unsigned int BitWidth)
static llvm::MVT getIntegerVT(
unsigned int BitWidth)
Declared at: llvm/include/llvm/Support/MachineValueType.h:1193
Parameters
- unsigned int BitWidth
¶llvm::MVT getPow2VectorType() const
llvm::MVT getPow2VectorType() const
Description
Widens the length of the given vector MVT up to the nearest power of 2 and returns that type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:513
¶static llvm::MVT getScalableVectorVT(
llvm::MVT VT,
unsigned int NumElements)
static llvm::MVT getScalableVectorVT(
llvm::MVT VT,
unsigned int NumElements)
Declared at: llvm/include/llvm/Support/MachineValueType.h:1357
Parameters
- llvm::MVT VT
- unsigned int NumElements
¶uint64_t getScalarSizeInBits() const
uint64_t getScalarSizeInBits() const
Declared at: llvm/include/llvm/Support/MachineValueType.h:1091
¶uint64_t getScalarStoreSize() const
uint64_t getScalarStoreSize() const
Declared at: llvm/include/llvm/Support/MachineValueType.h:1108
¶llvm::MVT getScalarType() const
llvm::MVT getScalarType() const
Description
If this is a vector, return the element type, otherwise return this.
Declared at: llvm/include/llvm/Support/MachineValueType.h:524
¶llvm::TypeSize getSizeInBits() const
llvm::TypeSize getSizeInBits() const
Description
Returns the size of the specified MVT in bits. If the value type is a scalable vector type, the scalable property will be set and the runtime size will be a positive integer multiple of the base size.
Declared at: llvm/include/llvm/Support/MachineValueType.h:883
¶llvm::TypeSize getStoreSize() const
llvm::TypeSize getStoreSize() const
Description
Return the number of bytes overwritten by a store of the specified value type. If the value type is a scalable vector type, the scalable property will be set and the runtime size will be a positive integer multiple of the base size.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1101
¶llvm::TypeSize getStoreSizeInBits() const
llvm::TypeSize getStoreSizeInBits() const
Description
Return the number of bits overwritten by a store of the specified value type. If the value type is a scalable vector type, the scalable property will be set and the runtime size will be a positive integer multiple of the base size.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1118
¶static llvm::MVT getVT(llvm::Type* Ty,
bool HandleUnknown = false)
static llvm::MVT getVT(llvm::Type* Ty,
bool HandleUnknown = false)
Description
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.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1451
Parameters
- llvm::Type* Ty
- bool HandleUnknown = false
¶llvm::ElementCount getVectorElementCount() const
llvm::ElementCount getVectorElementCount() const
Declared at: llvm/include/llvm/Support/MachineValueType.h:865
¶llvm::MVT getVectorElementType() const
llvm::MVT getVectorElementType() const
Declared at: llvm/include/llvm/Support/MachineValueType.h:528
¶unsigned int getVectorMinNumElements() const
unsigned int getVectorMinNumElements() const
Description
Given a vector type, return the minimum number of elements it contains.
Declared at: llvm/include/llvm/Support/MachineValueType.h:698
¶unsigned int getVectorNumElements() const
unsigned int getVectorNumElements() const
Declared at: llvm/include/llvm/Support/MachineValueType.h:869
¶static llvm::MVT getVectorVT(
llvm::MVT VT,
unsigned int NumElements)
static llvm::MVT getVectorVT(
llvm::MVT VT,
unsigned int NumElements)
Declared at: llvm/include/llvm/Support/MachineValueType.h:1216
Parameters
- llvm::MVT VT
- unsigned int NumElements
¶static llvm::MVT getVectorVT(
llvm::MVT VT,
unsigned int NumElements,
bool IsScalable)
static llvm::MVT getVectorVT(
llvm::MVT VT,
unsigned int NumElements,
bool IsScalable)
Declared at: llvm/include/llvm/Support/MachineValueType.h:1436
Parameters
- llvm::MVT VT
- unsigned int NumElements
- bool IsScalable
¶static llvm::MVT getVectorVT(
llvm::MVT VT,
llvm::ElementCount EC)
static llvm::MVT getVectorVT(
llvm::MVT VT,
llvm::ElementCount EC)
Declared at: llvm/include/llvm/Support/MachineValueType.h:1442
Parameters
¶static iota_range<llvm::MVT::SimpleValueType>
integer_fixedlen_vector_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
integer_fixedlen_vector_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1490
¶static iota_range<llvm::MVT::SimpleValueType>
integer_scalable_vector_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
integer_scalable_vector_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1502
¶static iota_range<llvm::MVT::SimpleValueType>
integer_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
integer_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1461
¶bool is1024BitVector() const
bool is1024BitVector() const
Description
Return true if this is a 1024-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:443
¶bool is128BitVector() const
bool is128BitVector() const
Description
Return true if this is a 128-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:415
¶bool is16BitVector() const
bool is16BitVector() const
Description
Return true if this is a 16-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:392
¶bool is2048BitVector() const
bool is2048BitVector() const
Description
Return true if this is a 2048-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:452
¶bool is256BitVector() const
bool is256BitVector() const
Description
Return true if this is a 256-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:424
¶bool is32BitVector() const
bool is32BitVector() const
Description
Return true if this is a 32-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:398
¶bool is512BitVector() const
bool is512BitVector() const
Description
Return true if this is a 512-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:434
¶bool is64BitVector() const
bool is64BitVector() const
Description
Return true if this is a 64-bit vector type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:406
¶bool isByteSized() const
bool isByteSized() const
Description
Returns true if the number of bits for the type is a multiple of an 8-bit byte.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1124
¶bool isFixedLengthVector() const
bool isFixedLengthVector() const
Declared at: llvm/include/llvm/Support/MachineValueType.h:386
¶bool isFloatingPoint() const
bool isFloatingPoint() const
Description
Return true if this is a FP or a vector FP type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:348
¶bool isInteger() const
bool isInteger() const
Description
Return true if this is an integer or a vector integer type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:358
¶bool isOverloaded() const
bool isOverloaded() const
Description
Return true if this is an overloaded type for TableGen.
Declared at: llvm/include/llvm/Support/MachineValueType.h:460
¶bool isPow2VectorType() const
bool isPow2VectorType() const
Description
Returns true if the given vector is a power of 2.
Declared at: llvm/include/llvm/Support/MachineValueType.h:506
¶bool isScalableVector() const
bool isScalableVector() const
Description
Return true if this is a vector value type where the runtime length is machine dependent
Declared at: llvm/include/llvm/Support/MachineValueType.h:381
¶bool isScalarInteger() const
bool isScalarInteger() const
Description
Return true if this is an integer, not including vectors.
Declared at: llvm/include/llvm/Support/MachineValueType.h:368
¶bool isValid() const
bool isValid() const
Description
Return true if this is a valid simple valuetype.
Declared at: llvm/include/llvm/Support/MachineValueType.h:342
¶bool isVector() const
bool isVector() const
Description
Return true if this is a vector value type.
Declared at: llvm/include/llvm/Support/MachineValueType.h:374
¶bool knownBitsGE(llvm::MVT VT) const
bool knownBitsGE(llvm::MVT VT) const
Description
Return true if we know at compile time this has more than or the same bits as VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1133
Parameters
- llvm::MVT VT
¶bool knownBitsGT(llvm::MVT VT) const
bool knownBitsGT(llvm::MVT VT) const
Description
Return true if we know at compile time this has more bits than VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1127
Parameters
- llvm::MVT VT
¶bool knownBitsLE(llvm::MVT VT) const
bool knownBitsLE(llvm::MVT VT) const
Description
Return true if we know at compile time this has fewer than or the same bits as VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1144
Parameters
- llvm::MVT VT
¶bool knownBitsLT(llvm::MVT VT) const
bool knownBitsLT(llvm::MVT VT) const
Description
Return true if we know at compile time this has fewer bits than VT.
Declared at: llvm/include/llvm/Support/MachineValueType.h:1138
Parameters
- llvm::MVT VT
¶static iota_range<llvm::MVT::SimpleValueType>
scalable_vector_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
scalable_vector_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1484
¶static iota_range<llvm::MVT::SimpleValueType>
vector_valuetypes()
static iota_range<llvm::MVT::SimpleValueType>
vector_valuetypes()
Declared at: llvm/include/llvm/Support/MachineValueType.h:1472