21 if (
auto VTy = dyn_cast<VectorType>(&Ty)) {
29 if (
auto PTy = dyn_cast<PointerType>(&Ty)) {
30 unsigned AddrSpace = PTy->getAddressSpace();
38 assert(SizeInBits != 0 &&
"invalid zero-sized type");
static MVT getIntegerVT(unsigned BitWidth)
A parsed version of the target data layout string in and methods for querying it. ...
static LLT pointer(unsigned AddressSpace, unsigned SizeInBits)
Get a low-level pointer in the given address space.
This class represents lattice values for constants.
static MVT getVectorVT(MVT VT, unsigned NumElements)
bool isSized(SmallPtrSetImpl< Type *> *Visited=nullptr) const
Return true if it makes sense to take the size of this type.
bool isVector() const
Return true if this is a vector value type.
TypeSize getSizeInBits() const
Returns the size of the specified MVT in bits.
unsigned getVectorNumElements() const
unsigned getPointerSizeInBits(unsigned AS=0) const
Layout pointer size, in bits FIXME: The defaults need to be removed once all of the backends/clients ...
TypeSize getTypeSizeInBits(Type *Ty) const
Size examples:
LLT getElementType() const
Returns the vector's element type. Only valid for vector types.
static LLT scalar(unsigned SizeInBits)
Get a low-level scalar or aggregate "bag of bits".
MVT getVectorElementType() const
MVT getMVTForLLT(LLT Ty)
Get a rough equivalent of an MVT for a given LLT.
The instances of the Type class are immutable: once they are created, they are never changed...
LLT getLLTForMVT(MVT Ty)
Get a rough equivalent of an LLT for a given MVT.
LLT getLLTForType(Type &Ty, const DataLayout &DL)
Construct a low-level type based on an LLVM type.
unsigned getSizeInBits() const
Returns the total size of the type. Must only be called on sized types.
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
uint16_t getNumElements() const
Returns the number of elements in a vector LLT.
static LLT vector(uint16_t NumElements, unsigned ScalarSizeInBits)
Get a low-level vector of some number of elements and element width.