fix benchmark

This commit is contained in:
Akhil Velagapudi 2020-04-25 20:16:56 -07:00
parent ffdef08163
commit 1b1cdc8c92
1 changed files with 2 additions and 3 deletions

View File

@ -1,5 +1,5 @@
use criterion::*;
use futures::{future, StreamExt};
use futures::StreamExt;
use rand::prelude::*;
use ring::{
digest,
@ -23,9 +23,8 @@ pub fn bench(c: &mut Criterion) {
b.iter(|| {
smol::run(
futures::stream::iter(0..NUM_BATCHES).for_each_concurrent(None, |_| {
smol::Task::blocking({
smol::Task::blocking(async {
do_work();
future::ready(())
})
}),
);