use fast calling convention

This commit is contained in:
Folkert 2020-10-15 01:46:28 +02:00
parent 729e16cad9
commit 02a396d08a

View file

@ -322,6 +322,7 @@ pub fn construct_optimization_passes<'a>(
pmb.set_optimization_level(OptimizationLevel::None);
}
OptLevel::Optimize => {
pmb.set_optimization_level(OptimizationLevel::Aggressive);
// this threshold seems to do what we want
pmb.set_inliner_with_threshold(275);
@ -1165,6 +1166,8 @@ pub fn build_exp_expr<'a, 'ctx, 'env>(
env.builder
.build_call(*function_value, &[], "evaluate_top_level_thunk");
call.set_call_convention(FAST_CALL_CONV);
call.try_as_basic_value().left().unwrap()
}
None => {