create parallel tasks extension (#5249)

This commit is contained in:
Nikolay Volf authored and GitHub committed 2020-03-16 16:30:39 +01:00
1 parent 418b7b8bc2
commit 372745705d
25 files changed
+189 -26

No files matched your search

@@ -23,6 +23,7 @@ use sc_service::{Configuration, ChainSpec};
use sc_executor::{NativeExecutor, NativeExecutionDispatch};
use codec::{Encode, Decode};
use frame_benchmarking::BenchmarkResults;
use sp_core::tasks;
/// The `benchmark` command used to benchmark FRAME Pallets.
#[derive(Debug, structopt::StructOpt, Clone)]
@@ -121,6 +122,7 @@ impl BenchmarkCmd {
).encode(),
Default::default(),
&sp_state_machine::backend::BackendRuntimeCode::new(&state).runtime_code()?,
tasks::executor(),
)
.execute(strategy.into())
.map_err(|e| format!("Error executing runtime benchmark: {:?}", e))?;