c66e0c8726
Clarify which kinds of MIR are allowed during which phases. This enhances documentation with these details and extends the validator to check these requirements more thoroughly. Most of these conditions were already being checked. There was also some disagreement between the `MirPhase` docs and validator as to what it meant for the `body.phase` field to have a certain value. This PR resolves those disagreements in favor of the `MirPhase` docs (which is what the pass manager implemented), adjusting the validator accordingly. The result is now that the `DropLowering` phase begins with the end of the elaborate drops pass, and lasts until the beginning of the generator lowring pass. This doesn't feel entirely natural to me, but as long as it's documented accurately it should be ok. r? rust-lang/mir-opt |
||
---|---|---|
.. | ||
coverage | ||
inline | ||
abort_unwinding_calls.rs | ||
add_call_guards.rs | ||
add_moves_for_packed_drops.rs | ||
add_retag.rs | ||
check_const_item_mutation.rs | ||
check_packed_ref.rs | ||
check_unsafety.rs | ||
cleanup_post_borrowck.rs | ||
const_debuginfo.rs | ||
const_goto.rs | ||
const_prop_lint.rs | ||
const_prop.rs | ||
deaggregator.rs | ||
deduplicate_blocks.rs | ||
dest_prop.rs | ||
dump_mir.rs | ||
early_otherwise_branch.rs | ||
elaborate_drops.rs | ||
function_item_references.rs | ||
generator.rs | ||
inline.rs | ||
instcombine.rs | ||
lib.rs | ||
lower_intrinsics.rs | ||
lower_slice_len.rs | ||
marker.rs | ||
match_branches.rs | ||
multiple_return_terminators.rs | ||
normalize_array_len.rs | ||
nrvo.rs | ||
pass_manager.rs | ||
remove_false_edges.rs | ||
remove_noop_landing_pads.rs | ||
remove_storage_markers.rs | ||
remove_uninit_drops.rs | ||
remove_unneeded_drops.rs | ||
remove_zsts.rs | ||
required_consts.rs | ||
reveal_all.rs | ||
separate_const_switch.rs | ||
shim.rs | ||
simplify_branches.rs | ||
simplify_comparison_integral.rs | ||
simplify_try.rs | ||
simplify.rs | ||
uninhabited_enum_branching.rs | ||
unreachable_prop.rs |