Struct rustc_mir::util::liveness::LivenessResult
[−]
[src]
pub struct LivenessResult {
pub mode: LivenessMode,
pub ins: IndexVec<BasicBlock, LocalSet>,
pub outs: IndexVec<BasicBlock, LocalSet>,
}🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
This gives the result of the liveness analysis at the boundary of
basic blocks. You can use simulate_block to obtain the
intra-block results.
Fields
mode: LivenessMode
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Liveness mode in use when these results were computed.
ins: IndexVec<BasicBlock, LocalSet>
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Live variables on entry to each basic block.
outs: IndexVec<BasicBlock, LocalSet>
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Live variables on exit to each basic block. This is equal to
the union of the ins for each successor.
Methods
impl LivenessResult[src]
impl LivenessResultpub fn simulate_block<'tcx, OP>(
&self,
mir: &Mir<'tcx>,
block: BasicBlock,
callback: OP
) where
OP: FnMut(Location, &LocalSet), [src]
pub fn simulate_block<'tcx, OP>(
&self,
mir: &Mir<'tcx>,
block: BasicBlock,
callback: OP
) where
OP: FnMut(Location, &LocalSet), 🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Walks backwards through the statements/terminator in the given
basic block block. At each point within block, invokes
the callback op with the current location and the set of
variables that are live on entry to that location.
Trait Implementations
Auto Trait Implementations
impl Send for LivenessResult
impl Send for LivenessResultimpl Sync for LivenessResult
impl Sync for LivenessResult