Skip to content

Commit 48a17a5

Browse files
committed
Use criterion 0.7
1 parent 2f27ec0 commit 48a17a5

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ futures-lite = { version = "2.0.0", default-features = false, features = ["std"]
3636
async-channel = "2.0.0"
3737
async-io = "2.1.0"
3838
async-lock = "3.0.0"
39-
criterion = { version = "0.6", default-features = false, features = ["cargo_bench_support"] }
39+
criterion = { version = "0.7", default-features = false, features = ["cargo_bench_support"] }
4040
easy-parallel = "3.1.0"
4141
fastrand = "2.0.0"
4242
futures-lite = "2.0.0"

benches/executor.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -462,7 +462,7 @@ fn running_benches(c: &mut Criterion) {
462462
let (resp_send, resp_recv) =
463463
async_channel::bounded(1);
464464
db_send.send(resp_send).await.unwrap();
465-
core::hint::black_box(
465+
black_box(
466466
resp_recv.recv().await.unwrap(),
467467
);
468468
}

benches/local_executor.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
use std::mem;
2+
use std::hint::black_box;
23

34
use async_executor::{Executor, LocalExecutor, StaticLocalExecutor};
45
use criterion::{criterion_group, criterion_main, Criterion};
@@ -320,7 +321,7 @@ fn running_benches(c: &mut Criterion) {
320321
for _ in 0..web_rng.usize(STEPS / 2..STEPS) {
321322
let (resp_send, resp_recv) = async_channel::bounded(1);
322323
db_send.send(resp_send).await.unwrap();
323-
core::hint::black_box(resp_recv.recv().await.unwrap());
324+
black_box(resp_recv.recv().await.unwrap());
324325
}
325326

326327
// Send the data back...
@@ -393,7 +394,7 @@ fn running_benches(c: &mut Criterion) {
393394
for _ in 0..web_rng.usize(STEPS / 2..STEPS) {
394395
let (resp_send, resp_recv) = async_channel::bounded(1);
395396
db_send.send(resp_send).await.unwrap();
396-
core::hint::black_box(resp_recv.recv().await.unwrap());
397+
black_box(resp_recv.recv().await.unwrap());
397398
}
398399

399400
// Send the data back...

0 commit comments

Comments
 (0)