@@ -6,7 +6,7 @@ use rustc_codegen_ssa::back::write::{BitcodeSection, CodegenContext, EmitObj, Mo
6
6
use rustc_codegen_ssa:: { CompiledModule , ModuleCodegen } ;
7
7
use rustc_errors:: DiagCtxtHandle ;
8
8
use rustc_fs_util:: link_or_copy;
9
- use rustc_session:: config:: { Lto , OutputType } ;
9
+ use rustc_session:: config:: OutputType ;
10
10
use rustc_span:: fatal_error:: FatalError ;
11
11
use rustc_target:: spec:: SplitDebuginfo ;
12
12
@@ -96,7 +96,6 @@ pub(crate) unsafe fn codegen(
96
96
if config. emit_obj == EmitObj :: ObjectCode ( BitcodeSection :: Full ) {
97
97
// TODO: we might want to emit to emit an error here, saying to set the
98
98
// environment variable EMBED_LTO_BITCODE.
99
- unreachable ! ( ) ;
100
99
let _timer = cgcx
101
100
. prof
102
101
. generic_activity_with_arg ( "GCC_module_codegen_embed_bitcode" , & * module. name ) ;
@@ -233,16 +232,11 @@ pub(crate) fn save_temp_bitcode(
233
232
234
233
fn create_msvc_imps < ' gcc > (
235
234
cgcx : & CodegenContext < GccCodegenBackend > ,
236
- context : & Context < ' gcc > ,
235
+ _context : & Context < ' gcc > ,
237
236
) {
238
237
if !cgcx. msvc_imps_needed {
239
238
return ;
240
239
}
241
- // The x86 ABI seems to require that leading underscores are added to symbol
242
- // names, so we need an extra underscore on x86. There's also a leading
243
- // '\x01' here which disables LLVM's symbol mangling (e.g., no extra
244
- // underscores added in front).
245
- let prefix = if cgcx. target_arch == "x86" { "\x01 __imp__" } else { "\x01 __imp_" } ;
246
240
247
241
/*unsafe {
248
242
let ptr_ty = Type::ptr_llcx(llcx);
0 commit comments