Skip to content

Commit d1be246

Browse files
committed
more bootstrapping
1 parent c7e595a commit d1be246

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

builtins-test/src/lib.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,12 +415,19 @@ mod bootstrap {
415415
compiler_builtins::float::extend::__extendhfsf2(a)
416416
}
417417

418-
#[cfg(f16_enabled)]
419418
#[cfg(f128_enabled)]
420419
#[cfg(target_arch = "x86")]
421420
#[linkage = "weak"]
422421
#[unsafe(no_mangle)]
423422
pub extern "C" fn __extenddftf2(a: f64) -> f128 {
424423
compiler_builtins::float::extend::__extenddftf2(a)
425424
}
425+
426+
#[cfg(f128_enabled)]
427+
#[cfg(target_arch = "x86")]
428+
#[linkage = "weak"]
429+
#[unsafe(no_mangle)]
430+
pub extern "C" fn __floattitf(i: i128) -> f128 {
431+
compiler_builtins::float::conv::__floattitf(a)
432+
}
426433
}

libm/configure.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ impl Config {
3434
.collect();
3535

3636
let target_arch = env::var("CARGO_CFG_TARGET_ARCH").unwrap();
37+
// Symbols are missing so we can't test until they get to nightly
3738
let bootstrapping_f128 = target_arch == "x86";
3839

3940
Self {
@@ -51,10 +52,10 @@ impl Config {
5152
target_features,
5253
// Note that these are unstable options, so only show up with the nightly compiler or
5354
// with `RUSTC_BOOTSTRAP=1` (which is required to use the types anyway).
54-
// reliable_f128: env::var_os("CARGO_CFG_TARGET_HAS_RELIABLE_F128").is_some(),
5555
// reliable_f16: env::var_os("CARGO_CFG_TARGET_HAS_RELIABLE_F16").is_some(),
5656
reliable_f16: true,
57-
reliable_f128: bootstrapping_f128,
57+
reliable_f128: env::var_os("CARGO_CFG_TARGET_HAS_RELIABLE_F128").is_some()
58+
&& !bootstrapping_f128,
5859
}
5960
}
6061
}

0 commit comments

Comments
 (0)