class VectorType

Declaration

class VectorType : public Type { /* full declaration omitted */ };

Description

Base class of all SIMD vector types

Declared at: llvm/include/llvm/IR/DerivedTypes.h:389

Inherits from: Type

Member Variables

private llvm::Type* ContainedType
The element type of the vector.
protected const unsigned int ElementQuantity
The element quantity of this vector. The meaning of this value depends on the type of vector: - For FixedVectorType = <ElementQuantity x ty>, there are exactly ElementQuantity elements in this vector. - For ScalableVectorType = <vscale x ElementQuantity x ty>, there are vscale * ElementQuantity elements in this vector, where vscale is a runtime-constant integer greater than 0.

Inherited from Type:

protected NumContainedTys = 0
protected ContainedTys = nullptr

Method Overview

Inherited from Type:

Methods

VectorType(llvm::Type* ElType,
           unsigned int EQ,
           Type::TypeID TID)

Declared at: llvm/include/llvm/IR/DerivedTypes.h:416

Parameters

llvm::Type* ElType
unsigned int EQ
Type::TypeID TID

VectorType(const llvm::VectorType&)

Declared at: llvm/include/llvm/IR/DerivedTypes.h:419

Parameters

const llvm::VectorType&

static bool classof(const llvm::Type* T)

Description

Methods for support type inquiry through isa, cast, and dyn_cast.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:518

Parameters

const llvm::Type* T

static llvm::VectorType* get(
    llvm::Type* ElementType,
    llvm::ElementCount EC)

Description

This static method is the primary way to construct an VectorType.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:425

Parameters

llvm::Type* ElementType
llvm::ElementCount EC

static llvm::VectorType* get(
    llvm::Type* ElementType,
    unsigned int NumElements,
    bool Scalable)

Declared at: llvm/include/llvm/IR/DerivedTypes.h:427

Parameters

llvm::Type* ElementType
unsigned int NumElements
bool Scalable

static llvm::VectorType* get(
    llvm::Type* ElementType,
    const llvm::VectorType* Other)

Declared at: llvm/include/llvm/IR/DerivedTypes.h:433

Parameters

llvm::Type* ElementType
const llvm::VectorType* Other

static llvm::VectorType*
getDoubleElementsVectorType(llvm::VectorType* VTy)

Description

This static method returns a VectorType with twice as many elements as the input type and the same element type.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:503

Parameters

llvm::VectorType* VTy

inline llvm::ElementCount getElementCount() const

Description

Return an ElementCount instance to represent the (possibly scalable) number of elements in the vector.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:515

llvm::Type* getElementType() const

Declared at: llvm/include/llvm/IR/DerivedTypes.h:422

static llvm::VectorType*
getExtendedElementVectorType(
    llvm::VectorType* VTy)

Description

This static method is like getInteger except that the element types are twice as wide as the elements in the input type.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:449

Parameters

llvm::VectorType* VTy

static llvm::VectorType*
getHalfElementsVectorType(llvm::VectorType* VTy)

Description

This static method returns a VectorType with half as many elements as the input type and the same element type.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:493

Parameters

llvm::VectorType* VTy

static llvm::VectorType* getInteger(
    llvm::VectorType* VTy)

Description

This static method gets a VectorType with the same number of elements as the input type, and the element type is an integer type of the same width as the input element type.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:440

Parameters

llvm::VectorType* VTy

static llvm::VectorType* getSubdividedVectorType(
    llvm::VectorType* VTy,
    int NumSubdivs)

Declared at: llvm/include/llvm/IR/DerivedTypes.h:483

Parameters

llvm::VectorType* VTy
int NumSubdivs

static llvm::VectorType*
getTruncatedElementVectorType(
    llvm::VectorType* VTy)

Declared at: llvm/include/llvm/IR/DerivedTypes.h:458

Parameters

llvm::VectorType* VTy

static bool isValidElementType(llvm::Type* ElemTy)

Description

Return true if the specified type is valid as a element type.

Declared at: llvm/include/llvm/IR/DerivedTypes.h:511

Parameters

llvm::Type* ElemTy