Skip to content

Commit

Permalink
speed up concurrent_insert_get_same_key under miri
Browse files Browse the repository at this point in the history
  • Loading branch information
ibraheemdev committed May 2, 2024
1 parent e7b5922 commit f71d77b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions crossbeam-skiplist/tests/map.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
use std::{iter, ops::Bound, sync::Barrier};
use std::iter;
use std::ops::Bound;
use std::sync::{Arc, Barrier};

use crossbeam_skiplist::SkipMap;
use crossbeam_utils::thread;
Expand Down Expand Up @@ -924,9 +926,8 @@ fn clear() {
// https://github.com/crossbeam-rs/crossbeam/issues/1023
#[test]
fn concurrent_insert_get_same_key() {
use std::sync::Arc;
let map: Arc<SkipMap<u32, ()>> = Arc::new(SkipMap::new());
let len = 10_0000;
let len = if cfg!(miri) { 100 } else { 10_000 };
let key = 0;
map.insert(0, ());

Expand Down

0 comments on commit f71d77b

Please sign in to comment.