Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .maintain/frame-weight-template.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#![allow(unused_imports)]
#![allow(missing_docs)]

use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
use frame_support::{traits::Get, weights::{Weight, constants::ParityDbWeight}};
use core::marker::PhantomData;

/// Weight functions needed for `{{pallet}}`.
Expand Down Expand Up @@ -102,16 +102,16 @@ impl WeightInfo for () {
.saturating_add(Weight::from_parts({{underscore cw.slope}}, 0).saturating_mul({{cw.name}}.into()))
{{/each}}
{{#if (ne benchmark.base_reads "0")}}
.saturating_add(RocksDbWeight::get().reads({{benchmark.base_reads}}_u64))
.saturating_add(ParityDbWeight::get().reads({{benchmark.base_reads}}_u64))
{{/if}}
{{#each benchmark.component_reads as |cr|}}
.saturating_add(RocksDbWeight::get().reads(({{cr.slope}}_u64).saturating_mul({{cr.name}}.into())))
.saturating_add(ParityDbWeight::get().reads(({{cr.slope}}_u64).saturating_mul({{cr.name}}.into())))
{{/each}}
{{#if (ne benchmark.base_writes "0")}}
.saturating_add(RocksDbWeight::get().writes({{benchmark.base_writes}}_u64))
.saturating_add(ParityDbWeight::get().writes({{benchmark.base_writes}}_u64))
{{/if}}
{{#each benchmark.component_writes as |cw|}}
.saturating_add(RocksDbWeight::get().writes(({{cw.slope}}_u64).saturating_mul({{cw.name}}.into())))
.saturating_add(ParityDbWeight::get().writes(({{cw.slope}}_u64).saturating_mul({{cw.name}}.into())))
{{/each}}
{{#each benchmark.component_calculated_proof_size as |cp|}}
.saturating_add(Weight::from_parts(0, {{cp.slope}}).saturating_mul({{cp.name}}.into()))
Expand Down
4 changes: 2 additions & 2 deletions chain-extensions/src/mock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use core::num::NonZeroU64;
use frame_support::dispatch::DispatchResult;
use frame_support::traits::{Contains, Everything, InherentBuilder, InsideBoth};
use frame_support::weights::Weight;
use frame_support::weights::constants::RocksDbWeight;
use frame_support::weights::constants::ParityDbWeight;
use frame_support::{PalletId, derive_impl};
use frame_support::{assert_ok, parameter_types, traits::PrivilegeCmp};
use frame_system as system;
Expand Down Expand Up @@ -212,7 +212,7 @@ impl system::Config for Test {
type BaseCallFilter = InsideBoth<Everything, NoNestingCallFilter>;
type BlockWeights = BlockWeights;
type BlockLength = ();
type DbWeight = RocksDbWeight;
type DbWeight = ParityDbWeight;
type RuntimeOrigin = RuntimeOrigin;
type RuntimeCall = RuntimeCall;
type Hash = H256;
Expand Down
10 changes: 5 additions & 5 deletions pallets/commitments/src/weights.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#![allow(unused_imports)]
#![allow(missing_docs)]

use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
use frame_support::{traits::Get, weights::{Weight, constants::ParityDbWeight}};
use core::marker::PhantomData;

/// Weight functions needed for `pallet_commitments`.
Expand Down Expand Up @@ -52,7 +52,7 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
/// Sudo setting rate limit for commitments
fn set_rate_limit() -> Weight {
Weight::from_parts(10_000_000, 2000)
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
}
}

Expand All @@ -68,13 +68,13 @@ impl WeightInfo for () {
// Estimated: `6344`
// Minimum execution time: 28_000_000 picoseconds.
Weight::from_parts(28_000_000, 6344)
.saturating_add(RocksDbWeight::get().reads(2_u64))
.saturating_add(RocksDbWeight::get().writes(2_u64))
.saturating_add(ParityDbWeight::get().reads(2_u64))
.saturating_add(ParityDbWeight::get().writes(2_u64))
}

/// Sudo setting rate limit for commitments
fn set_rate_limit() -> Weight {
Weight::from_parts(10_000_000, 2000)
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
}
}
40 changes: 20 additions & 20 deletions pallets/crowdloan/src/weights.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#![allow(unused_imports)]
#![allow(missing_docs)]

use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
use frame_support::{traits::Get, weights::{Weight, constants::ParityDbWeight}};
use core::marker::PhantomData;

/// Weight functions needed for `pallet_crowdloan`.
Expand Down Expand Up @@ -195,8 +195,8 @@ impl WeightInfo for () {
// Estimated: `6148`
// Minimum execution time: 42_128_000 picoseconds.
Weight::from_parts(42_930_000, 6148)
.saturating_add(RocksDbWeight::get().reads(3_u64))
.saturating_add(RocksDbWeight::get().writes(5_u64))
.saturating_add(ParityDbWeight::get().reads(3_u64))
.saturating_add(ParityDbWeight::get().writes(5_u64))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
/// Proof: `Crowdloan::Crowdloans` (`max_values`: None, `max_size`: Some(278), added: 2753, mode: `MaxEncodedLen`)
Expand All @@ -210,8 +210,8 @@ impl WeightInfo for () {
// Estimated: `6148`
// Minimum execution time: 43_161_000 picoseconds.
Weight::from_parts(44_192_000, 6148)
.saturating_add(RocksDbWeight::get().reads(4_u64))
.saturating_add(RocksDbWeight::get().writes(4_u64))
.saturating_add(ParityDbWeight::get().reads(4_u64))
.saturating_add(ParityDbWeight::get().writes(4_u64))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
/// Proof: `Crowdloan::Crowdloans` (`max_values`: None, `max_size`: Some(278), added: 2753, mode: `MaxEncodedLen`)
Expand All @@ -225,8 +225,8 @@ impl WeightInfo for () {
// Estimated: `6148`
// Minimum execution time: 40_235_000 picoseconds.
Weight::from_parts(40_907_000, 6148)
.saturating_add(RocksDbWeight::get().reads(4_u64))
.saturating_add(RocksDbWeight::get().writes(4_u64))
.saturating_add(ParityDbWeight::get().reads(4_u64))
.saturating_add(ParityDbWeight::get().writes(4_u64))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
/// Proof: `Crowdloan::Crowdloans` (`max_values`: None, `max_size`: Some(278), added: 2753, mode: `MaxEncodedLen`)
Expand All @@ -242,8 +242,8 @@ impl WeightInfo for () {
// Estimated: `6148`
// Minimum execution time: 40_986_000 picoseconds.
Weight::from_parts(41_858_000, 6148)
.saturating_add(RocksDbWeight::get().reads(4_u64))
.saturating_add(RocksDbWeight::get().writes(4_u64))
.saturating_add(ParityDbWeight::get().reads(4_u64))
.saturating_add(ParityDbWeight::get().writes(4_u64))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
/// Proof: `Crowdloan::Crowdloans` (`max_values`: None, `max_size`: Some(278), added: 2753, mode: `MaxEncodedLen`)
Expand All @@ -260,9 +260,9 @@ impl WeightInfo for () {
Weight::from_parts(2_729_302, 3743)
// Standard Error: 351_422
.saturating_add(Weight::from_parts(31_033_274, 0).saturating_mul(k.into()))
.saturating_add(RocksDbWeight::get().reads(2_u64))
.saturating_add(RocksDbWeight::get().reads((2_u64).saturating_mul(k.into())))
.saturating_add(RocksDbWeight::get().writes((2_u64).saturating_mul(k.into())))
.saturating_add(ParityDbWeight::get().reads(2_u64))
.saturating_add(ParityDbWeight::get().reads((2_u64).saturating_mul(k.into())))
.saturating_add(ParityDbWeight::get().writes((2_u64).saturating_mul(k.into())))
.saturating_add(Weight::from_parts(0, 2579).saturating_mul(k.into()))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
Expand All @@ -277,8 +277,8 @@ impl WeightInfo for () {
// Estimated: `6148`
// Minimum execution time: 43_341_000 picoseconds.
Weight::from_parts(44_402_000, 6148)
.saturating_add(RocksDbWeight::get().reads(4_u64))
.saturating_add(RocksDbWeight::get().writes(3_u64))
.saturating_add(ParityDbWeight::get().reads(4_u64))
.saturating_add(ParityDbWeight::get().writes(3_u64))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
/// Proof: `Crowdloan::Crowdloans` (`max_values`: None, `max_size`: Some(278), added: 2753, mode: `MaxEncodedLen`)
Expand All @@ -288,8 +288,8 @@ impl WeightInfo for () {
// Estimated: `3743`
// Minimum execution time: 8_876_000 picoseconds.
Weight::from_parts(9_137_000, 3743)
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
/// Proof: `Crowdloan::Crowdloans` (`max_values`: None, `max_size`: Some(278), added: 2753, mode: `MaxEncodedLen`)
Expand All @@ -299,8 +299,8 @@ impl WeightInfo for () {
// Estimated: `3743`
// Minimum execution time: 9_117_000 picoseconds.
Weight::from_parts(9_438_000, 3743)
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: `Crowdloan::Crowdloans` (r:1 w:1)
/// Proof: `Crowdloan::Crowdloans` (`max_values`: None, `max_size`: Some(278), added: 2753, mode: `MaxEncodedLen`)
Expand All @@ -310,7 +310,7 @@ impl WeightInfo for () {
// Estimated: `3743`
// Minimum execution time: 8_766_000 picoseconds.
Weight::from_parts(9_087_000, 3743)
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
}
42 changes: 21 additions & 21 deletions pallets/proxy/src/weights.rs
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ impl WeightInfo for () {
Weight::from_parts(25_084_085, 4706)
// Standard Error: 2_569
.saturating_add(Weight::from_parts(33_574, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(3_u64))
.saturating_add(ParityDbWeight::get().reads(3_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:0)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -299,8 +299,8 @@ impl WeightInfo for () {
.saturating_add(Weight::from_parts(171_107, 0).saturating_mul(a.into()))
// Standard Error: 3_834
.saturating_add(Weight::from_parts(34_523, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(5_u64))
.saturating_add(RocksDbWeight::get().writes(2_u64))
.saturating_add(ParityDbWeight::get().reads(5_u64))
.saturating_add(ParityDbWeight::get().writes(2_u64))
}
/// Storage: `Proxy::Announcements` (r:1 w:1)
/// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2233), added: 4708, mode: `MaxEncodedLen`)
Expand All @@ -318,8 +318,8 @@ impl WeightInfo for () {
.saturating_add(Weight::from_parts(158_572, 0).saturating_mul(a.into()))
// Standard Error: 1_881
.saturating_add(Weight::from_parts(8_433, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(2_u64))
.saturating_add(RocksDbWeight::get().writes(2_u64))
.saturating_add(ParityDbWeight::get().reads(2_u64))
.saturating_add(ParityDbWeight::get().writes(2_u64))
}
/// Storage: `Proxy::Announcements` (r:1 w:1)
/// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2233), added: 4708, mode: `MaxEncodedLen`)
Expand All @@ -337,8 +337,8 @@ impl WeightInfo for () {
.saturating_add(Weight::from_parts(176_827, 0).saturating_mul(a.into()))
// Standard Error: 1_901
.saturating_add(Weight::from_parts(9_607, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(2_u64))
.saturating_add(RocksDbWeight::get().writes(2_u64))
.saturating_add(ParityDbWeight::get().reads(2_u64))
.saturating_add(ParityDbWeight::get().writes(2_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:0)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -358,8 +358,8 @@ impl WeightInfo for () {
.saturating_add(Weight::from_parts(157_335, 0).saturating_mul(a.into()))
// Standard Error: 2_730
.saturating_add(Weight::from_parts(28_872, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(3_u64))
.saturating_add(RocksDbWeight::get().writes(2_u64))
.saturating_add(ParityDbWeight::get().reads(3_u64))
.saturating_add(ParityDbWeight::get().writes(2_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:1)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -372,8 +372,8 @@ impl WeightInfo for () {
Weight::from_parts(28_296_216, 4706)
// Standard Error: 1_643
.saturating_add(Weight::from_parts(50_271, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:1)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -386,8 +386,8 @@ impl WeightInfo for () {
Weight::from_parts(28_379_566, 4706)
// Standard Error: 1_547
.saturating_add(Weight::from_parts(45_784, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:1)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -400,8 +400,8 @@ impl WeightInfo for () {
Weight::from_parts(25_821_878, 4706)
// Standard Error: 2_300
.saturating_add(Weight::from_parts(33_972, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:1)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -414,8 +414,8 @@ impl WeightInfo for () {
Weight::from_parts(29_662_728, 4706)
// Standard Error: 1_851
.saturating_add(Weight::from_parts(29_928, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:1)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -428,8 +428,8 @@ impl WeightInfo for () {
Weight::from_parts(26_780_627, 4706)
// Standard Error: 1_581
.saturating_add(Weight::from_parts(33_085, 0).saturating_mul(p.into()))
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: `Proxy::Proxies` (r:1 w:1)
/// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1241), added: 3716, mode: `MaxEncodedLen`)
Expand All @@ -443,7 +443,7 @@ impl WeightInfo for () {
// Estimated: `5698`
// Minimum execution time: 46_733_000 picoseconds.
Weight::from_parts(47_972_000, 5698)
.saturating_add(RocksDbWeight::get().reads(3_u64))
.saturating_add(RocksDbWeight::get().writes(3_u64))
.saturating_add(ParityDbWeight::get().reads(3_u64))
.saturating_add(ParityDbWeight::get().writes(3_u64))
}
}
10 changes: 5 additions & 5 deletions pallets/registry/src/weights.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#![allow(unused_imports)]
#![allow(missing_docs)]

use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
use frame_support::{traits::Get, weights::{Weight, constants::ParityDbWeight}};
use core::marker::PhantomData;

/// Weight functions needed for `pallet_registry`.
Expand Down Expand Up @@ -70,8 +70,8 @@ impl WeightInfo for () {
// Estimated: `3499`
// Minimum execution time: 41_000_000 picoseconds.
Weight::from_parts(41_000_000, 3499)
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
/// Storage: Registry IdentityOf (r:1 w:1)
/// Proof Skipped: Registry IdentityOf (max_values: None, max_size: None, mode: Measured)
Expand All @@ -81,7 +81,7 @@ impl WeightInfo for () {
// Estimated: `3860`
// Minimum execution time: 36_000_000 picoseconds.
Weight::from_parts(36_000_000, 3860)
.saturating_add(RocksDbWeight::get().reads(1_u64))
.saturating_add(RocksDbWeight::get().writes(1_u64))
.saturating_add(ParityDbWeight::get().reads(1_u64))
.saturating_add(ParityDbWeight::get().writes(1_u64))
}
}
4 changes: 2 additions & 2 deletions pallets/subtensor/src/tests/mock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ use crate::utils::rate_limiting::TransactionType;
use crate::*;
use frame_support::traits::{Contains, Everything, InherentBuilder, InsideBoth, InstanceFilter};
use frame_support::weights::Weight;
use frame_support::weights::constants::RocksDbWeight;
use frame_support::weights::constants::ParityDbWeight;
use frame_support::{PalletId, derive_impl};
use frame_support::{
assert_ok, parameter_types,
Expand Down Expand Up @@ -122,7 +122,7 @@ impl system::Config for Test {
type BaseCallFilter = InsideBoth<Everything, NoNestingCallFilter>;
type BlockWeights = BlockWeights;
type BlockLength = ();
type DbWeight = RocksDbWeight;
type DbWeight = ParityDbWeight;
type RuntimeOrigin = RuntimeOrigin;
type RuntimeCall = RuntimeCall;
type Hash = H256;
Expand Down
2 changes: 1 addition & 1 deletion pallets/subtensor/src/tests/staking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ fn test_remove_stake_dispatch_info_ok() {
assert_eq!(
call.get_dispatch_info(),
DispatchInfo {
call_weight: frame_support::weights::Weight::from_parts(1_671_800_000, 0)
call_weight: frame_support::weights::Weight::from_parts(848_800_000, 0)
.add_proof_size(0),
extension_weight: frame_support::weights::Weight::zero(),
class: DispatchClass::Normal,
Expand Down
Loading
Loading