Struct cranelift_codegen::machinst::lower::InstColor [−][src]
An “instruction color” partitions CLIF instructions by side-effecting ops. All instructions with the same “color” are guaranteed not to be separated by any side-effecting op (for this purpose, loads are also considered side-effecting, to avoid subtle questions w.r.t. the memory model), and furthermore, it is guaranteed that for any two instructions A and B such that color(A) == color(B), either A dominates B and B postdominates A, or vice-versa. (For now, in practice, only ops in the same basic block can ever have the same color, trivially providing the second condition.) Intuitively, this means that the ops of the same color must always execute “together”, as part of one atomic contiguous section of the dynamic execution trace, and they can be freely permuted (modulo true dataflow dependencies) without affecting program behavior.
Implementations
impl InstColor
[src]
pub fn get(self) -> u32
[src]
Get an arbitrary index representing this color. The index is unique within a single function compilation, but indices may be reused across functions.
Trait Implementations
impl Clone for InstColor
[src]
impl Copy for InstColor
[src]
impl Debug for InstColor
[src]
impl Eq for InstColor
[src]
impl Hash for InstColor
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
pub fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl PartialEq<InstColor> for InstColor
[src]
impl StructuralEq for InstColor
[src]
impl StructuralPartialEq for InstColor
[src]
Auto Trait Implementations
impl RefUnwindSafe for InstColor
impl Send for InstColor
impl Sync for InstColor
impl Unpin for InstColor
impl UnwindSafe for InstColor
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> CallHasher for T where
T: Hash,
[src]
T: Hash,
impl<Q, K> Equivalent<K> for Q where
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
[src]
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
pub fn equivalent(&self, key: &K) -> bool
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,