Drop unused jump_counter

This commit is contained in:
Richard Feldman 2020-08-08 19:52:31 -04:00
parent 5c6939e7ec
commit 3fe2a4e3fd
7 changed files with 0 additions and 10 deletions

View file

@ -258,7 +258,6 @@ pub fn gen(src: &[u8], target: Triple, opt_level: OptLevel) -> Result<(String, S
problems: &mut mono_problems,
home,
ident_ids: &mut ident_ids,
jump_counter: arena.alloc(0),
};
let main_body = roc_mono::expr::Expr::new(&mut mono_env, loc_expr.value, &mut procs);

View file

@ -169,7 +169,6 @@ pub fn gen(
problems: &mut mono_problems,
home,
ident_ids: &mut ident_ids,
jump_counter: arena.alloc(0),
};
// Add modules' decls to Procs

View file

@ -70,7 +70,6 @@ macro_rules! assert_llvm_evals_to {
problems: &mut mono_problems,
home,
ident_ids: &mut ident_ids,
jump_counter: arena.alloc(0),
};
let main_body = Expr::new(&mut mono_env, loc_expr.value, &mut procs);
@ -255,7 +254,6 @@ macro_rules! assert_opt_evals_to {
problems: &mut mono_problems,
home,
ident_ids: &mut ident_ids,
jump_counter: arena.alloc(0),
};
let main_body = Expr::new(&mut mono_env, loc_expr.value, &mut procs);

View file

@ -910,9 +910,6 @@ pub fn optimize_when<'a>(
&jumps,
);
// increase the jump counter by the number of jumps in this branching structure
*env.jump_counter += jumps.len() as u64;
Expr::Store(stores, env.arena.alloc(expr))
}

View file

@ -252,7 +252,6 @@ pub struct Env<'a, 'i> {
pub problems: &'i mut std::vec::Vec<MonoProblem>,
pub home: ModuleId,
pub ident_ids: &'i mut IdentIds,
pub jump_counter: &'a mut u64,
}
impl<'a, 'i> Env<'a, 'i> {

View file

@ -58,7 +58,6 @@ mod test_mono {
problems: &mut mono_problems,
home,
ident_ids: &mut ident_ids,
jump_counter: arena.alloc(0),
};
let mono_expr = Expr::new(&mut mono_env, loc_expr.value, &mut procs);
let procs =

View file

@ -93,7 +93,6 @@ mod test_reporting {
problems: &mut mono_problems,
home,
ident_ids: &mut ident_ids,
jump_counter: arena.alloc(0),
};
let _mono_expr = Expr::new(&mut mono_env, loc_expr.value, &mut procs);
}