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
Add benchmarking to rococo; Remove weights from runtime_parachains #3914
Merged
Merged
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
b1343de
Add benchmarking to rococo; Remove weights from runtime_parachains
emostov 1e8434c
Merge branch 'master' of https://github.com/paritytech/polkadot into …
288d43a
cargo run --quiet --release --features runtime-benchmarks -- benchmar…
2e7675b
Impl TestWeightInfo for Paras and Configuration
emostov f3bc1c5
Merge branch 'zeke-add-rococo-weights' of https://github.com/parityte…
emostov dab9ac4
fmt
emostov 3148c58
cargo run --quiet --release --features runtime-benchmarks -- benchmar…
9007d36
Fix CI complaint: error: unused variable: `c`
emostov fccf318
polkadot-runtime-common & polkadot-test-runtime compile
emostov 2c2e5f8
xcm-simulator compile
emostov 1f6923d
change TestWeightInfo to max_block
emostov 4413986
Merge branch 'master' of https://github.com/paritytech/polkadot into …
7dc8535
cargo run --quiet --release --features runtime-benchmarks -- benchmar…
ce4d8f5
Try merge origin master
emostov ee8d096
ordering
emostov cd36b05
cargo run --quiet --release --features runtime-benchmarks -- benchmar…
174cb8a
Replace max_block with Weight::MAX
KiChjang c00e371
Merge remote-tracking branch 'origin' into zeke-add-rococo-weights
KiChjang File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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
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
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 |
---|---|---|
@@ -1 +1,20 @@ | ||
// Copyright (C) 2020 Parity Technologies (UK) Ltd. | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
//! A list of the different weight modules for our runtime. | ||
|
||
pub mod runtime_parachains_configuration; | ||
pub mod runtime_parachains_disputes; | ||
pub mod runtime_parachains_paras; |
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 |
---|---|---|
@@ -1,28 +1,37 @@ | ||
// 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 `runtime_parachains::paras` | ||
//! | ||
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev | ||
//! DATE: 2021-09-21, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` | ||
//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 128 | ||
//! DATE: 2021-09-24, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` | ||
//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 128 | ||
|
||
// Executed Command: | ||
// ./target/release/polkadot | ||
// target/release/polkadot | ||
// benchmark | ||
// --chain | ||
// westend-dev | ||
// --chain=rococo-dev | ||
// --steps=50 | ||
// --repeat=20 | ||
// --pallet=runtime_parachains::paras | ||
// --extrinsic=* | ||
// --execution=wasm | ||
// --wasm-execution=compiled | ||
// --pallet | ||
// runtime_parachains::paras | ||
// --steps | ||
// 50 | ||
// --repeat | ||
// 20 | ||
// --raw | ||
// --extrinsic | ||
// * | ||
// --output | ||
// runtime/parachains/src/paras/weights.rs | ||
// --heap-pages=4096 | ||
// --output=./runtime/rococo/src/weights/runtime_parachains_paras.rs | ||
// --header=./file_header.txt | ||
|
||
|
||
#![cfg_attr(rustfmt, rustfmt_skip)] | ||
|
@@ -34,25 +43,25 @@ use sp_std::marker::PhantomData; | |
|
||
/// Weight functions for `runtime_parachains::paras`. | ||
pub struct WeightInfo<T>(PhantomData<T>); | ||
impl<T: frame_system::Config> super::WeightInfo for WeightInfo<T> { | ||
impl<T: frame_system::Config> runtime_parachains::paras::WeightInfo for WeightInfo<T> { | ||
// Storage: Paras CurrentCodeHash (r:1 w:1) | ||
// Storage: Paras CodeByHashRefs (r:1 w:1) | ||
// Storage: Paras PastCodeMeta (r:1 w:1) | ||
// Storage: Paras PastCodePruning (r:1 w:1) | ||
// Storage: Paras PastCodeHash (r:0 w:1) | ||
// Storage: Paras CodeByHash (r:0 w:1) | ||
fn force_set_current_code(c: u32, ) -> Weight { | ||
(14_669_000 as Weight) | ||
(0 as Weight) | ||
// Standard Error: 0 | ||
.saturating_add((3_000 as Weight).saturating_mul(c as Weight)) | ||
.saturating_add(T::DbWeight::get().reads(4 as Weight)) | ||
.saturating_add(T::DbWeight::get().writes(6 as Weight)) | ||
} | ||
// Storage: Paras Heads (r:0 w:1) | ||
fn force_set_current_head(s: u32, ) -> Weight { | ||
(0 as Weight) | ||
(18_653_000 as Weight) | ||
// Standard Error: 0 | ||
.saturating_add((2_000 as Weight).saturating_mul(s as Weight)) | ||
.saturating_add((1_000 as Weight).saturating_mul(s as Weight)) | ||
.saturating_add(T::DbWeight::get().writes(1 as Weight)) | ||
} | ||
// Storage: Configuration ActiveConfig (r:1 w:0) | ||
|
@@ -65,7 +74,7 @@ impl<T: frame_system::Config> super::WeightInfo for WeightInfo<T> { | |
// Storage: Paras FutureCodeHash (r:0 w:1) | ||
// Storage: Paras UpgradeRestrictionSignal (r:0 w:1) | ||
fn force_schedule_code_upgrade(c: u32, ) -> Weight { | ||
(37_383_000 as Weight) | ||
(0 as Weight) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is a particularly big change |
||
// Standard Error: 0 | ||
.saturating_add((3_000 as Weight).saturating_mul(c as Weight)) | ||
.saturating_add(T::DbWeight::get().reads(6 as Weight)) | ||
|
@@ -81,16 +90,16 @@ impl<T: frame_system::Config> super::WeightInfo for WeightInfo<T> { | |
// Storage: Paras PastCodeHash (r:0 w:1) | ||
// Storage: Paras UpgradeGoAheadSignal (r:0 w:1) | ||
fn force_note_new_head(s: u32, ) -> Weight { | ||
(60_855_000 as Weight) | ||
(69_515_000 as Weight) | ||
// Standard Error: 0 | ||
.saturating_add((2_000 as Weight).saturating_mul(s as Weight)) | ||
.saturating_add((1_000 as Weight).saturating_mul(s as Weight)) | ||
.saturating_add(T::DbWeight::get().reads(6 as Weight)) | ||
.saturating_add(T::DbWeight::get().writes(9 as Weight)) | ||
} | ||
// Storage: ParasShared CurrentSessionIndex (r:1 w:0) | ||
// Storage: Paras ActionsQueue (r:1 w:1) | ||
fn force_queue_action() -> Weight { | ||
(32_014_000 as Weight) | ||
(26_804_000 as Weight) | ||
.saturating_add(T::DbWeight::get().reads(2 as Weight)) | ||
.saturating_add(T::DbWeight::get().writes(1 as Weight)) | ||
} | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure whats up here