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

Methods

constexpr MVT(llvm::MVT::SimpleValueType SVT)

Declared at: llvm/include/llvm/Support/MachineValueType.h:332

Parameters

llvm::MVT::SimpleValueType SVT

MVT()

Declared at: llvm/include/llvm/Support/MachineValueType.h:331

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

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

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

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

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()

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

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

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()

Declared at: llvm/include/llvm/Support/MachineValueType.h:1478

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()

Declared at: llvm/include/llvm/Support/MachineValueType.h:1508

static iota_range<llvm::MVT::SimpleValueType>
fp_valuetypes()

Declared at: llvm/include/llvm/Support/MachineValueType.h:1467

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)

Declared at: llvm/include/llvm/Support/MachineValueType.h:1176

Parameters

unsigned int BitWidth

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)

Declared at: llvm/include/llvm/Support/MachineValueType.h:1193

Parameters

unsigned int BitWidth

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)

Declared at: llvm/include/llvm/Support/MachineValueType.h:1357

Parameters

llvm::MVT VT
unsigned int NumElements

uint64_t getScalarSizeInBits() const

Declared at: llvm/include/llvm/Support/MachineValueType.h:1091

uint64_t getScalarStoreSize() const

Declared at: llvm/include/llvm/Support/MachineValueType.h:1108

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

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

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

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)

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

Declared at: llvm/include/llvm/Support/MachineValueType.h:865

llvm::MVT getVectorElementType() const

Declared at: llvm/include/llvm/Support/MachineValueType.h:528

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

Declared at: llvm/include/llvm/Support/MachineValueType.h:869

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)

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)

Declared at: llvm/include/llvm/Support/MachineValueType.h:1442

Parameters

llvm::MVT VT
llvm::ElementCount EC

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()

Declared at: llvm/include/llvm/Support/MachineValueType.h:1502

static iota_range<llvm::MVT::SimpleValueType>
integer_valuetypes()

Declared at: llvm/include/llvm/Support/MachineValueType.h:1461

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

Description

Return true if this is a 128-bit vector type.

Declared at: llvm/include/llvm/Support/MachineValueType.h:415

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

Description

Return true if this is a 2048-bit vector type.

Declared at: llvm/include/llvm/Support/MachineValueType.h:452

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

Description

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

Declared at: llvm/include/llvm/Support/MachineValueType.h:398

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

Description

Return true if this is a 64-bit vector type.

Declared at: llvm/include/llvm/Support/MachineValueType.h:406

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

Declared at: llvm/include/llvm/Support/MachineValueType.h:386

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

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

Description

Return true if this is an overloaded type for TableGen.

Declared at: llvm/include/llvm/Support/MachineValueType.h:460

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

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

Description

Return true if this is an integer, not including vectors.

Declared at: llvm/include/llvm/Support/MachineValueType.h:368

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

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

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

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

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

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()

Declared at: llvm/include/llvm/Support/MachineValueType.h:1484

static iota_range<llvm::MVT::SimpleValueType>
vector_valuetypes()

Declared at: llvm/include/llvm/Support/MachineValueType.h:1472