This repository has been archived by the owner on Nov 15, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Don't merge this Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * cargo run --quiet --profile=production --features=runtime-benchmarks -- benchmark --chain=polkadot-dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/polkadot/src/weights/ * cargo run --quiet --profile=production --features=runtime-benchmarks -- benchmark --chain=kusama-dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/kusama/src/weights/ * Add baseline benches Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * Revert "Don't merge this" This reverts commit d0fcc4f. * cargo run --quiet --profile=production --features=runtime-benchmarks -- benchmark --chain=kusama-dev --steps=50 --repeat=20 --pallet=frame_benchmarking::baseline --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/kusama/src/weights/frame_benchmarking_baseline.rs * cargo run --quiet --profile=production --features=runtime-benchmarks -- benchmark --chain=polkadot-dev --steps=50 --repeat=20 --pallet=frame_benchmarking::baseline --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/polkadot/src/weights/frame_benchmarking_baseline.rs * Add weight modules Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * Apply suggestions from code review Co-authored-by: Parity Bot <admin@parity.io> Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
- Loading branch information
1 parent
1c2a0e2
commit 594e3b9
Showing
6 changed files
with
210 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
// Copyright 2017-2021 Parity Technologies (UK) Ltd. | ||
// This file is part of Polkadot. | ||
|
||
// Polkadot is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
|
||
// Polkadot is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
|
||
// You should have received a copy of the GNU General Public License | ||
// along with Polkadot. If not, see <http://www.gnu.org/licenses/>. | ||
//! Autogenerated weights for `frame_benchmarking::baseline` | ||
//! | ||
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev | ||
//! DATE: 2022-01-28, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` | ||
//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 | ||
|
||
// Executed Command: | ||
// target/production/polkadot | ||
// benchmark | ||
// --chain=kusama-dev | ||
// --steps=50 | ||
// --repeat=20 | ||
// --pallet=frame_benchmarking::baseline | ||
// --extrinsic=* | ||
// --execution=wasm | ||
// --wasm-execution=compiled | ||
// --heap-pages=4096 | ||
// --header=./file_header.txt | ||
// --output=./runtime/kusama/src/weights/frame_benchmarking_baseline.rs | ||
|
||
#![cfg_attr(rustfmt, rustfmt_skip)] | ||
#![allow(unused_parens)] | ||
#![allow(unused_imports)] | ||
|
||
use frame_support::{traits::Get, weights::Weight}; | ||
use sp_std::marker::PhantomData; | ||
|
||
/// Weight functions for `frame_benchmarking::baseline`. | ||
pub struct WeightInfo<T>(PhantomData<T>); | ||
impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for WeightInfo<T> { | ||
fn addition(_i: u32, ) -> Weight { | ||
(128_000 as Weight) | ||
} | ||
fn subtraction(_i: u32, ) -> Weight { | ||
(128_000 as Weight) | ||
} | ||
fn multiplication(_i: u32, ) -> Weight { | ||
(133_000 as Weight) | ||
} | ||
fn division(_i: u32, ) -> Weight { | ||
(147_000 as Weight) | ||
} | ||
fn hashing(i: u32, ) -> Weight { | ||
(19_711_716_000 as Weight) | ||
// Standard Error: 116_000 | ||
.saturating_add((320_000 as Weight).saturating_mul(i as Weight)) | ||
} | ||
fn sr25519_verification(i: u32, ) -> Weight { | ||
(0 as Weight) | ||
// Standard Error: 14_000 | ||
.saturating_add((47_625_000 as Weight).saturating_mul(i as Weight)) | ||
} | ||
// Storage: Skipped Metadata (r:0 w:0) | ||
fn storage_read(i: u32, ) -> Weight { | ||
(0 as Weight) | ||
// Standard Error: 3_000 | ||
.saturating_add((2_027_000 as Weight).saturating_mul(i as Weight)) | ||
.saturating_add(T::DbWeight::get().reads((1 as Weight).saturating_mul(i as Weight))) | ||
} | ||
// Storage: Skipped Metadata (r:0 w:0) | ||
fn storage_write(i: u32, ) -> Weight { | ||
(0 as Weight) | ||
// Standard Error: 0 | ||
.saturating_add((329_000 as Weight).saturating_mul(i as Weight)) | ||
.saturating_add(T::DbWeight::get().writes((1 as Weight).saturating_mul(i as Weight))) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
82 changes: 82 additions & 0 deletions
82
runtime/polkadot/src/weights/frame_benchmarking_baseline.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
// Copyright 2017-2021 Parity Technologies (UK) Ltd. | ||
// This file is part of Polkadot. | ||
|
||
// Polkadot is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
|
||
// Polkadot is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
|
||
// You should have received a copy of the GNU General Public License | ||
// along with Polkadot. If not, see <http://www.gnu.org/licenses/>. | ||
//! Autogenerated weights for `frame_benchmarking::baseline` | ||
//! | ||
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev | ||
//! DATE: 2022-01-29, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` | ||
//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 | ||
|
||
// Executed Command: | ||
// target/production/polkadot | ||
// benchmark | ||
// --chain=polkadot-dev | ||
// --steps=50 | ||
// --repeat=20 | ||
// --pallet=frame_benchmarking::baseline | ||
// --extrinsic=* | ||
// --execution=wasm | ||
// --wasm-execution=compiled | ||
// --heap-pages=4096 | ||
// --header=./file_header.txt | ||
// --output=./runtime/polkadot/src/weights/frame_benchmarking_baseline.rs | ||
|
||
#![cfg_attr(rustfmt, rustfmt_skip)] | ||
#![allow(unused_parens)] | ||
#![allow(unused_imports)] | ||
|
||
use frame_support::{traits::Get, weights::Weight}; | ||
use sp_std::marker::PhantomData; | ||
|
||
/// Weight functions for `frame_benchmarking::baseline`. | ||
pub struct WeightInfo<T>(PhantomData<T>); | ||
impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for WeightInfo<T> { | ||
fn addition(_i: u32, ) -> Weight { | ||
(112_000 as Weight) | ||
} | ||
fn subtraction(_i: u32, ) -> Weight { | ||
(112_000 as Weight) | ||
} | ||
fn multiplication(_i: u32, ) -> Weight { | ||
(112_000 as Weight) | ||
} | ||
fn division(_i: u32, ) -> Weight { | ||
(111_000 as Weight) | ||
} | ||
fn hashing(i: u32, ) -> Weight { | ||
(19_613_380_000 as Weight) | ||
// Standard Error: 88_000 | ||
.saturating_add((203_000 as Weight).saturating_mul(i as Weight)) | ||
} | ||
fn sr25519_verification(i: u32, ) -> Weight { | ||
(0 as Weight) | ||
// Standard Error: 15_000 | ||
.saturating_add((47_554_000 as Weight).saturating_mul(i as Weight)) | ||
} | ||
// Storage: Skipped Metadata (r:0 w:0) | ||
fn storage_read(i: u32, ) -> Weight { | ||
(0 as Weight) | ||
// Standard Error: 3_000 | ||
.saturating_add((1_973_000 as Weight).saturating_mul(i as Weight)) | ||
.saturating_add(T::DbWeight::get().reads((1 as Weight).saturating_mul(i as Weight))) | ||
} | ||
// Storage: Skipped Metadata (r:0 w:0) | ||
fn storage_write(i: u32, ) -> Weight { | ||
(0 as Weight) | ||
// Standard Error: 0 | ||
.saturating_add((323_000 as Weight).saturating_mul(i as Weight)) | ||
.saturating_add(T::DbWeight::get().writes((1 as Weight).saturating_mul(i as Weight))) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters