| MLIR
    22.0.0git
    | 
An attribute that specifies the target version, allowed extensions and capabilities, and resource limits. More...
#include "mlir/Dialect/SPIRV/IR/SPIRVAttributes.h"
 Inheritance diagram for mlir::spirv::TargetEnvAttr:
 Inheritance diagram for mlir::spirv::TargetEnvAttr:| Public Types | |
| using | Base = StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits... > | 
| Utility declarations for the concrete attribute class.  More... | |
|  Public Types inherited from mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits > | |
| using | Base = StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits... > | 
| Utility declarations for the concrete attribute class.  More... | |
| using | ImplType = StorageT | 
| using | HasTraitFn = bool(*)(TypeID) | 
| Public Member Functions | |
| VerCapExtAttr | getTripleAttr () const | 
| Returns the (version, capabilities, extensions) triple attribute.  More... | |
| Version | getVersion () const | 
| Returns the target version.  More... | |
| VerCapExtAttr::ext_range | getExtensions () | 
| Returns the target extensions.  More... | |
| ArrayAttr | getExtensionsAttr () | 
| Returns the target extensions as a string array attribute.  More... | |
| VerCapExtAttr::cap_range | getCapabilities () | 
| Returns the target capabilities.  More... | |
| ArrayAttr | getCapabilitiesAttr () | 
| Returns the target capabilities as an integer array attribute.  More... | |
| ClientAPI | getClientAPI () const | 
| Returns the client API.  More... | |
| Vendor | getVendorID () const | 
| Returns the vendor ID.  More... | |
| DeviceType | getDeviceType () const | 
| Returns the device type.  More... | |
| uint32_t | getDeviceID () const | 
| Returns the device ID.  More... | |
| ResourceLimitsAttr | getResourceLimits () const | 
| Returns the target resource limits.  More... | |
|  Public Member Functions inherited from mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits > | |
| ImplType * | getImpl () const | 
| Utility for easy access to the storage instance.  More... | |
| Static Public Member Functions | |
| static TargetEnvAttr | get (VerCapExtAttr triple, ResourceLimitsAttr limits, ClientAPI clientAPI=ClientAPI::Unknown, Vendor vendorID=Vendor::Unknown, DeviceType deviceType=DeviceType::Unknown, uint32_t deviceId=kUnknownDeviceID) | 
| Gets a TargetEnvAttr instance.  More... | |
| static StringRef | getKindName () | 
| Returns the attribute kind's name (without the 'spirv.' prefix).  More... | |
|  Static Public Member Functions inherited from mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits > | |
| static TypeID | getTypeID () | 
| Return a unique identifier for the concrete type.  More... | |
| template<typename T > | |
| static bool | classof (T val) | 
| Provide an implementation of 'classof' that compares the type id of the provided value with that of the concrete type.  More... | |
| static detail::InterfaceMap | getInterfaceMap () | 
| Returns an interface map for the interfaces registered to this storage user.  More... | |
| static HasTraitFn | getHasTraitFn () | 
| Returns the function that returns true if the given Trait ID matches the IDs of any of the traits defined by the storage user.  More... | |
| static auto | getWalkImmediateSubElementsFn () | 
| Returns a function that walks immediate sub elements of a given instance of the storage user.  More... | |
| static auto | getReplaceImmediateSubElementsFn () | 
| Returns a function that replaces immediate sub elements of a given instance of the storage user.  More... | |
| template<typename... IfaceModels> | |
| static void | attachInterface (MLIRContext &context) | 
| Attach the given models as implementations of the corresponding interfaces for the concrete storage user class.  More... | |
| template<typename... Args> | |
| static ConcreteT | get (MLIRContext *ctx, Args &&...args) | 
| Get or create a new ConcreteT instance within the ctx.  More... | |
| template<typename... Args> | |
| static ConcreteT | getChecked (const Location &loc, Args &&...args) | 
| Get or create a new ConcreteT instance within the ctx, defined at the given, potentially unknown, location.  More... | |
| template<typename... Args> | |
| static ConcreteT | getChecked (function_ref< InFlightDiagnostic()> emitErrorFn, MLIRContext *ctx, Args... args) | 
| Get or create a new ConcreteT instance within the ctx.  More... | |
| static ConcreteT | getFromOpaquePointer (const void *ptr) | 
| Get an instance of the concrete type from a void pointer.  More... | |
| Static Public Attributes | |
| static constexpr uint32_t | kUnknownDeviceID = 0x7FFFFFFF | 
| ID for unknown devices.  More... | |
| static constexpr StringLiteral | name = "spirv.target_env" | 
| Additional Inherited Members | |
|  Protected Member Functions inherited from mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits > | |
| template<typename... Args> | |
| LogicalResult | mutate (Args &&...args) | 
| Mutate the current storage instance.  More... | |
|  Static Protected Member Functions inherited from mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits > | |
| template<typename... Args> | |
| static LogicalResult | verifyInvariants (Args... args) | 
| Default implementation that just returns success.  More... | |
An attribute that specifies the target version, allowed extensions and capabilities, and resource limits.
These information describes a SPIR-V target environment.
Definition at line 143 of file SPIRVAttributes.h.
| using mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits >::Base = StorageUserBase<ConcreteT, BaseT, StorageT, UniquerT, Traits...> | 
Utility declarations for the concrete attribute class.
Definition at line 100 of file StorageUniquerSupport.h.
| 
 | static | 
Gets a TargetEnvAttr instance.
Definition at line 290 of file SPIRVAttributes.cpp.
References mlir::get().
Referenced by mlir::spirv::getDefaultTargetEnv(), and parseTargetEnvAttr().
| spirv::VerCapExtAttr::cap_range spirv::TargetEnvAttr::getCapabilities | ( | ) | 
Returns the target capabilities.
Definition at line 317 of file SPIRVAttributes.cpp.
Referenced by mlir::spirv::getAddressingModel(), mlir::spirv::getExecutionModel(), mlir::spirv::getMemoryModel(), mlir::spirv::needsInterfaceVarABIAttrs(), and mlir::spirv::TargetEnv::TargetEnv().
| ArrayAttr spirv::TargetEnvAttr::getCapabilitiesAttr | ( | ) | 
Returns the target capabilities as an integer array attribute.
Definition at line 321 of file SPIRVAttributes.cpp.
| spirv::ClientAPI spirv::TargetEnvAttr::getClientAPI | ( | ) | const | 
Returns the client API.
Definition at line 325 of file SPIRVAttributes.cpp.
References mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits >::getImpl().
Referenced by print().
| uint32_t spirv::TargetEnvAttr::getDeviceID | ( | ) | const | 
Returns the device ID.
Definition at line 337 of file SPIRVAttributes.cpp.
References mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits >::getImpl().
Referenced by print().
| spirv::DeviceType spirv::TargetEnvAttr::getDeviceType | ( | ) | const | 
Returns the device type.
Definition at line 333 of file SPIRVAttributes.cpp.
References mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits >::getImpl().
Referenced by print().
| spirv::VerCapExtAttr::ext_range spirv::TargetEnvAttr::getExtensions | ( | ) | 
Returns the target extensions.
Definition at line 309 of file SPIRVAttributes.cpp.
Referenced by mlir::spirv::TargetEnv::TargetEnv().
| ArrayAttr spirv::TargetEnvAttr::getExtensionsAttr | ( | ) | 
Returns the target extensions as a string array attribute.
Definition at line 313 of file SPIRVAttributes.cpp.
| 
 | static | 
Returns the attribute kind's name (without the 'spirv.' prefix).
Definition at line 299 of file SPIRVAttributes.cpp.
Referenced by print().
| spirv::ResourceLimitsAttr spirv::TargetEnvAttr::getResourceLimits | ( | ) | const | 
Returns the target resource limits.
Definition at line 341 of file SPIRVAttributes.cpp.
References mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits >::getImpl().
Referenced by print().
| spirv::VerCapExtAttr spirv::TargetEnvAttr::getTripleAttr | ( | ) | const | 
Returns the (version, capabilities, extensions) triple attribute.
Definition at line 301 of file SPIRVAttributes.cpp.
References mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits >::getImpl().
Referenced by print().
| spirv::Vendor spirv::TargetEnvAttr::getVendorID | ( | ) | const | 
Returns the vendor ID.
Definition at line 329 of file SPIRVAttributes.cpp.
References mlir::detail::StorageUserBase< ConcreteT, BaseT, StorageT, UniquerT, Traits >::getImpl().
Referenced by print().
| spirv::Version spirv::TargetEnvAttr::getVersion | ( | ) | const | 
Returns the target version.
Definition at line 305 of file SPIRVAttributes.cpp.
Referenced by mlir::spirv::TargetEnv::TargetEnv().
| 
 | staticconstexpr | 
ID for unknown devices.
Definition at line 148 of file SPIRVAttributes.h.
Referenced by mlir::spirv::getDefaultTargetEnv(), parseTargetEnvAttr(), and print().
| 
 | staticconstexpr | 
Definition at line 193 of file SPIRVAttributes.h.