diff --git a/dip-template/runtimes/dip-provider/src/lib.rs b/dip-template/runtimes/dip-provider/src/lib.rs index 98f14446a8..2af012c235 100644 --- a/dip-template/runtimes/dip-provider/src/lib.rs +++ b/dip-template/runtimes/dip-provider/src/lib.rs @@ -453,6 +453,9 @@ impl pallet_web3_names::Config for Runtime { type Web3Name = Web3Name; type Web3NameOwner = DidIdentifier; type WeightInfo = weights::pallet_web3_names::WeightInfo; + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = (); } #[cfg(feature = "runtime-benchmarks")] diff --git a/pallets/pallet-migration/src/mock.rs b/pallets/pallet-migration/src/mock.rs index 0f4926fb6b..d7b99602ed 100644 --- a/pallets/pallet-migration/src/mock.rs +++ b/pallets/pallet-migration/src/mock.rs @@ -340,6 +340,9 @@ pub mod runtime { type Web3NameOwner = TestWeb3NameOwner; type WeightInfo = (); type BalanceMigrationManager = Migration; + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = (); } #[derive( diff --git a/pallets/pallet-web3-names/src/benchmarking.rs b/pallets/pallet-web3-names/src/benchmarking.rs index 4a442aa01f..d1ffa897d0 100644 --- a/pallets/pallet-web3-names/src/benchmarking.rs +++ b/pallets/pallet-web3-names/src/benchmarking.rs @@ -31,7 +31,7 @@ use frame_support::{ }; use frame_system::{pallet_prelude::BlockNumberFor, RawOrigin}; use sp_runtime::app_crypto::sr25519; -use sp_std::{vec, vec::Vec}; +use sp_std::vec::Vec; use kilt_support::{traits::GenerateBenchmarkOrigin, Deposit}; @@ -40,6 +40,16 @@ use crate::{ Web3NameOwnerOf, }; +pub trait BenchmarkHelper { + fn generate_name_input_with_length(length: usize) -> Vec; +} + +impl BenchmarkHelper for () { + fn generate_name_input_with_length(length: usize) -> Vec { + sp_std::vec![b'a'; length] + } +} + const CALLER_SEED: u32 = 0; const OWNER_SEED: u32 = 1; @@ -55,28 +65,24 @@ where CurrencyOf::::set_balance(account, balance); } -fn generate_web3_name_input(length: usize) -> Vec { - vec![b'1'; length] -} - benchmarks_instance_pallet! { where_clause { where T::AccountId: From, - T::Web3NameOwner: From, - T::OwnerOrigin: GenerateBenchmarkOrigin, - T::BanOrigin: EnsureOrigin, + >::Web3NameOwner: From, + >::OwnerOrigin: GenerateBenchmarkOrigin>::Web3NameOwner>, + >::BanOrigin: EnsureOrigin, <>::Web3Name as TryFrom>>::Error: Into>, >::Currency: Mutate, } claim { - let n in (T::MinNameLength::get()) .. (T::MaxNameLength::get()); + let n in (>::MinNameLength::get()) .. (>::MaxNameLength::get()); let caller: AccountIdOf = account("caller", 0, CALLER_SEED); let owner: Web3NameOwnerOf = account("owner", 0, OWNER_SEED); - let web3_name_input: BoundedVec = BoundedVec::try_from(generate_web3_name_input(n.saturated_into())).expect("BoundedVec creation should not fail."); + let web3_name_input: BoundedVec>::MaxNameLength> = BoundedVec::try_from(>::BenchmarkHelper::generate_name_input_with_length(n.saturated_into())).expect("BoundedVec creation should not fail."); let web3_name_input_clone = web3_name_input.clone(); - let origin = T::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); + let origin = >::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); make_free_for_did::(&caller); }: _(origin, web3_name_input_clone) @@ -91,8 +97,8 @@ benchmarks_instance_pallet! { release_by_owner { let caller: AccountIdOf = account("caller", 0, CALLER_SEED); let owner: Web3NameOwnerOf = account("owner", 0, OWNER_SEED); - let web3_name_input: BoundedVec = BoundedVec::try_from(generate_web3_name_input(T::MaxNameLength::get().saturated_into())).expect("BoundedVec creation should not fail."); - let origin = T::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); + let web3_name_input: BoundedVec>::MaxNameLength> = BoundedVec::try_from(>::BenchmarkHelper::generate_name_input_with_length(>::MaxNameLength::get().saturated_into())).expect("BoundedVec creation should not fail."); + let origin = >::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); make_free_for_did::(&caller); Pallet::::claim(origin.clone(), web3_name_input.clone()).expect("Should register the claimed web3 name."); @@ -106,12 +112,12 @@ benchmarks_instance_pallet! { } reclaim_deposit { - let n in (T::MinNameLength::get()) .. (T::MaxNameLength::get()); + let n in (>::MinNameLength::get()) .. (>::MaxNameLength::get()); let caller: AccountIdOf = account("caller", 0, CALLER_SEED); let owner: Web3NameOwnerOf = account("owner", 0, OWNER_SEED); - let web3_name_input: BoundedVec = BoundedVec::try_from(generate_web3_name_input(n.saturated_into())).expect("BoundedVec creation should not fail."); + let web3_name_input: BoundedVec>::MaxNameLength> = BoundedVec::try_from(>::BenchmarkHelper::generate_name_input_with_length(n.saturated_into())).expect("BoundedVec creation should not fail."); let web3_name_input_clone = web3_name_input.clone(); - let did_origin = T::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); + let did_origin = >::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); let signed_origin = RawOrigin::Signed(caller.clone()); make_free_for_did::(&caller); @@ -126,12 +132,12 @@ benchmarks_instance_pallet! { } ban { - let n in (T::MinNameLength::get()) .. (T::MaxNameLength::get()); + let n in (>::MinNameLength::get()) .. (>::MaxNameLength::get()); let caller: AccountIdOf = account("caller", 0, CALLER_SEED); let owner: Web3NameOwnerOf = account("owner", 0, OWNER_SEED); - let web3_name_input: BoundedVec = BoundedVec::try_from(generate_web3_name_input(n.saturated_into())).expect("BoundedVec creation should not fail."); + let web3_name_input: BoundedVec>::MaxNameLength> = BoundedVec::try_from(>::BenchmarkHelper::generate_name_input_with_length(n.saturated_into())).expect("BoundedVec creation should not fail."); let web3_name_input_clone = web3_name_input.clone(); - let did_origin = T::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); + let did_origin = >::OwnerOrigin::generate_origin(caller.clone(), owner.clone()); let ban_origin = RawOrigin::Root; make_free_for_did::(&caller); @@ -147,10 +153,10 @@ benchmarks_instance_pallet! { } unban { - let n in (T::MinNameLength::get()) .. (T::MaxNameLength::get()); + let n in (>::MinNameLength::get()) .. (>::MaxNameLength::get()); let caller: AccountIdOf = account("caller", 0, CALLER_SEED); let owner: Web3NameOwnerOf = account("owner", 0, OWNER_SEED); - let web3_name_input: BoundedVec = BoundedVec::try_from(generate_web3_name_input(n.saturated_into())).expect("BoundedVec creation should not fail."); + let web3_name_input: BoundedVec>::MaxNameLength> = BoundedVec::try_from(>::BenchmarkHelper::generate_name_input_with_length(n.saturated_into())).expect("BoundedVec creation should not fail."); let web3_name_input_clone = web3_name_input.clone(); let ban_origin = RawOrigin::Root; @@ -170,17 +176,17 @@ benchmarks_instance_pallet! { let deposit_owner_old: AccountIdOf = account("caller", 0, CALLER_SEED); let deposit_owner_new: AccountIdOf = account("caller", 1, CALLER_SEED); let owner: Web3NameOwnerOf = account("owner", 0, OWNER_SEED); - let web3_name_input: BoundedVec = BoundedVec::try_from( - generate_web3_name_input(T::MaxNameLength::get().saturated_into()) + let web3_name_input: BoundedVec>::MaxNameLength> = BoundedVec::try_from( + >::BenchmarkHelper::generate_name_input_with_length(>::MaxNameLength::get().saturated_into()) ).expect("BoundedVec creation should not fail."); let web3_name_input_clone = web3_name_input.clone(); - let origin_create = T::OwnerOrigin::generate_origin(deposit_owner_old.clone(), owner.clone()); + let origin_create = >::OwnerOrigin::generate_origin(deposit_owner_old.clone(), owner.clone()); make_free_for_did::(&deposit_owner_old); make_free_for_did::(&deposit_owner_new); Pallet::::claim(origin_create, web3_name_input.clone()).expect("Should register the claimed web3 name."); - let origin = T::OwnerOrigin::generate_origin(deposit_owner_new.clone(), owner); + let origin = >::OwnerOrigin::generate_origin(deposit_owner_new.clone(), owner); }: _(origin) verify { let Ok(web3_name) = Web3NameOf::::try_from(web3_name_input.to_vec()) else { @@ -195,8 +201,8 @@ benchmarks_instance_pallet! { update_deposit { let deposit_owner: AccountIdOf = account("caller", 0, CALLER_SEED); let owner: Web3NameOwnerOf = account("owner", 0, OWNER_SEED); - let web3_name_input: BoundedVec = BoundedVec::try_from( - generate_web3_name_input(T::MaxNameLength::get().saturated_into()) + let web3_name_input: BoundedVec>::MaxNameLength> = BoundedVec::try_from( + >::BenchmarkHelper::generate_name_input_with_length(>::MaxNameLength::get().saturated_into()) ).expect("BoundedVec creation should not fail."); let Ok(web3_name) = Web3NameOf::::try_from(web3_name_input.to_vec()) else { panic!(); diff --git a/pallets/pallet-web3-names/src/lib.rs b/pallets/pallet-web3-names/src/lib.rs index 17ca44d186..631759d22d 100644 --- a/pallets/pallet-web3-names/src/lib.rs +++ b/pallets/pallet-web3-names/src/lib.rs @@ -36,6 +36,8 @@ mod tests; #[cfg(feature = "runtime-benchmarks")] mod benchmarking; +#[cfg(feature = "runtime-benchmarks")] +pub use benchmarking::BenchmarkHelper; pub use crate::{default_weights::WeightInfo, pallet::*}; @@ -149,6 +151,9 @@ pub mod pallet { /// Migration manager to handle new created entries type BalanceMigrationManager: BalanceMigrationManager, BalanceOf>; + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper: crate::benchmarking::BenchmarkHelper; } #[pallet::event] diff --git a/pallets/pallet-web3-names/src/mock.rs b/pallets/pallet-web3-names/src/mock.rs index 7c69773c3d..239059ab36 100644 --- a/pallets/pallet-web3-names/src/mock.rs +++ b/pallets/pallet-web3-names/src/mock.rs @@ -166,6 +166,9 @@ pub(crate) mod runtime { type Web3NameOwner = TestWeb3NameOwner; type WeightInfo = (); type BalanceMigrationManager = (); + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = (); } impl mock_origin::Config for Test { diff --git a/runtimes/common/src/constants.rs b/runtimes/common/src/constants.rs index b3a686cea1..de3bbc3eaa 100644 --- a/runtimes/common/src/constants.rs +++ b/runtimes/common/src/constants.rs @@ -512,8 +512,8 @@ pub mod dot_names { const MIN_NAME_LENGTH: u32 = 3; const MAX_NAME_LENGTH: u32 = 28; - const DOT_NAME_SUFFIX: &str = ".dot"; + pub const DOT_NAME_SUFFIX: &str = ".dot"; #[allow(clippy::as_conversions)] pub const MIN_LENGTH: u32 = MIN_NAME_LENGTH + DOT_NAME_SUFFIX.len() as u32; #[allow(clippy::as_conversions)] diff --git a/runtimes/common/src/dip/mock.rs b/runtimes/common/src/dip/mock.rs index 35629475fd..44055fdfc5 100644 --- a/runtimes/common/src/dip/mock.rs +++ b/runtimes/common/src/dip/mock.rs @@ -158,6 +158,9 @@ impl pallet_web3_names::Config for TestRuntime { type Web3Name = AsciiWeb3Name; type Web3NameOwner = DidIdentifier; type WeightInfo = (); + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = (); } impl pallet_did_lookup::Config for TestRuntime { diff --git a/runtimes/common/src/dot_names/mod.rs b/runtimes/common/src/dot_names/mod.rs index 01a76cb838..ad217cbc91 100644 --- a/runtimes/common/src/dot_names/mod.rs +++ b/runtimes/common/src/dot_names/mod.rs @@ -25,6 +25,8 @@ use sp_std::vec::Vec; use pallet_web3_names::{Config, Error}; +use crate::constants::dot_names::DOT_NAME_SUFFIX; + #[cfg(test)] mod tests; @@ -64,7 +66,7 @@ impl TryFrom> for DotName< } } fn is_valid_dot_name(input: &[u8]) -> bool { - let Some(dot_name_without_suffix) = input.strip_suffix(b".dot") else { + let Some(dot_name_without_suffix) = input.strip_suffix(DOT_NAME_SUFFIX.as_bytes()) else { return false; }; // Char validation logic taken from https://github.com/paritytech/polkadot-sdk/blob/657b5503a04e97737696fa7344641019350fb521/substrate/frame/identity/src/lib.rs#L1435 diff --git a/runtimes/kestrel/src/lib.rs b/runtimes/kestrel/src/lib.rs index ad73b6e40c..083084f47e 100644 --- a/runtimes/kestrel/src/lib.rs +++ b/runtimes/kestrel/src/lib.rs @@ -456,6 +456,9 @@ impl pallet_web3_names::Config for Runtime { type Web3NameOwner = DidIdentifier; type WeightInfo = (); type BalanceMigrationManager = (); + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = (); } parameter_types! { diff --git a/runtimes/peregrine/src/lib.rs b/runtimes/peregrine/src/lib.rs index 858796e7fe..cf6c7aeb36 100644 --- a/runtimes/peregrine/src/lib.rs +++ b/runtimes/peregrine/src/lib.rs @@ -27,6 +27,7 @@ #[cfg(feature = "std")] include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); +use cfg_if::cfg_if; use cumulus_pallet_parachain_system::RelayNumberMonotonicallyIncreases; use frame_support::{ construct_runtime, @@ -35,7 +36,7 @@ use frame_support::{ traits::{ fungible::HoldConsideration, tokens::{PayFromAccount, UnityAssetBalanceConversion}, - AsEnsureOriginWithArg, ConstU32, EitherOfDiverse, EnqueueWithOrigin, Everything, InstanceFilter, + AsEnsureOriginWithArg, ChangeMembers, ConstU32, EitherOfDiverse, EnqueueWithOrigin, Everything, InstanceFilter, LinearStoragePrice, PrivilegeCmp, }, weights::{ConstantMultiplier, Weight}, @@ -535,7 +536,7 @@ impl pallet_collective::Config for Runtime { type MaxProposals = constants::governance::CouncilMaxProposals; type MaxMembers = constants::governance::CouncilMaxMembers; type DefaultVote = pallet_collective::PrimeDefaultVote; - type WeightInfo = weights::pallet_collective_council::WeightInfo; + type WeightInfo = weights::pallet_collective::WeightInfo; type SetMembersOrigin = EnsureRoot; } @@ -549,7 +550,7 @@ impl pallet_collective::Config for Runtime { type MaxProposals = constants::governance::TechnicalMaxProposals; type MaxMembers = constants::governance::TechnicalMaxMembers; type DefaultVote = pallet_collective::PrimeDefaultVote; - type WeightInfo = weights::pallet_collective_technical_committee::WeightInfo; + type WeightInfo = weights::pallet_technical_committee_collective::WeightInfo; type SetMembersOrigin = EnsureRoot; } @@ -564,7 +565,28 @@ impl pallet_membership::Config for Runtime { type MembershipInitialized = TechnicalCommittee; type MembershipChanged = TechnicalCommittee; type MaxMembers = constants::governance::TechnicalMaxMembers; - type WeightInfo = weights::pallet_membership::WeightInfo; + type WeightInfo = weights::pallet_technical_membership::WeightInfo; +} + +// Implementation of `MembershipChanged` equivalent to using `()` but that +// returns `Some(AccountId::new([0; 32]))` in `get_prime()` only when +// benchmarking. TODO: Remove once we upgrade with a version containing the fix: https://github.com/paritytech/polkadot-sdk/pull/6439 +pub struct MockMembershipChangedForBenchmarks; + +impl ChangeMembers for MockMembershipChangedForBenchmarks { + fn change_members_sorted(incoming: &[AccountId], outgoing: &[AccountId], sorted_new: &[AccountId]) { + <()>::change_members_sorted(incoming, outgoing, sorted_new) + } + + fn get_prime() -> Option { + cfg_if! { + if #[cfg(feature = "runtime-benchmark")] { + Some(AccountId::new([0; 32])) + } else { + <()>::get_prime() + } + } + } } type TipsMembershipProvider = pallet_membership::Instance2; @@ -576,7 +598,7 @@ impl pallet_membership::Config for Runtime { type ResetOrigin = MoreThanHalfCouncil; type PrimeOrigin = MoreThanHalfCouncil; type MembershipInitialized = (); - type MembershipChanged = (); + type MembershipChanged = MockMembershipChangedForBenchmarks; type MaxMembers = constants::governance::TipperMaxMembers; type WeightInfo = weights::pallet_membership::WeightInfo; } @@ -702,7 +724,7 @@ impl pallet_did_lookup::Config for Runtime { type EnsureOrigin = did::EnsureDidOrigin; type OriginSuccess = did::DidRawOrigin; - type WeightInfo = weights::pallet_did_lookup_did_lookup::WeightInfo; + type WeightInfo = weights::pallet_did_lookup::WeightInfo; type BalanceMigrationManager = Migration; // Do not change the below flag to `true` without also deploying a runtime // migration which removes any links that point to the same DID! @@ -720,7 +742,7 @@ impl pallet_did_lookup::Config for Runtime { type RuntimeEvent = RuntimeEvent; type RuntimeHoldReason = RuntimeHoldReason; type UniqueLinkingEnabled = ConstBool; - type WeightInfo = weights::pallet_did_lookup_did_unique_linking::WeightInfo; + type WeightInfo = weights::pallet_unique_linking::WeightInfo; } impl pallet_web3_names::Config for Runtime { @@ -735,8 +757,11 @@ impl pallet_web3_names::Config for Runtime { type MinNameLength = constants::web3_names::MinNameLength; type Web3Name = pallet_web3_names::web3_name::AsciiWeb3Name; type Web3NameOwner = DidIdentifier; - type WeightInfo = weights::pallet_web3_names_web3_names::WeightInfo; + type WeightInfo = weights::pallet_web3_names::WeightInfo; type BalanceMigrationManager = Migration; + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = benches::Web3NamesBenchmarkHelper; } pub type DotName = runtime_common::DotName<{ constants::dot_names::MIN_LENGTH }, { constants::dot_names::MAX_LENGTH }>; @@ -755,7 +780,10 @@ impl pallet_web3_names::Config for Runtime { type RuntimeHoldReason = RuntimeHoldReason; type Web3Name = DotName; type Web3NameOwner = DidIdentifier; - type WeightInfo = weights::pallet_web3_names_dot_names::WeightInfo; + type WeightInfo = weights::pallet_dot_names::WeightInfo; + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = benches::DotNamesBenchmarkHelper; } impl pallet_inflation::Config for Runtime { @@ -1291,14 +1319,26 @@ mod benches { use frame_system::RawOrigin; use pallet_asset_switch::PartialBenchmarkInfo; use runtime_common::AccountId; + use sp_std::{vec, vec::Vec}; use xcm::v4::{Asset, AssetId, Fungibility, Junction, Junctions, Location, ParentThen}; - use crate::{Fungibles, ParachainSystem}; + use crate::{DotNamesDeployment, Fungibles, ParachainSystem, Runtime}; frame_support::parameter_types! { pub const MaxBalance: crate::Balance = crate::Balance::max_value(); } + /// Workaround for a bug in the benchmarking code around instances. + /// Upstream fix PR: https://github.com/paritytech/polkadot-sdk/pull/6435 + #[allow(unused_imports)] + use pallet_collective as pallet_technical_committee_collective; + #[allow(unused_imports)] + use pallet_did_lookup as pallet_unique_linking; + #[allow(unused_imports)] + use pallet_membership as pallet_technical_membership; + #[allow(unused_imports)] + use pallet_web3_names as pallet_dot_names; + frame_benchmarking::define_benchmarks!( [frame_system, SystemBench::] [pallet_timestamp, Timestamp] @@ -1307,9 +1347,6 @@ mod benches { [pallet_session, SessionBench::] [parachain_staking, ParachainStaking] [pallet_democracy, Democracy] - [pallet_collective, Council] - [pallet_collective, TechnicalCommittee] - [pallet_membership, TechnicalMembership] [pallet_treasury, Treasury] [pallet_sudo, Sudo] [pallet_utility, Utility] @@ -1324,10 +1361,6 @@ mod benches { [delegation, Delegation] [did, Did] [pallet_inflation, Inflation] - [pallet_did_lookup, DidLookup] - [pallet_did_lookup, UniqueLinking] - [pallet_web3_names, Web3Names] - [pallet_web3_names, DotNames] [public_credentials, PublicCredentials] [pallet_xcm, PalletXcmExtrinsicsBenchmark::] [pallet_migration, Migration] @@ -1338,6 +1371,18 @@ mod benches { [pallet_message_queue, MessageQueue] [cumulus_pallet_parachain_system, ParachainSystem] [frame_benchmarking::baseline, Baseline::] + // pallet_collective instances + [pallet_collective, Council] + [pallet_technical_committee_collective, TechnicalCommittee] + // pallet_membership instances + [pallet_membership, TipsMembership] + [pallet_technical_membership, TechnicalMembership] + // pallet_did_lookup instances + [pallet_did_lookup, DidLookup] + [pallet_unique_linking, UniqueLinking] + // pallet_web3_names instances + [pallet_web3_names, Web3Names] + [pallet_dot_names, DotNames] ); // Required since the pallet `AssetTransactor` will try to deduct the XCM fee @@ -1384,6 +1429,39 @@ mod benches { }) } } + + pub struct Web3NamesBenchmarkHelper; + + impl pallet_web3_names::BenchmarkHelper for Web3NamesBenchmarkHelper { + fn generate_name_input_with_length(length: usize) -> Vec { + let input = vec![b'a'; length]; + + debug_assert!(>::Web3Name::try_from(input.clone()).is_ok()); + input + } + } + + pub struct DotNamesBenchmarkHelper; + + impl pallet_web3_names::BenchmarkHelper for DotNamesBenchmarkHelper { + // Returns the name `11[...]111.dot` with as many `1`s as the provided length - + // 4, to account for the ".dot" suffix. + fn generate_name_input_with_length(length: usize) -> Vec { + let suffix_length = runtime_common::constants::dot_names::DOT_NAME_SUFFIX.len(); + let remaining_name_length = length + .checked_sub(suffix_length) + .expect("Provided length should cover at least the length of the suffix."); + let input = vec![b'1'; remaining_name_length] + .into_iter() + .chain(runtime_common::constants::dot_names::DOT_NAME_SUFFIX.bytes()) + .collect::>(); + + debug_assert!( + >::Web3Name::try_from(input.clone()).is_ok() + ); + input + } + } } impl_runtime_apis! { diff --git a/runtimes/peregrine/src/weights/mod.rs b/runtimes/peregrine/src/weights/mod.rs index 5f47aa6f45..c334e1c17d 100644 --- a/runtimes/peregrine/src/weights/mod.rs +++ b/runtimes/peregrine/src/weights/mod.rs @@ -26,13 +26,12 @@ pub mod frame_system; pub mod pallet_asset_switch; pub mod pallet_assets; pub mod pallet_balances; -pub mod pallet_collective_council; -pub mod pallet_collective_technical_committee; +pub mod pallet_collective; pub mod pallet_democracy; pub mod pallet_deposit_storage; -pub mod pallet_did_lookup_did_lookup; -pub mod pallet_did_lookup_did_unique_linking; +pub mod pallet_did_lookup; pub mod pallet_dip_provider; +pub mod pallet_dot_names; pub mod pallet_indices; pub mod pallet_inflation; pub mod pallet_membership; @@ -44,13 +43,15 @@ pub mod pallet_proxy; pub mod pallet_scheduler; pub mod pallet_session; pub mod pallet_sudo; +pub mod pallet_technical_committee_collective; +pub mod pallet_technical_membership; pub mod pallet_timestamp; pub mod pallet_tips; pub mod pallet_treasury; +pub mod pallet_unique_linking; pub mod pallet_utility; pub mod pallet_vesting; -pub mod pallet_web3_names_dot_names; -pub mod pallet_web3_names_web3_names; +pub mod pallet_web3_names; pub mod pallet_xcm; pub mod parachain_staking; pub mod public_credentials; diff --git a/runtimes/peregrine/src/weights/pallet_collective_council.rs b/runtimes/peregrine/src/weights/pallet_collective.rs similarity index 57% rename from runtimes/peregrine/src/weights/pallet_collective_council.rs rename to runtimes/peregrine/src/weights/pallet_collective.rs index 8736e10709..545e4bf131 100644 --- a/runtimes/peregrine/src/weights/pallet_collective_council.rs +++ b/runtimes/peregrine/src/weights/pallet_collective.rs @@ -19,24 +19,24 @@ //! Autogenerated weights for `pallet_collective` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-08-23, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 // --chain=dev // --pallet=pallet-collective // --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs // --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] @@ -50,278 +50,216 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl pallet_collective::WeightInfo for WeightInfo { /// Storage: `Council::Members` (r:1 w:1) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:0) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:100 w:100) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Prime` (r:0 w:1) - /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[0, 100]`. - /// The range of component `n` is `[0, 100]`. - /// The range of component `p` is `[0, 100]`. + /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[0, 100]`. /// The range of component `n` is `[0, 100]`. /// The range of component `p` is `[0, 100]`. fn set_members(m: u32, _n: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `0 + m * (3232 ±0) + p * (3194 ±0)` - // Estimated: `15736 + m * (1967 ±16) + p * (4336 ±16)` - // Minimum execution time: 9_109_000 picoseconds. - Weight::from_parts(9_418_000, 0) - .saturating_add(Weight::from_parts(0, 15736)) - // Standard Error: 22_204 - .saturating_add(Weight::from_parts(2_365_752, 0).saturating_mul(m.into())) - // Standard Error: 22_204 - .saturating_add(Weight::from_parts(4_463_067, 0).saturating_mul(p.into())) + // Measured: `0 + m * (3228 ±0) + p * (3195 ±0)` + // Estimated: `990` + // Minimum execution time: 369_621_000 picoseconds. + Weight::from_parts(369_621_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 17_102_279 + .saturating_add(Weight::from_parts(91_979_117, 0).saturating_mul(m.into())) + // Standard Error: 17_102_279 + .saturating_add(Weight::from_parts(90_212_097, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) - .saturating_add(Weight::from_parts(0, 1967).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 4336).saturating_mul(p.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. - fn execute(b: u32, m: u32, ) -> Weight { + fn execute(b: u32, _m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `69 + m * (32 ±0)` - // Estimated: `1555 + m * (32 ±0)` - // Minimum execution time: 6_912_000 picoseconds. - Weight::from_parts(6_602_454, 0) - .saturating_add(Weight::from_parts(0, 1555)) - // Standard Error: 14 - .saturating_add(Weight::from_parts(1_002, 0).saturating_mul(b.into())) - // Standard Error: 148 - .saturating_add(Weight::from_parts(8_521, 0).saturating_mul(m.into())) + // Measured: `68 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 625_331_000 picoseconds. + Weight::from_parts(787_644_463, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 16_228 + .saturating_add(Weight::from_parts(62_712, 0).saturating_mul(b.into())) .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:0) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. fn propose_execute(b: u32, m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `69 + m * (32 ±0)` - // Estimated: `3535 + m * (32 ±0)` - // Minimum execution time: 8_210_000 picoseconds. - Weight::from_parts(7_713_293, 0) - .saturating_add(Weight::from_parts(0, 3535)) - // Standard Error: 17 - .saturating_add(Weight::from_parts(1_075, 0).saturating_mul(b.into())) - // Standard Error: 178 - .saturating_add(Weight::from_parts(14_181, 0).saturating_mul(m.into())) + // Measured: `68 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 711_111_000 picoseconds. + Weight::from_parts(658_477_137, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 17_555 + .saturating_add(Weight::from_parts(171_729, 0).saturating_mul(b.into())) + // Standard Error: 181_226 + .saturating_add(Weight::from_parts(522_904, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalCount` (r:1 w:1) - /// Proof: `Council::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:0 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[2, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[2, 100]`. /// The range of component `p` is `[1, 100]`. - fn propose_proposed(b: u32, m: u32, p: u32, ) -> Weight { + fn propose_proposed(b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `359 + m * (32 ±0) + p * (36 ±0)` - // Estimated: `3751 + m * (33 ±0) + p * (36 ±0)` - // Minimum execution time: 10_937_000 picoseconds. - Weight::from_parts(11_241_511, 0) - .saturating_add(Weight::from_parts(0, 3751)) - // Standard Error: 42 - .saturating_add(Weight::from_parts(1_778, 0).saturating_mul(b.into())) - // Standard Error: 441 - .saturating_add(Weight::from_parts(15_139, 0).saturating_mul(m.into())) - // Standard Error: 436 - .saturating_add(Weight::from_parts(113_658, 0).saturating_mul(p.into())) + // Measured: `4 + m * (32 ±0) + p * (39 ±0)` + // Estimated: `990` + // Minimum execution time: 775_269_000 picoseconds. + Weight::from_parts(905_763_953, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 89_660 + .saturating_add(Weight::from_parts(3_241, 0).saturating_mul(b.into())) + // Standard Error: 925_589 + .saturating_add(Weight::from_parts(5_095_420, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) - .saturating_add(Weight::from_parts(0, 33).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[5, 100]`. + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[5, 100]`. - fn vote(m: u32, ) -> Weight { + fn vote(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `812 + m * (64 ±0)` - // Estimated: `4276 + m * (64 ±0)` - // Minimum execution time: 12_611_000 picoseconds. - Weight::from_parts(13_405_315, 0) - .saturating_add(Weight::from_parts(0, 4276)) - // Standard Error: 255 - .saturating_add(Weight::from_parts(21_472, 0).saturating_mul(m.into())) + // Measured: `811 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 801_344_000 picoseconds. + Weight::from_parts(8_168_627_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:0 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_disapproved(m: u32, p: u32, ) -> Weight { + fn close_early_disapproved(_m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `401 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3846 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 12_969_000 picoseconds. - Weight::from_parts(13_065_552, 0) - .saturating_add(Weight::from_parts(0, 3846)) - // Standard Error: 509 - .saturating_add(Weight::from_parts(25_389, 0).saturating_mul(m.into())) - // Standard Error: 497 - .saturating_add(Weight::from_parts(110_113, 0).saturating_mul(p.into())) + // Measured: `185 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 869_858_000 picoseconds. + Weight::from_parts(951_242_033, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 608_221 + .saturating_add(Weight::from_parts(3_301_904, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_early_approved(_b: u32, _m: u32, _p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `703 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4020 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 18_256_000 picoseconds. - Weight::from_parts(20_094_140, 0) - .saturating_add(Weight::from_parts(0, 4020)) - // Standard Error: 83 - .saturating_add(Weight::from_parts(1_077, 0).saturating_mul(b.into())) - // Standard Error: 881 - .saturating_add(Weight::from_parts(3_161, 0).saturating_mul(m.into())) - // Standard Error: 859 - .saturating_add(Weight::from_parts(140_431, 0).saturating_mul(p.into())) + // Measured: `400 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_416_290_000 picoseconds. + Weight::from_parts(27_075_651_756, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Prime` (r:1 w:0) - /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:0 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. - fn close_disapproved(m: u32, p: u32, ) -> Weight { + fn close_disapproved(_m: u32, _p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `421 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3866 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 13_836_000 picoseconds. - Weight::from_parts(14_266_023, 0) - .saturating_add(Weight::from_parts(0, 3866)) - // Standard Error: 397 - .saturating_add(Weight::from_parts(21_338, 0).saturating_mul(m.into())) - // Standard Error: 387 - .saturating_add(Weight::from_parts(112_270, 0).saturating_mul(p.into())) + // Measured: `205 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 1_168_659_000 picoseconds. + Weight::from_parts(1_589_757_573, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Prime` (r:1 w:0) - /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_approved(_b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `723 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4040 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 19_289_000 picoseconds. - Weight::from_parts(20_296_061, 0) - .saturating_add(Weight::from_parts(0, 4040)) - // Standard Error: 81 - .saturating_add(Weight::from_parts(1_871, 0).saturating_mul(b.into())) - // Standard Error: 856 - .saturating_add(Weight::from_parts(4_275, 0).saturating_mul(m.into())) - // Standard Error: 835 - .saturating_add(Weight::from_parts(144_231, 0).saturating_mul(p.into())) + // Measured: `420 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_204_090_000 picoseconds. + Weight::from_parts(33_870_289_808, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 2_576_837 + .saturating_add(Weight::from_parts(8_788_127, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:0 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:0 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `p` is `[1, 100]`. - fn disapprove_proposal(p: u32, ) -> Weight { + fn disapprove_proposal(_p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `226 + p * (32 ±0)` - // Estimated: `1711 + p * (32 ±0)` - // Minimum execution time: 6_650_000 picoseconds. - Weight::from_parts(7_941_746, 0) - .saturating_add(Weight::from_parts(0, 1711)) - // Standard Error: 337 - .saturating_add(Weight::from_parts(96_988, 0).saturating_mul(p.into())) + // Measured: `224 + p * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 754_675_000 picoseconds. + Weight::from_parts(1_018_024_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(p.into())) } } @@ -336,7 +274,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 15736 + > 990 ); } #[test] @@ -348,7 +286,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1555 + > 990 ); } #[test] @@ -360,7 +298,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3535 + > 990 ); } #[test] @@ -372,7 +310,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3751 + > 990 ); } #[test] @@ -384,7 +322,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4276 + > 990 ); } #[test] @@ -396,7 +334,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3846 + > 990 ); } #[test] @@ -408,7 +346,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4020 + > 990 ); } #[test] @@ -420,7 +358,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3866 + > 990 ); } #[test] @@ -432,7 +370,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4040 + > 990 ); } #[test] @@ -444,7 +382,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1711 + > 990 ); } } diff --git a/runtimes/peregrine/src/weights/pallet_did_lookup_did_lookup.rs b/runtimes/peregrine/src/weights/pallet_did_lookup.rs similarity index 73% rename from runtimes/peregrine/src/weights/pallet_did_lookup_did_lookup.rs rename to runtimes/peregrine/src/weights/pallet_did_lookup.rs index 740d3d9ff3..4e72c59d6b 100644 --- a/runtimes/peregrine/src/weights/pallet_did_lookup_did_lookup.rs +++ b/runtimes/peregrine/src/weights/pallet_did_lookup.rs @@ -19,25 +19,25 @@ //! Autogenerated weights for `pallet_did_lookup` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-20, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 // --chain=dev // --pallet=pallet-did-lookup // --extrinsic=* -// --output=./runtimes/peregrine/src/weights/pallet_did_lookup.rs +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -50,178 +50,178 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl pallet_did_lookup::WeightInfo for WeightInfo { /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_account_multisig_sr25519() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 127_399_000 picoseconds. - Weight::from_parts(128_343_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 8_231_783_000 picoseconds. + Weight::from_parts(8_231_783_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_account_multisig_ed25519() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 140_373_000 picoseconds. - Weight::from_parts(142_236_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 3_532_242_000 picoseconds. + Weight::from_parts(3_532_242_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_account_multisig_ecdsa() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 131_340_000 picoseconds. - Weight::from_parts(133_723_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 4_624_007_000 picoseconds. + Weight::from_parts(4_624_007_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_eth_account() -> Weight { // Proof Size summary in bytes: // Measured: `449` - // Estimated: `3658` - // Minimum execution time: 132_297_000 picoseconds. - Weight::from_parts(134_225_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 7_807_837_000 picoseconds. + Weight::from_parts(7_807_837_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_sender() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 82_978_000 picoseconds. - Weight::from_parts(85_676_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 3_061_394_000 picoseconds. + Weight::from_parts(3_061_394_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) fn remove_sender_association() -> Weight { // Proof Size summary in bytes: // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 47_480_000 picoseconds. - Weight::from_parts(48_148_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 1_769_975_000 picoseconds. + Weight::from_parts(1_769_975_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) fn remove_account_association() -> Weight { // Proof Size summary in bytes: // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 48_550_000 picoseconds. - Weight::from_parts(49_242_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 1_514_759_000 picoseconds. + Weight::from_parts(1_514_759_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn change_deposit_owner() -> Weight { // Proof Size summary in bytes: // Measured: `647` - // Estimated: `6326` - // Minimum execution time: 77_392_000 picoseconds. - Weight::from_parts(79_999_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) + // Estimated: `990` + // Minimum execution time: 2_512_929_000 picoseconds. + Weight::from_parts(2_512_929_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn update_deposit() -> Weight { // Proof Size summary in bytes: // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 71_171_000 picoseconds. - Weight::from_parts(72_100_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 2_369_856_000 picoseconds. + Weight::from_parts(2_369_856_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -238,7 +238,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -250,7 +250,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -262,7 +262,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -274,7 +274,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -286,7 +286,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -298,7 +298,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -310,7 +310,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -322,7 +322,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 6326 + > 990 ); } #[test] @@ -334,7 +334,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } } diff --git a/runtimes/peregrine/src/weights/pallet_dot_names.rs b/runtimes/peregrine/src/weights/pallet_dot_names.rs new file mode 100644 index 0000000000..e592de56cc --- /dev/null +++ b/runtimes/peregrine/src/weights/pallet_dot_names.rs @@ -0,0 +1,269 @@ +// KILT Blockchain – https://botlabs.org +// Copyright (C) 2019-2024 BOTLabs GmbH + +// The KILT Blockchain 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. + +// The KILT Blockchain 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 this program. If not, see . + +// If you feel like getting in touch with us, you can do so at info@botlabs.org + +//! Autogenerated weights for `pallet_dot_names` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 + +// Executed Command: +// ./target/debug/kilt-parachain +// benchmark +// pallet +// --heap-pages=4096 +// --chain=dev +// --pallet=pallet-dot-names +// --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_imports)] +#![allow(clippy::as_conversions)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_web3_names as pallet_dot_names; + +/// Weight functions for `pallet_dot_names`. +pub struct WeightInfo(PhantomData); +impl pallet_dot_names::WeightInfo for WeightInfo { + /// Storage: `DotNames::Names` (r:1 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `DotNames::Banned` (r:1 w:0) + /// Proof: `DotNames::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn claim(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `147` + // Estimated: `990` + // Minimum execution time: 2_034_175_000 picoseconds. + Weight::from_parts(2_047_230_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `DotNames::Names` (r:1 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn release_by_owner() -> Weight { + // Proof Size summary in bytes: + // Measured: `474` + // Estimated: `990` + // Minimum execution time: 1_503_537_000 picoseconds. + Weight::from_parts(1_503_537_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `DotNames::Names` (r:0 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn reclaim_deposit(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `369 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_430_949_000 picoseconds. + Weight::from_parts(1_575_358_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `DotNames::Banned` (r:1 w:1) + /// Proof: `DotNames::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `DotNames::Names` (r:0 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn ban(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `369 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_543_707_000 picoseconds. + Weight::from_parts(1_800_627_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `DotNames::Banned` (r:1 w:1) + /// Proof: `DotNames::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn unban(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `83 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 645_352_000 picoseconds. + Weight::from_parts(657_482_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `DotNames::Names` (r:1 w:0) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:2 w:2) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn change_deposit_owner() -> Weight { + // Proof Size summary in bytes: + // Measured: `581` + // Estimated: `990` + // Minimum execution time: 2_716_990_000 picoseconds. + Weight::from_parts(2_716_990_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn update_deposit() -> Weight { + // Proof Size summary in bytes: + // Measured: `403` + // Estimated: `990` + // Minimum execution time: 2_180_700_000 picoseconds. + Weight::from_parts(2_180_700_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} + +#[cfg(test)] +mod tests { + #[test] + fn test_claim() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_release_by_owner() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_reclaim_deposit() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_ban() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_unban() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_change_deposit_owner() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_update_deposit() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } +} diff --git a/runtimes/peregrine/src/weights/pallet_membership.rs b/runtimes/peregrine/src/weights/pallet_membership.rs index 39d5997164..333c2fb6b9 100644 --- a/runtimes/peregrine/src/weights/pallet_membership.rs +++ b/runtimes/peregrine/src/weights/pallet_membership.rs @@ -19,25 +19,25 @@ //! Autogenerated weights for `pallet_membership` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-20, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 // --chain=dev // --pallet=pallet-membership // --extrinsic=* -// --output=./runtimes/peregrine/src/weights/pallet_membership.rs +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -49,159 +49,105 @@ use sp_std::marker::PhantomData; /// Weight functions for `pallet_membership`. pub struct WeightInfo(PhantomData); impl pallet_membership::WeightInfo for WeightInfo { - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 99]`. - fn add_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// The range of component `m` is `[1, 20]`. + fn add_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `102 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 13_140_000 picoseconds. - Weight::from_parts(13_601_267, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 269 - .saturating_add(Weight::from_parts(23_922, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `135 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 353_129_000 picoseconds. + Weight::from_parts(377_804_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:0) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[2, 100]`. - fn remove_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:0) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[2, 21]`. + fn remove_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 15_032_000 picoseconds. - Weight::from_parts(15_408_780, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 2_360 - .saturating_add(Weight::from_parts(30_552, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `189 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 390_037_000 picoseconds. + Weight::from_parts(404_106_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:0) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[2, 100]`. - fn swap_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:0) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[2, 21]`. + fn swap_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 15_260_000 picoseconds. - Weight::from_parts(15_919_548, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 303 - .saturating_add(Weight::from_parts(35_862, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `189 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 393_449_000 picoseconds. + Weight::from_parts(403_152_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:0) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn reset_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:0) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn reset_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 14_309_000 picoseconds. - Weight::from_parts(16_116_348, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 2_958 - .saturating_add(Weight::from_parts(150_504, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `187 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 448_047_000 picoseconds. + Weight::from_parts(448_683_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:1) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn change_key(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:1) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn change_key(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 15_169_000 picoseconds. - Weight::from_parts(16_416_917, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 424 - .saturating_add(Weight::from_parts(36_041, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(4)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `187 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 437_193_000 picoseconds. + Weight::from_parts(516_613_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:0) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalMembership::Prime` (r:0 w:1) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn set_prime(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:0) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:0 w:1) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn set_prime(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `32 + m * (32 ±0)` - // Estimated: `4687 + m * (32 ±0)` - // Minimum execution time: 7_126_000 picoseconds. - Weight::from_parts(7_475_376, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 1_232 - .saturating_add(Weight::from_parts(14_898, 0).saturating_mul(m.into())) + // Measured: `135 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 305_850_000 picoseconds. + Weight::from_parts(329_866_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(2)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Prime` (r:0 w:1) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn clear_prime(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Prime` (r:0 w:1) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn clear_prime(_m: u32, ) -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_640_000 picoseconds. - Weight::from_parts(2_874_782, 0) + // Minimum execution time: 163_207_000 picoseconds. + Weight::from_parts(171_566_000, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 419 - .saturating_add(Weight::from_parts(1_068, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes(1)) } } @@ -216,7 +162,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -228,7 +174,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -240,7 +186,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -252,7 +198,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -264,7 +210,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -276,7 +222,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } } diff --git a/runtimes/peregrine/src/weights/pallet_collective_technical_committee.rs b/runtimes/peregrine/src/weights/pallet_technical_committee_collective.rs similarity index 55% rename from runtimes/peregrine/src/weights/pallet_collective_technical_committee.rs rename to runtimes/peregrine/src/weights/pallet_technical_committee_collective.rs index 2101f6d43f..96d316ac5a 100644 --- a/runtimes/peregrine/src/weights/pallet_collective_technical_committee.rs +++ b/runtimes/peregrine/src/weights/pallet_technical_committee_collective.rs @@ -16,27 +16,27 @@ // If you feel like getting in touch with us, you can do so at info@botlabs.org -//! Autogenerated weights for `pallet_collective` +//! Autogenerated weights for `pallet_technical_committee_collective` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-08-23, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 // --chain=dev -// --pallet=pallet-collective +// --pallet=pallet-technical-committee-collective // --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs // --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] @@ -46,282 +46,233 @@ use frame_support::{traits::Get, weights::Weight}; use sp_std::marker::PhantomData; -/// Weight functions for `pallet_collective`. +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_collective as pallet_technical_committee_collective; + +/// Weight functions for `pallet_technical_committee_collective`. pub struct WeightInfo(PhantomData); -impl pallet_collective::WeightInfo for WeightInfo { +impl pallet_technical_committee_collective::WeightInfo for WeightInfo { /// Storage: `TechnicalCommittee::Members` (r:1 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:100 w:100) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[0, 100]`. - /// The range of component `n` is `[0, 100]`. - /// The range of component `p` is `[0, 100]`. + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[0, 100]`. /// The range of component `n` is `[0, 100]`. /// The range of component `p` is `[0, 100]`. - fn set_members(m: u32, _n: u32, p: u32, ) -> Weight { + fn set_members(m: u32, n: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `0 + m * (3232 ±0) + p * (3194 ±0)` - // Estimated: `15770 + m * (1967 ±16) + p * (4336 ±16)` - // Minimum execution time: 8_938_000 picoseconds. - Weight::from_parts(9_304_000, 0) - .saturating_add(Weight::from_parts(0, 15770)) - // Standard Error: 23_884 - .saturating_add(Weight::from_parts(2_555_049, 0).saturating_mul(m.into())) - // Standard Error: 23_884 - .saturating_add(Weight::from_parts(4_568_397, 0).saturating_mul(p.into())) + // Measured: `0 + m * (3228 ±0) + p * (3195 ±0)` + // Estimated: `990` + // Minimum execution time: 460_642_000 picoseconds. + Weight::from_parts(460_642_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 255_764_641 + .saturating_add(Weight::from_parts(127_672_940, 0).saturating_mul(m.into())) + // Standard Error: 255_764_641 + .saturating_add(Weight::from_parts(34_349_310, 0).saturating_mul(n.into())) + // Standard Error: 255_764_641 + .saturating_add(Weight::from_parts(126_599_270, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) - .saturating_add(Weight::from_parts(0, 1967).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 4336).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. - fn execute(b: u32, m: u32, ) -> Weight { + fn execute(b: u32, _m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `103 + m * (32 ±0)` - // Estimated: `1589 + m * (32 ±0)` - // Minimum execution time: 6_948_000 picoseconds. - Weight::from_parts(6_619_520, 0) - .saturating_add(Weight::from_parts(0, 1589)) - // Standard Error: 12 - .saturating_add(Weight::from_parts(989, 0).saturating_mul(b.into())) - // Standard Error: 128 - .saturating_add(Weight::from_parts(7_990, 0).saturating_mul(m.into())) + // Measured: `102 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 573_430_000 picoseconds. + Weight::from_parts(29_965_404_055, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 3_984_281 + .saturating_add(Weight::from_parts(2_473_578, 0).saturating_mul(b.into())) .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:0) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. fn propose_execute(b: u32, m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `103 + m * (32 ±0)` - // Estimated: `3569 + m * (32 ±0)` - // Minimum execution time: 8_195_000 picoseconds. - Weight::from_parts(7_708_951, 0) - .saturating_add(Weight::from_parts(0, 3569)) - // Standard Error: 13 - .saturating_add(Weight::from_parts(1_041, 0).saturating_mul(b.into())) - // Standard Error: 143 - .saturating_add(Weight::from_parts(13_823, 0).saturating_mul(m.into())) + // Measured: `102 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 715_079_000 picoseconds. + Weight::from_parts(636_745_116, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 10_109 + .saturating_add(Weight::from_parts(75_330, 0).saturating_mul(b.into())) + // Standard Error: 104_360 + .saturating_add(Weight::from_parts(1_195_222, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalCount` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[2, 100]`. /// The range of component `p` is `[1, 100]`. - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[2, 100]`. - /// The range of component `p` is `[1, 100]`. - fn propose_proposed(b: u32, m: u32, p: u32, ) -> Weight { + fn propose_proposed(b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `393 + m * (32 ±0) + p * (36 ±0)` - // Estimated: `3785 + m * (33 ±0) + p * (36 ±0)` - // Minimum execution time: 11_255_000 picoseconds. - Weight::from_parts(11_184_069, 0) - .saturating_add(Weight::from_parts(0, 3785)) - // Standard Error: 40 - .saturating_add(Weight::from_parts(1_759, 0).saturating_mul(b.into())) - // Standard Error: 418 - .saturating_add(Weight::from_parts(15_531, 0).saturating_mul(m.into())) - // Standard Error: 412 - .saturating_add(Weight::from_parts(114_209, 0).saturating_mul(p.into())) + // Measured: `38 + m * (32 ±0) + p * (39 ±0)` + // Estimated: `990` + // Minimum execution time: 972_408_000 picoseconds. + Weight::from_parts(1_342_425_531, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 40_523 + .saturating_add(Weight::from_parts(142_705, 0).saturating_mul(b.into())) + // Standard Error: 418_333 + .saturating_add(Weight::from_parts(3_118_730, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) - .saturating_add(Weight::from_parts(0, 33).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[5, 100]`. + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[5, 100]`. - fn vote(m: u32, ) -> Weight { + fn vote(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `846 + m * (64 ±0)` - // Estimated: `4310 + m * (64 ±0)` - // Minimum execution time: 12_698_000 picoseconds. - Weight::from_parts(13_416_646, 0) - .saturating_add(Weight::from_parts(0, 4310)) - // Standard Error: 237 - .saturating_add(Weight::from_parts(20_581, 0).saturating_mul(m.into())) + // Measured: `845 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 604_239_000 picoseconds. + Weight::from_parts(705_575_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_disapproved(m: u32, p: u32, ) -> Weight { + fn close_early_disapproved(m: u32, _p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `435 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3880 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 13_050_000 picoseconds. - Weight::from_parts(13_115_665, 0) - .saturating_add(Weight::from_parts(0, 3880)) - // Standard Error: 495 - .saturating_add(Weight::from_parts(24_190, 0).saturating_mul(m.into())) - // Standard Error: 483 - .saturating_add(Weight::from_parts(109_525, 0).saturating_mul(p.into())) + // Measured: `219 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 1_062_882_000 picoseconds. + Weight::from_parts(17_615_015_534, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 1_146_969 + .saturating_add(Weight::from_parts(1_026_338, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_early_approved(_b: u32, m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `737 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4054 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 18_600_000 picoseconds. - Weight::from_parts(20_000_597, 0) - .saturating_add(Weight::from_parts(0, 4054)) - // Standard Error: 83 - .saturating_add(Weight::from_parts(1_128, 0).saturating_mul(b.into())) - // Standard Error: 882 - .saturating_add(Weight::from_parts(4_331, 0).saturating_mul(m.into())) - // Standard Error: 860 - .saturating_add(Weight::from_parts(140_064, 0).saturating_mul(p.into())) + // Measured: `434 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_150_858_000 picoseconds. + Weight::from_parts(17_456_729_928, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 729_009 + .saturating_add(Weight::from_parts(116_718, 0).saturating_mul(m.into())) + // Standard Error: 706_917 + .saturating_add(Weight::from_parts(4_476_141, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. fn close_disapproved(m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `455 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3900 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 14_181_000 picoseconds. - Weight::from_parts(14_468_852, 0) - .saturating_add(Weight::from_parts(0, 3900)) - // Standard Error: 396 - .saturating_add(Weight::from_parts(20_054, 0).saturating_mul(m.into())) - // Standard Error: 386 - .saturating_add(Weight::from_parts(110_460, 0).saturating_mul(p.into())) + // Measured: `239 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 876_906_000 picoseconds. + Weight::from_parts(876_906_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 77_271_809 + .saturating_add(Weight::from_parts(34_940_280, 0).saturating_mul(m.into())) + // Standard Error: 77_291_124 + .saturating_add(Weight::from_parts(39_111_834, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_approved(_b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `757 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4074 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 19_563_000 picoseconds. - Weight::from_parts(20_320_995, 0) - .saturating_add(Weight::from_parts(0, 4074)) - // Standard Error: 81 - .saturating_add(Weight::from_parts(1_809, 0).saturating_mul(b.into())) - // Standard Error: 864 - .saturating_add(Weight::from_parts(3_798, 0).saturating_mul(m.into())) - // Standard Error: 842 - .saturating_add(Weight::from_parts(144_696, 0).saturating_mul(p.into())) + // Measured: `454 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_610_558_000 picoseconds. + Weight::from_parts(2_769_131_417, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 10_668_245 + .saturating_add(Weight::from_parts(5_164_747, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `p` is `[1, 100]`. - fn disapprove_proposal(p: u32, ) -> Weight { + fn disapprove_proposal(_p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `260 + p * (32 ±0)` - // Estimated: `1745 + p * (32 ±0)` - // Minimum execution time: 6_792_000 picoseconds. - Weight::from_parts(7_993_416, 0) - .saturating_add(Weight::from_parts(0, 1745)) - // Standard Error: 335 - .saturating_add(Weight::from_parts(96_207, 0).saturating_mul(p.into())) + // Measured: `258 + p * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 1_112_072_000 picoseconds. + Weight::from_parts(1_726_467_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(p.into())) } } @@ -336,7 +287,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 15770 + > 990 ); } #[test] @@ -348,7 +299,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1589 + > 990 ); } #[test] @@ -360,7 +311,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3569 + > 990 ); } #[test] @@ -372,7 +323,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3785 + > 990 ); } #[test] @@ -384,7 +335,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4310 + > 990 ); } #[test] @@ -396,7 +347,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3880 + > 990 ); } #[test] @@ -408,7 +359,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4054 + > 990 ); } #[test] @@ -420,7 +371,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3900 + > 990 ); } #[test] @@ -432,7 +383,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4074 + > 990 ); } #[test] @@ -444,7 +395,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1745 + > 990 ); } } diff --git a/runtimes/peregrine/src/weights/pallet_technical_membership.rs b/runtimes/peregrine/src/weights/pallet_technical_membership.rs new file mode 100644 index 0000000000..349df77da8 --- /dev/null +++ b/runtimes/peregrine/src/weights/pallet_technical_membership.rs @@ -0,0 +1,265 @@ +// KILT Blockchain – https://botlabs.org +// Copyright (C) 2019-2024 BOTLabs GmbH + +// The KILT Blockchain 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. + +// The KILT Blockchain 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 this program. If not, see . + +// If you feel like getting in touch with us, you can do so at info@botlabs.org + +//! Autogenerated weights for `pallet_technical_membership` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 + +// Executed Command: +// ./target/debug/kilt-parachain +// benchmark +// pallet +// --heap-pages=4096 +// --chain=dev +// --pallet=pallet-technical-membership +// --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_imports)] +#![allow(clippy::as_conversions)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_membership as pallet_technical_membership; + +/// Weight functions for `pallet_technical_membership`. +pub struct WeightInfo(PhantomData); +impl pallet_technical_membership::WeightInfo for WeightInfo { + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 99]`. + fn add_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `133 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 405_749_000 picoseconds. + Weight::from_parts(498_827_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:0) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[2, 100]`. + fn remove_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `239 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 500_744_000 picoseconds. + Weight::from_parts(527_487_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:0) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[2, 100]`. + fn swap_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `239 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 511_254_000 picoseconds. + Weight::from_parts(993_980_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:0) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn reset_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `237 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 534_955_000 picoseconds. + Weight::from_parts(688_451_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:1) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn change_key(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `237 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 538_986_000 picoseconds. + Weight::from_parts(598_771_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:0) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:0 w:1) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn set_prime(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `30 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 259_951_000 picoseconds. + Weight::from_parts(340_969_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `TechnicalMembership::Prime` (r:0 w:1) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn clear_prime(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 154_822_000 picoseconds. + Weight::from_parts(220_683_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(2)) + } +} + +#[cfg(test)] +mod tests { + #[test] + fn test_add_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_remove_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_swap_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_reset_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_change_key() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_set_prime() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } +} diff --git a/runtimes/peregrine/src/weights/pallet_unique_linking.rs b/runtimes/peregrine/src/weights/pallet_unique_linking.rs new file mode 100644 index 0000000000..8b16e82ef5 --- /dev/null +++ b/runtimes/peregrine/src/weights/pallet_unique_linking.rs @@ -0,0 +1,325 @@ +// KILT Blockchain – https://botlabs.org +// Copyright (C) 2019-2024 BOTLabs GmbH + +// The KILT Blockchain 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. + +// The KILT Blockchain 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 this program. If not, see . + +// If you feel like getting in touch with us, you can do so at info@botlabs.org + +//! Autogenerated weights for `pallet_unique_linking` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 + +// Executed Command: +// ./target/debug/kilt-parachain +// benchmark +// pallet +// --heap-pages=4096 +// --chain=dev +// --pallet=pallet-unique-linking +// --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_imports)] +#![allow(clippy::as_conversions)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_did_lookup as pallet_unique_linking; + +/// Weight functions for `pallet_unique_linking`. +pub struct WeightInfo(PhantomData); +impl pallet_unique_linking::WeightInfo for WeightInfo { + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_account_multisig_sr25519() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 25_113_487_000 picoseconds. + Weight::from_parts(25_113_487_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_account_multisig_ed25519() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 3_828_833_000 picoseconds. + Weight::from_parts(3_828_833_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_account_multisig_ecdsa() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 3_368_653_000 picoseconds. + Weight::from_parts(3_368_653_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_eth_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `455` + // Estimated: `990` + // Minimum execution time: 3_868_482_000 picoseconds. + Weight::from_parts(3_868_482_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_sender() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 3_316_476_000 picoseconds. + Weight::from_parts(3_316_476_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:0 w:1) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + fn remove_sender_association() -> Weight { + // Proof Size summary in bytes: + // Measured: `395` + // Estimated: `990` + // Minimum execution time: 1_563_980_000 picoseconds. + Weight::from_parts(1_563_980_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:0 w:1) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + fn remove_account_association() -> Weight { + // Proof Size summary in bytes: + // Measured: `395` + // Estimated: `990` + // Minimum execution time: 1_550_726_000 picoseconds. + Weight::from_parts(1_550_726_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:2 w:2) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn change_deposit_owner() -> Weight { + // Proof Size summary in bytes: + // Measured: `502` + // Estimated: `990` + // Minimum execution time: 2_422_759_000 picoseconds. + Weight::from_parts(2_422_759_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn update_deposit() -> Weight { + // Proof Size summary in bytes: + // Measured: `395` + // Estimated: `990` + // Minimum execution time: 2_447_655_000 picoseconds. + Weight::from_parts(2_447_655_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} + +#[cfg(test)] +mod tests { + #[test] + fn test_associate_account_multisig_sr25519() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_account_multisig_ed25519() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_account_multisig_ecdsa() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_eth_account() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_sender() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_remove_sender_association() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_remove_account_association() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_change_deposit_owner() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_update_deposit() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } +} diff --git a/runtimes/peregrine/src/weights/pallet_web3_names_web3_names.rs b/runtimes/peregrine/src/weights/pallet_web3_names.rs similarity index 70% rename from runtimes/peregrine/src/weights/pallet_web3_names_web3_names.rs rename to runtimes/peregrine/src/weights/pallet_web3_names.rs index edfdbcff1f..e65ac2f0ed 100644 --- a/runtimes/peregrine/src/weights/pallet_web3_names_web3_names.rs +++ b/runtimes/peregrine/src/weights/pallet_web3_names.rs @@ -19,25 +19,25 @@ //! Autogenerated weights for `pallet_web3_names` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-20, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 // --chain=dev // --pallet=pallet-web3-names // --extrinsic=* -// --output=./runtimes/peregrine/src/weights/pallet_web3_names.rs +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -50,146 +50,140 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl pallet_web3_names::WeightInfo for WeightInfo { /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Web3Names::Banned` (r:1 w:0) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. - fn claim(n: u32, ) -> Weight { + fn claim(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `111` - // Estimated: `3658` - // Minimum execution time: 56_002_000 picoseconds. - Weight::from_parts(57_034_446, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 1_741 - .saturating_add(Weight::from_parts(17_996, 0).saturating_mul(n.into())) + // Measured: `147` + // Estimated: `990` + // Minimum execution time: 1_933_283_000 picoseconds. + Weight::from_parts(2_123_318_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn release_by_owner() -> Weight { // Proof Size summary in bytes: - // Measured: `515` - // Estimated: `3658` - // Minimum execution time: 49_858_000 picoseconds. - Weight::from_parts(50_437_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Measured: `552` + // Estimated: `990` + // Minimum execution time: 1_704_333_000 picoseconds. + Weight::from_parts(1_704_333_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. - fn reclaim_deposit(n: u32, ) -> Weight { + fn reclaim_deposit(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 47_552_000 picoseconds. - Weight::from_parts(48_579_429, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 5_097 - .saturating_add(Weight::from_parts(202, 0).saturating_mul(n.into())) + // Measured: `447 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_632_584_000 picoseconds. + Weight::from_parts(1_797_797_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. fn ban(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 52_931_000 picoseconds. - Weight::from_parts(54_749_477, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Measured: `447 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_884_191_000 picoseconds. + Weight::from_parts(2_552_638_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. - fn unban(n: u32, ) -> Weight { + fn unban(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `47 + n * (1 ±0)` - // Estimated: `3514` - // Minimum execution time: 12_517_000 picoseconds. - Weight::from_parts(12_938_732, 0) - .saturating_add(Weight::from_parts(0, 3514)) - // Standard Error: 2_619 - .saturating_add(Weight::from_parts(22_854, 0).saturating_mul(n.into())) + // Measured: `83 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 607_060_000 picoseconds. + Weight::from_parts(614_873_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: `Web3Names::Names` (r:1 w:0) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn change_deposit_owner() -> Weight { // Proof Size summary in bytes: - // Measured: `622` - // Estimated: `6326` - // Minimum execution time: 79_612_000 picoseconds. - Weight::from_parts(80_738_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) + // Measured: `659` + // Estimated: `990` + // Minimum execution time: 3_036_222_000 picoseconds. + Weight::from_parts(3_036_222_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn update_deposit() -> Weight { // Proof Size summary in bytes: - // Measured: `370` - // Estimated: `3658` - // Minimum execution time: 64_512_000 picoseconds. - Weight::from_parts(65_038_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Measured: `407` + // Estimated: `990` + // Minimum execution time: 2_369_820_000 picoseconds. + Weight::from_parts(2_369_820_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -206,7 +200,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -218,7 +212,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -230,7 +224,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -242,7 +236,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -254,7 +248,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3514 + > 990 ); } #[test] @@ -266,7 +260,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 6326 + > 990 ); } #[test] @@ -278,7 +272,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } } diff --git a/runtimes/spiritnet/src/lib.rs b/runtimes/spiritnet/src/lib.rs index 6b2f0a9201..aa5964d2a4 100644 --- a/runtimes/spiritnet/src/lib.rs +++ b/runtimes/spiritnet/src/lib.rs @@ -27,6 +27,7 @@ #[cfg(feature = "std")] include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); +use cfg_if::cfg_if; use cumulus_pallet_parachain_system::RelayNumberMonotonicallyIncreases; use frame_support::{ construct_runtime, @@ -35,7 +36,7 @@ use frame_support::{ traits::{ fungible::HoldConsideration, tokens::{PayFromAccount, UnityAssetBalanceConversion}, - AsEnsureOriginWithArg, ConstU32, EitherOfDiverse, EnqueueWithOrigin, Everything, InstanceFilter, + AsEnsureOriginWithArg, ChangeMembers, ConstU32, EitherOfDiverse, EnqueueWithOrigin, Everything, InstanceFilter, LinearStoragePrice, PrivilegeCmp, }, weights::{ConstantMultiplier, Weight}, @@ -528,7 +529,7 @@ impl pallet_collective::Config for Runtime { type MaxProposals = constants::governance::CouncilMaxProposals; type MaxMembers = constants::governance::CouncilMaxMembers; type DefaultVote = pallet_collective::PrimeDefaultVote; - type WeightInfo = weights::pallet_collective_council::WeightInfo; + type WeightInfo = weights::pallet_collective::WeightInfo; type SetMembersOrigin = EnsureRoot; } @@ -542,7 +543,7 @@ impl pallet_collective::Config for Runtime { type MaxProposals = constants::governance::TechnicalMaxProposals; type MaxMembers = constants::governance::TechnicalMaxMembers; type DefaultVote = pallet_collective::PrimeDefaultVote; - type WeightInfo = weights::pallet_collective_technical_committee::WeightInfo; + type WeightInfo = weights::pallet_technical_committee_collective::WeightInfo; type SetMembersOrigin = EnsureRoot; } @@ -557,7 +558,28 @@ impl pallet_membership::Config for Runtime { type MembershipInitialized = TechnicalCommittee; type MembershipChanged = TechnicalCommittee; type MaxMembers = constants::governance::TechnicalMaxMembers; - type WeightInfo = weights::pallet_membership::WeightInfo; + type WeightInfo = weights::pallet_technical_membership::WeightInfo; +} + +// Implementation of `MembershipChanged` equivalent to using `()` but that +// returns `Some(AccountId::new([0; 32]))` in `get_prime()` only when +// benchmarking. TODO: Remove once we upgrade with a version containing the fix: https://github.com/paritytech/polkadot-sdk/pull/6439 +pub struct MockMembershipChangedForBenchmarks; + +impl ChangeMembers for MockMembershipChangedForBenchmarks { + fn change_members_sorted(incoming: &[AccountId], outgoing: &[AccountId], sorted_new: &[AccountId]) { + <()>::change_members_sorted(incoming, outgoing, sorted_new) + } + + fn get_prime() -> Option { + cfg_if! { + if #[cfg(feature = "runtime-benchmark")] { + Some(AccountId::new([0; 32])) + } else { + <()>::get_prime() + } + } + } } type TipsMembershipProvider = pallet_membership::Instance2; @@ -569,7 +591,7 @@ impl pallet_membership::Config for Runtime { type ResetOrigin = MoreThanHalfCouncil; type PrimeOrigin = MoreThanHalfCouncil; type MembershipInitialized = (); - type MembershipChanged = (); + type MembershipChanged = MockMembershipChangedForBenchmarks; type MaxMembers = constants::governance::TipperMaxMembers; type WeightInfo = weights::pallet_membership::WeightInfo; } @@ -695,7 +717,7 @@ impl pallet_did_lookup::Config for Runtime { type EnsureOrigin = did::EnsureDidOrigin; type OriginSuccess = did::DidRawOrigin; - type WeightInfo = weights::pallet_did_lookup_did_lookup::WeightInfo; + type WeightInfo = weights::pallet_did_lookup::WeightInfo; type BalanceMigrationManager = Migration; // Do not change the below flag to `true` without also deploying a runtime // migration which removes any links that point to the same DID! @@ -713,7 +735,7 @@ impl pallet_did_lookup::Config for Runtime { type RuntimeEvent = RuntimeEvent; type RuntimeHoldReason = RuntimeHoldReason; type UniqueLinkingEnabled = ConstBool; - type WeightInfo = weights::pallet_did_lookup_unique_linking::WeightInfo; + type WeightInfo = weights::pallet_unique_linking::WeightInfo; } impl pallet_web3_names::Config for Runtime { @@ -728,8 +750,11 @@ impl pallet_web3_names::Config for Runtime { type MinNameLength = constants::web3_names::MinNameLength; type Web3Name = pallet_web3_names::web3_name::AsciiWeb3Name; type Web3NameOwner = DidIdentifier; - type WeightInfo = weights::pallet_web3_names_web3_names::WeightInfo; + type WeightInfo = weights::pallet_web3_names::WeightInfo; type BalanceMigrationManager = Migration; + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = benches::Web3NamesBenchmarkHelper; } pub type DotName = runtime_common::DotName<{ constants::dot_names::MIN_LENGTH }, { constants::dot_names::MAX_LENGTH }>; @@ -748,7 +773,10 @@ impl pallet_web3_names::Config for Runtime { type RuntimeHoldReason = RuntimeHoldReason; type Web3Name = DotName; type Web3NameOwner = DidIdentifier; - type WeightInfo = weights::pallet_web3_names_dot_names::WeightInfo; + type WeightInfo = weights::pallet_dot_names::WeightInfo; + + #[cfg(feature = "runtime-benchmarks")] + type BenchmarkHelper = benches::DotNamesBenchmarkHelper; } impl pallet_inflation::Config for Runtime { @@ -1282,14 +1310,26 @@ mod benches { use frame_system::RawOrigin; use pallet_asset_switch::PartialBenchmarkInfo; use runtime_common::AccountId; + use sp_std::{vec, vec::Vec}; use xcm::v4::{Asset, AssetId, Fungibility, Junction, Junctions, Location, ParentThen}; - use crate::{Fungibles, ParachainSystem}; + use crate::{DotNamesDeployment, Fungibles, ParachainSystem, Runtime}; frame_support::parameter_types! { pub const MaxBalance: crate::Balance = crate::Balance::max_value(); } + /// Workaround for a bug in the benchmarking code around instances. + /// Upstream fix PR: https://github.com/paritytech/polkadot-sdk/pull/6435 + #[allow(unused_imports)] + use pallet_collective as pallet_technical_committee_collective; + #[allow(unused_imports)] + use pallet_did_lookup as pallet_unique_linking; + #[allow(unused_imports)] + use pallet_membership as pallet_technical_membership; + #[allow(unused_imports)] + use pallet_web3_names as pallet_dot_names; + frame_benchmarking::define_benchmarks!( [frame_system, SystemBench::] [pallet_timestamp, Timestamp] @@ -1298,9 +1338,6 @@ mod benches { [pallet_session, SessionBench::] [parachain_staking, ParachainStaking] [pallet_democracy, Democracy] - [pallet_collective, Council] - [pallet_collective, TechnicalCommittee] - [pallet_membership, TechnicalMembership] [pallet_treasury, Treasury] [pallet_utility, Utility] [pallet_vesting, Vesting] @@ -1314,10 +1351,6 @@ mod benches { [delegation, Delegation] [did, Did] [pallet_inflation, Inflation] - [pallet_did_lookup, DidLookup] - [pallet_did_lookup, UniqueLinking] - [pallet_web3_names, Web3Names] - [pallet_web3_names, DotNames] [public_credentials, PublicCredentials] [pallet_xcm, PalletXcmExtrinsicsBenchmark::] [pallet_migration, Migration] @@ -1328,6 +1361,18 @@ mod benches { [pallet_message_queue, MessageQueue] [cumulus_pallet_parachain_system, ParachainSystem] [frame_benchmarking::baseline, Baseline::] + // pallet_collective instances + [pallet_collective, Council] + [pallet_technical_committee_collective, TechnicalCommittee] + // pallet_membership instances + [pallet_membership, TipsMembership] + [pallet_technical_membership, TechnicalMembership] + // pallet_did_lookup instances + [pallet_did_lookup, DidLookup] + [pallet_unique_linking, UniqueLinking] + // pallet_web3_names instances + [pallet_web3_names, Web3Names] + [pallet_dot_names, DotNames] ); // Required since the pallet `AssetTransactor` will try to deduct the XCM fee @@ -1374,6 +1419,39 @@ mod benches { }) } } + + pub struct Web3NamesBenchmarkHelper; + + impl pallet_web3_names::BenchmarkHelper for Web3NamesBenchmarkHelper { + fn generate_name_input_with_length(length: usize) -> Vec { + let input = vec![b'a'; length]; + + debug_assert!(>::Web3Name::try_from(input.clone()).is_ok()); + input + } + } + + pub struct DotNamesBenchmarkHelper; + + impl pallet_web3_names::BenchmarkHelper for DotNamesBenchmarkHelper { + // Returns the name `11[...]111.dot` with as many `1`s as the provided length - + // 4, to account for the ".dot" suffix. + fn generate_name_input_with_length(length: usize) -> Vec { + let suffix_length = runtime_common::constants::dot_names::DOT_NAME_SUFFIX.len(); + let remaining_name_length = length + .checked_sub(suffix_length) + .expect("Provided length should cover at least the length of the suffix."); + let input = vec![b'1'; remaining_name_length] + .into_iter() + .chain(runtime_common::constants::dot_names::DOT_NAME_SUFFIX.bytes()) + .collect::>(); + + debug_assert!( + >::Web3Name::try_from(input.clone()).is_ok() + ); + input + } + } } impl_runtime_apis! { diff --git a/runtimes/spiritnet/src/weights/mod.rs b/runtimes/spiritnet/src/weights/mod.rs index fcd027cbf2..30e79fa609 100644 --- a/runtimes/spiritnet/src/weights/mod.rs +++ b/runtimes/spiritnet/src/weights/mod.rs @@ -26,13 +26,12 @@ pub mod frame_system; pub mod pallet_asset_switch; pub mod pallet_assets; pub mod pallet_balances; -pub mod pallet_collective_council; -pub mod pallet_collective_technical_committee; +pub mod pallet_collective; pub mod pallet_democracy; pub mod pallet_deposit_storage; -pub mod pallet_did_lookup_did_lookup; -pub mod pallet_did_lookup_unique_linking; +pub mod pallet_did_lookup; pub mod pallet_dip_provider; +pub mod pallet_dot_names; pub mod pallet_indices; pub mod pallet_inflation; pub mod pallet_membership; @@ -43,13 +42,15 @@ pub mod pallet_preimage; pub mod pallet_proxy; pub mod pallet_scheduler; pub mod pallet_session; +pub mod pallet_technical_committee_collective; +pub mod pallet_technical_membership; pub mod pallet_timestamp; pub mod pallet_tips; pub mod pallet_treasury; +pub mod pallet_unique_linking; pub mod pallet_utility; pub mod pallet_vesting; -pub mod pallet_web3_names_dot_names; -pub mod pallet_web3_names_web3_names; +pub mod pallet_web3_names; pub mod pallet_xcm; pub mod parachain_staking; pub mod public_credentials; diff --git a/runtimes/spiritnet/src/weights/pallet_collective_council.rs b/runtimes/spiritnet/src/weights/pallet_collective.rs similarity index 56% rename from runtimes/spiritnet/src/weights/pallet_collective_council.rs rename to runtimes/spiritnet/src/weights/pallet_collective.rs index d0aedb9da4..545e4bf131 100644 --- a/runtimes/spiritnet/src/weights/pallet_collective_council.rs +++ b/runtimes/spiritnet/src/weights/pallet_collective.rs @@ -19,25 +19,25 @@ //! Autogenerated weights for `pallet_collective` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-08-23, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` -//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("spiritnet-dev"), DB CACHE: 1024 +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 -// --chain=spiritnet-dev +// --chain=dev // --pallet=pallet-collective // --extrinsic=* -// --output=./runtimes/spiritnet/src/weights/ +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -50,278 +50,216 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl pallet_collective::WeightInfo for WeightInfo { /// Storage: `Council::Members` (r:1 w:1) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:0) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:100 w:100) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Prime` (r:0 w:1) - /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[0, 100]`. - /// The range of component `n` is `[0, 100]`. - /// The range of component `p` is `[0, 100]`. + /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[0, 100]`. /// The range of component `n` is `[0, 100]`. /// The range of component `p` is `[0, 100]`. fn set_members(m: u32, _n: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `0 + m * (3232 ±0) + p * (3194 ±0)` - // Estimated: `15736 + m * (1967 ±16) + p * (4336 ±16)` - // Minimum execution time: 8_516_000 picoseconds. - Weight::from_parts(8_768_000, 0) - .saturating_add(Weight::from_parts(0, 15736)) - // Standard Error: 25_842 - .saturating_add(Weight::from_parts(3_070_541, 0).saturating_mul(m.into())) - // Standard Error: 25_842 - .saturating_add(Weight::from_parts(4_631_676, 0).saturating_mul(p.into())) + // Measured: `0 + m * (3228 ±0) + p * (3195 ±0)` + // Estimated: `990` + // Minimum execution time: 369_621_000 picoseconds. + Weight::from_parts(369_621_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 17_102_279 + .saturating_add(Weight::from_parts(91_979_117, 0).saturating_mul(m.into())) + // Standard Error: 17_102_279 + .saturating_add(Weight::from_parts(90_212_097, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) - .saturating_add(Weight::from_parts(0, 1967).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 4336).saturating_mul(p.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. - fn execute(b: u32, m: u32, ) -> Weight { + fn execute(b: u32, _m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `69 + m * (32 ±0)` - // Estimated: `1555 + m * (32 ±0)` - // Minimum execution time: 6_648_000 picoseconds. - Weight::from_parts(6_481_143, 0) - .saturating_add(Weight::from_parts(0, 1555)) - // Standard Error: 12 - .saturating_add(Weight::from_parts(901, 0).saturating_mul(b.into())) - // Standard Error: 128 - .saturating_add(Weight::from_parts(6_901, 0).saturating_mul(m.into())) + // Measured: `68 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 625_331_000 picoseconds. + Weight::from_parts(787_644_463, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 16_228 + .saturating_add(Weight::from_parts(62_712, 0).saturating_mul(b.into())) .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:0) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. fn propose_execute(b: u32, m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `69 + m * (32 ±0)` - // Estimated: `3535 + m * (32 ±0)` - // Minimum execution time: 7_995_000 picoseconds. - Weight::from_parts(7_547_575, 0) - .saturating_add(Weight::from_parts(0, 3535)) - // Standard Error: 13 - .saturating_add(Weight::from_parts(966, 0).saturating_mul(b.into())) - // Standard Error: 135 - .saturating_add(Weight::from_parts(13_106, 0).saturating_mul(m.into())) + // Measured: `68 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 711_111_000 picoseconds. + Weight::from_parts(658_477_137, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 17_555 + .saturating_add(Weight::from_parts(171_729, 0).saturating_mul(b.into())) + // Standard Error: 181_226 + .saturating_add(Weight::from_parts(522_904, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalCount` (r:1 w:1) - /// Proof: `Council::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:0 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[2, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[2, 100]`. /// The range of component `p` is `[1, 100]`. - fn propose_proposed(b: u32, m: u32, p: u32, ) -> Weight { + fn propose_proposed(b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `359 + m * (32 ±0) + p * (36 ±0)` - // Estimated: `3751 + m * (33 ±0) + p * (36 ±0)` - // Minimum execution time: 10_734_000 picoseconds. - Weight::from_parts(10_845_014, 0) - .saturating_add(Weight::from_parts(0, 3751)) - // Standard Error: 37 - .saturating_add(Weight::from_parts(1_861, 0).saturating_mul(b.into())) - // Standard Error: 391 - .saturating_add(Weight::from_parts(12_504, 0).saturating_mul(m.into())) - // Standard Error: 386 - .saturating_add(Weight::from_parts(111_098, 0).saturating_mul(p.into())) + // Measured: `4 + m * (32 ±0) + p * (39 ±0)` + // Estimated: `990` + // Minimum execution time: 775_269_000 picoseconds. + Weight::from_parts(905_763_953, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 89_660 + .saturating_add(Weight::from_parts(3_241, 0).saturating_mul(b.into())) + // Standard Error: 925_589 + .saturating_add(Weight::from_parts(5_095_420, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) - .saturating_add(Weight::from_parts(0, 33).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[5, 100]`. + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[5, 100]`. - fn vote(m: u32, ) -> Weight { + fn vote(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `812 + m * (64 ±0)` - // Estimated: `4276 + m * (64 ±0)` - // Minimum execution time: 12_360_000 picoseconds. - Weight::from_parts(13_143_385, 0) - .saturating_add(Weight::from_parts(0, 4276)) - // Standard Error: 202 - .saturating_add(Weight::from_parts(21_186, 0).saturating_mul(m.into())) + // Measured: `811 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 801_344_000 picoseconds. + Weight::from_parts(8_168_627_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:0 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_disapproved(m: u32, p: u32, ) -> Weight { + fn close_early_disapproved(_m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `401 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3846 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 12_388_000 picoseconds. - Weight::from_parts(13_266_787, 0) - .saturating_add(Weight::from_parts(0, 3846)) - // Standard Error: 425 - .saturating_add(Weight::from_parts(16_504, 0).saturating_mul(m.into())) - // Standard Error: 414 - .saturating_add(Weight::from_parts(103_301, 0).saturating_mul(p.into())) + // Measured: `185 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 869_858_000 picoseconds. + Weight::from_parts(951_242_033, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 608_221 + .saturating_add(Weight::from_parts(3_301_904, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_early_approved(_b: u32, _m: u32, _p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `703 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4020 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 17_675_000 picoseconds. - Weight::from_parts(18_489_344, 0) - .saturating_add(Weight::from_parts(0, 4020)) - // Standard Error: 83 - .saturating_add(Weight::from_parts(1_943, 0).saturating_mul(b.into())) - // Standard Error: 884 - .saturating_add(Weight::from_parts(1_910, 0).saturating_mul(m.into())) - // Standard Error: 861 - .saturating_add(Weight::from_parts(134_652, 0).saturating_mul(p.into())) + // Measured: `400 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_416_290_000 picoseconds. + Weight::from_parts(27_075_651_756, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Prime` (r:1 w:0) - /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:0 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. - fn close_disapproved(m: u32, p: u32, ) -> Weight { + fn close_disapproved(_m: u32, _p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `421 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3866 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 13_574_000 picoseconds. - Weight::from_parts(13_875_488, 0) - .saturating_add(Weight::from_parts(0, 3866)) - // Standard Error: 367 - .saturating_add(Weight::from_parts(19_617, 0).saturating_mul(m.into())) - // Standard Error: 358 - .saturating_add(Weight::from_parts(106_734, 0).saturating_mul(p.into())) + // Measured: `205 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 1_168_659_000 picoseconds. + Weight::from_parts(1_589_757_573, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `Council::Voting` (r:1 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Members` (r:1 w:0) - /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Prime` (r:1 w:0) - /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:1 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_approved(_b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `723 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4040 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 18_520_000 picoseconds. - Weight::from_parts(20_236_953, 0) - .saturating_add(Weight::from_parts(0, 4040)) - // Standard Error: 79 - .saturating_add(Weight::from_parts(1_300, 0).saturating_mul(b.into())) - // Standard Error: 843 - .saturating_add(Weight::from_parts(687, 0).saturating_mul(m.into())) - // Standard Error: 822 - .saturating_add(Weight::from_parts(136_320, 0).saturating_mul(p.into())) + // Measured: `420 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_204_090_000 picoseconds. + Weight::from_parts(33_870_289_808, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 2_576_837 + .saturating_add(Weight::from_parts(8_788_127, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `Council::Proposals` (r:1 w:1) - /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `Council::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `Council::Voting` (r:0 w:1) - /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `Council::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `Council::ProposalOf` (r:0 w:1) - /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `p` is `[1, 100]`. + /// Proof: `Council::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `p` is `[1, 100]`. - fn disapprove_proposal(p: u32, ) -> Weight { + fn disapprove_proposal(_p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `226 + p * (32 ±0)` - // Estimated: `1711 + p * (32 ±0)` - // Minimum execution time: 6_711_000 picoseconds. - Weight::from_parts(7_962_060, 0) - .saturating_add(Weight::from_parts(0, 1711)) - // Standard Error: 430 - .saturating_add(Weight::from_parts(93_156, 0).saturating_mul(p.into())) + // Measured: `224 + p * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 754_675_000 picoseconds. + Weight::from_parts(1_018_024_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(p.into())) } } @@ -336,7 +274,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 15736 + > 990 ); } #[test] @@ -348,7 +286,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1555 + > 990 ); } #[test] @@ -360,7 +298,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3535 + > 990 ); } #[test] @@ -372,7 +310,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3751 + > 990 ); } #[test] @@ -384,7 +322,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4276 + > 990 ); } #[test] @@ -396,7 +334,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3846 + > 990 ); } #[test] @@ -408,7 +346,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4020 + > 990 ); } #[test] @@ -420,7 +358,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3866 + > 990 ); } #[test] @@ -432,7 +370,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4040 + > 990 ); } #[test] @@ -444,7 +382,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1711 + > 990 ); } } diff --git a/runtimes/peregrine/src/weights/pallet_did_lookup_did_unique_linking.rs b/runtimes/spiritnet/src/weights/pallet_did_lookup.rs similarity index 73% rename from runtimes/peregrine/src/weights/pallet_did_lookup_did_unique_linking.rs rename to runtimes/spiritnet/src/weights/pallet_did_lookup.rs index 740d3d9ff3..4e72c59d6b 100644 --- a/runtimes/peregrine/src/weights/pallet_did_lookup_did_unique_linking.rs +++ b/runtimes/spiritnet/src/weights/pallet_did_lookup.rs @@ -19,25 +19,25 @@ //! Autogenerated weights for `pallet_did_lookup` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-20, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 // --chain=dev // --pallet=pallet-did-lookup // --extrinsic=* -// --output=./runtimes/peregrine/src/weights/pallet_did_lookup.rs +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -50,178 +50,178 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl pallet_did_lookup::WeightInfo for WeightInfo { /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_account_multisig_sr25519() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 127_399_000 picoseconds. - Weight::from_parts(128_343_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 8_231_783_000 picoseconds. + Weight::from_parts(8_231_783_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_account_multisig_ed25519() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 140_373_000 picoseconds. - Weight::from_parts(142_236_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 3_532_242_000 picoseconds. + Weight::from_parts(3_532_242_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_account_multisig_ecdsa() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 131_340_000 picoseconds. - Weight::from_parts(133_723_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 4_624_007_000 picoseconds. + Weight::from_parts(4_624_007_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_eth_account() -> Weight { // Proof Size summary in bytes: // Measured: `449` - // Estimated: `3658` - // Minimum execution time: 132_297_000 picoseconds. - Weight::from_parts(134_225_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 7_807_837_000 picoseconds. + Weight::from_parts(7_807_837_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) fn associate_sender() -> Weight { // Proof Size summary in bytes: // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 82_978_000 picoseconds. - Weight::from_parts(85_676_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 3_061_394_000 picoseconds. + Weight::from_parts(3_061_394_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) fn remove_sender_association() -> Weight { // Proof Size summary in bytes: // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 47_480_000 picoseconds. - Weight::from_parts(48_148_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 1_769_975_000 picoseconds. + Weight::from_parts(1_769_975_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) fn remove_account_association() -> Weight { // Proof Size summary in bytes: // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 48_550_000 picoseconds. - Weight::from_parts(49_242_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 1_514_759_000 picoseconds. + Weight::from_parts(1_514_759_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn change_deposit_owner() -> Weight { // Proof Size summary in bytes: // Measured: `647` - // Estimated: `6326` - // Minimum execution time: 77_392_000 picoseconds. - Weight::from_parts(79_999_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) + // Estimated: `990` + // Minimum execution time: 2_512_929_000 picoseconds. + Weight::from_parts(2_512_929_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) + /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn update_deposit() -> Weight { // Proof Size summary in bytes: // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 71_171_000 picoseconds. - Weight::from_parts(72_100_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Estimated: `990` + // Minimum execution time: 2_369_856_000 picoseconds. + Weight::from_parts(2_369_856_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -238,7 +238,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -250,7 +250,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -262,7 +262,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -274,7 +274,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -286,7 +286,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -298,7 +298,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -310,7 +310,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -322,7 +322,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 6326 + > 990 ); } #[test] @@ -334,7 +334,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } } diff --git a/runtimes/spiritnet/src/weights/pallet_did_lookup_did_lookup.rs b/runtimes/spiritnet/src/weights/pallet_did_lookup_did_lookup.rs deleted file mode 100644 index b9310a445d..0000000000 --- a/runtimes/spiritnet/src/weights/pallet_did_lookup_did_lookup.rs +++ /dev/null @@ -1,340 +0,0 @@ -// KILT Blockchain – https://botlabs.org -// Copyright (C) 2019-2024 BOTLabs GmbH - -// The KILT Blockchain 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. - -// The KILT Blockchain 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 this program. If not, see . - -// If you feel like getting in touch with us, you can do so at info@botlabs.org - -//! Autogenerated weights for `pallet_did_lookup` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` -//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("spiritnet-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/release/kilt-parachain -// benchmark -// pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled -// --heap-pages=4096 -// --steps=50 -// --repeat=20 -// --chain=spiritnet-dev -// --pallet=pallet-did-lookup -// --extrinsic=* -// --output=./runtimes/spiritnet/src/weights/pallet_did_lookup.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_imports)] -#![allow(clippy::as_conversions)] - -use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; - -/// Weight functions for `pallet_did_lookup`. -pub struct WeightInfo(PhantomData); -impl pallet_did_lookup::WeightInfo for WeightInfo { - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_account_multisig_sr25519() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 130_333_000 picoseconds. - Weight::from_parts(131_946_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_account_multisig_ed25519() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 142_549_000 picoseconds. - Weight::from_parts(144_156_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_account_multisig_ecdsa() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 131_703_000 picoseconds. - Weight::from_parts(133_877_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_eth_account() -> Weight { - // Proof Size summary in bytes: - // Measured: `449` - // Estimated: `3658` - // Minimum execution time: 134_857_000 picoseconds. - Weight::from_parts(135_895_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_sender() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 83_538_000 picoseconds. - Weight::from_parts(84_203_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - fn remove_sender_association() -> Weight { - // Proof Size summary in bytes: - // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 48_280_000 picoseconds. - Weight::from_parts(48_686_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - fn remove_account_association() -> Weight { - // Proof Size summary in bytes: - // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 49_796_000 picoseconds. - Weight::from_parts(50_261_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn change_deposit_owner() -> Weight { - // Proof Size summary in bytes: - // Measured: `647` - // Estimated: `6326` - // Minimum execution time: 78_581_000 picoseconds. - Weight::from_parts(79_327_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) - .saturating_add(T::DbWeight::get().reads(6)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn update_deposit() -> Weight { - // Proof Size summary in bytes: - // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 73_010_000 picoseconds. - Weight::from_parts(73_417_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(3)) - } -} - -#[cfg(test)] -mod tests { - #[test] - fn test_associate_account_multisig_sr25519() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_account_multisig_ed25519() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_account_multisig_ecdsa() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_eth_account() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_sender() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_remove_sender_association() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_remove_account_association() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_change_deposit_owner() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 6326 - ); - } - #[test] - fn test_update_deposit() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } -} diff --git a/runtimes/spiritnet/src/weights/pallet_did_lookup_unique_linking.rs b/runtimes/spiritnet/src/weights/pallet_did_lookup_unique_linking.rs deleted file mode 100644 index b9310a445d..0000000000 --- a/runtimes/spiritnet/src/weights/pallet_did_lookup_unique_linking.rs +++ /dev/null @@ -1,340 +0,0 @@ -// KILT Blockchain – https://botlabs.org -// Copyright (C) 2019-2024 BOTLabs GmbH - -// The KILT Blockchain 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. - -// The KILT Blockchain 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 this program. If not, see . - -// If you feel like getting in touch with us, you can do so at info@botlabs.org - -//! Autogenerated weights for `pallet_did_lookup` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` -//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("spiritnet-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/release/kilt-parachain -// benchmark -// pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled -// --heap-pages=4096 -// --steps=50 -// --repeat=20 -// --chain=spiritnet-dev -// --pallet=pallet-did-lookup -// --extrinsic=* -// --output=./runtimes/spiritnet/src/weights/pallet_did_lookup.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_imports)] -#![allow(clippy::as_conversions)] - -use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; - -/// Weight functions for `pallet_did_lookup`. -pub struct WeightInfo(PhantomData); -impl pallet_did_lookup::WeightInfo for WeightInfo { - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_account_multisig_sr25519() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 130_333_000 picoseconds. - Weight::from_parts(131_946_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_account_multisig_ed25519() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 142_549_000 picoseconds. - Weight::from_parts(144_156_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_account_multisig_ecdsa() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 131_703_000 picoseconds. - Weight::from_parts(133_877_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_eth_account() -> Weight { - // Proof Size summary in bytes: - // Measured: `449` - // Estimated: `3658` - // Minimum execution time: 134_857_000 picoseconds. - Weight::from_parts(135_895_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:2) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - fn associate_sender() -> Weight { - // Proof Size summary in bytes: - // Measured: `462` - // Estimated: `3658` - // Minimum execution time: 83_538_000 picoseconds. - Weight::from_parts(84_203_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - fn remove_sender_association() -> Weight { - // Proof Size summary in bytes: - // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 48_280_000 picoseconds. - Weight::from_parts(48_686_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `DidLookup::ConnectedAccounts` (r:0 w:1) - /// Proof: `DidLookup::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `MaxEncodedLen`) - fn remove_account_association() -> Weight { - // Proof Size summary in bytes: - // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 49_796_000 picoseconds. - Weight::from_parts(50_261_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn change_deposit_owner() -> Weight { - // Proof Size summary in bytes: - // Measured: `647` - // Estimated: `6326` - // Minimum execution time: 78_581_000 picoseconds. - Weight::from_parts(79_327_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) - .saturating_add(T::DbWeight::get().reads(6)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `DidLookup::ConnectedDids` (r:1 w:1) - /// Proof: `DidLookup::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn update_deposit() -> Weight { - // Proof Size summary in bytes: - // Measured: `540` - // Estimated: `3658` - // Minimum execution time: 73_010_000 picoseconds. - Weight::from_parts(73_417_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(3)) - } -} - -#[cfg(test)] -mod tests { - #[test] - fn test_associate_account_multisig_sr25519() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_account_multisig_ed25519() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_account_multisig_ecdsa() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_eth_account() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_associate_sender() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_remove_sender_association() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_remove_account_association() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_change_deposit_owner() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 6326 - ); - } - #[test] - fn test_update_deposit() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } -} diff --git a/runtimes/spiritnet/src/weights/pallet_dot_names.rs b/runtimes/spiritnet/src/weights/pallet_dot_names.rs new file mode 100644 index 0000000000..e592de56cc --- /dev/null +++ b/runtimes/spiritnet/src/weights/pallet_dot_names.rs @@ -0,0 +1,269 @@ +// KILT Blockchain – https://botlabs.org +// Copyright (C) 2019-2024 BOTLabs GmbH + +// The KILT Blockchain 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. + +// The KILT Blockchain 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 this program. If not, see . + +// If you feel like getting in touch with us, you can do so at info@botlabs.org + +//! Autogenerated weights for `pallet_dot_names` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 + +// Executed Command: +// ./target/debug/kilt-parachain +// benchmark +// pallet +// --heap-pages=4096 +// --chain=dev +// --pallet=pallet-dot-names +// --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_imports)] +#![allow(clippy::as_conversions)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_web3_names as pallet_dot_names; + +/// Weight functions for `pallet_dot_names`. +pub struct WeightInfo(PhantomData); +impl pallet_dot_names::WeightInfo for WeightInfo { + /// Storage: `DotNames::Names` (r:1 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `DotNames::Banned` (r:1 w:0) + /// Proof: `DotNames::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn claim(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `147` + // Estimated: `990` + // Minimum execution time: 2_034_175_000 picoseconds. + Weight::from_parts(2_047_230_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `DotNames::Names` (r:1 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn release_by_owner() -> Weight { + // Proof Size summary in bytes: + // Measured: `474` + // Estimated: `990` + // Minimum execution time: 1_503_537_000 picoseconds. + Weight::from_parts(1_503_537_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `DotNames::Names` (r:0 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn reclaim_deposit(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `369 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_430_949_000 picoseconds. + Weight::from_parts(1_575_358_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `DotNames::Banned` (r:1 w:1) + /// Proof: `DotNames::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `DotNames::Names` (r:0 w:1) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn ban(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `369 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_543_707_000 picoseconds. + Weight::from_parts(1_800_627_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `DotNames::Banned` (r:1 w:1) + /// Proof: `DotNames::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) + /// The range of component `n` is `[7, 32]`. + fn unban(_n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `83 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 645_352_000 picoseconds. + Weight::from_parts(657_482_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `DotNames::Names` (r:1 w:0) + /// Proof: `DotNames::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:2 w:2) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn change_deposit_owner() -> Weight { + // Proof Size summary in bytes: + // Measured: `581` + // Estimated: `990` + // Minimum execution time: 2_716_990_000 picoseconds. + Weight::from_parts(2_716_990_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `DotNames::Owner` (r:1 w:1) + /// Proof: `DotNames::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn update_deposit() -> Weight { + // Proof Size summary in bytes: + // Measured: `403` + // Estimated: `990` + // Minimum execution time: 2_180_700_000 picoseconds. + Weight::from_parts(2_180_700_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} + +#[cfg(test)] +mod tests { + #[test] + fn test_claim() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_release_by_owner() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_reclaim_deposit() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_ban() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_unban() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_change_deposit_owner() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_update_deposit() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } +} diff --git a/runtimes/spiritnet/src/weights/pallet_membership.rs b/runtimes/spiritnet/src/weights/pallet_membership.rs index 1ed068f3a9..333c2fb6b9 100644 --- a/runtimes/spiritnet/src/weights/pallet_membership.rs +++ b/runtimes/spiritnet/src/weights/pallet_membership.rs @@ -19,25 +19,25 @@ //! Autogenerated weights for `pallet_membership` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` -//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("spiritnet-dev"), DB CACHE: 1024 +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 -// --chain=spiritnet-dev +// --chain=dev // --pallet=pallet-membership // --extrinsic=* -// --output=./runtimes/spiritnet/src/weights/pallet_membership.rs +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -49,159 +49,105 @@ use sp_std::marker::PhantomData; /// Weight functions for `pallet_membership`. pub struct WeightInfo(PhantomData); impl pallet_membership::WeightInfo for WeightInfo { - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 99]`. - fn add_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// The range of component `m` is `[1, 20]`. + fn add_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `102 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 13_128_000 picoseconds. - Weight::from_parts(13_700_386, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 245 - .saturating_add(Weight::from_parts(24_779, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `135 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 353_129_000 picoseconds. + Weight::from_parts(377_804_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:0) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[2, 100]`. - fn remove_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:0) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[2, 21]`. + fn remove_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 15_295_000 picoseconds. - Weight::from_parts(15_737_436, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 289 - .saturating_add(Weight::from_parts(25_549, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `189 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 390_037_000 picoseconds. + Weight::from_parts(404_106_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:0) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[2, 100]`. - fn swap_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:0) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[2, 21]`. + fn swap_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 15_774_000 picoseconds. - Weight::from_parts(16_241_962, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 315 - .saturating_add(Weight::from_parts(38_272, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `189 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 393_449_000 picoseconds. + Weight::from_parts(403_152_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:0) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn reset_member(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:0) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn reset_member(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 15_110_000 picoseconds. - Weight::from_parts(16_414_722, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 520 - .saturating_add(Weight::from_parts(150_482, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `187 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 448_047_000 picoseconds. + Weight::from_parts(448_683_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:1) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalMembership::Prime` (r:1 w:1) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Members` (r:0 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn change_key(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:1) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:1 w:1) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn change_key(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `206 + m * (64 ±0)` - // Estimated: `4687 + m * (64 ±0)` - // Minimum execution time: 15_940_000 picoseconds. - Weight::from_parts(16_886_000, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 388 - .saturating_add(Weight::from_parts(37_450, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().writes(4)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + // Measured: `187 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 437_193_000 picoseconds. + Weight::from_parts(516_613_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: `TechnicalMembership::Members` (r:1 w:0) - /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `MaxEncodedLen`) - /// Storage: `TechnicalMembership::Prime` (r:0 w:1) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn set_prime(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Members` (r:1 w:0) + /// Proof: `TipsMembership::Members` (`max_values`: Some(1), `max_size`: Some(673), added: 1168, mode: `Ignored`) + /// Storage: `TipsMembership::Prime` (r:0 w:1) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn set_prime(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `32 + m * (32 ±0)` - // Estimated: `4687 + m * (32 ±0)` - // Minimum execution time: 7_035_000 picoseconds. - Weight::from_parts(7_569_844, 0) - .saturating_add(Weight::from_parts(0, 4687)) - // Standard Error: 205 - .saturating_add(Weight::from_parts(10_559, 0).saturating_mul(m.into())) + // Measured: `135 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 305_850_000 picoseconds. + Weight::from_parts(329_866_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(2)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `TechnicalMembership::Prime` (r:0 w:1) - /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) - /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[1, 100]`. - fn clear_prime(m: u32, ) -> Weight { + /// Storage: `TipsMembership::Prime` (r:0 w:1) + /// Proof: `TipsMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// The range of component `m` is `[1, 21]`. + fn clear_prime(_m: u32, ) -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_492_000 picoseconds. - Weight::from_parts(2_695_321, 0) + // Minimum execution time: 163_207_000 picoseconds. + Weight::from_parts(171_566_000, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 78 - .saturating_add(Weight::from_parts(1_040, 0).saturating_mul(m.into())) - .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes(1)) } } @@ -216,7 +162,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -228,7 +174,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -240,7 +186,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -252,7 +198,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -264,7 +210,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } #[test] @@ -276,7 +222,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4687 + > 990 ); } } diff --git a/runtimes/spiritnet/src/weights/pallet_collective_technical_committee.rs b/runtimes/spiritnet/src/weights/pallet_technical_committee_collective.rs similarity index 55% rename from runtimes/spiritnet/src/weights/pallet_collective_technical_committee.rs rename to runtimes/spiritnet/src/weights/pallet_technical_committee_collective.rs index 5bf1844bee..96d316ac5a 100644 --- a/runtimes/spiritnet/src/weights/pallet_collective_technical_committee.rs +++ b/runtimes/spiritnet/src/weights/pallet_technical_committee_collective.rs @@ -16,28 +16,28 @@ // If you feel like getting in touch with us, you can do so at info@botlabs.org -//! Autogenerated weights for `pallet_collective` +//! Autogenerated weights for `pallet_technical_committee_collective` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-08-23, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` -//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("spiritnet-dev"), DB CACHE: 1024 +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 -// --chain=spiritnet-dev -// --pallet=pallet-collective +// --chain=dev +// --pallet=pallet-technical-committee-collective // --extrinsic=* -// --output=./runtimes/spiritnet/src/weights/ +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -46,282 +46,233 @@ use frame_support::{traits::Get, weights::Weight}; use sp_std::marker::PhantomData; -/// Weight functions for `pallet_collective`. +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_collective as pallet_technical_committee_collective; + +/// Weight functions for `pallet_technical_committee_collective`. pub struct WeightInfo(PhantomData); -impl pallet_collective::WeightInfo for WeightInfo { +impl pallet_technical_committee_collective::WeightInfo for WeightInfo { /// Storage: `TechnicalCommittee::Members` (r:1 w:1) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:100 w:100) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[0, 100]`. - /// The range of component `n` is `[0, 100]`. - /// The range of component `p` is `[0, 100]`. + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[0, 100]`. /// The range of component `n` is `[0, 100]`. /// The range of component `p` is `[0, 100]`. - fn set_members(m: u32, _n: u32, p: u32, ) -> Weight { + fn set_members(m: u32, n: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `0 + m * (3232 ±0) + p * (3194 ±0)` - // Estimated: `15736 + m * (1967 ±16) + p * (4336 ±16)` - // Minimum execution time: 8_480_000 picoseconds. - Weight::from_parts(8_687_000, 0) - .saturating_add(Weight::from_parts(0, 15736)) - // Standard Error: 25_771 - .saturating_add(Weight::from_parts(3_035_292, 0).saturating_mul(m.into())) - // Standard Error: 25_771 - .saturating_add(Weight::from_parts(4_613_880, 0).saturating_mul(p.into())) + // Measured: `0 + m * (3228 ±0) + p * (3195 ±0)` + // Estimated: `990` + // Minimum execution time: 460_642_000 picoseconds. + Weight::from_parts(460_642_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 255_764_641 + .saturating_add(Weight::from_parts(127_672_940, 0).saturating_mul(m.into())) + // Standard Error: 255_764_641 + .saturating_add(Weight::from_parts(34_349_310, 0).saturating_mul(n.into())) + // Standard Error: 255_764_641 + .saturating_add(Weight::from_parts(126_599_270, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(m.into()))) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) - .saturating_add(Weight::from_parts(0, 1967).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 4336).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. - fn execute(b: u32, m: u32, ) -> Weight { + fn execute(b: u32, _m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `69 + m * (32 ±0)` - // Estimated: `1555 + m * (32 ±0)` - // Minimum execution time: 6_690_000 picoseconds. - Weight::from_parts(6_424_657, 0) - .saturating_add(Weight::from_parts(0, 1555)) - // Standard Error: 10 - .saturating_add(Weight::from_parts(899, 0).saturating_mul(b.into())) - // Standard Error: 110 - .saturating_add(Weight::from_parts(7_213, 0).saturating_mul(m.into())) + // Measured: `102 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 573_430_000 picoseconds. + Weight::from_parts(29_965_404_055, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 3_984_281 + .saturating_add(Weight::from_parts(2_473_578, 0).saturating_mul(b.into())) .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:0) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[1, 100]`. fn propose_execute(b: u32, m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `69 + m * (32 ±0)` - // Estimated: `3535 + m * (32 ±0)` - // Minimum execution time: 8_020_000 picoseconds. - Weight::from_parts(7_450_070, 0) - .saturating_add(Weight::from_parts(0, 3535)) - // Standard Error: 10 - .saturating_add(Weight::from_parts(984, 0).saturating_mul(b.into())) - // Standard Error: 109 - .saturating_add(Weight::from_parts(13_090, 0).saturating_mul(m.into())) + // Measured: `102 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 715_079_000 picoseconds. + Weight::from_parts(636_745_116, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 10_109 + .saturating_add(Weight::from_parts(75_330, 0).saturating_mul(b.into())) + // Standard Error: 104_360 + .saturating_add(Weight::from_parts(1_195_222, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalCount` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[2, 100]`. /// The range of component `p` is `[1, 100]`. - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[2, 100]`. - /// The range of component `p` is `[1, 100]`. - fn propose_proposed(b: u32, m: u32, p: u32, ) -> Weight { + fn propose_proposed(b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `359 + m * (32 ±0) + p * (36 ±0)` - // Estimated: `3751 + m * (33 ±0) + p * (36 ±0)` - // Minimum execution time: 10_852_000 picoseconds. - Weight::from_parts(10_659_778, 0) - .saturating_add(Weight::from_parts(0, 3751)) - // Standard Error: 37 - .saturating_add(Weight::from_parts(1_888, 0).saturating_mul(b.into())) - // Standard Error: 393 - .saturating_add(Weight::from_parts(13_052, 0).saturating_mul(m.into())) - // Standard Error: 388 - .saturating_add(Weight::from_parts(112_833, 0).saturating_mul(p.into())) + // Measured: `38 + m * (32 ±0) + p * (39 ±0)` + // Estimated: `990` + // Minimum execution time: 972_408_000 picoseconds. + Weight::from_parts(1_342_425_531, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 40_523 + .saturating_add(Weight::from_parts(142_705, 0).saturating_mul(b.into())) + // Standard Error: 418_333 + .saturating_add(Weight::from_parts(3_118_730, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) - .saturating_add(Weight::from_parts(0, 33).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[5, 100]`. + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[5, 100]`. - fn vote(m: u32, ) -> Weight { + fn vote(_m: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `812 + m * (64 ±0)` - // Estimated: `4276 + m * (64 ±0)` - // Minimum execution time: 12_577_000 picoseconds. - Weight::from_parts(13_192_847, 0) - .saturating_add(Weight::from_parts(0, 4276)) - // Standard Error: 195 - .saturating_add(Weight::from_parts(21_445, 0).saturating_mul(m.into())) + // Measured: `845 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 604_239_000 picoseconds. + Weight::from_parts(705_575_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) - .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_disapproved(m: u32, p: u32, ) -> Weight { + fn close_early_disapproved(m: u32, _p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `401 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3846 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 12_546_000 picoseconds. - Weight::from_parts(13_273_449, 0) - .saturating_add(Weight::from_parts(0, 3846)) - // Standard Error: 407 - .saturating_add(Weight::from_parts(16_432, 0).saturating_mul(m.into())) - // Standard Error: 397 - .saturating_add(Weight::from_parts(103_596, 0).saturating_mul(p.into())) + // Measured: `219 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 1_062_882_000 picoseconds. + Weight::from_parts(17_615_015_534, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 1_146_969 + .saturating_add(Weight::from_parts(1_026_338, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_early_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_early_approved(_b: u32, m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `703 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4020 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 17_465_000 picoseconds. - Weight::from_parts(18_442_350, 0) - .saturating_add(Weight::from_parts(0, 4020)) - // Standard Error: 84 - .saturating_add(Weight::from_parts(1_916, 0).saturating_mul(b.into())) - // Standard Error: 896 - .saturating_add(Weight::from_parts(3_110, 0).saturating_mul(m.into())) - // Standard Error: 874 - .saturating_add(Weight::from_parts(134_518, 0).saturating_mul(p.into())) + // Measured: `434 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_150_858_000 picoseconds. + Weight::from_parts(17_456_729_928, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 729_009 + .saturating_add(Weight::from_parts(116_718, 0).saturating_mul(m.into())) + // Standard Error: 706_917 + .saturating_add(Weight::from_parts(4_476_141, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. fn close_disapproved(m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `421 + m * (64 ±0) + p * (36 ±0)` - // Estimated: `3866 + m * (65 ±0) + p * (36 ±0)` - // Minimum execution time: 13_865_000 picoseconds. - Weight::from_parts(13_890_210, 0) - .saturating_add(Weight::from_parts(0, 3866)) - // Standard Error: 342 - .saturating_add(Weight::from_parts(19_818, 0).saturating_mul(m.into())) - // Standard Error: 333 - .saturating_add(Weight::from_parts(107_324, 0).saturating_mul(p.into())) + // Measured: `239 + m * (64 ±0) + p * (38 ±0)` + // Estimated: `990` + // Minimum execution time: 876_906_000 picoseconds. + Weight::from_parts(876_906_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 77_271_809 + .saturating_add(Weight::from_parts(34_940_280, 0).saturating_mul(m.into())) + // Standard Error: 77_291_124 + .saturating_add(Weight::from_parts(39_111_834, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 65).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 36).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Members` (r:1 w:0) - /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) - /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) - /// The range of component `b` is `[2, 1024]`. - /// The range of component `m` is `[4, 100]`. - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// The range of component `b` is `[2, 1024]`. /// The range of component `m` is `[4, 100]`. /// The range of component `p` is `[1, 100]`. - fn close_approved(b: u32, m: u32, p: u32, ) -> Weight { + fn close_approved(_b: u32, _m: u32, p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `723 + b * (1 ±0) + m * (64 ±0) + p * (40 ±0)` - // Estimated: `4040 + b * (1 ±0) + m * (66 ±0) + p * (40 ±0)` - // Minimum execution time: 18_823_000 picoseconds. - Weight::from_parts(20_458_159, 0) - .saturating_add(Weight::from_parts(0, 4040)) - // Standard Error: 79 - .saturating_add(Weight::from_parts(1_234, 0).saturating_mul(b.into())) - // Standard Error: 839 - .saturating_add(Weight::from_parts(490, 0).saturating_mul(m.into())) - // Standard Error: 818 - .saturating_add(Weight::from_parts(134_767, 0).saturating_mul(p.into())) + // Measured: `454 + m * (64 ±0) + p * (44 ±0)` + // Estimated: `990` + // Minimum execution time: 1_610_558_000 picoseconds. + Weight::from_parts(2_769_131_417, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 10_668_245 + .saturating_add(Weight::from_parts(5_164_747, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) - .saturating_add(Weight::from_parts(0, 66).saturating_mul(m.into())) - .saturating_add(Weight::from_parts(0, 40).saturating_mul(p.into())) } /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) - /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) - /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) - /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// The range of component `p` is `[1, 100]`. + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Ignored`) /// The range of component `p` is `[1, 100]`. - fn disapprove_proposal(p: u32, ) -> Weight { + fn disapprove_proposal(_p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `226 + p * (32 ±0)` - // Estimated: `1711 + p * (32 ±0)` - // Minimum execution time: 6_765_000 picoseconds. - Weight::from_parts(7_975_046, 0) - .saturating_add(Weight::from_parts(0, 1711)) - // Standard Error: 437 - .saturating_add(Weight::from_parts(93_162, 0).saturating_mul(p.into())) + // Measured: `258 + p * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 1_112_072_000 picoseconds. + Weight::from_parts(1_726_467_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(3)) - .saturating_add(Weight::from_parts(0, 32).saturating_mul(p.into())) } } @@ -336,7 +287,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 15736 + > 990 ); } #[test] @@ -348,7 +299,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1555 + > 990 ); } #[test] @@ -360,7 +311,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3535 + > 990 ); } #[test] @@ -372,7 +323,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3751 + > 990 ); } #[test] @@ -384,7 +335,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4276 + > 990 ); } #[test] @@ -396,7 +347,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3846 + > 990 ); } #[test] @@ -408,7 +359,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4020 + > 990 ); } #[test] @@ -420,7 +371,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3866 + > 990 ); } #[test] @@ -432,7 +383,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 4040 + > 990 ); } #[test] @@ -444,7 +395,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 1711 + > 990 ); } } diff --git a/runtimes/spiritnet/src/weights/pallet_technical_membership.rs b/runtimes/spiritnet/src/weights/pallet_technical_membership.rs new file mode 100644 index 0000000000..349df77da8 --- /dev/null +++ b/runtimes/spiritnet/src/weights/pallet_technical_membership.rs @@ -0,0 +1,265 @@ +// KILT Blockchain – https://botlabs.org +// Copyright (C) 2019-2024 BOTLabs GmbH + +// The KILT Blockchain 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. + +// The KILT Blockchain 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 this program. If not, see . + +// If you feel like getting in touch with us, you can do so at info@botlabs.org + +//! Autogenerated weights for `pallet_technical_membership` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 + +// Executed Command: +// ./target/debug/kilt-parachain +// benchmark +// pallet +// --heap-pages=4096 +// --chain=dev +// --pallet=pallet-technical-membership +// --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_imports)] +#![allow(clippy::as_conversions)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_membership as pallet_technical_membership; + +/// Weight functions for `pallet_technical_membership`. +pub struct WeightInfo(PhantomData); +impl pallet_technical_membership::WeightInfo for WeightInfo { + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 99]`. + fn add_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `133 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 405_749_000 picoseconds. + Weight::from_parts(498_827_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:0) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[2, 100]`. + fn remove_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `239 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 500_744_000 picoseconds. + Weight::from_parts(527_487_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:0) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[2, 100]`. + fn swap_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `239 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 511_254_000 picoseconds. + Weight::from_parts(993_980_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:0) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn reset_member(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `237 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 534_955_000 picoseconds. + Weight::from_parts(688_451_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:1) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:1 w:1) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Members` (r:0 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn change_key(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `237 + m * (64 ±0)` + // Estimated: `990` + // Minimum execution time: 538_986_000 picoseconds. + Weight::from_parts(598_771_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `TechnicalMembership::Members` (r:1 w:0) + /// Proof: `TechnicalMembership::Members` (`max_values`: Some(1), `max_size`: Some(3202), added: 3697, mode: `Ignored`) + /// Storage: `TechnicalMembership::Prime` (r:0 w:1) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn set_prime(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `30 + m * (32 ±0)` + // Estimated: `990` + // Minimum execution time: 259_951_000 picoseconds. + Weight::from_parts(340_969_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `TechnicalMembership::Prime` (r:0 w:1) + /// Proof: `TechnicalMembership::Prime` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `Ignored`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Ignored`) + /// The range of component `m` is `[1, 100]`. + fn clear_prime(_m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 154_822_000 picoseconds. + Weight::from_parts(220_683_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(2)) + } +} + +#[cfg(test)] +mod tests { + #[test] + fn test_add_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_remove_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_swap_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_reset_member() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_change_key() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_set_prime() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } +} diff --git a/runtimes/spiritnet/src/weights/pallet_unique_linking.rs b/runtimes/spiritnet/src/weights/pallet_unique_linking.rs new file mode 100644 index 0000000000..8b16e82ef5 --- /dev/null +++ b/runtimes/spiritnet/src/weights/pallet_unique_linking.rs @@ -0,0 +1,325 @@ +// KILT Blockchain – https://botlabs.org +// Copyright (C) 2019-2024 BOTLabs GmbH + +// The KILT Blockchain 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. + +// The KILT Blockchain 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 this program. If not, see . + +// If you feel like getting in touch with us, you can do so at info@botlabs.org + +//! Autogenerated weights for `pallet_unique_linking` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 + +// Executed Command: +// ./target/debug/kilt-parachain +// benchmark +// pallet +// --heap-pages=4096 +// --chain=dev +// --pallet=pallet-unique-linking +// --extrinsic=* +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_imports)] +#![allow(clippy::as_conversions)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +// TODO: Remove once the benchmarking stuff fully supports pallet instances. +use pallet_did_lookup as pallet_unique_linking; + +/// Weight functions for `pallet_unique_linking`. +pub struct WeightInfo(PhantomData); +impl pallet_unique_linking::WeightInfo for WeightInfo { + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_account_multisig_sr25519() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 25_113_487_000 picoseconds. + Weight::from_parts(25_113_487_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_account_multisig_ed25519() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 3_828_833_000 picoseconds. + Weight::from_parts(3_828_833_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_account_multisig_ecdsa() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 3_368_653_000 picoseconds. + Weight::from_parts(3_368_653_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_eth_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `455` + // Estimated: `990` + // Minimum execution time: 3_868_482_000 picoseconds. + Weight::from_parts(3_868_482_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:1 w:2) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + fn associate_sender() -> Weight { + // Proof Size summary in bytes: + // Measured: `480` + // Estimated: `990` + // Minimum execution time: 3_316_476_000 picoseconds. + Weight::from_parts(3_316_476_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:0 w:1) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + fn remove_sender_association() -> Weight { + // Proof Size summary in bytes: + // Measured: `395` + // Estimated: `990` + // Minimum execution time: 1_563_980_000 picoseconds. + Weight::from_parts(1_563_980_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + /// Storage: `UniqueLinking::ConnectedAccounts` (r:0 w:1) + /// Proof: `UniqueLinking::ConnectedAccounts` (`max_values`: None, `max_size`: Some(97), added: 2572, mode: `Ignored`) + fn remove_account_association() -> Weight { + // Proof Size summary in bytes: + // Measured: `395` + // Estimated: `990` + // Minimum execution time: 1_550_726_000 picoseconds. + Weight::from_parts(1_550_726_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:2 w:2) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn change_deposit_owner() -> Weight { + // Proof Size summary in bytes: + // Measured: `502` + // Estimated: `990` + // Minimum execution time: 2_422_759_000 picoseconds. + Weight::from_parts(2_422_759_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `UniqueLinking::ConnectedDids` (r:1 w:1) + /// Proof: `UniqueLinking::ConnectedDids` (`max_values`: None, `max_size`: Some(129), added: 2604, mode: `Ignored`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) + fn update_deposit() -> Weight { + // Proof Size summary in bytes: + // Measured: `395` + // Estimated: `990` + // Minimum execution time: 2_447_655_000 picoseconds. + Weight::from_parts(2_447_655_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} + +#[cfg(test)] +mod tests { + #[test] + fn test_associate_account_multisig_sr25519() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_account_multisig_ed25519() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_account_multisig_ecdsa() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_eth_account() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_associate_sender() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_remove_sender_association() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_remove_account_association() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_change_deposit_owner() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } + #[test] + fn test_update_deposit() { + assert!( + ::BlockWeights::get() + .per_class + .get(frame_support::dispatch::DispatchClass::Normal) + .max_extrinsic + .unwrap_or_else(::max_value) + .proof_size() + > 990 + ); + } +} diff --git a/runtimes/peregrine/src/weights/pallet_web3_names_dot_names.rs b/runtimes/spiritnet/src/weights/pallet_web3_names.rs similarity index 70% rename from runtimes/peregrine/src/weights/pallet_web3_names_dot_names.rs rename to runtimes/spiritnet/src/weights/pallet_web3_names.rs index edfdbcff1f..e65ac2f0ed 100644 --- a/runtimes/peregrine/src/weights/pallet_web3_names_dot_names.rs +++ b/runtimes/spiritnet/src/weights/pallet_web3_names.rs @@ -19,25 +19,25 @@ //! Autogenerated weights for `pallet_web3_names` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-20, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-11-11, STEPS: `2`, REPEAT: `1`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` +//! HOSTNAME: `rust-2`, CPU: `12th Gen Intel(R) Core(TM) i9-12900K` //! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024 // Executed Command: -// ./target/release/kilt-parachain +// ./target/debug/kilt-parachain // benchmark // pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled // --heap-pages=4096 -// --steps=50 -// --repeat=20 // --chain=dev // --pallet=pallet-web3-names // --extrinsic=* -// --output=./runtimes/peregrine/src/weights/pallet_web3_names.rs +// --steps=2 +// --repeat=1 +// --default-pov-mode=ignored +// --header=HEADER-GPL +// --template=.maintain/runtime-weight-template.hbs +// --output=./runtimes/peregrine/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_imports)] @@ -50,146 +50,140 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl pallet_web3_names::WeightInfo for WeightInfo { /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Web3Names::Banned` (r:1 w:0) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. - fn claim(n: u32, ) -> Weight { + fn claim(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `111` - // Estimated: `3658` - // Minimum execution time: 56_002_000 picoseconds. - Weight::from_parts(57_034_446, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 1_741 - .saturating_add(Weight::from_parts(17_996, 0).saturating_mul(n.into())) + // Measured: `147` + // Estimated: `990` + // Minimum execution time: 1_933_283_000 picoseconds. + Weight::from_parts(2_123_318_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn release_by_owner() -> Weight { // Proof Size summary in bytes: - // Measured: `515` - // Estimated: `3658` - // Minimum execution time: 49_858_000 picoseconds. - Weight::from_parts(50_437_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Measured: `552` + // Estimated: `990` + // Minimum execution time: 1_704_333_000 picoseconds. + Weight::from_parts(1_704_333_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. - fn reclaim_deposit(n: u32, ) -> Weight { + fn reclaim_deposit(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 47_552_000 picoseconds. - Weight::from_parts(48_579_429, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 5_097 - .saturating_add(Weight::from_parts(202, 0).saturating_mul(n.into())) + // Measured: `447 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_632_584_000 picoseconds. + Weight::from_parts(1_797_797_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. fn ban(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 52_931_000 picoseconds. - Weight::from_parts(54_749_477, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Measured: `447 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 1_884_191_000 picoseconds. + Weight::from_parts(2_552_638_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `Ignored`) /// The range of component `n` is `[3, 32]`. - fn unban(n: u32, ) -> Weight { + fn unban(_n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `47 + n * (1 ±0)` - // Estimated: `3514` - // Minimum execution time: 12_517_000 picoseconds. - Weight::from_parts(12_938_732, 0) - .saturating_add(Weight::from_parts(0, 3514)) - // Standard Error: 2_619 - .saturating_add(Weight::from_parts(22_854, 0).saturating_mul(n.into())) + // Measured: `83 + n * (1 ±0)` + // Estimated: `990` + // Minimum execution time: 607_060_000 picoseconds. + Weight::from_parts(614_873_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: `Web3Names::Names` (r:1 w:0) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn change_deposit_owner() -> Weight { // Proof Size summary in bytes: - // Measured: `622` - // Estimated: `6326` - // Minimum execution time: 79_612_000 picoseconds. - Weight::from_parts(80_738_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) + // Measured: `659` + // Estimated: `990` + // Minimum execution time: 3_036_222_000 picoseconds. + Weight::from_parts(3_036_222_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) + /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `Ignored`) /// Storage: `Migration::MigratedKeys` (r:1 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `Ignored`) /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `Ignored`) /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `Ignored`) fn update_deposit() -> Weight { // Proof Size summary in bytes: - // Measured: `370` - // Estimated: `3658` - // Minimum execution time: 64_512_000 picoseconds. - Weight::from_parts(65_038_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) + // Measured: `407` + // Estimated: `990` + // Minimum execution time: 2_369_820_000 picoseconds. + Weight::from_parts(2_369_820_000, 0) + .saturating_add(Weight::from_parts(0, 990)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -206,7 +200,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -218,7 +212,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -230,7 +224,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -242,7 +236,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } #[test] @@ -254,7 +248,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3514 + > 990 ); } #[test] @@ -266,7 +260,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 6326 + > 990 ); } #[test] @@ -278,7 +272,7 @@ mod tests { .max_extrinsic .unwrap_or_else(::max_value) .proof_size() - > 3658 + > 990 ); } } diff --git a/runtimes/spiritnet/src/weights/pallet_web3_names_dot_names.rs b/runtimes/spiritnet/src/weights/pallet_web3_names_dot_names.rs deleted file mode 100644 index c51c57a35d..0000000000 --- a/runtimes/spiritnet/src/weights/pallet_web3_names_dot_names.rs +++ /dev/null @@ -1,284 +0,0 @@ -// KILT Blockchain – https://botlabs.org -// Copyright (C) 2019-2024 BOTLabs GmbH - -// The KILT Blockchain 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. - -// The KILT Blockchain 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 this program. If not, see . - -// If you feel like getting in touch with us, you can do so at info@botlabs.org - -//! Autogenerated weights for `pallet_web3_names` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` -//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("spiritnet-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/release/kilt-parachain -// benchmark -// pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled -// --heap-pages=4096 -// --steps=50 -// --repeat=20 -// --chain=spiritnet-dev -// --pallet=pallet-web3-names -// --extrinsic=* -// --output=./runtimes/spiritnet/src/weights/pallet_web3_names.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_imports)] -#![allow(clippy::as_conversions)] - -use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; - -/// Weight functions for `pallet_web3_names`. -pub struct WeightInfo(PhantomData); -impl pallet_web3_names::WeightInfo for WeightInfo { - /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Banned` (r:1 w:0) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn claim(n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `111` - // Estimated: `3658` - // Minimum execution time: 58_563_000 picoseconds. - Weight::from_parts(59_662_237, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 1_099 - .saturating_add(Weight::from_parts(7_968, 0).saturating_mul(n.into())) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn release_by_owner() -> Weight { - // Proof Size summary in bytes: - // Measured: `515` - // Estimated: `3658` - // Minimum execution time: 51_526_000 picoseconds. - Weight::from_parts(51_915_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn reclaim_deposit(n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 49_388_000 picoseconds. - Weight::from_parts(50_066_225, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 913 - .saturating_add(Weight::from_parts(21_509, 0).saturating_mul(n.into())) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn ban(_n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 55_030_000 picoseconds. - Weight::from_parts(58_781_704, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn unban(n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `47 + n * (1 ±0)` - // Estimated: `3514` - // Minimum execution time: 13_030_000 picoseconds. - Weight::from_parts(13_421_837, 0) - .saturating_add(Weight::from_parts(0, 3514)) - // Standard Error: 697 - .saturating_add(Weight::from_parts(18_015, 0).saturating_mul(n.into())) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: `Web3Names::Names` (r:1 w:0) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn change_deposit_owner() -> Weight { - // Proof Size summary in bytes: - // Measured: `622` - // Estimated: `6326` - // Minimum execution time: 82_747_000 picoseconds. - Weight::from_parts(83_384_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn update_deposit() -> Weight { - // Proof Size summary in bytes: - // Measured: `370` - // Estimated: `3658` - // Minimum execution time: 67_321_000 picoseconds. - Weight::from_parts(67_947_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } -} - -#[cfg(test)] -mod tests { - #[test] - fn test_claim() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_release_by_owner() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_reclaim_deposit() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_ban() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_unban() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3514 - ); - } - #[test] - fn test_change_deposit_owner() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 6326 - ); - } - #[test] - fn test_update_deposit() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } -} diff --git a/runtimes/spiritnet/src/weights/pallet_web3_names_web3_names.rs b/runtimes/spiritnet/src/weights/pallet_web3_names_web3_names.rs deleted file mode 100644 index c51c57a35d..0000000000 --- a/runtimes/spiritnet/src/weights/pallet_web3_names_web3_names.rs +++ /dev/null @@ -1,284 +0,0 @@ -// KILT Blockchain – https://botlabs.org -// Copyright (C) 2019-2024 BOTLabs GmbH - -// The KILT Blockchain 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. - -// The KILT Blockchain 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 this program. If not, see . - -// If you feel like getting in touch with us, you can do so at info@botlabs.org - -//! Autogenerated weights for `pallet_web3_names` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 33.0.0 -//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `eyrie-7`, CPU: `Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz` -//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("spiritnet-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/release/kilt-parachain -// benchmark -// pallet -// --template=.maintain/runtime-weight-template.hbs -// --header=HEADER-GPL -// --wasm-execution=compiled -// --heap-pages=4096 -// --steps=50 -// --repeat=20 -// --chain=spiritnet-dev -// --pallet=pallet-web3-names -// --extrinsic=* -// --output=./runtimes/spiritnet/src/weights/pallet_web3_names.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_imports)] -#![allow(clippy::as_conversions)] - -use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; - -/// Weight functions for `pallet_web3_names`. -pub struct WeightInfo(PhantomData); -impl pallet_web3_names::WeightInfo for WeightInfo { - /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Banned` (r:1 w:0) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:0 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn claim(n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `111` - // Estimated: `3658` - // Minimum execution time: 58_563_000 picoseconds. - Weight::from_parts(59_662_237, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 1_099 - .saturating_add(Weight::from_parts(7_968, 0).saturating_mul(n.into())) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `Web3Names::Names` (r:1 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn release_by_owner() -> Weight { - // Proof Size summary in bytes: - // Measured: `515` - // Estimated: `3658` - // Minimum execution time: 51_526_000 picoseconds. - Weight::from_parts(51_915_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn reclaim_deposit(n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 49_388_000 picoseconds. - Weight::from_parts(50_066_225, 0) - .saturating_add(Weight::from_parts(0, 3658)) - // Standard Error: 913 - .saturating_add(Weight::from_parts(21_509, 0).saturating_mul(n.into())) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Names` (r:0 w:1) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn ban(_n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `411 + n * (1 ±0)` - // Estimated: `3658` - // Minimum execution time: 55_030_000 picoseconds. - Weight::from_parts(58_781_704, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `Web3Names::Banned` (r:1 w:1) - /// Proof: `Web3Names::Banned` (`max_values`: None, `max_size`: Some(49), added: 2524, mode: `MaxEncodedLen`) - /// The range of component `n` is `[3, 32]`. - fn unban(n: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `47 + n * (1 ±0)` - // Estimated: `3514` - // Minimum execution time: 13_030_000 picoseconds. - Weight::from_parts(13_421_837, 0) - .saturating_add(Weight::from_parts(0, 3514)) - // Standard Error: 697 - .saturating_add(Weight::from_parts(18_015, 0).saturating_mul(n.into())) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: `Web3Names::Names` (r:1 w:0) - /// Proof: `Web3Names::Names` (`max_values`: None, `max_size`: Some(81), added: 2556, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:0) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:2 w:2) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:2 w:2) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn change_deposit_owner() -> Weight { - // Proof Size summary in bytes: - // Measured: `622` - // Estimated: `6326` - // Minimum execution time: 82_747_000 picoseconds. - Weight::from_parts(83_384_000, 0) - .saturating_add(Weight::from_parts(0, 6326)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: `Web3Names::Owner` (r:1 w:1) - /// Proof: `Web3Names::Owner` (`max_values`: None, `max_size`: Some(137), added: 2612, mode: `MaxEncodedLen`) - /// Storage: `Migration::MigratedKeys` (r:1 w:1) - /// Proof: `Migration::MigratedKeys` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(132), added: 2607, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(193), added: 2668, mode: `MaxEncodedLen`) - fn update_deposit() -> Weight { - // Proof Size summary in bytes: - // Measured: `370` - // Estimated: `3658` - // Minimum execution time: 67_321_000 picoseconds. - Weight::from_parts(67_947_000, 0) - .saturating_add(Weight::from_parts(0, 3658)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) - } -} - -#[cfg(test)] -mod tests { - #[test] - fn test_claim() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_release_by_owner() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_reclaim_deposit() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_ban() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } - #[test] - fn test_unban() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3514 - ); - } - #[test] - fn test_change_deposit_owner() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 6326 - ); - } - #[test] - fn test_update_deposit() { - assert!( - ::BlockWeights::get() - .per_class - .get(frame_support::dispatch::DispatchClass::Normal) - .max_extrinsic - .unwrap_or_else(::max_value) - .proof_size() - > 3658 - ); - } -} diff --git a/scripts/run_benches_for_runtime.sh b/scripts/run_benches_for_runtime.sh index fb6f8d671b..142ea97660 100755 --- a/scripts/run_benches_for_runtime.sh +++ b/scripts/run_benches_for_runtime.sh @@ -20,12 +20,9 @@ pallets=( did frame-system pallet-balances - pallet-collective pallet-democracy - pallet-did-lookup pallet-indices pallet-inflation - pallet-membership pallet-preimage pallet-proxy pallet-scheduler @@ -35,7 +32,6 @@ pallets=( pallet-treasury pallet-utility pallet-vesting - pallet-web3-names pallet-xcm parachain-staking public-credentials @@ -46,13 +42,25 @@ pallets=( pallet_multisig pallet-assets pallet-asset-switch + # `pallet-membership` instances + pallet-membership + pallet-technical-membership + # `pallet-collective` instances + pallet-collective + pallet-technical-committee-collective + # `pallet-did-lookup` instances + pallet-did-lookup + pallet-unique-linking + # `pallet-web3-names` instances + pallet-dot-names + pallet-web3-names ) # Add Peregrine-only pallets here! if [ "$runtime" = "peregrine" ]; then - pallets+=( - pallet-sudo - ) + pallets+=( + pallet-sudo + ) fi echo "[+] Running all runtime benchmarks for \"$runtime\", \"--chain=$chain\" and profile \"$profile\"" @@ -60,11 +68,11 @@ echo "[+] Running all runtime benchmarks for \"$runtime\", \"--chain=$chain\" an cargo build $standard_args if [ $profile == "dev" ]; then - target_folder="debug" + target_folder="debug" # We care about benchmark correctness, not accuracy. additional_args="--steps=2 --repeat=1 --default-pov-mode=ignored --no-verify" else - target_folder=$profile + target_folder=$profile additional_args="--header=HEADER-GPL --template=.maintain/runtime-weight-template.hbs --output=./runtimes/${runtime}/src/weights/" fi @@ -82,7 +90,7 @@ for pallet in "${pallets[@]}"; do # Exit with error as soon as one benchmark fails if [ $bench_status -ne 0 ]; then - exit $bench_status - fi + exit $bench_status + fi done