LLVM 19.0.0git
Public Member Functions | Public Attributes | List of all members
llvm::SPIRVGlobalRegistry Class Reference

#include "Target/SPIRV/SPIRVGlobalRegistry.h"

Public Member Functions

 SPIRVGlobalRegistry (unsigned PointerSize)
 
void add (const Constant *C, MachineFunction *MF, Register R)
 
void add (const GlobalVariable *GV, MachineFunction *MF, Register R)
 
void add (const Function *F, MachineFunction *MF, Register R)
 
void add (const Argument *Arg, MachineFunction *MF, Register R)
 
void add (const MachineInstr *MI, MachineFunction *MF, Register R)
 
Register find (const MachineInstr *MI, MachineFunction *MF)
 
Register find (const Constant *C, MachineFunction *MF)
 
Register find (const GlobalVariable *GV, MachineFunction *MF)
 
Register find (const Function *F, MachineFunction *MF)
 
void buildDepsGraph (std::vector< SPIRV::DTSortableEntry * > &Graph, MachineModuleInfo *MMI=nullptr)
 
void setBound (unsigned V)
 
unsigned getBound ()
 
void addReturnType (const Function *ArgF, TypedPointerType *DerivedTy)
 
const TypedPointerTypefindReturnType (const Function *ArgF)
 
void addDeducedElementType (Value *Val, Type *Ty)
 
TypefindDeducedElementType (const Value *Val)
 
void addDeducedCompositeType (Value *Val, Type *Ty)
 
TypefindDeducedCompositeType (const Value *Val)
 
TypegetDeducedGlobalValueType (const GlobalValue *Global)
 
const MachineOperandgetFunctionDefinitionByUse (const MachineOperand *Use)
 
const MachineInstrgetFunctionDefinition (const Function *F)
 
const FunctiongetFunctionByDefinition (const MachineInstr *MI)
 
void recordFunctionPointer (const MachineOperand *MO, const Function *F)
 
void recordFunctionDefinition (const Function *F, const MachineOperand *MO)
 
bool hasConstFunPtr ()
 
void addForwardCall (const Function *F, MachineInstr *MI)
 
SmallPtrSet< MachineInstr *, 8 > * getForwardCalls (const Function *F)
 
SPIRVTypeassignTypeToVReg (const Type *Type, Register VReg, MachineIRBuilder &MIRBuilder, SPIRV::AccessQualifier::AccessQualifier AQ=SPIRV::AccessQualifier::ReadWrite, bool EmitIR=true)
 
SPIRVTypeassignIntTypeToVReg (unsigned BitWidth, Register VReg, MachineInstr &I, const SPIRVInstrInfo &TII)
 
SPIRVTypeassignFloatTypeToVReg (unsigned BitWidth, Register VReg, MachineInstr &I, const SPIRVInstrInfo &TII)
 
SPIRVTypeassignVectTypeToVReg (SPIRVType *BaseType, unsigned NumElements, Register VReg, MachineInstr &I, const SPIRVInstrInfo &TII)
 
void assignSPIRVTypeToVReg (SPIRVType *Type, Register VReg, MachineFunction &MF)
 
SPIRVTypegetOrCreateSPIRVType (const Type *Type, MachineIRBuilder &MIRBuilder, SPIRV::AccessQualifier::AccessQualifier AQ=SPIRV::AccessQualifier::ReadWrite, bool EmitIR=true)
 
const TypegetTypeForSPIRVType (const SPIRVType *Ty) const
 
unsigned getPointeeTypeOp (Register PtrReg)
 
SPIRVTypegetOrCreateSPIRVTypeByName (StringRef TypeStr, MachineIRBuilder &MIRBuilder, SPIRV::StorageClass::StorageClass SC=SPIRV::StorageClass::Function, SPIRV::AccessQualifier::AccessQualifier AQ=SPIRV::AccessQualifier::ReadWrite)
 
SPIRVTypegetSPIRVTypeForVReg (Register VReg, const MachineFunction *MF=nullptr) const
 
bool hasSPIRVTypeForVReg (Register VReg) const
 
Register getSPIRVTypeID (const SPIRVType *SpirvType) const
 
MachineFunctionsetCurrentFunc (MachineFunction &MF)
 
bool isScalarOfType (Register VReg, unsigned TypeOpcode) const
 
bool isScalarOrVectorOfType (Register VReg, unsigned TypeOpcode) const
 
unsigned getScalarOrVectorComponentCount (Register VReg) const
 
unsigned getScalarOrVectorComponentCount (SPIRVType *Type) const
 
unsigned getScalarOrVectorBitWidth (const SPIRVType *Type) const
 
unsigned getNumScalarOrVectorTotalBitWidth (const SPIRVType *Type) const
 
const SPIRVTyperetrieveScalarOrVectorIntType (const SPIRVType *Type) const
 
bool isScalarOrVectorSigned (const SPIRVType *Type) const
 
SPIRV::StorageClass::StorageClass getPointerStorageClass (Register VReg) const
 
unsigned getPointerSize () const
 
bool isBitcastCompatible (const SPIRVType *Type1, const SPIRVType *Type2) const
 
Register buildConstantInt (uint64_t Val, MachineIRBuilder &MIRBuilder, SPIRVType *SpvType=nullptr, bool EmitIR=true)
 
Register getOrCreateConstInt (uint64_t Val, MachineInstr &I, SPIRVType *SpvType, const SPIRVInstrInfo &TII, bool ZeroAsNull=true)
 
Register getOrCreateConstFP (APFloat Val, MachineInstr &I, SPIRVType *SpvType, const SPIRVInstrInfo &TII, bool ZeroAsNull=true)
 
Register buildConstantFP (APFloat Val, MachineIRBuilder &MIRBuilder, SPIRVType *SpvType=nullptr)
 
Register getOrCreateConstVector (uint64_t Val, MachineInstr &I, SPIRVType *SpvType, const SPIRVInstrInfo &TII, bool ZeroAsNull=true)
 
Register getOrCreateConstVector (APFloat Val, MachineInstr &I, SPIRVType *SpvType, const SPIRVInstrInfo &TII, bool ZeroAsNull=true)
 
Register getOrCreateConsIntArray (uint64_t Val, MachineInstr &I, SPIRVType *SpvType, const SPIRVInstrInfo &TII)
 
Register getOrCreateConsIntVector (uint64_t Val, MachineIRBuilder &MIRBuilder, SPIRVType *SpvType, bool EmitIR=true)
 
Register getOrCreateConsIntArray (uint64_t Val, MachineIRBuilder &MIRBuilder, SPIRVType *SpvType, bool EmitIR=true)
 
Register getOrCreateConstNullPtr (MachineIRBuilder &MIRBuilder, SPIRVType *SpvType)
 
Register buildConstantSampler (Register Res, unsigned AddrMode, unsigned Param, unsigned FilerMode, MachineIRBuilder &MIRBuilder, SPIRVType *SpvType)
 
Register getOrCreateUndef (MachineInstr &I, SPIRVType *SpvType, const SPIRVInstrInfo &TII)
 
Register buildGlobalVariable (Register Reg, SPIRVType *BaseType, StringRef Name, const GlobalValue *GV, SPIRV::StorageClass::StorageClass Storage, const MachineInstr *Init, bool IsConst, bool HasLinkageTy, SPIRV::LinkageType::LinkageType LinkageType, MachineIRBuilder &MIRBuilder, bool IsInstSelector)
 
SPIRVTypegetOrCreateSPIRVIntegerType (unsigned BitWidth, MachineIRBuilder &MIRBuilder)
 
SPIRVTypegetOrCreateSPIRVIntegerType (unsigned BitWidth, MachineInstr &I, const SPIRVInstrInfo &TII)
 
SPIRVTypegetOrCreateSPIRVType (unsigned BitWidth, MachineInstr &I, const SPIRVInstrInfo &TII, unsigned SPIRVOPcode, Type *LLVMTy)
 
SPIRVTypegetOrCreateSPIRVFloatType (unsigned BitWidth, MachineInstr &I, const SPIRVInstrInfo &TII)
 
SPIRVTypegetOrCreateSPIRVBoolType (MachineIRBuilder &MIRBuilder)
 
SPIRVTypegetOrCreateSPIRVBoolType (MachineInstr &I, const SPIRVInstrInfo &TII)
 
SPIRVTypegetOrCreateSPIRVVectorType (SPIRVType *BaseType, unsigned NumElements, MachineIRBuilder &MIRBuilder)
 
SPIRVTypegetOrCreateSPIRVVectorType (SPIRVType *BaseType, unsigned NumElements, MachineInstr &I, const SPIRVInstrInfo &TII)
 
SPIRVTypegetOrCreateSPIRVArrayType (SPIRVType *BaseType, unsigned NumElements, MachineInstr &I, const SPIRVInstrInfo &TII)
 
SPIRVTypegetOrCreateSPIRVPointerType (SPIRVType *BaseType, MachineIRBuilder &MIRBuilder, SPIRV::StorageClass::StorageClass SClass=SPIRV::StorageClass::Function)
 
SPIRVTypegetOrCreateSPIRVPointerType (SPIRVType *BaseType, MachineInstr &I, const SPIRVInstrInfo &TII, SPIRV::StorageClass::StorageClass SClass=SPIRV::StorageClass::Function)
 
SPIRVTypegetOrCreateOpTypeImage (MachineIRBuilder &MIRBuilder, SPIRVType *SampledType, SPIRV::Dim::Dim Dim, uint32_t Depth, uint32_t Arrayed, uint32_t Multisampled, uint32_t Sampled, SPIRV::ImageFormat::ImageFormat ImageFormat, SPIRV::AccessQualifier::AccessQualifier AccQual)
 
SPIRVTypegetOrCreateOpTypeSampler (MachineIRBuilder &MIRBuilder)
 
SPIRVTypegetOrCreateOpTypeSampledImage (SPIRVType *ImageType, MachineIRBuilder &MIRBuilder)
 
SPIRVTypegetOrCreateOpTypePipe (MachineIRBuilder &MIRBuilder, SPIRV::AccessQualifier::AccessQualifier AccQual)
 
SPIRVTypegetOrCreateOpTypeDeviceEvent (MachineIRBuilder &MIRBuilder)
 
SPIRVTypegetOrCreateOpTypeFunctionWithArgs (const Type *Ty, SPIRVType *RetType, const SmallVectorImpl< SPIRVType * > &ArgTypes, MachineIRBuilder &MIRBuilder)
 
SPIRVTypegetOrCreateOpTypeByOpcode (const Type *Ty, MachineIRBuilder &MIRBuilder, unsigned Opcode)
 

Public Attributes

MachineFunctionCurMF
 

Detailed Description

Definition at line 29 of file SPIRVGlobalRegistry.h.

Constructor & Destructor Documentation

◆ SPIRVGlobalRegistry()

SPIRVGlobalRegistry::SPIRVGlobalRegistry ( unsigned  PointerSize)

Definition at line 30 of file SPIRVGlobalRegistry.cpp.

Member Function Documentation

◆ add() [1/5]

void llvm::SPIRVGlobalRegistry::add ( const Argument Arg,
MachineFunction MF,
Register  R 
)
inline

Definition at line 109 of file SPIRVGlobalRegistry.h.

References llvm::SPIRVGeneralDuplicatesTracker::add().

◆ add() [2/5]

void llvm::SPIRVGlobalRegistry::add ( const Constant C,
MachineFunction MF,
Register  R 
)
inline

◆ add() [3/5]

void llvm::SPIRVGlobalRegistry::add ( const Function F,
MachineFunction MF,
Register  R 
)
inline

Definition at line 105 of file SPIRVGlobalRegistry.h.

References llvm::SPIRVGeneralDuplicatesTracker::add(), and F.

◆ add() [4/5]

void llvm::SPIRVGlobalRegistry::add ( const GlobalVariable GV,
MachineFunction MF,
Register  R 
)
inline

Definition at line 101 of file SPIRVGlobalRegistry.h.

References llvm::SPIRVGeneralDuplicatesTracker::add().

◆ add() [5/5]

void llvm::SPIRVGlobalRegistry::add ( const MachineInstr MI,
MachineFunction MF,
Register  R 
)
inline

Definition at line 113 of file SPIRVGlobalRegistry.h.

References llvm::SPIRVGeneralDuplicatesTracker::add(), and MI.

◆ addDeducedCompositeType()

void llvm::SPIRVGlobalRegistry::addDeducedCompositeType ( Value Val,
Type Ty 
)
inline

Definition at line 160 of file SPIRVGlobalRegistry.h.

◆ addDeducedElementType()

void llvm::SPIRVGlobalRegistry::addDeducedElementType ( Value Val,
Type Ty 
)
inline

Definition at line 153 of file SPIRVGlobalRegistry.h.

◆ addForwardCall()

void llvm::SPIRVGlobalRegistry::addForwardCall ( const Function F,
MachineInstr MI 
)
inline

◆ addReturnType()

void llvm::SPIRVGlobalRegistry::addReturnType ( const Function ArgF,
TypedPointerType DerivedTy 
)
inline

◆ assignFloatTypeToVReg()

SPIRVType * SPIRVGlobalRegistry::assignFloatTypeToVReg ( unsigned  BitWidth,
Register  VReg,
MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ assignIntTypeToVReg()

SPIRVType * SPIRVGlobalRegistry::assignIntTypeToVReg ( unsigned  BitWidth,
Register  VReg,
MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ assignSPIRVTypeToVReg()

void SPIRVGlobalRegistry::assignSPIRVTypeToVReg ( SPIRVType Type,
Register  VReg,
MachineFunction MF 
)

◆ assignTypeToVReg()

SPIRVType * SPIRVGlobalRegistry::assignTypeToVReg ( const Type Type,
Register  VReg,
MachineIRBuilder MIRBuilder,
SPIRV::AccessQualifier::AccessQualifier  AQ = SPIRV::AccessQualifier::ReadWrite,
bool  EmitIR = true 
)

◆ assignVectTypeToVReg()

SPIRVType * SPIRVGlobalRegistry::assignVectTypeToVReg ( SPIRVType BaseType,
unsigned  NumElements,
Register  VReg,
MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ buildConstantFP()

Register SPIRVGlobalRegistry::buildConstantFP ( APFloat  Val,
MachineIRBuilder MIRBuilder,
SPIRVType SpvType = nullptr 
)

◆ buildConstantInt()

Register SPIRVGlobalRegistry::buildConstantInt ( uint64_t  Val,
MachineIRBuilder MIRBuilder,
SPIRVType SpvType = nullptr,
bool  EmitIR = true 
)

◆ buildConstantSampler()

Register SPIRVGlobalRegistry::buildConstantSampler ( Register  Res,
unsigned  AddrMode,
unsigned  Param,
unsigned  FilerMode,
MachineIRBuilder MIRBuilder,
SPIRVType SpvType 
)

◆ buildDepsGraph()

void llvm::SPIRVGlobalRegistry::buildDepsGraph ( std::vector< SPIRV::DTSortableEntry * > &  Graph,
MachineModuleInfo MMI = nullptr 
)
inline

◆ buildGlobalVariable()

Register SPIRVGlobalRegistry::buildGlobalVariable ( Register  Reg,
SPIRVType BaseType,
StringRef  Name,
const GlobalValue GV,
SPIRV::StorageClass::StorageClass  Storage,
const MachineInstr Init,
bool  IsConst,
bool  HasLinkageTy,
SPIRV::LinkageType::LinkageType  LinkageType,
MachineIRBuilder MIRBuilder,
bool  IsInstSelector 
)

◆ find() [1/4]

Register llvm::SPIRVGlobalRegistry::find ( const Constant C,
MachineFunction MF 
)
inline

◆ find() [2/4]

Register llvm::SPIRVGlobalRegistry::find ( const Function F,
MachineFunction MF 
)
inline

Definition at line 129 of file SPIRVGlobalRegistry.h.

References F, and llvm::SPIRVGeneralDuplicatesTracker::find().

◆ find() [3/4]

Register llvm::SPIRVGlobalRegistry::find ( const GlobalVariable GV,
MachineFunction MF 
)
inline

◆ find() [4/4]

Register llvm::SPIRVGlobalRegistry::find ( const MachineInstr MI,
MachineFunction MF 
)
inline

◆ findDeducedCompositeType()

Type * llvm::SPIRVGlobalRegistry::findDeducedCompositeType ( const Value Val)
inline

◆ findDeducedElementType()

Type * llvm::SPIRVGlobalRegistry::findDeducedElementType ( const Value Val)
inline

◆ findReturnType()

const TypedPointerType * llvm::SPIRVGlobalRegistry::findReturnType ( const Function ArgF)
inline

◆ getBound()

unsigned llvm::SPIRVGlobalRegistry::getBound ( )
inline

Definition at line 139 of file SPIRVGlobalRegistry.h.

◆ getDeducedGlobalValueType()

Type * llvm::SPIRVGlobalRegistry::getDeducedGlobalValueType ( const GlobalValue Global)
inline

◆ getForwardCalls()

SmallPtrSet< MachineInstr *, 8 > * llvm::SPIRVGlobalRegistry::getForwardCalls ( const Function F)
inline

◆ getFunctionByDefinition()

const Function * llvm::SPIRVGlobalRegistry::getFunctionByDefinition ( const MachineInstr MI)
inline

◆ getFunctionDefinition()

const MachineInstr * llvm::SPIRVGlobalRegistry::getFunctionDefinition ( const Function F)
inline

◆ getFunctionDefinitionByUse()

const MachineOperand * llvm::SPIRVGlobalRegistry::getFunctionDefinitionByUse ( const MachineOperand Use)
inline

◆ getNumScalarOrVectorTotalBitWidth()

unsigned SPIRVGlobalRegistry::getNumScalarOrVectorTotalBitWidth ( const SPIRVType Type) const

Definition at line 1017 of file SPIRVGlobalRegistry.cpp.

References assert(), and getSPIRVTypeForVReg().

Referenced by isBitcastCompatible().

◆ getOrCreateConsIntArray() [1/2]

Register SPIRVGlobalRegistry::getOrCreateConsIntArray ( uint64_t  Val,
MachineInstr I,
SPIRVType SpvType,
const SPIRVInstrInfo TII 
)

◆ getOrCreateConsIntArray() [2/2]

Register SPIRVGlobalRegistry::getOrCreateConsIntArray ( uint64_t  Val,
MachineIRBuilder MIRBuilder,
SPIRVType SpvType,
bool  EmitIR = true 
)

◆ getOrCreateConsIntVector()

Register SPIRVGlobalRegistry::getOrCreateConsIntVector ( uint64_t  Val,
MachineIRBuilder MIRBuilder,
SPIRVType SpvType,
bool  EmitIR = true 
)

◆ getOrCreateConstFP()

Register SPIRVGlobalRegistry::getOrCreateConstFP ( APFloat  Val,
MachineInstr I,
SPIRVType SpvType,
const SPIRVInstrInfo TII,
bool  ZeroAsNull = true 
)

◆ getOrCreateConstInt()

Register SPIRVGlobalRegistry::getOrCreateConstInt ( uint64_t  Val,
MachineInstr I,
SPIRVType SpvType,
const SPIRVInstrInfo TII,
bool  ZeroAsNull = true 
)

◆ getOrCreateConstNullPtr()

Register SPIRVGlobalRegistry::getOrCreateConstNullPtr ( MachineIRBuilder MIRBuilder,
SPIRVType SpvType 
)

◆ getOrCreateConstVector() [1/2]

Register SPIRVGlobalRegistry::getOrCreateConstVector ( APFloat  Val,
MachineInstr I,
SPIRVType SpvType,
const SPIRVInstrInfo TII,
bool  ZeroAsNull = true 
)

◆ getOrCreateConstVector() [2/2]

Register SPIRVGlobalRegistry::getOrCreateConstVector ( uint64_t  Val,
MachineInstr I,
SPIRVType SpvType,
const SPIRVInstrInfo TII,
bool  ZeroAsNull = true 
)

◆ getOrCreateOpTypeByOpcode()

SPIRVType * SPIRVGlobalRegistry::getOrCreateOpTypeByOpcode ( const Type Ty,
MachineIRBuilder MIRBuilder,
unsigned  Opcode 
)

◆ getOrCreateOpTypeDeviceEvent()

SPIRVType * SPIRVGlobalRegistry::getOrCreateOpTypeDeviceEvent ( MachineIRBuilder MIRBuilder)

◆ getOrCreateOpTypeFunctionWithArgs()

SPIRVType * SPIRVGlobalRegistry::getOrCreateOpTypeFunctionWithArgs ( const Type Ty,
SPIRVType RetType,
const SmallVectorImpl< SPIRVType * > &  ArgTypes,
MachineIRBuilder MIRBuilder 
)

◆ getOrCreateOpTypeImage()

SPIRVType * SPIRVGlobalRegistry::getOrCreateOpTypeImage ( MachineIRBuilder MIRBuilder,
SPIRVType SampledType,
SPIRV::Dim::Dim  Dim,
uint32_t  Depth,
uint32_t  Arrayed,
uint32_t  Multisampled,
uint32_t  Sampled,
SPIRV::ImageFormat::ImageFormat  ImageFormat,
SPIRV::AccessQualifier::AccessQualifier  AccQual 
)

◆ getOrCreateOpTypePipe()

SPIRVType * SPIRVGlobalRegistry::getOrCreateOpTypePipe ( MachineIRBuilder MIRBuilder,
SPIRV::AccessQualifier::AccessQualifier  AccQual 
)

◆ getOrCreateOpTypeSampledImage()

SPIRVType * SPIRVGlobalRegistry::getOrCreateOpTypeSampledImage ( SPIRVType ImageType,
MachineIRBuilder MIRBuilder 
)

◆ getOrCreateOpTypeSampler()

SPIRVType * SPIRVGlobalRegistry::getOrCreateOpTypeSampler ( MachineIRBuilder MIRBuilder)

◆ getOrCreateSPIRVArrayType()

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVArrayType ( SPIRVType BaseType,
unsigned  NumElements,
MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ getOrCreateSPIRVBoolType() [1/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVBoolType ( MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ getOrCreateSPIRVBoolType() [2/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVBoolType ( MachineIRBuilder MIRBuilder)

◆ getOrCreateSPIRVFloatType()

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVFloatType ( unsigned  BitWidth,
MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ getOrCreateSPIRVIntegerType() [1/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVIntegerType ( unsigned  BitWidth,
MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ getOrCreateSPIRVIntegerType() [2/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVIntegerType ( unsigned  BitWidth,
MachineIRBuilder MIRBuilder 
)

◆ getOrCreateSPIRVPointerType() [1/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVPointerType ( SPIRVType BaseType,
MachineInstr I,
const SPIRVInstrInfo TII,
SPIRV::StorageClass::StorageClass  SClass = SPIRV::StorageClass::Function 
)

Definition at line 1364 of file SPIRVGlobalRegistry.cpp.

References getOrCreateSPIRVPointerType(), and I.

◆ getOrCreateSPIRVPointerType() [2/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVPointerType ( SPIRVType BaseType,
MachineIRBuilder MIRBuilder,
SPIRV::StorageClass::StorageClass  SClass = SPIRV::StorageClass::Function 
)

◆ getOrCreateSPIRVType() [1/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVType ( const Type Type,
MachineIRBuilder MIRBuilder,
SPIRV::AccessQualifier::AccessQualifier  AQ = SPIRV::AccessQualifier::ReadWrite,
bool  EmitIR = true 
)

◆ getOrCreateSPIRVType() [2/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVType ( unsigned  BitWidth,
MachineInstr I,
const SPIRVInstrInfo TII,
unsigned  SPIRVOPcode,
Type LLVMTy 
)

◆ getOrCreateSPIRVTypeByName()

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVTypeByName ( StringRef  TypeStr,
MachineIRBuilder MIRBuilder,
SPIRV::StorageClass::StorageClass  SC = SPIRV::StorageClass::Function,
SPIRV::AccessQualifier::AccessQualifier  AQ = SPIRV::AccessQualifier::ReadWrite 
)

◆ getOrCreateSPIRVVectorType() [1/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVVectorType ( SPIRVType BaseType,
unsigned  NumElements,
MachineInstr I,
const SPIRVInstrInfo TII 
)

◆ getOrCreateSPIRVVectorType() [2/2]

SPIRVType * SPIRVGlobalRegistry::getOrCreateSPIRVVectorType ( SPIRVType BaseType,
unsigned  NumElements,
MachineIRBuilder MIRBuilder 
)

◆ getOrCreateUndef()

Register SPIRVGlobalRegistry::getOrCreateUndef ( MachineInstr I,
SPIRVType SpvType,
const SPIRVInstrInfo TII 
)

◆ getPointeeTypeOp()

unsigned SPIRVGlobalRegistry::getPointeeTypeOp ( Register  PtrReg)

◆ getPointerSize()

unsigned llvm::SPIRVGlobalRegistry::getPointerSize ( ) const
inline

◆ getPointerStorageClass()

SPIRV::StorageClass::StorageClass SPIRVGlobalRegistry::getPointerStorageClass ( Register  VReg) const

◆ getScalarOrVectorBitWidth()

unsigned SPIRVGlobalRegistry::getScalarOrVectorBitWidth ( const SPIRVType Type) const

◆ getScalarOrVectorComponentCount() [1/2]

unsigned SPIRVGlobalRegistry::getScalarOrVectorComponentCount ( Register  VReg) const

◆ getScalarOrVectorComponentCount() [2/2]

unsigned SPIRVGlobalRegistry::getScalarOrVectorComponentCount ( SPIRVType Type) const

Definition at line 994 of file SPIRVGlobalRegistry.cpp.

◆ getSPIRVTypeForVReg()

SPIRVType * SPIRVGlobalRegistry::getSPIRVTypeForVReg ( Register  VReg,
const MachineFunction MF = nullptr 
) const

◆ getSPIRVTypeID()

Register SPIRVGlobalRegistry::getSPIRVTypeID ( const SPIRVType SpirvType) const

◆ getTypeForSPIRVType()

const Type * llvm::SPIRVGlobalRegistry::getTypeForSPIRVType ( const SPIRVType Ty) const
inline

◆ hasConstFunPtr()

bool llvm::SPIRVGlobalRegistry::hasConstFunPtr ( )
inline

◆ hasSPIRVTypeForVReg()

bool llvm::SPIRVGlobalRegistry::hasSPIRVTypeForVReg ( Register  VReg) const
inline

Definition at line 301 of file SPIRVGlobalRegistry.h.

References getSPIRVTypeForVReg().

◆ isBitcastCompatible()

bool SPIRVGlobalRegistry::isBitcastCompatible ( const SPIRVType Type1,
const SPIRVType Type2 
) const

◆ isScalarOfType()

bool SPIRVGlobalRegistry::isScalarOfType ( Register  VReg,
unsigned  TypeOpcode 
) const

◆ isScalarOrVectorOfType()

bool SPIRVGlobalRegistry::isScalarOrVectorOfType ( Register  VReg,
unsigned  TypeOpcode 
) const

◆ isScalarOrVectorSigned()

bool SPIRVGlobalRegistry::isScalarOrVectorSigned ( const SPIRVType Type) const

◆ recordFunctionDefinition()

void llvm::SPIRVGlobalRegistry::recordFunctionDefinition ( const Function F,
const MachineOperand MO 
)
inline

◆ recordFunctionPointer()

void llvm::SPIRVGlobalRegistry::recordFunctionPointer ( const MachineOperand MO,
const Function F 
)
inline

Definition at line 214 of file SPIRVGlobalRegistry.h.

References F.

◆ retrieveScalarOrVectorIntType()

const SPIRVType * SPIRVGlobalRegistry::retrieveScalarOrVectorIntType ( const SPIRVType Type) const

Definition at line 1031 of file SPIRVGlobalRegistry.cpp.

References getSPIRVTypeForVReg().

Referenced by isBitcastCompatible(), and isScalarOrVectorSigned().

◆ setBound()

void llvm::SPIRVGlobalRegistry::setBound ( unsigned  V)
inline

Definition at line 138 of file SPIRVGlobalRegistry.h.

◆ setCurrentFunc()

MachineFunction * llvm::SPIRVGlobalRegistry::setCurrentFunc ( MachineFunction MF)
inline

Member Data Documentation

◆ CurMF

MachineFunction* llvm::SPIRVGlobalRegistry::CurMF

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