pub enum SpecConstantInstruction {
Show 59 variants
AccessChain {
base: Id,
indexes: Vec<Id>,
},
InBoundsAccessChain {
base: Id,
indexes: Vec<Id>,
},
PtrAccessChain {
base: Id,
element: Id,
indexes: Vec<Id>,
},
InBoundsPtrAccessChain {
base: Id,
element: Id,
indexes: Vec<Id>,
},
VectorShuffle {
vector_1: Id,
vector_2: Id,
components: Vec<u32>,
},
CompositeExtract {
composite: Id,
indexes: Vec<u32>,
},
CompositeInsert {
object: Id,
composite: Id,
indexes: Vec<u32>,
},
ConvertFToU {
float_value: Id,
},
ConvertFToS {
float_value: Id,
},
ConvertSToF {
signed_value: Id,
},
ConvertUToF {
unsigned_value: Id,
},
UConvert {
unsigned_value: Id,
},
SConvert {
signed_value: Id,
},
FConvert {
float_value: Id,
},
QuantizeToF16 {
value: Id,
},
ConvertPtrToU {
pointer: Id,
},
ConvertUToPtr {
integer_value: Id,
},
PtrCastToGeneric {
pointer: Id,
},
GenericCastToPtr {
pointer: Id,
},
Bitcast {
operand: Id,
},
SNegate {
operand: Id,
},
FNegate {
operand: Id,
},
IAdd {
operand1: Id,
operand2: Id,
},
FAdd {
operand1: Id,
operand2: Id,
},
ISub {
operand1: Id,
operand2: Id,
},
FSub {
operand1: Id,
operand2: Id,
},
IMul {
operand1: Id,
operand2: Id,
},
FMul {
operand1: Id,
operand2: Id,
},
UDiv {
operand1: Id,
operand2: Id,
},
SDiv {
operand1: Id,
operand2: Id,
},
FDiv {
operand1: Id,
operand2: Id,
},
UMod {
operand1: Id,
operand2: Id,
},
SRem {
operand1: Id,
operand2: Id,
},
SMod {
operand1: Id,
operand2: Id,
},
FRem {
operand1: Id,
operand2: Id,
},
FMod {
operand1: Id,
operand2: Id,
},
LogicalEqual {
operand1: Id,
operand2: Id,
},
LogicalNotEqual {
operand1: Id,
operand2: Id,
},
LogicalOr {
operand1: Id,
operand2: Id,
},
LogicalAnd {
operand1: Id,
operand2: Id,
},
LogicalNot {
operand: Id,
},
Select {
condition: Id,
object_1: Id,
object_2: Id,
},
IEqual {
operand1: Id,
operand2: Id,
},
INotEqual {
operand1: Id,
operand2: Id,
},
UGreaterThan {
operand1: Id,
operand2: Id,
},
SGreaterThan {
operand1: Id,
operand2: Id,
},
UGreaterThanEqual {
operand1: Id,
operand2: Id,
},
SGreaterThanEqual {
operand1: Id,
operand2: Id,
},
ULessThan {
operand1: Id,
operand2: Id,
},
SLessThan {
operand1: Id,
operand2: Id,
},
ULessThanEqual {
operand1: Id,
operand2: Id,
},
SLessThanEqual {
operand1: Id,
operand2: Id,
},
ShiftRightLogical {
base: Id,
shift: Id,
},
ShiftRightArithmetic {
base: Id,
shift: Id,
},
ShiftLeftLogical {
base: Id,
shift: Id,
},
BitwiseOr {
operand1: Id,
operand2: Id,
},
BitwiseXor {
operand1: Id,
operand2: Id,
},
BitwiseAnd {
operand1: Id,
operand2: Id,
},
Not {
operand: Id,
},
}
Expand description
An instruction that is used as the operand of the SpecConstantOp
instruction.
Variants
AccessChain
InBoundsAccessChain
PtrAccessChain
InBoundsPtrAccessChain
VectorShuffle
CompositeExtract
CompositeInsert
ConvertFToU
Fields
float_value: Id
ConvertFToS
Fields
float_value: Id
ConvertSToF
Fields
signed_value: Id
ConvertUToF
Fields
unsigned_value: Id
UConvert
Fields
unsigned_value: Id
SConvert
Fields
signed_value: Id
FConvert
Fields
float_value: Id
QuantizeToF16
Fields
value: Id
ConvertPtrToU
Fields
pointer: Id
ConvertUToPtr
Fields
integer_value: Id
PtrCastToGeneric
Fields
pointer: Id
GenericCastToPtr
Fields
pointer: Id
Bitcast
Fields
operand: Id
SNegate
Fields
operand: Id
FNegate
Fields
operand: Id
IAdd
FAdd
ISub
FSub
IMul
FMul
UDiv
SDiv
FDiv
UMod
SRem
SMod
FRem
FMod
LogicalEqual
LogicalNotEqual
LogicalOr
LogicalAnd
LogicalNot
Fields
operand: Id
Select
IEqual
INotEqual
UGreaterThan
SGreaterThan
UGreaterThanEqual
SGreaterThanEqual
ULessThan
SLessThan
ULessThanEqual
SLessThanEqual
ShiftRightLogical
ShiftRightArithmetic
ShiftLeftLogical
BitwiseOr
BitwiseXor
BitwiseAnd
Not
Fields
operand: Id
Trait Implementations
sourceimpl Clone for SpecConstantInstruction
impl Clone for SpecConstantInstruction
sourcefn clone(&self) -> SpecConstantInstruction
fn clone(&self) -> SpecConstantInstruction
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for SpecConstantInstruction
impl Debug for SpecConstantInstruction
sourceimpl PartialEq<SpecConstantInstruction> for SpecConstantInstruction
impl PartialEq<SpecConstantInstruction> for SpecConstantInstruction
sourcefn eq(&self, other: &SpecConstantInstruction) -> bool
fn eq(&self, other: &SpecConstantInstruction) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &SpecConstantInstruction) -> bool
fn ne(&self, other: &SpecConstantInstruction) -> bool
This method tests for !=
.
impl StructuralPartialEq for SpecConstantInstruction
Auto Trait Implementations
impl RefUnwindSafe for SpecConstantInstruction
impl Send for SpecConstantInstruction
impl Sync for SpecConstantInstruction
impl Unpin for SpecConstantInstruction
impl UnwindSafe for SpecConstantInstruction
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more