Storage Layer for All FRAME Extrinsics (#11431)

* add new trait

* implement DispatchableWithStorageLayer

* at least one transactional

* all dispatch is at least transactional

* storage_layer api

* add test

* storage layer tests

* deprecate transactional tag

* i guess no reason to deprecate

* remove transactional from batch_all

* update tests

* extend trait

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_balances --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/balances/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_staking --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/staking/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* fix copy paste name

* cargo run --quiet --profile=production --features runtime-benchmarks --manifest-path bin/node/cli/Cargo.toml -- benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet=pallet_utility --extrinsic=* --execution=wasm --wasm-execution=compiled --output=./frame/utility/src/weights.rs --template=./.maintain/frame-weight-template.hbs

* Create run_all_benchmarks.sh

* uncomment build

* update number of steps and repeats

* add skip build

* Update run_all_benchmarks.sh

* Update run_all_benchmarks.sh

* new benchmarks

* Update frame/support/src/traits/dispatch.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Update frame/support/src/traits/dispatch.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Update frame/support/test/tests/storage_layers.rs

Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>

* Update frame/support/test/tests/storage_layers.rs

* weights

* Update dispatch.rs

* doc link

* decl_macro support

Co-authored-by: Parity Bot <admin@parity.io>
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
This commit is contained in:
Shawn Tabrizi
2022-05-26 15:28:32 -04:00
committed by GitHub
parent ea469886f8
commit 8e7adaf283
52 changed files with 1741 additions and 1355 deletions
+91 -91
View File
@@ -18,7 +18,7 @@
//! Autogenerated weights for pallet_democracy
//!
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
//! DATE: 2022-05-22, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]`
//! DATE: 2022-05-23, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]`
//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024
// Executed Command:
@@ -80,15 +80,15 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy Blacklist (r:1 w:0)
// Storage: Democracy DepositOf (r:0 w:1)
fn propose() -> Weight {
(43_581_000 as Weight)
(48_328_000 as Weight)
.saturating_add(T::DbWeight::get().reads(3 as Weight))
.saturating_add(T::DbWeight::get().writes(3 as Weight))
}
// Storage: Democracy DepositOf (r:1 w:1)
fn second(s: u32, ) -> Weight {
(26_887_000 as Weight)
(30_923_000 as Weight)
// Standard Error: 1_000
.saturating_add((134_000 as Weight).saturating_mul(s as Weight))
.saturating_add((142_000 as Weight).saturating_mul(s as Weight))
.saturating_add(T::DbWeight::get().reads(1 as Weight))
.saturating_add(T::DbWeight::get().writes(1 as Weight))
}
@@ -96,9 +96,9 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy VotingOf (r:1 w:1)
// Storage: Balances Locks (r:1 w:1)
fn vote_new(r: u32, ) -> Weight {
(35_520_000 as Weight)
// Standard Error: 2_000
.saturating_add((131_000 as Weight).saturating_mul(r as Weight))
(40_345_000 as Weight)
// Standard Error: 1_000
.saturating_add((140_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(3 as Weight))
.saturating_add(T::DbWeight::get().writes(3 as Weight))
}
@@ -106,16 +106,16 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy VotingOf (r:1 w:1)
// Storage: Balances Locks (r:1 w:1)
fn vote_existing(r: u32, ) -> Weight {
(34_793_000 as Weight)
(39_853_000 as Weight)
// Standard Error: 1_000
.saturating_add((138_000 as Weight).saturating_mul(r as Weight))
.saturating_add((150_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(3 as Weight))
.saturating_add(T::DbWeight::get().writes(3 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Democracy Cancellations (r:1 w:1)
fn emergency_cancel() -> Weight {
(15_401_000 as Weight)
(19_364_000 as Weight)
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(2 as Weight))
}
@@ -126,45 +126,45 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy DepositOf (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn blacklist(p: u32, ) -> Weight {
(51_233_000 as Weight)
// Standard Error: 3_000
.saturating_add((189_000 as Weight).saturating_mul(p as Weight))
(57_708_000 as Weight)
// Standard Error: 4_000
.saturating_add((192_000 as Weight).saturating_mul(p as Weight))
.saturating_add(T::DbWeight::get().reads(5 as Weight))
.saturating_add(T::DbWeight::get().writes(6 as Weight))
}
// Storage: Democracy NextExternal (r:1 w:1)
// Storage: Democracy Blacklist (r:1 w:0)
fn external_propose(v: u32, ) -> Weight {
(7_650_000 as Weight)
(10_714_000 as Weight)
// Standard Error: 0
.saturating_add((30_000 as Weight).saturating_mul(v as Weight))
.saturating_add((33_000 as Weight).saturating_mul(v as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(1 as Weight))
}
// Storage: Democracy NextExternal (r:0 w:1)
fn external_propose_majority() -> Weight {
(1_341_000 as Weight)
(3_697_000 as Weight)
.saturating_add(T::DbWeight::get().writes(1 as Weight))
}
// Storage: Democracy NextExternal (r:0 w:1)
fn external_propose_default() -> Weight {
(1_360_000 as Weight)
(3_831_000 as Weight)
.saturating_add(T::DbWeight::get().writes(1 as Weight))
}
// Storage: Democracy NextExternal (r:1 w:1)
// Storage: Democracy ReferendumCount (r:1 w:1)
// Storage: Democracy ReferendumInfoOf (r:0 w:1)
fn fast_track() -> Weight {
(16_021_000 as Weight)
(20_271_000 as Weight)
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(3 as Weight))
}
// Storage: Democracy NextExternal (r:1 w:1)
// Storage: Democracy Blacklist (r:1 w:1)
fn veto_external(v: u32, ) -> Weight {
(17_350_000 as Weight)
(21_319_000 as Weight)
// Standard Error: 0
.saturating_add((46_000 as Weight).saturating_mul(v as Weight))
.saturating_add((52_000 as Weight).saturating_mul(v as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(2 as Weight))
}
@@ -172,23 +172,23 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy DepositOf (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn cancel_proposal(p: u32, ) -> Weight {
(39_418_000 as Weight)
(43_960_000 as Weight)
// Standard Error: 2_000
.saturating_add((170_000 as Weight).saturating_mul(p as Weight))
.saturating_add((184_000 as Weight).saturating_mul(p as Weight))
.saturating_add(T::DbWeight::get().reads(3 as Weight))
.saturating_add(T::DbWeight::get().writes(3 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:0 w:1)
fn cancel_referendum() -> Weight {
(10_239_000 as Weight)
(13_475_000 as Weight)
.saturating_add(T::DbWeight::get().writes(1 as Weight))
}
// Storage: Scheduler Lookup (r:1 w:1)
// Storage: Scheduler Agenda (r:1 w:1)
fn cancel_queued(r: u32, ) -> Weight {
(20_483_000 as Weight)
(24_320_000 as Weight)
// Standard Error: 1_000
.saturating_add((565_000 as Weight).saturating_mul(r as Weight))
.saturating_add((560_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(2 as Weight))
}
@@ -196,9 +196,9 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy ReferendumCount (r:1 w:0)
// Storage: Democracy ReferendumInfoOf (r:1 w:0)
fn on_initialize_base(r: u32, ) -> Weight {
(3_871_000 as Weight)
(3_428_000 as Weight)
// Standard Error: 2_000
.saturating_add((3_038_000 as Weight).saturating_mul(r as Weight))
.saturating_add((3_171_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(T::DbWeight::get().writes(1 as Weight))
@@ -210,9 +210,9 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy PublicProps (r:1 w:0)
// Storage: Democracy ReferendumInfoOf (r:1 w:0)
fn on_initialize_base_with_launch_period(r: u32, ) -> Weight {
(7_597_000 as Weight)
(7_867_000 as Weight)
// Standard Error: 2_000
.saturating_add((3_046_000 as Weight).saturating_mul(r as Weight))
.saturating_add((3_177_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(5 as Weight))
.saturating_add(T::DbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(T::DbWeight::get().writes(1 as Weight))
@@ -221,9 +221,9 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Balances Locks (r:1 w:1)
fn delegate(r: u32, ) -> Weight {
(32_554_000 as Weight)
// Standard Error: 3_000
.saturating_add((3_903_000 as Weight).saturating_mul(r as Weight))
(37_902_000 as Weight)
// Standard Error: 4_000
.saturating_add((4_335_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(4 as Weight))
.saturating_add(T::DbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(T::DbWeight::get().writes(4 as Weight))
@@ -232,9 +232,9 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy VotingOf (r:2 w:2)
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
fn undelegate(r: u32, ) -> Weight {
(15_440_000 as Weight)
(21_272_000 as Weight)
// Standard Error: 3_000
.saturating_add((3_972_000 as Weight).saturating_mul(r as Weight))
.saturating_add((4_351_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(T::DbWeight::get().writes(2 as Weight))
@@ -242,12 +242,12 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
}
// Storage: Democracy PublicProps (r:0 w:1)
fn clear_public_proposals() -> Weight {
(1_662_000 as Weight)
(4_913_000 as Weight)
.saturating_add(T::DbWeight::get().writes(1 as Weight))
}
// Storage: Democracy Preimages (r:1 w:1)
fn note_preimage(b: u32, ) -> Weight {
(24_170_000 as Weight)
(27_986_000 as Weight)
// Standard Error: 0
.saturating_add((2_000 as Weight).saturating_mul(b as Weight))
.saturating_add(T::DbWeight::get().reads(1 as Weight))
@@ -255,7 +255,7 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
}
// Storage: Democracy Preimages (r:1 w:1)
fn note_imminent_preimage(b: u32, ) -> Weight {
(16_470_000 as Weight)
(20_058_000 as Weight)
// Standard Error: 0
.saturating_add((2_000 as Weight).saturating_mul(b as Weight))
.saturating_add(T::DbWeight::get().reads(1 as Weight))
@@ -264,7 +264,7 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Democracy Preimages (r:1 w:1)
// Storage: System Account (r:1 w:0)
fn reap_preimage(b: u32, ) -> Weight {
(24_547_000 as Weight)
(28_619_000 as Weight)
// Standard Error: 0
.saturating_add((1_000 as Weight).saturating_mul(b as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
@@ -274,9 +274,9 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Balances Locks (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn unlock_remove(r: u32, ) -> Weight {
(22_596_000 as Weight)
(26_619_000 as Weight)
// Standard Error: 1_000
.saturating_add((61_000 as Weight).saturating_mul(r as Weight))
.saturating_add((56_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(3 as Weight))
.saturating_add(T::DbWeight::get().writes(3 as Weight))
}
@@ -284,27 +284,27 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Storage: Balances Locks (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn unlock_set(r: u32, ) -> Weight {
(21_589_000 as Weight)
(25_373_000 as Weight)
// Standard Error: 1_000
.saturating_add((125_000 as Weight).saturating_mul(r as Weight))
.saturating_add((142_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(3 as Weight))
.saturating_add(T::DbWeight::get().writes(3 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Democracy VotingOf (r:1 w:1)
fn remove_vote(r: u32, ) -> Weight {
(12_120_000 as Weight)
(15_961_000 as Weight)
// Standard Error: 1_000
.saturating_add((106_000 as Weight).saturating_mul(r as Weight))
.saturating_add((115_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(2 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Democracy VotingOf (r:1 w:1)
fn remove_other_vote(r: u32, ) -> Weight {
(12_563_000 as Weight)
(15_992_000 as Weight)
// Standard Error: 1_000
.saturating_add((105_000 as Weight).saturating_mul(r as Weight))
.saturating_add((113_000 as Weight).saturating_mul(r as Weight))
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(2 as Weight))
}
@@ -317,15 +317,15 @@ impl WeightInfo for () {
// Storage: Democracy Blacklist (r:1 w:0)
// Storage: Democracy DepositOf (r:0 w:1)
fn propose() -> Weight {
(43_581_000 as Weight)
(48_328_000 as Weight)
.saturating_add(RocksDbWeight::get().reads(3 as Weight))
.saturating_add(RocksDbWeight::get().writes(3 as Weight))
}
// Storage: Democracy DepositOf (r:1 w:1)
fn second(s: u32, ) -> Weight {
(26_887_000 as Weight)
(30_923_000 as Weight)
// Standard Error: 1_000
.saturating_add((134_000 as Weight).saturating_mul(s as Weight))
.saturating_add((142_000 as Weight).saturating_mul(s as Weight))
.saturating_add(RocksDbWeight::get().reads(1 as Weight))
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
}
@@ -333,9 +333,9 @@ impl WeightInfo for () {
// Storage: Democracy VotingOf (r:1 w:1)
// Storage: Balances Locks (r:1 w:1)
fn vote_new(r: u32, ) -> Weight {
(35_520_000 as Weight)
// Standard Error: 2_000
.saturating_add((131_000 as Weight).saturating_mul(r as Weight))
(40_345_000 as Weight)
// Standard Error: 1_000
.saturating_add((140_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(3 as Weight))
.saturating_add(RocksDbWeight::get().writes(3 as Weight))
}
@@ -343,16 +343,16 @@ impl WeightInfo for () {
// Storage: Democracy VotingOf (r:1 w:1)
// Storage: Balances Locks (r:1 w:1)
fn vote_existing(r: u32, ) -> Weight {
(34_793_000 as Weight)
(39_853_000 as Weight)
// Standard Error: 1_000
.saturating_add((138_000 as Weight).saturating_mul(r as Weight))
.saturating_add((150_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(3 as Weight))
.saturating_add(RocksDbWeight::get().writes(3 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Democracy Cancellations (r:1 w:1)
fn emergency_cancel() -> Weight {
(15_401_000 as Weight)
(19_364_000 as Weight)
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(2 as Weight))
}
@@ -363,45 +363,45 @@ impl WeightInfo for () {
// Storage: Democracy DepositOf (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn blacklist(p: u32, ) -> Weight {
(51_233_000 as Weight)
// Standard Error: 3_000
.saturating_add((189_000 as Weight).saturating_mul(p as Weight))
(57_708_000 as Weight)
// Standard Error: 4_000
.saturating_add((192_000 as Weight).saturating_mul(p as Weight))
.saturating_add(RocksDbWeight::get().reads(5 as Weight))
.saturating_add(RocksDbWeight::get().writes(6 as Weight))
}
// Storage: Democracy NextExternal (r:1 w:1)
// Storage: Democracy Blacklist (r:1 w:0)
fn external_propose(v: u32, ) -> Weight {
(7_650_000 as Weight)
(10_714_000 as Weight)
// Standard Error: 0
.saturating_add((30_000 as Weight).saturating_mul(v as Weight))
.saturating_add((33_000 as Weight).saturating_mul(v as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
}
// Storage: Democracy NextExternal (r:0 w:1)
fn external_propose_majority() -> Weight {
(1_341_000 as Weight)
(3_697_000 as Weight)
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
}
// Storage: Democracy NextExternal (r:0 w:1)
fn external_propose_default() -> Weight {
(1_360_000 as Weight)
(3_831_000 as Weight)
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
}
// Storage: Democracy NextExternal (r:1 w:1)
// Storage: Democracy ReferendumCount (r:1 w:1)
// Storage: Democracy ReferendumInfoOf (r:0 w:1)
fn fast_track() -> Weight {
(16_021_000 as Weight)
(20_271_000 as Weight)
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(3 as Weight))
}
// Storage: Democracy NextExternal (r:1 w:1)
// Storage: Democracy Blacklist (r:1 w:1)
fn veto_external(v: u32, ) -> Weight {
(17_350_000 as Weight)
(21_319_000 as Weight)
// Standard Error: 0
.saturating_add((46_000 as Weight).saturating_mul(v as Weight))
.saturating_add((52_000 as Weight).saturating_mul(v as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(2 as Weight))
}
@@ -409,23 +409,23 @@ impl WeightInfo for () {
// Storage: Democracy DepositOf (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn cancel_proposal(p: u32, ) -> Weight {
(39_418_000 as Weight)
(43_960_000 as Weight)
// Standard Error: 2_000
.saturating_add((170_000 as Weight).saturating_mul(p as Weight))
.saturating_add((184_000 as Weight).saturating_mul(p as Weight))
.saturating_add(RocksDbWeight::get().reads(3 as Weight))
.saturating_add(RocksDbWeight::get().writes(3 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:0 w:1)
fn cancel_referendum() -> Weight {
(10_239_000 as Weight)
(13_475_000 as Weight)
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
}
// Storage: Scheduler Lookup (r:1 w:1)
// Storage: Scheduler Agenda (r:1 w:1)
fn cancel_queued(r: u32, ) -> Weight {
(20_483_000 as Weight)
(24_320_000 as Weight)
// Standard Error: 1_000
.saturating_add((565_000 as Weight).saturating_mul(r as Weight))
.saturating_add((560_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(2 as Weight))
}
@@ -433,9 +433,9 @@ impl WeightInfo for () {
// Storage: Democracy ReferendumCount (r:1 w:0)
// Storage: Democracy ReferendumInfoOf (r:1 w:0)
fn on_initialize_base(r: u32, ) -> Weight {
(3_871_000 as Weight)
(3_428_000 as Weight)
// Standard Error: 2_000
.saturating_add((3_038_000 as Weight).saturating_mul(r as Weight))
.saturating_add((3_171_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
@@ -447,9 +447,9 @@ impl WeightInfo for () {
// Storage: Democracy PublicProps (r:1 w:0)
// Storage: Democracy ReferendumInfoOf (r:1 w:0)
fn on_initialize_base_with_launch_period(r: u32, ) -> Weight {
(7_597_000 as Weight)
(7_867_000 as Weight)
// Standard Error: 2_000
.saturating_add((3_046_000 as Weight).saturating_mul(r as Weight))
.saturating_add((3_177_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(5 as Weight))
.saturating_add(RocksDbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
@@ -458,9 +458,9 @@ impl WeightInfo for () {
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Balances Locks (r:1 w:1)
fn delegate(r: u32, ) -> Weight {
(32_554_000 as Weight)
// Standard Error: 3_000
.saturating_add((3_903_000 as Weight).saturating_mul(r as Weight))
(37_902_000 as Weight)
// Standard Error: 4_000
.saturating_add((4_335_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(4 as Weight))
.saturating_add(RocksDbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(RocksDbWeight::get().writes(4 as Weight))
@@ -469,9 +469,9 @@ impl WeightInfo for () {
// Storage: Democracy VotingOf (r:2 w:2)
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
fn undelegate(r: u32, ) -> Weight {
(15_440_000 as Weight)
(21_272_000 as Weight)
// Standard Error: 3_000
.saturating_add((3_972_000 as Weight).saturating_mul(r as Weight))
.saturating_add((4_351_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().reads((1 as Weight).saturating_mul(r as Weight)))
.saturating_add(RocksDbWeight::get().writes(2 as Weight))
@@ -479,12 +479,12 @@ impl WeightInfo for () {
}
// Storage: Democracy PublicProps (r:0 w:1)
fn clear_public_proposals() -> Weight {
(1_662_000 as Weight)
(4_913_000 as Weight)
.saturating_add(RocksDbWeight::get().writes(1 as Weight))
}
// Storage: Democracy Preimages (r:1 w:1)
fn note_preimage(b: u32, ) -> Weight {
(24_170_000 as Weight)
(27_986_000 as Weight)
// Standard Error: 0
.saturating_add((2_000 as Weight).saturating_mul(b as Weight))
.saturating_add(RocksDbWeight::get().reads(1 as Weight))
@@ -492,7 +492,7 @@ impl WeightInfo for () {
}
// Storage: Democracy Preimages (r:1 w:1)
fn note_imminent_preimage(b: u32, ) -> Weight {
(16_470_000 as Weight)
(20_058_000 as Weight)
// Standard Error: 0
.saturating_add((2_000 as Weight).saturating_mul(b as Weight))
.saturating_add(RocksDbWeight::get().reads(1 as Weight))
@@ -501,7 +501,7 @@ impl WeightInfo for () {
// Storage: Democracy Preimages (r:1 w:1)
// Storage: System Account (r:1 w:0)
fn reap_preimage(b: u32, ) -> Weight {
(24_547_000 as Weight)
(28_619_000 as Weight)
// Standard Error: 0
.saturating_add((1_000 as Weight).saturating_mul(b as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
@@ -511,9 +511,9 @@ impl WeightInfo for () {
// Storage: Balances Locks (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn unlock_remove(r: u32, ) -> Weight {
(22_596_000 as Weight)
(26_619_000 as Weight)
// Standard Error: 1_000
.saturating_add((61_000 as Weight).saturating_mul(r as Weight))
.saturating_add((56_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(3 as Weight))
.saturating_add(RocksDbWeight::get().writes(3 as Weight))
}
@@ -521,27 +521,27 @@ impl WeightInfo for () {
// Storage: Balances Locks (r:1 w:1)
// Storage: System Account (r:1 w:1)
fn unlock_set(r: u32, ) -> Weight {
(21_589_000 as Weight)
(25_373_000 as Weight)
// Standard Error: 1_000
.saturating_add((125_000 as Weight).saturating_mul(r as Weight))
.saturating_add((142_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(3 as Weight))
.saturating_add(RocksDbWeight::get().writes(3 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Democracy VotingOf (r:1 w:1)
fn remove_vote(r: u32, ) -> Weight {
(12_120_000 as Weight)
(15_961_000 as Weight)
// Standard Error: 1_000
.saturating_add((106_000 as Weight).saturating_mul(r as Weight))
.saturating_add((115_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(2 as Weight))
}
// Storage: Democracy ReferendumInfoOf (r:1 w:1)
// Storage: Democracy VotingOf (r:1 w:1)
fn remove_other_vote(r: u32, ) -> Weight {
(12_563_000 as Weight)
(15_992_000 as Weight)
// Standard Error: 1_000
.saturating_add((105_000 as Weight).saturating_mul(r as Weight))
.saturating_add((113_000 as Weight).saturating_mul(r as Weight))
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(2 as Weight))
}