mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 17:31:05 +00:00
Add benchmarking to rococo; Remove weights from runtime_parachains (#3914)
* Add benchmarking to rococo; Remove weights from runtime_parachains * cargo run --quiet --release --features runtime-benchmarks -- benchmark --chain=rococo-dev --steps=50 --repeat=20 --pallet=runtime_parachains::paras --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./runtime/rococo/src/weights/runtime_parachains_paras.rs --header=./file_header.txt * Impl TestWeightInfo for Paras and Configuration * fmt * cargo run --quiet --release --features runtime-benchmarks -- benchmark --chain=rococo-dev --steps=50 --repeat=20 --pallet=runtime_parachains::configuration --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./runtime/rococo/src/weights/runtime_parachains_configuration.rs --header=./file_header.txt * Fix CI complaint: error: unused variable: `c` * polkadot-runtime-common & polkadot-test-runtime compile * xcm-simulator compile * change TestWeightInfo to max_block * cargo run --quiet --release --features runtime-benchmarks -- benchmark --chain=rococo-dev --steps=50 --repeat=20 --pallet=runtime_parachains::paras --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./runtime/rococo/src/weights/runtime_parachains_paras.rs --header=./file_header.txt * ordering * cargo run --quiet --release --features runtime-benchmarks -- benchmark --chain=rococo-dev --steps=50 --repeat=20 --pallet=runtime_parachains::paras --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --output=./runtime/rococo/src/weights/runtime_parachains_paras.rs --header=./file_header.txt * Replace max_block with Weight::MAX Co-authored-by: Parity Bot <admin@parity.io> Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>
This commit is contained in:
@@ -578,7 +578,7 @@ impl pallet_authorship::Config for Runtime {
|
||||
impl parachains_origin::Config for Runtime {}
|
||||
|
||||
impl parachains_configuration::Config for Runtime {
|
||||
type WeightInfo = parachains_configuration::weights::WeightInfo<Runtime>;
|
||||
type WeightInfo = weights::runtime_parachains_configuration::WeightInfo<Runtime>;
|
||||
}
|
||||
|
||||
impl parachains_shared::Config for Runtime {}
|
||||
@@ -599,7 +599,7 @@ impl parachains_inclusion::Config for Runtime {
|
||||
impl parachains_paras::Config for Runtime {
|
||||
type Origin = Origin;
|
||||
type Event = Event;
|
||||
type WeightInfo = parachains_paras::weights::WeightInfo<Runtime>;
|
||||
type WeightInfo = weights::runtime_parachains_paras::WeightInfo<Runtime>;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
@@ -1599,7 +1599,9 @@ sp_api::impl_runtime_apis! {
|
||||
|
||||
let mut list = Vec::<BenchmarkList>::new();
|
||||
|
||||
list_benchmark!(list, extra, runtime_parachains::configuration, Configuration);
|
||||
list_benchmark!(list, extra, runtime_parachains::disputes, ParasDisputes);
|
||||
list_benchmark!(list, extra, runtime_parachains::paras, Paras);
|
||||
|
||||
let storage_info = AllPalletsWithSystem::storage_info();
|
||||
|
||||
@@ -1629,7 +1631,9 @@ sp_api::impl_runtime_apis! {
|
||||
];
|
||||
let params = (&config, &whitelist);
|
||||
|
||||
add_benchmark!(params, batches, runtime_parachains::configuration, Configuration);
|
||||
add_benchmark!(params, batches, runtime_parachains::disputes, ParasDisputes);
|
||||
add_benchmark!(params, batches, runtime_parachains::paras, Paras);
|
||||
|
||||
if batches.is_empty() { return Err("Benchmark not found for this pallet.".into()) }
|
||||
Ok(batches)
|
||||
|
||||
Reference in New Issue
Block a user