Module rustc_mir::transform [−][src]
🔬 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?
Re-exports
use borrow_check::nll::type_check; |
use build; |
use rustc::hir::def_id::CrateNum; |
use rustc::hir::def_id::DefId; |
use rustc::hir::def_id::LOCAL_CRATE; |
use rustc::mir::Mir; |
use rustc::mir::Promoted; |
use rustc::ty::TyCtxt; |
use rustc::ty::maps::Providers; |
use rustc::ty::steal::Steal; |
use rustc::hir; |
use rustc::hir::intravisit; |
use rustc::hir::intravisit::Visitor; |
use rustc::hir::intravisit::NestedVisitorMap; |
use rustc::util::nodemap::DefIdSet; |
use rustc_data_structures::sync::Lrc; |
use std::borrow::Cow; |
use syntax::ast; |
use syntax_pos::Span; |
Modules
add_call_guards |
[ Experimental ]
|
add_moves_for_packed_drops |
[ Experimental ]
|
add_validation |
[ Experimental ] This pass adds validation calls (AcquireValid, ReleaseValid) where appropriate. It has to be run really early, before transformations like inlining, because introducing these calls adds UB -- so, conceptually, this pass is actually part of MIR building, and only after this pass we think of the program has having the normal MIR semantics. |
check_unsafety |
[ Experimental ]
|
cleanup_post_borrowck |
[ Experimental ] This module provides two passes: |
const_prop |
[ Experimental ] Propagates constants for early reporting of statically known assertion failures |
copy_prop |
[ Experimental ] Trivial copy propagation pass. |
deaggregator |
[ Experimental ]
|
dump_mir |
[ Experimental ] This pass just dumps MIR at a specified point. |
elaborate_drops |
[ Experimental ]
|
erase_regions |
[ Experimental ] This pass erases all early-bound regions from the types occurring in the MIR. We want to do this once just before trans, so trans does not have to take care erasing regions all over the place. NOTE: We do NOT erase regions of statements that are relevant for "types-as-contracts"-validation, namely, AcquireValid, ReleaseValid, and EndRegion. |
generator |
[ Experimental ] This is the implementation of the pass which transforms generators into state machines. |
inline |
[ Experimental ] Inlining pass for MIR functions |
instcombine |
[ Experimental ] Performs various peephole optimizations. |
lower_128bit |
[ Experimental ] Replaces 128-bit operators with lang item calls |
no_landing_pads |
[ Experimental ] This pass removes the unwind branch of all the terminators when the no-landing-pads option is specified. |
promote_consts |
[ Experimental ] A pass that promotes borrows of constant rvalues. |
qualify_consts |
[ Experimental ] A pass that qualifies constness of temporaries in constants, static initializers and functions and also drives promotion. |
remove_noop_landing_pads |
[ Experimental ]
|
rustc_peek |
[ Experimental ]
|
simplify |
[ Experimental ] A number of passes which remove various redundancies in the CFG. |
simplify_branches |
[ Experimental ] A pass that simplifies branches when their condition is known. |
uniform_array_move_out |
[ Experimental ]
|
Structs
MirSource |
[ Experimental ] Where a specific Mir comes from. |
Traits
MirPass |
[ Experimental ] A streamlined trait that you can implement to create a pass; the
pass will be named after the type, and it will consist of a main
loop that goes over each available MIR and applies |
Functions
default_name |
[ Experimental ] Generates a default name for the pass based on the name of the
type |
is_mir_available |
[ Experimental ]
|
mir_built |
[ Experimental ]
|
mir_const |
[ Experimental ]
|
mir_keys |
[ Experimental ] Finds the full set of def-ids within the current crate that have MIR associated with them. |
mir_validated |
[ Experimental ]
|
optimized_mir |
[ Experimental ]
|
provide |
[ Experimental ]
|