@@ -9,6 +9,7 @@ pub(crate) fn maybe_create_entry_wrapper(
99 tcx : TyCtxt < ' _ > ,
1010 module : & mut Module < impl Backend + ' static > ,
1111 unwind_context : & mut UnwindContext < ' _ > ,
12+ use_jit : bool ,
1213) {
1314 let ( main_def_id, use_start_lang_item) = match tcx. entry_fn ( LOCAL_CRATE ) {
1415 Some ( ( def_id, entry_ty) ) => (
@@ -32,6 +33,7 @@ pub(crate) fn maybe_create_entry_wrapper(
3233 unwind_context,
3334 main_def_id,
3435 use_start_lang_item,
36+ use_jit,
3537 ) ;
3638
3739 fn create_entry_fn (
@@ -40,6 +42,7 @@ pub(crate) fn maybe_create_entry_wrapper(
4042 unwind_context : & mut UnwindContext < ' _ > ,
4143 rust_main_def_id : DefId ,
4244 use_start_lang_item : bool ,
45+ use_jit : bool ,
4346 ) {
4447 let main_ret_ty = tcx. fn_sig ( rust_main_def_id) . output ( ) ;
4548 // Given that `main()` has no arguments,
@@ -83,7 +86,7 @@ pub(crate) fn maybe_create_entry_wrapper(
8386 let arg_argc = bcx. append_block_param ( block, m. target_config ( ) . pointer_type ( ) ) ;
8487 let arg_argv = bcx. append_block_param ( block, m. target_config ( ) . pointer_type ( ) ) ;
8588
86- crate :: atomic_shim:: init_global_lock ( m, & mut bcx) ;
89+ crate :: atomic_shim:: init_global_lock ( m, & mut bcx, use_jit ) ;
8790
8891 let main_func_ref = m. declare_func_in_func ( main_func_id, & mut bcx. func ) ;
8992
0 commit comments