AnalysisError

Enum AnalysisError 

Source
pub enum AnalysisError {
    CriticalEdge {
        from: BlockIx,
        to: BlockIx,
    },
    EntryLiveinValues(Vec<Reg>),
    IllegalRealReg(RealReg),
    UnreachableBlocks,
    ImplementationLimitsExceeded,
    LsraCriticalEdge {
        block: BlockIx,
        inst: InstIx,
    },
}

Variants§

§

CriticalEdge

A critical edge from “from” to “to” has been found, and should have been removed by the caller in the first place.

Fields

§from: BlockIx
§

EntryLiveinValues(Vec<Reg>)

Some values in the entry block are live in to the function, but are not declared as such.

§

IllegalRealReg(RealReg)

The incoming code has an explicit or implicit mention (use, def or mod) of a real register, which either (1) isn’t listed in the universe at all, or (2) is one of the suggested_scratch registers in the universe. (1) isn’t allowed because the client must mention all real registers in the universe. (2) isn’t allowed because the client promises to us that the suggested_scratch registers really are completely unused in the incoming code, so that the allocator can use them at literally any point it wants.

§

UnreachableBlocks

At least one block is dead.

§

ImplementationLimitsExceeded

Implementation limits exceeded. The incoming function is too big. It may contain at most 1 million basic blocks and 16 million instructions.

§

LsraCriticalEdge

Linear scan requires that if a block ends with a control flow instruction that has at least one register mention (use, mod or def), then the successor blocks must have a single predecessor.

In practice, this means that users should consider associated edges to be “critical” and split them (and maybe remove dead blocks afterwards).

For details, see the comment in linear_scan::analysis generating this error.

Fields

§block: BlockIx
§inst: InstIx

Trait Implementations§

Source§

impl Clone for AnalysisError

Source§

fn clone(&self) -> AnalysisError

Returns a duplicate 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 AnalysisError

Source§

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

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

impl ToString for AnalysisError

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. 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,

Source§

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, U> TryFrom<U> for T
where U: Into<T>,

Source§

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>,

Source§

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.