|
MLIR 22.0.0git
|
Type conversion from builtin types to SPIR-V types for shader interface. More...
#include "mlir/Dialect/SPIRV/Transforms/SPIRVConversion.h"
Public Member Functions | |
| SPIRVTypeConverter (spirv::TargetEnvAttr targetAttr, const SPIRVConversionOptions &options={}) | |
| Type | getIndexType () const |
| Gets the SPIR-V correspondence for the standard index type. | |
| unsigned | getIndexTypeBitwidth () const |
| Gets the bitwidth of the index type when converted to SPIR-V. | |
| const spirv::TargetEnv & | getTargetEnv () const |
| const SPIRVConversionOptions & | getOptions () const |
| Returns the options controlling the SPIR-V type converter. | |
| bool | allows (spirv::Capability capability) const |
| Checks if the SPIR-V capability inquired is supported. | |
Type conversion from builtin types to SPIR-V types for shader interface.
For memref types, this converter additionally performs type wrapping to satisfy shader interface requirements: shader interface types must be pointers to structs.
Definition at line 74 of file SPIRVConversion.h.
|
explicit |
Definition at line 1541 of file SPIRVConversion.cpp.
References getIndexType().
| bool SPIRVTypeConverter::allows | ( | spirv::Capability | capability | ) | const |
Checks if the SPIR-V capability inquired is supported.
Definition at line 1610 of file SPIRVConversion.cpp.
Referenced by mlir::spirv::getElementPtr().
| Type SPIRVTypeConverter::getIndexType | ( | ) | const |
Gets the SPIR-V correspondence for the standard index type.
Definition at line 1602 of file SPIRVConversion.cpp.
References getContext().
Referenced by mlir::spirv::getOpenCLElementPtr(), mlir::spirv::getVulkanElementPtr(), and SPIRVTypeConverter().
|
inline |
Gets the bitwidth of the index type when converted to SPIR-V.
Definition at line 83 of file SPIRVConversion.h.
|
inline |
Returns the options controlling the SPIR-V type converter.
Definition at line 90 of file SPIRVConversion.h.
|
inline |
Definition at line 87 of file SPIRVConversion.h.