Enum rspirv::dr::Operand

source ·
pub enum Operand {
Show 55 variants ImageOperands(ImageOperands), FPFastMathMode(FPFastMathMode), SelectionControl(SelectionControl), LoopControl(LoopControl), FunctionControl(FunctionControl), MemorySemantics(MemorySemantics), MemoryAccess(MemoryAccess), KernelProfilingInfo(KernelProfilingInfo), RayFlags(RayFlags), FragmentShadingRate(FragmentShadingRate), SourceLanguage(SourceLanguage), ExecutionModel(ExecutionModel), AddressingModel(AddressingModel), MemoryModel(MemoryModel), ExecutionMode(ExecutionMode), StorageClass(StorageClass), Dim(Dim), SamplerAddressingMode(SamplerAddressingMode), SamplerFilterMode(SamplerFilterMode), ImageFormat(ImageFormat), ImageChannelOrder(ImageChannelOrder), ImageChannelDataType(ImageChannelDataType), FPRoundingMode(FPRoundingMode), FPDenormMode(FPDenormMode), QuantizationModes(QuantizationModes), FPOperationMode(FPOperationMode), OverflowModes(OverflowModes), LinkageType(LinkageType), AccessQualifier(AccessQualifier), HostAccessQualifier(HostAccessQualifier), FunctionParameterAttribute(FunctionParameterAttribute), Decoration(Decoration), BuiltIn(BuiltIn), Scope(Scope), GroupOperation(GroupOperation), KernelEnqueueFlags(KernelEnqueueFlags), Capability(Capability), RayQueryIntersection(RayQueryIntersection), RayQueryCommittedIntersectionType(RayQueryCommittedIntersectionType), RayQueryCandidateIntersectionType(RayQueryCandidateIntersectionType), PackedVectorFormat(PackedVectorFormat), CooperativeMatrixOperands(CooperativeMatrixOperands), CooperativeMatrixLayout(CooperativeMatrixLayout), CooperativeMatrixUse(CooperativeMatrixUse), InitializationModeQualifier(InitializationModeQualifier), LoadCacheControl(LoadCacheControl), StoreCacheControl(StoreCacheControl), IdMemorySemantics(Word), IdScope(Word), IdRef(Word), LiteralBit32(u32), LiteralBit64(u64), LiteralExtInstInteger(u32), LiteralSpecConstantOpInteger(Op), LiteralString(String),
}
Expand description

Data representation of a SPIR-V operand.

Variants§

§

ImageOperands(ImageOperands)

§

FPFastMathMode(FPFastMathMode)

§

SelectionControl(SelectionControl)

§

LoopControl(LoopControl)

§

FunctionControl(FunctionControl)

§

MemorySemantics(MemorySemantics)

§

MemoryAccess(MemoryAccess)

§

KernelProfilingInfo(KernelProfilingInfo)

§

RayFlags(RayFlags)

§

FragmentShadingRate(FragmentShadingRate)

§

SourceLanguage(SourceLanguage)

§

ExecutionModel(ExecutionModel)

§

AddressingModel(AddressingModel)

§

MemoryModel(MemoryModel)

§

ExecutionMode(ExecutionMode)

§

StorageClass(StorageClass)

§

Dim(Dim)

§

SamplerAddressingMode(SamplerAddressingMode)

§

SamplerFilterMode(SamplerFilterMode)

§

ImageFormat(ImageFormat)

§

ImageChannelOrder(ImageChannelOrder)

§

ImageChannelDataType(ImageChannelDataType)

§

FPRoundingMode(FPRoundingMode)

§

FPDenormMode(FPDenormMode)

§

QuantizationModes(QuantizationModes)

§

FPOperationMode(FPOperationMode)

§

OverflowModes(OverflowModes)

§

LinkageType(LinkageType)

§

AccessQualifier(AccessQualifier)

§

HostAccessQualifier(HostAccessQualifier)

§

FunctionParameterAttribute(FunctionParameterAttribute)

§

Decoration(Decoration)

§

BuiltIn(BuiltIn)

§

Scope(Scope)

§

GroupOperation(GroupOperation)

§

KernelEnqueueFlags(KernelEnqueueFlags)

§

Capability(Capability)

§

RayQueryIntersection(RayQueryIntersection)

§

RayQueryCommittedIntersectionType(RayQueryCommittedIntersectionType)

§

RayQueryCandidateIntersectionType(RayQueryCandidateIntersectionType)

§

PackedVectorFormat(PackedVectorFormat)

§

CooperativeMatrixOperands(CooperativeMatrixOperands)

§

CooperativeMatrixLayout(CooperativeMatrixLayout)

§

CooperativeMatrixUse(CooperativeMatrixUse)

§

InitializationModeQualifier(InitializationModeQualifier)

§

LoadCacheControl(LoadCacheControl)

§

StoreCacheControl(StoreCacheControl)

§

IdMemorySemantics(Word)

§

IdScope(Word)

§

IdRef(Word)

§

LiteralBit32(u32)

§

LiteralBit64(u64)

§

LiteralExtInstInteger(u32)

§

LiteralSpecConstantOpInteger(Op)

§

LiteralString(String)

Implementations§

source§

impl Operand

source

pub fn unwrap_image_operands(&self) -> ImageOperands

source

pub fn unwrap_fp_fast_math_mode(&self) -> FPFastMathMode

source

pub fn unwrap_selection_control(&self) -> SelectionControl

source

pub fn unwrap_loop_control(&self) -> LoopControl

source

pub fn unwrap_function_control(&self) -> FunctionControl

source

pub fn unwrap_memory_semantics(&self) -> MemorySemantics

source

pub fn unwrap_memory_access(&self) -> MemoryAccess

source

pub fn unwrap_kernel_profiling_info(&self) -> KernelProfilingInfo

source

pub fn unwrap_ray_flags(&self) -> RayFlags

source

pub fn unwrap_fragment_shading_rate(&self) -> FragmentShadingRate

source

pub fn unwrap_source_language(&self) -> SourceLanguage

source

pub fn unwrap_execution_model(&self) -> ExecutionModel

source

pub fn unwrap_addressing_model(&self) -> AddressingModel

source

pub fn unwrap_memory_model(&self) -> MemoryModel

source

pub fn unwrap_execution_mode(&self) -> ExecutionMode

source

pub fn unwrap_storage_class(&self) -> StorageClass

source

pub fn unwrap_dim(&self) -> Dim

source

pub fn unwrap_sampler_addressing_mode(&self) -> SamplerAddressingMode

source

pub fn unwrap_sampler_filter_mode(&self) -> SamplerFilterMode

source

pub fn unwrap_image_format(&self) -> ImageFormat

source

pub fn unwrap_image_channel_order(&self) -> ImageChannelOrder

source

pub fn unwrap_image_channel_data_type(&self) -> ImageChannelDataType

source

pub fn unwrap_fp_rounding_mode(&self) -> FPRoundingMode

source

pub fn unwrap_fp_denorm_mode(&self) -> FPDenormMode

source

pub fn unwrap_quantization_modes(&self) -> QuantizationModes

source

pub fn unwrap_fp_operation_mode(&self) -> FPOperationMode

source

pub fn unwrap_overflow_modes(&self) -> OverflowModes

source

pub fn unwrap_linkage_type(&self) -> LinkageType

source

pub fn unwrap_access_qualifier(&self) -> AccessQualifier

source

pub fn unwrap_host_access_qualifier(&self) -> HostAccessQualifier

source

pub fn unwrap_function_parameter_attribute(&self) -> FunctionParameterAttribute

source

pub fn unwrap_decoration(&self) -> Decoration

source

pub fn unwrap_built_in(&self) -> BuiltIn

source

pub fn unwrap_scope(&self) -> Scope

source

pub fn unwrap_group_operation(&self) -> GroupOperation

source

pub fn unwrap_kernel_enqueue_flags(&self) -> KernelEnqueueFlags

source

pub fn unwrap_capability(&self) -> Capability

source

pub fn unwrap_ray_query_intersection(&self) -> RayQueryIntersection

source

pub fn unwrap_ray_query_committed_intersection_type( &self ) -> RayQueryCommittedIntersectionType

source

pub fn unwrap_ray_query_candidate_intersection_type( &self ) -> RayQueryCandidateIntersectionType

source

pub fn unwrap_packed_vector_format(&self) -> PackedVectorFormat

source

pub fn unwrap_cooperative_matrix_operands(&self) -> CooperativeMatrixOperands

source

pub fn unwrap_cooperative_matrix_layout(&self) -> CooperativeMatrixLayout

source

pub fn unwrap_cooperative_matrix_use(&self) -> CooperativeMatrixUse

source

pub fn unwrap_initialization_mode_qualifier( &self ) -> InitializationModeQualifier

source

pub fn unwrap_load_cache_control(&self) -> LoadCacheControl

source

pub fn unwrap_store_cache_control(&self) -> StoreCacheControl

source

pub fn unwrap_id_memory_semantics(&self) -> Word

source

pub fn unwrap_id_scope(&self) -> Word

source

pub fn unwrap_id_ref(&self) -> Word

source

pub fn unwrap_literal_bit32(&self) -> u32

source

pub fn unwrap_literal_bit64(&self) -> u64

source

pub fn unwrap_literal_ext_inst_integer(&self) -> u32

source

pub fn unwrap_literal_spec_constant_op_integer(&self) -> Op

source

pub fn unwrap_literal_string(&self) -> &str

source

pub fn id_ref_any(&self) -> Option<Word>

source

pub fn id_ref_any_mut(&mut self) -> Option<&mut Word>

source

pub fn required_capabilities(&self) -> Vec<Capability>

source

pub fn required_extensions(&self) -> Vec<&'static str>

source

pub fn additional_operands(&self) -> Vec<LogicalOperand>

Trait Implementations§

source§

impl Assemble for Operand

source§

fn assemble_into(&self, result: &mut Vec<u32>)

Assembles the current object into the result vector, reducing the need for lots of allocations
source§

fn assemble(&self) -> Vec<u32>

Assembles the current object and returns the binary code. Helper method to remain backwards compatible, calls assemble_into
source§

impl Clone for Operand

source§

fn clone(&self) -> Operand

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Operand

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Disassemble for Operand

source§

fn disassemble(&self) -> String

Disassembles the current object and returns the assembly code.
source§

impl Display for Operand

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'a> From<&'a str> for Operand

source§

fn from(val: &'a str) -> Self

Converts to this type from the input type.
source§

impl From<AccessQualifier> for Operand

source§

fn from(o: AccessQualifier) -> Self

Converts to this type from the input type.
source§

impl From<AddressingModel> for Operand

source§

fn from(o: AddressingModel) -> Self

Converts to this type from the input type.
source§

impl From<BuiltIn> for Operand

source§

fn from(o: BuiltIn) -> Self

Converts to this type from the input type.
source§

impl From<Capability> for Operand

source§

fn from(o: Capability) -> Self

Converts to this type from the input type.
source§

impl From<CooperativeMatrixLayout> for Operand

source§

fn from(o: CooperativeMatrixLayout) -> Self

Converts to this type from the input type.
source§

impl From<CooperativeMatrixOperands> for Operand

source§

fn from(o: CooperativeMatrixOperands) -> Self

Converts to this type from the input type.
source§

impl From<CooperativeMatrixUse> for Operand

source§

fn from(o: CooperativeMatrixUse) -> Self

Converts to this type from the input type.
source§

impl From<Decoration> for Operand

source§

fn from(o: Decoration) -> Self

Converts to this type from the input type.
source§

impl From<Dim> for Operand

source§

fn from(o: Dim) -> Self

Converts to this type from the input type.
source§

impl From<ExecutionMode> for Operand

source§

fn from(o: ExecutionMode) -> Self

Converts to this type from the input type.
source§

impl From<ExecutionModel> for Operand

source§

fn from(o: ExecutionModel) -> Self

Converts to this type from the input type.
source§

impl From<FPDenormMode> for Operand

source§

fn from(o: FPDenormMode) -> Self

Converts to this type from the input type.
source§

impl From<FPFastMathMode> for Operand

source§

fn from(o: FPFastMathMode) -> Self

Converts to this type from the input type.
source§

impl From<FPOperationMode> for Operand

source§

fn from(o: FPOperationMode) -> Self

Converts to this type from the input type.
source§

impl From<FPRoundingMode> for Operand

source§

fn from(o: FPRoundingMode) -> Self

Converts to this type from the input type.
source§

impl From<FragmentShadingRate> for Operand

source§

fn from(o: FragmentShadingRate) -> Self

Converts to this type from the input type.
source§

impl From<FunctionControl> for Operand

source§

fn from(o: FunctionControl) -> Self

Converts to this type from the input type.
source§

impl From<FunctionParameterAttribute> for Operand

source§

fn from(o: FunctionParameterAttribute) -> Self

Converts to this type from the input type.
source§

impl From<GroupOperation> for Operand

source§

fn from(o: GroupOperation) -> Self

Converts to this type from the input type.
source§

impl From<HostAccessQualifier> for Operand

source§

fn from(o: HostAccessQualifier) -> Self

Converts to this type from the input type.
source§

impl From<ImageChannelDataType> for Operand

source§

fn from(o: ImageChannelDataType) -> Self

Converts to this type from the input type.
source§

impl From<ImageChannelOrder> for Operand

source§

fn from(o: ImageChannelOrder) -> Self

Converts to this type from the input type.
source§

impl From<ImageFormat> for Operand

source§

fn from(o: ImageFormat) -> Self

Converts to this type from the input type.
source§

impl From<ImageOperands> for Operand

source§

fn from(o: ImageOperands) -> Self

Converts to this type from the input type.
source§

impl From<InitializationModeQualifier> for Operand

source§

fn from(o: InitializationModeQualifier) -> Self

Converts to this type from the input type.
source§

impl From<KernelEnqueueFlags> for Operand

source§

fn from(o: KernelEnqueueFlags) -> Self

Converts to this type from the input type.
source§

impl From<KernelProfilingInfo> for Operand

source§

fn from(o: KernelProfilingInfo) -> Self

Converts to this type from the input type.
source§

impl From<LinkageType> for Operand

source§

fn from(o: LinkageType) -> Self

Converts to this type from the input type.
source§

impl From<LoadCacheControl> for Operand

source§

fn from(o: LoadCacheControl) -> Self

Converts to this type from the input type.
source§

impl From<LoopControl> for Operand

source§

fn from(o: LoopControl) -> Self

Converts to this type from the input type.
source§

impl From<MemoryAccess> for Operand

source§

fn from(o: MemoryAccess) -> Self

Converts to this type from the input type.
source§

impl From<MemoryModel> for Operand

source§

fn from(o: MemoryModel) -> Self

Converts to this type from the input type.
source§

impl From<MemorySemantics> for Operand

source§

fn from(o: MemorySemantics) -> Self

Converts to this type from the input type.
source§

impl From<Op> for Operand

source§

fn from(o: Op) -> Self

Converts to this type from the input type.
source§

impl From<OverflowModes> for Operand

source§

fn from(o: OverflowModes) -> Self

Converts to this type from the input type.
source§

impl From<PackedVectorFormat> for Operand

source§

fn from(o: PackedVectorFormat) -> Self

Converts to this type from the input type.
source§

impl From<QuantizationModes> for Operand

source§

fn from(o: QuantizationModes) -> Self

Converts to this type from the input type.
source§

impl From<RayFlags> for Operand

source§

fn from(o: RayFlags) -> Self

Converts to this type from the input type.
source§

impl From<RayQueryCandidateIntersectionType> for Operand

source§

fn from(o: RayQueryCandidateIntersectionType) -> Self

Converts to this type from the input type.
source§

impl From<RayQueryCommittedIntersectionType> for Operand

source§

fn from(o: RayQueryCommittedIntersectionType) -> Self

Converts to this type from the input type.
source§

impl From<RayQueryIntersection> for Operand

source§

fn from(o: RayQueryIntersection) -> Self

Converts to this type from the input type.
source§

impl From<SamplerAddressingMode> for Operand

source§

fn from(o: SamplerAddressingMode) -> Self

Converts to this type from the input type.
source§

impl From<SamplerFilterMode> for Operand

source§

fn from(o: SamplerFilterMode) -> Self

Converts to this type from the input type.
source§

impl From<Scope> for Operand

source§

fn from(o: Scope) -> Self

Converts to this type from the input type.
source§

impl From<SelectionControl> for Operand

source§

fn from(o: SelectionControl) -> Self

Converts to this type from the input type.
source§

impl From<SourceLanguage> for Operand

source§

fn from(o: SourceLanguage) -> Self

Converts to this type from the input type.
source§

impl From<StorageClass> for Operand

source§

fn from(o: StorageClass) -> Self

Converts to this type from the input type.
source§

impl From<StoreCacheControl> for Operand

source§

fn from(o: StoreCacheControl) -> Self

Converts to this type from the input type.
source§

impl From<String> for Operand

source§

fn from(o: String) -> Self

Converts to this type from the input type.
source§

impl From<u32> for Operand

source§

fn from(o: u32) -> Self

Converts to this type from the input type.
source§

impl From<u64> for Operand

source§

fn from(o: u64) -> Self

Converts to this type from the input type.
source§

impl Hash for Operand

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl PartialEq for Operand

source§

fn eq(&self, other: &Operand) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for Operand

source§

impl StructuralEq for Operand

source§

impl StructuralPartialEq for Operand

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> ToString for T
where T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.