Skip to content

Commit

Permalink
dont call mir.post_mono_checks in codegen
Browse files Browse the repository at this point in the history
  • Loading branch information
RalfJung committed Sep 29, 2023
1 parent 56ada88 commit 11297c8
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions compiler/rustc_codegen_ssa/src/mir/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -211,17 +211,6 @@ pub fn codegen_mir<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(

fx.per_local_var_debug_info = fx.compute_per_local_var_debug_info(&mut start_bx);

// Rust post-monomorphization checks; we later rely on them.
if let Err(err) =
mir.post_mono_checks(cx.tcx(), ty::ParamEnv::reveal_all(), |c| Ok(fx.monomorphize(c)))
{
err.emit_err(cx.tcx());
// This IR shouldn't ever be emitted, but let's try to guard against any of this code
// ever running.
start_bx.abort();
return;
}

let memory_locals = analyze::non_ssa_locals(&fx);

// Allocate variable and temp allocas
Expand Down

0 comments on commit 11297c8

Please sign in to comment.