Miri is really slow

This commit is contained in:
Ralf Jung 2019-08-09 11:18:17 +02:00
parent c5687e3940
commit 29ca428ffa
3 changed files with 5 additions and 4 deletions

View File

@ -77,6 +77,7 @@ fn infinity() {
fn zero() {
test_literal!(0.0);
test_literal!(1e-325);
#[cfg(not(miri))] // Miri is too slow
test_literal!(1e-326);
#[cfg(not(miri))] // Miri is too slow
test_literal!(1e-500);

View File

@ -45,7 +45,7 @@ fn test_estimate_scaling_factor() {
#[cfg(not(miri))] // Miri is too slow
let iter = -1074..972;
#[cfg(miri)]
let iter = (-1074..972).step_by(11);
let iter = (-1074..972).step_by(37);
for i in iter {
let expected = super::ldexp_f64(1.0, i).log10().ceil();

View File

@ -112,7 +112,7 @@ fn shortest_random_equivalence_test() {
#[cfg(not(miri))] // Miri is too slow
const N: usize = 10_000;
#[cfg(miri)]
const N: usize = 20;
const N: usize = 10;
f64_random_equivalence_test(format_shortest_opt, fallback, MAX_SIG_DIGITS, N);
f32_random_equivalence_test(format_shortest_opt, fallback, MAX_SIG_DIGITS, N);
@ -146,7 +146,7 @@ fn exact_f32_random_equivalence_test() {
#[cfg(not(miri))] // Miri is too slow
const N: usize = 1_000;
#[cfg(miri)]
const N: usize = 10;
const N: usize = 3;
for k in 1..21 {
f32_random_equivalence_test(|d, buf| format_exact_opt(d, buf, i16::MIN),
@ -160,7 +160,7 @@ fn exact_f64_random_equivalence_test() {
#[cfg(not(miri))] // Miri is too slow
const N: usize = 1_000;
#[cfg(miri)]
const N: usize = 5;
const N: usize = 3;
for k in 1..21 {
f64_random_equivalence_test(|d, buf| format_exact_opt(d, buf, i16::MIN),