From 6d2241fa0a0f09080ef24e58cf556596b2fc3df6 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Thu, 13 Apr 2023 18:00:15 -0300 Subject: [PATCH 01/53] Add polkadot XCM benchmarks --- Cargo.lock | 1 + runtime/polkadot/Cargo.toml | 2 + runtime/polkadot/src/lib.rs | 82 +++++++++++++++++++++++++++++- runtime/polkadot/src/xcm_config.rs | 3 +- 4 files changed, 86 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 498c8db1189b..d730cb1d0e7d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7615,6 +7615,7 @@ dependencies = [ "pallet-vesting", "pallet-whitelist", "pallet-xcm", + "pallet-xcm-benchmarks", "parity-scale-codec", "polkadot-primitives", "polkadot-runtime-common", diff --git a/runtime/polkadot/Cargo.toml b/runtime/polkadot/Cargo.toml index 8f13542c727e..c207b36809b1 100644 --- a/runtime/polkadot/Cargo.toml +++ b/runtime/polkadot/Cargo.toml @@ -80,6 +80,7 @@ pallet-vesting = { git = "https://github.com/paritytech/substrate", branch = "ma pallet-utility = { git = "https://github.com/paritytech/substrate", branch = "master", default-features = false } frame-election-provider-support = { git = "https://github.com/paritytech/substrate", branch = "master", default-features = false } pallet-xcm = { path = "../../xcm/pallet-xcm", default-features = false } +pallet-xcm-benchmarks = { path = "../../xcm/pallet-xcm-benchmarks", default-features = false, optional = true } frame-benchmarking = { git = "https://github.com/paritytech/substrate", branch = "master", default-features = false, optional = true } frame-try-runtime = { git = "https://github.com/paritytech/substrate", branch = "master", default-features = false, optional = true } @@ -237,6 +238,7 @@ runtime-benchmarks = [ "xcm-builder/runtime-benchmarks", "frame-election-provider-support/runtime-benchmarks", "runtime-parachains/runtime-benchmarks", + "pallet-xcm-benchmarks/runtime-benchmarks", ] try-runtime = [ "frame-executive/try-runtime", diff --git a/runtime/polkadot/src/lib.rs b/runtime/polkadot/src/lib.rs index 70f1fc52bffe..234d73b2c07a 100644 --- a/runtime/polkadot/src/lib.rs +++ b/runtime/polkadot/src/lib.rs @@ -1503,6 +1503,8 @@ mod benches { [pallet_whitelist, Whitelist] // XCM [pallet_xcm, XcmPallet] + [pallet_xcm_benchmarks::fungible, pallet_xcm_benchmarks::fungible::Pallet::] + [pallet_xcm_benchmarks::generic, pallet_xcm_benchmarks::generic::Pallet::] ); } @@ -1958,7 +1960,7 @@ sp_api::impl_runtime_apis! { Vec, sp_runtime::RuntimeString, > { - use frame_benchmarking::{Benchmarking, BenchmarkBatch, TrackedStorageKey}; + use frame_benchmarking::{Benchmarking, BenchmarkBatch, TrackedStorageKey, BenchmarkError}; // Trying to add benchmarks directly to some pallets caused cyclic dependency issues. // To get around that, we separated the benchmarks into its own crate. use pallet_session_benchmarking::Pallet as SessionBench; @@ -1967,6 +1969,8 @@ sp_api::impl_runtime_apis! { use pallet_nomination_pools_benchmarking::Pallet as NominationPoolsBench; use frame_system_benchmarking::Pallet as SystemBench; use frame_benchmarking::baseline::Pallet as Baseline; + use xcm::latest::prelude::*; + use xcm_config::{XcmConfig, StatemintLocation, TokenLocation, LocalCheckAccount, SovereignAccountOf}; impl pallet_session_benchmarking::Config for Runtime {} impl pallet_offences_benchmarking::Config for Runtime {} @@ -1975,6 +1979,82 @@ sp_api::impl_runtime_apis! { impl frame_benchmarking::baseline::Config for Runtime {} impl pallet_nomination_pools_benchmarking::Config for Runtime {} + impl pallet_xcm_benchmarks::Config for Runtime { + type XcmConfig = XcmConfig; + type AccountIdConverter = SovereignAccountOf; + fn valid_destination() -> Result { + Ok(StatemintLocation::get()) + } + fn worst_case_holding(_depositable_count: u32) -> MultiAssets { + // Polkadot only knows about DOT + vec![MultiAsset { id: Concrete(TokenLocation::get()), fun: Fungible(1_000_000 * UNITS) }].into() + } + } + + parameter_types! { + pub const TrustedTeleporter: Option<(MultiLocation, MultiAsset)> = Some(( + StatemintLocation::get(), + MultiAsset { id: Concrete(TokenLocation::get()), fun: Fungible(1 * UNITS) } + )); + } + + impl pallet_xcm_benchmarks::fungible::Config for Runtime { + type TransactAsset = Balances; + + type CheckedAccount = LocalCheckAccount; + type TrustedTeleporter = TrustedTeleporter; + fn get_multi_asset() -> MultiAsset { + MultiAsset { + id: Concrete(TokenLocation::get()), + fun: Fungible(1 * UNITS) + } + } + } + + impl pallet_xcm_benchmarks::generic::Config for Runtime { + type RuntimeCall = RuntimeCall; + + fn worst_case_response() -> (u64, Response) { + (0u64, Response::Version(Default::default())) + } + + fn worst_case_asset_exchange() -> Result<(MultiAssets, MultiAssets), BenchmarkError> { + // Polkadot doesn't support asset exchanges + Err(BenchmarkError::Skip) + } + + fn universal_alias() -> Result<(MultiLocation, Junction), BenchmarkError> { + // The XCM executor of Polkadot doesn't have a configured `UniversalAliases` + Err(BenchmarkError::Skip) + } + + fn transact_origin_and_runtime_call() -> Result<(MultiLocation, RuntimeCall), BenchmarkError> { + Ok((StatemintLocation::get(), frame_system::Call::remark_with_event { remark: vec![] }.into())) + } + + fn subscribe_origin() -> Result { + Ok(StatemintLocation::get()) + } + + fn claimable_asset() -> Result<(MultiLocation, MultiLocation, MultiAssets), BenchmarkError> { + let origin = StatemintLocation::get(); + let assets: MultiAssets = (Concrete(TokenLocation::get()), 1_000 * UNITS).into(); + let ticket = MultiLocation { parents: 0, interior: Here }; + Ok((origin, ticket, assets)) + } + + fn unlockable_asset() -> Result<(MultiLocation, MultiLocation, MultiAsset), BenchmarkError> { + // Polkadot doesn't support asset locking + Err(BenchmarkError::Skip) + } + + fn export_message_origin_and_destination( + ) -> Result<(MultiLocation, NetworkId, InteriorMultiLocation), BenchmarkError> { + // Polkadot doesn't support exporting messages + Err(BenchmarkError::Skip) + } + } + let whitelist: Vec = vec![ // Block Number hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(), diff --git a/runtime/polkadot/src/xcm_config.rs b/runtime/polkadot/src/xcm_config.rs index 5aa841564bf5..660a0ee0be25 100644 --- a/runtime/polkadot/src/xcm_config.rs +++ b/runtime/polkadot/src/xcm_config.rs @@ -117,7 +117,8 @@ pub type XcmRouter = ( parameter_types! { pub const Dot: MultiAssetFilter = Wild(AllOf { fun: WildFungible, id: Concrete(TokenLocation::get()) }); - pub const DotForStatemint: (MultiAssetFilter, MultiLocation) = (Dot::get(), Parachain(STATEMINT_ID).into_location()); + pub const StatemintLocation: MultiLocation = Parachain(STATEMINT_ID).into_location(); + pub const DotForStatemint: (MultiAssetFilter, MultiLocation) = (Dot::get(), StatemintLocation::get()); pub const CollectivesLocation: MultiLocation = Parachain(COLLECTIVES_ID).into_location(); pub const DotForCollectives: (MultiAssetFilter, MultiLocation) = (Dot::get(), CollectivesLocation::get()); pub const MaxAssetsIntoHolding: u32 = 64; From 5135506f633f54d748b959de3dad98dfb277bca8 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Thu, 13 Apr 2023 18:47:24 -0300 Subject: [PATCH 02/53] Add temp --- runtime/polkadot/src/weights/xcm/temp | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 runtime/polkadot/src/weights/xcm/temp diff --git a/runtime/polkadot/src/weights/xcm/temp b/runtime/polkadot/src/weights/xcm/temp new file mode 100644 index 000000000000..e69de29bb2d1 From 557fa67936709ac5c407165fcbb99534a2c7525b Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Thu, 13 Apr 2023 22:30:07 +0000 Subject: [PATCH 03/53] ".git/.scripts/commands/bench/bench.sh" xcm polkadot pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 139 ++++++++++++++++++ 1 file changed, 139 insertions(+) create mode 100644 runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs new file mode 100644 index 000000000000..7b50203486c3 --- /dev/null +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -0,0 +1,139 @@ +// Copyright (C) Parity Technologies (UK) Ltd. +// This file is part of Polkadot. + +// Polkadot is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Polkadot is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Polkadot. If not, see . + +//! Autogenerated weights for `pallet_xcm_benchmarks::fungible` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev +//! DATE: 2023-04-13, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 + +// Executed Command: +// target/production/polkadot +// benchmark +// pallet +// --steps=50 +// --repeat=20 +// --extrinsic=* +// --execution=wasm +// --wasm-execution=compiled +// --heap-pages=4096 +// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json +// --pallet=pallet_xcm_benchmarks::fungible +// --chain=polkadot-dev +// --header=./file_header.txt +// --template=./xcm/pallet-xcm-benchmarks/template.hbs +// --output=./runtime/polkadot/src/weights/xcm/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +/// Weights for `pallet_xcm_benchmarks::fungible`. +pub struct WeightInfo(PhantomData); +impl WeightInfo { + // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn withdraw_asset() -> Weight { + Weight::from_ref_time(23_068_000 as u64) + .saturating_add(T::DbWeight::get().reads(1 as u64)) + .saturating_add(T::DbWeight::get().writes(1 as u64)) + } + // Storage: System Account (r:2 w:2) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn transfer_asset() -> Weight { + Weight::from_ref_time(47_403_000 as u64) + .saturating_add(T::DbWeight::get().reads(2 as u64)) + .saturating_add(T::DbWeight::get().writes(2 as u64)) + } + // Storage: System Account (r:2 w:2) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn transfer_reserve_asset() -> Weight { + Weight::from_ref_time(73_056_000 as u64) + .saturating_add(T::DbWeight::get().reads(8 as u64)) + .saturating_add(T::DbWeight::get().writes(5 as u64)) + } + // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub(crate) fn receive_teleported_asset() -> Weight { + Weight::from_ref_time(23_922_000 as u64) + .saturating_add(T::DbWeight::get().reads(2 as u64)) + .saturating_add(T::DbWeight::get().writes(2 as u64)) + } + // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn deposit_asset() -> Weight { + Weight::from_ref_time(24_975_000 as u64) + .saturating_add(T::DbWeight::get().reads(1 as u64)) + .saturating_add(T::DbWeight::get().writes(1 as u64)) + } + // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn deposit_reserve_asset() -> Weight { + Weight::from_ref_time(55_235_000 as u64) + .saturating_add(T::DbWeight::get().reads(7 as u64)) + .saturating_add(T::DbWeight::get().writes(4 as u64)) + } + // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_teleport() -> Weight { + Weight::from_ref_time(57_122_000 as u64) + .saturating_add(T::DbWeight::get().reads(8 as u64)) + .saturating_add(T::DbWeight::get().writes(5 as u64)) + } +} From 4e7bc947d7922f4c783ce2a78e85876bea30d27b Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Thu, 13 Apr 2023 23:17:57 +0000 Subject: [PATCH 04/53] ".git/.scripts/commands/bench/bench.sh" xcm polkadot pallet_xcm_benchmarks::generic --- .../xcm/pallet_xcm_benchmarks_generic.rs | 233 ++++++++++++++++++ 1 file changed, 233 insertions(+) create mode 100644 runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs new file mode 100644 index 000000000000..4428f20a16dd --- /dev/null +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -0,0 +1,233 @@ +// Copyright (C) Parity Technologies (UK) Ltd. +// This file is part of Polkadot. + +// Polkadot is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Polkadot is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Polkadot. If not, see . + +//! Autogenerated weights for `pallet_xcm_benchmarks::generic` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev +//! DATE: 2023-04-13, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 + +// Executed Command: +// target/production/polkadot +// benchmark +// pallet +// --steps=50 +// --repeat=20 +// --extrinsic=* +// --execution=wasm +// --wasm-execution=compiled +// --heap-pages=4096 +// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json +// --pallet=pallet_xcm_benchmarks::generic +// --chain=polkadot-dev +// --header=./file_header.txt +// --template=./xcm/pallet-xcm-benchmarks/template.hbs +// --output=./runtime/polkadot/src/weights/xcm/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] + +use frame_support::{traits::Get, weights::Weight}; +use sp_std::marker::PhantomData; + +/// Weights for `pallet_xcm_benchmarks::generic`. +pub struct WeightInfo(PhantomData); +impl WeightInfo { + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn report_holding() -> Weight { + Weight::from_ref_time(33_538_000 as u64) + .saturating_add(T::DbWeight::get().reads(6 as u64)) + .saturating_add(T::DbWeight::get().writes(3 as u64)) + } + pub(crate) fn buy_execution() -> Weight { + Weight::from_ref_time(3_018_000 as u64) + } + // Storage: XcmPallet Queries (r:1 w:0) + // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) + pub(crate) fn query_response() -> Weight { + Weight::from_ref_time(12_644_000 as u64) + .saturating_add(T::DbWeight::get().reads(1 as u64)) + } + pub(crate) fn transact() -> Weight { + Weight::from_ref_time(13_371_000 as u64) + } + pub(crate) fn refund_surplus() -> Weight { + Weight::from_ref_time(3_236_000 as u64) + } + pub(crate) fn set_error_handler() -> Weight { + Weight::from_ref_time(3_022_000 as u64) + } + pub(crate) fn set_appendix() -> Weight { + Weight::from_ref_time(3_077_000 as u64) + } + pub(crate) fn clear_error() -> Weight { + Weight::from_ref_time(2_976_000 as u64) + } + pub(crate) fn descend_origin() -> Weight { + Weight::from_ref_time(3_847_000 as u64) + } + pub(crate) fn clear_origin() -> Weight { + Weight::from_ref_time(2_928_000 as u64) + } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn report_error() -> Weight { + Weight::from_ref_time(28_104_000 as u64) + .saturating_add(T::DbWeight::get().reads(6 as u64)) + .saturating_add(T::DbWeight::get().writes(3 as u64)) + } + // Storage: XcmPallet AssetTraps (r:1 w:1) + // Proof Skipped: XcmPallet AssetTraps (max_values: None, max_size: None, mode: Measured) + pub(crate) fn claim_asset() -> Weight { + Weight::from_ref_time(16_919_000 as u64) + .saturating_add(T::DbWeight::get().reads(1 as u64)) + .saturating_add(T::DbWeight::get().writes(1 as u64)) + } + pub(crate) fn trap() -> Weight { + Weight::from_ref_time(2_941_000 as u64) + } + // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn subscribe_version() -> Weight { + Weight::from_ref_time(34_841_000 as u64) + .saturating_add(T::DbWeight::get().reads(7 as u64)) + .saturating_add(T::DbWeight::get().writes(4 as u64)) + } + // Storage: XcmPallet VersionNotifyTargets (r:0 w:1) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) + pub(crate) fn unsubscribe_version() -> Weight { + Weight::from_ref_time(5_427_000 as u64) + .saturating_add(T::DbWeight::get().writes(1 as u64)) + } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_reserve_withdraw() -> Weight { + Weight::from_ref_time(32_854_000 as u64) + .saturating_add(T::DbWeight::get().reads(6 as u64)) + .saturating_add(T::DbWeight::get().writes(3 as u64)) + } + pub(crate) fn burn_asset() -> Weight { + Weight::from_ref_time(5_028_000 as u64) + } + pub(crate) fn expect_asset() -> Weight { + Weight::from_ref_time(3_206_000 as u64) + } + pub(crate) fn expect_origin() -> Weight { + Weight::from_ref_time(3_135_000 as u64) + } + pub(crate) fn expect_error() -> Weight { + Weight::from_ref_time(2_977_000 as u64) + } + pub(crate) fn expect_transact_status() -> Weight { + Weight::from_ref_time(3_200_000 as u64) + } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn query_pallet() -> Weight { + Weight::from_ref_time(36_411_000 as u64) + .saturating_add(T::DbWeight::get().reads(6 as u64)) + .saturating_add(T::DbWeight::get().writes(3 as u64)) + } + pub(crate) fn expect_pallet() -> Weight { + Weight::from_ref_time(8_501_000 as u64) + } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn report_transact_status() -> Weight { + Weight::from_ref_time(28_416_000 as u64) + .saturating_add(T::DbWeight::get().reads(6 as u64)) + .saturating_add(T::DbWeight::get().writes(3 as u64)) + } + pub(crate) fn clear_transact_status() -> Weight { + Weight::from_ref_time(3_048_000 as u64) + } + pub(crate) fn set_topic() -> Weight { + Weight::from_ref_time(2_958_000 as u64) + } + pub(crate) fn clear_topic() -> Weight { + Weight::from_ref_time(2_945_000 as u64) + } + pub(crate) fn set_fees_mode() -> Weight { + Weight::from_ref_time(3_014_000 as u64) + } + pub(crate) fn unpaid_execution() -> Weight { + Weight::from_ref_time(3_179_000 as u64) + } +} From 477387cfd2c737e3d38d9fda0404f30d53537485 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Thu, 13 Apr 2023 23:05:24 -0300 Subject: [PATCH 05/53] Add weights to XCM on Polkadot --- runtime/polkadot/src/weights/mod.rs | 1 + runtime/polkadot/src/weights/xcm/mod.rs | 291 ++++++++++++++++++++++++ runtime/polkadot/src/weights/xcm/temp | 0 runtime/polkadot/src/xcm_config.rs | 16 +- 4 files changed, 304 insertions(+), 4 deletions(-) create mode 100644 runtime/polkadot/src/weights/xcm/mod.rs delete mode 100644 runtime/polkadot/src/weights/xcm/temp diff --git a/runtime/polkadot/src/weights/mod.rs b/runtime/polkadot/src/weights/mod.rs index d9471c6a3f24..f7b5d4147767 100644 --- a/runtime/polkadot/src/weights/mod.rs +++ b/runtime/polkadot/src/weights/mod.rs @@ -59,3 +59,4 @@ pub mod runtime_parachains_initializer; pub mod runtime_parachains_paras; pub mod runtime_parachains_paras_inherent; pub mod runtime_parachains_ump; +pub mod xcm; diff --git a/runtime/polkadot/src/weights/xcm/mod.rs b/runtime/polkadot/src/weights/xcm/mod.rs new file mode 100644 index 000000000000..2727d2a35bca --- /dev/null +++ b/runtime/polkadot/src/weights/xcm/mod.rs @@ -0,0 +1,291 @@ +// Copyright (C) Parity Technologies (UK) Ltd. +// This file is part of Polkadot. + +// Polkadot is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Polkadot is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Polkadot. If not, see . + +mod pallet_xcm_benchmarks_fungible; +mod pallet_xcm_benchmarks_generic; + +use crate::Runtime; +use frame_support::weights::Weight; +use sp_std::prelude::*; +use xcm::{latest::prelude::*, DoubleEncoded}; + +use pallet_xcm_benchmarks_fungible::WeightInfo as XcmBalancesWeight; +use pallet_xcm_benchmarks_generic::WeightInfo as XcmGeneric; + +/// Types of asset supported by the Polkadot runtime. +pub enum AssetTypes { + /// An asset backed by `pallet-balances`. + Balances, + /// Unknown asset. + Unknown, +} + +impl From<&MultiAsset> for AssetTypes { + fn from(asset: &MultiAsset) -> Self { + match asset { + MultiAsset { id: Concrete(MultiLocation { parents: 0, interior: Here }), .. } => + AssetTypes::Balances, + _ => AssetTypes::Unknown, + } + } +} + +trait WeighMultiAssets { + fn weigh_multi_assets(&self, balances_weight: Weight) -> Weight; +} + +// Polkadot only knows about one asset, the balances pallet. +const MAX_ASSETS: u64 = 1; + +impl WeighMultiAssets for MultiAssetFilter { + fn weigh_multi_assets(&self, balances_weight: Weight) -> Weight { + match self { + Self::Definite(assets) => assets + .inner() + .into_iter() + .map(From::from) + .map(|t| match t { + AssetTypes::Balances => balances_weight, + AssetTypes::Unknown => Weight::MAX, + }) + .fold(Weight::zero(), |acc, x| acc.saturating_add(x)), + // We don't support any NFTs on Polkadot, so these two variants will always match + // only 1 kind of fungible asset. + Self::Wild(AllOf { .. } | AllOfCounted { .. }) => balances_weight, + Self::Wild(AllCounted(count)) => + balances_weight.saturating_mul(MAX_ASSETS.min(*count as u64)), + Self::Wild(All) => balances_weight.saturating_mul(MAX_ASSETS), + } + } +} + +impl WeighMultiAssets for MultiAssets { + fn weigh_multi_assets(&self, balances_weight: Weight) -> Weight { + self.inner() + .into_iter() + .map(|m| >::from(m)) + .map(|t| match t { + AssetTypes::Balances => balances_weight, + AssetTypes::Unknown => Weight::MAX, + }) + .fold(Weight::zero(), |acc, x| acc.saturating_add(x)) + } +} + +pub struct PolkadotXcmWeight(core::marker::PhantomData); +impl XcmWeightInfo for PolkadotXcmWeight { + fn withdraw_asset(assets: &MultiAssets) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) + } + fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { + // TODO: The reserve asset deposited benchmark was removed + // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + Weight::MAX + } + fn receive_teleported_asset(assets: &MultiAssets) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) + } + fn query_response( + _query_id: &u64, + _response: &Response, + _max_weight: &Weight, + _querier: &Option, + ) -> Weight { + XcmGeneric::::query_response() + } + fn transfer_asset(assets: &MultiAssets, _dest: &MultiLocation) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::transfer_asset()) + } + fn transfer_reserve_asset( + assets: &MultiAssets, + _dest: &MultiLocation, + _xcm: &Xcm<()>, + ) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::transfer_reserve_asset()) + } + fn transact( + _origin_kind: &OriginKind, + _require_weight_at_most: &Weight, + _call: &DoubleEncoded, + ) -> Weight { + XcmGeneric::::transact() + } + fn hrmp_new_channel_open_request( + _sender: &u32, + _max_message_size: &u32, + _max_capacity: &u32, + ) -> Weight { + // XCM Executor does not currently support HRMP channel operations + Weight::MAX + } + fn hrmp_channel_accepted(_recipient: &u32) -> Weight { + // XCM Executor does not currently support HRMP channel operations + Weight::MAX + } + fn hrmp_channel_closing(_initiator: &u32, _sender: &u32, _recipient: &u32) -> Weight { + // XCM Executor does not currently support HRMP channel operations + Weight::MAX + } + fn clear_origin() -> Weight { + XcmGeneric::::clear_origin() + } + fn descend_origin(_who: &InteriorMultiLocation) -> Weight { + XcmGeneric::::descend_origin() + } + fn report_error(_query_response_info: &QueryResponseInfo) -> Weight { + XcmGeneric::::report_error() + } + + fn deposit_asset(assets: &MultiAssetFilter, _dest: &MultiLocation) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::deposit_asset()) + } + fn deposit_reserve_asset( + assets: &MultiAssetFilter, + _dest: &MultiLocation, + _xcm: &Xcm<()>, + ) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::deposit_reserve_asset()) + } + fn exchange_asset(_give: &MultiAssetFilter, _receive: &MultiAssets, _maximal: &bool) -> Weight { + // Polkadot does not currently support exchange asset operations + Weight::MAX + } + fn initiate_reserve_withdraw( + assets: &MultiAssetFilter, + _reserve: &MultiLocation, + _xcm: &Xcm<()>, + ) -> Weight { + assets.weigh_multi_assets(XcmGeneric::::initiate_reserve_withdraw()) + } + fn initiate_teleport( + assets: &MultiAssetFilter, + _dest: &MultiLocation, + _xcm: &Xcm<()>, + ) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::initiate_teleport()) + } + fn report_holding(_response_info: &QueryResponseInfo, _assets: &MultiAssetFilter) -> Weight { + XcmGeneric::::report_holding() + } + fn buy_execution(_fees: &MultiAsset, _weight_limit: &WeightLimit) -> Weight { + XcmGeneric::::buy_execution() + } + fn refund_surplus() -> Weight { + XcmGeneric::::refund_surplus() + } + fn set_error_handler(_xcm: &Xcm) -> Weight { + XcmGeneric::::set_error_handler() + } + fn set_appendix(_xcm: &Xcm) -> Weight { + XcmGeneric::::set_appendix() + } + fn clear_error() -> Weight { + XcmGeneric::::clear_error() + } + fn claim_asset(_assets: &MultiAssets, _ticket: &MultiLocation) -> Weight { + XcmGeneric::::claim_asset() + } + fn trap(_code: &u64) -> Weight { + XcmGeneric::::trap() + } + fn subscribe_version(_query_id: &QueryId, _max_response_weight: &Weight) -> Weight { + XcmGeneric::::subscribe_version() + } + fn unsubscribe_version() -> Weight { + XcmGeneric::::unsubscribe_version() + } + fn burn_asset(assets: &MultiAssets) -> Weight { + assets.weigh_multi_assets(XcmGeneric::::burn_asset()) + } + fn expect_asset(assets: &MultiAssets) -> Weight { + assets.weigh_multi_assets(XcmGeneric::::expect_asset()) + } + fn expect_origin(_origin: &Option) -> Weight { + XcmGeneric::::expect_origin() + } + fn expect_error(_error: &Option<(u32, XcmError)>) -> Weight { + XcmGeneric::::expect_error() + } + fn expect_transact_status(_transact_status: &MaybeErrorCode) -> Weight { + XcmGeneric::::expect_transact_status() + } + fn query_pallet(_module_name: &Vec, _response_info: &QueryResponseInfo) -> Weight { + XcmGeneric::::query_pallet() + } + fn expect_pallet( + _index: &u32, + _name: &Vec, + _module_name: &Vec, + _crate_major: &u32, + _min_crate_minor: &u32, + ) -> Weight { + XcmGeneric::::expect_pallet() + } + fn report_transact_status(_response_info: &QueryResponseInfo) -> Weight { + XcmGeneric::::report_transact_status() + } + fn clear_transact_status() -> Weight { + XcmGeneric::::clear_transact_status() + } + fn universal_origin(_: &Junction) -> Weight { + // Polkadot does not currently support universal origin operations + Weight::MAX + } + fn export_message(_: &NetworkId, _: &Junctions, _: &Xcm<()>) -> Weight { + // Polkadot relay should not support export message operations + Weight::MAX + } + fn lock_asset(_: &MultiAsset, _: &MultiLocation) -> Weight { + // Polkadot does not currently support asset locking operations + Weight::MAX + } + fn unlock_asset(_: &MultiAsset, _: &MultiLocation) -> Weight { + // Polkadot does not currently support asset locking operations + Weight::MAX + } + fn note_unlockable(_: &MultiAsset, _: &MultiLocation) -> Weight { + // Polkadot does not currently support asset locking operations + Weight::MAX + } + fn request_unlock(_: &MultiAsset, _: &MultiLocation) -> Weight { + // Polkadot does not currently support asset locking operations + Weight::MAX + } + fn set_fees_mode(_: &bool) -> Weight { + XcmGeneric::::set_fees_mode() + } + fn set_topic(_topic: &[u8; 32]) -> Weight { + XcmGeneric::::set_topic() + } + fn clear_topic() -> Weight { + XcmGeneric::::clear_topic() + } + fn alias_origin(_: &MultiLocation) -> Weight { + // XCM Executor does not currently support alias origin operations + Weight::MAX + } + fn unpaid_execution(_: &WeightLimit, _: &Option) -> Weight { + XcmGeneric::::unpaid_execution() + } +} + +#[test] +fn all_counted_has_a_sane_weight_upper_limit() { + let assets = MultiAssetFilter::Wild(AllCounted(4294967295)); + let weight = Weight::from_parts(1000, 1000); + + assert_eq!(assets.weigh_multi_assets(weight), weight * MAX_ASSETS); +} diff --git a/runtime/polkadot/src/weights/xcm/temp b/runtime/polkadot/src/weights/xcm/temp deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/runtime/polkadot/src/xcm_config.rs b/runtime/polkadot/src/xcm_config.rs index 660a0ee0be25..87784473443f 100644 --- a/runtime/polkadot/src/xcm_config.rs +++ b/runtime/polkadot/src/xcm_config.rs @@ -36,9 +36,9 @@ use xcm_builder::{ AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowKnownQueryResponses, AllowSubscriptionsFrom, AllowTopLevelPaidExecutionFrom, BackingToPlurality, ChildParachainAsNative, ChildParachainConvertsVia, CurrencyAdapter as XcmCurrencyAdapter, - FixedWeightBounds, IsConcrete, MintLocation, OriginToPluralityVoice, SignedAccountId32AsNative, + IsConcrete, MintLocation, OriginToPluralityVoice, SignedAccountId32AsNative, SignedToAccountId32, SovereignSignedViaLocation, TakeWeightCredit, UsingComponents, - WithComputedOrigin, + WeightInfoBounds, WithComputedOrigin, }; use xcm_executor::traits::WithOriginFilter; @@ -341,7 +341,11 @@ impl xcm_executor::Config for XcmConfig { type IsTeleporter = TrustedTeleporters; type UniversalLocation = UniversalLocation; type Barrier = Barrier; - type Weigher = FixedWeightBounds; + type Weigher = WeightInfoBounds< + crate::weights::xcm::PolkadotXcmWeight, + RuntimeCall, + MaxInstructions, + >; // The weight trader piggybacks on the existing transaction-fee conversion logic. type Trader = UsingComponents>; @@ -421,7 +425,11 @@ impl pallet_xcm::Config for Runtime { type XcmExecutor = xcm_executor::XcmExecutor; type XcmTeleportFilter = Everything; // == Allow All type XcmReserveTransferFilter = Everything; // == Allow All - type Weigher = FixedWeightBounds; + type Weigher = WeightInfoBounds< + crate::weights::xcm::PolkadotXcmWeight, + RuntimeCall, + MaxInstructions, + >; type UniversalLocation = UniversalLocation; type RuntimeOrigin = RuntimeOrigin; type RuntimeCall = RuntimeCall; From c82f5cc0a3a73b769f7927d3393d98c962840157 Mon Sep 17 00:00:00 2001 From: Oliver Tale-Yazdi Date: Fri, 14 Apr 2023 15:10:26 +0200 Subject: [PATCH 06/53] Make CI fail on old files Signed-off-by: Oliver Tale-Yazdi --- .../kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs | 1 + runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs | 2 +- .../rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs | 2 +- runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs | 2 +- .../westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs | 2 +- .../westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs | 2 +- 6 files changed, 6 insertions(+), 5 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 480e509b825a..e1470d21c278 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -51,6 +51,7 @@ impl WeightInfo { .saturating_add(T::DbWeight::get().reads(1 as u64)) .saturating_add(T::DbWeight::get().writes(1 as u64)) } + // FAIL-CI update me // Storage: System Account (r:2 w:2) pub(crate) fn transfer_asset() -> Weight { Weight::from_parts(32_756_000 as u64, 0) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 4bc4c74af59a..dc078b731ac7 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -19,7 +19,7 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev //! DATE: 2022-04-18, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 - +// FAIL-CI update me // Executed Command: // target/production/polkadot // benchmark diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index e8efa7ab95ee..7045186e96d6 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -19,7 +19,7 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev //! DATE: 2022-03-08, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 - +// FAIL-CI update me // Executed Command: // target/production/polkadot // benchmark diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index d49345abf80f..837cc89880c2 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -19,7 +19,7 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev //! DATE: 2022-03-08, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 - +// FAIL-CI update me // Executed Command: // target/production/polkadot // benchmark diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 5f5ef52956e8..50530941007a 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -19,7 +19,7 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev //! DATE: 2022-03-08, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 - +// FAIL-CI update me // Executed Command: // target/production/polkadot // benchmark diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index a2e599d6b888..99607abe5a7f 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -19,7 +19,7 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev //! DATE: 2022-12-12, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 - +// FAIL-CI update me // Executed Command: // /home/benchbot/cargo_target_dir/production/polkadot // benchmark From 71983ac364fc386dc6474d8f2a51a866b96377b9 Mon Sep 17 00:00:00 2001 From: Oliver Tale-Yazdi Date: Fri, 14 Apr 2023 15:15:54 +0200 Subject: [PATCH 07/53] Update template Signed-off-by: Oliver Tale-Yazdi --- xcm/pallet-xcm-benchmarks/template.hbs | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/xcm/pallet-xcm-benchmarks/template.hbs b/xcm/pallet-xcm-benchmarks/template.hbs index 7171f6599019..7a7c21630298 100644 --- a/xcm/pallet-xcm-benchmarks/template.hbs +++ b/xcm/pallet-xcm-benchmarks/template.hbs @@ -39,27 +39,37 @@ impl WeightInfo { {{#each benchmark.comments as |comment|}} // {{comment}} {{/each}} - pub(crate) fn {{benchmark.name~}} + {{#each benchmark.component_ranges as |range|}} + /// The range of component `{{range.name}}` is `[{{range.min}}, {{range.max}}]`. + {{/each}} + pub fn {{benchmark.name~}} ( {{~#each benchmark.components as |c| ~}} {{~#if (not c.is_used)}}_{{/if}}{{c.name}}: u32, {{/each~}} ) -> Weight { - Weight::from_ref_time({{underscore benchmark.base_weight}} as u64) + // Proof Size summary in bytes: + // Measured: `{{benchmark.base_recorded_proof_size}}{{#each benchmark.component_recorded_proof_size as |cp|}} + {{cp.name}} * ({{cp.slope}} ±{{underscore cp.error}}){{/each}}` + // Estimated: `{{benchmark.base_calculated_proof_size}}{{#each benchmark.component_calculated_proof_size as |cp|}} + {{cp.name}} * ({{cp.slope}} ±{{underscore cp.error}}){{/each}}` + // Minimum execution time: {{underscore benchmark.min_execution_time}}_000 picoseconds. + Weight::from_parts({{underscore benchmark.base_weight}}, {{benchmark.base_calculated_proof_size}}) {{#each benchmark.component_weight as |cw|}} // Standard Error: {{underscore cw.error}} - .saturating_add(Weight::from_ref_time({{underscore cw.slope}} as u64).saturating_mul({{cw.name}} as u64)) + .saturating_add(Weight::from_parts({{underscore cw.slope}}, 0).saturating_mul({{cw.name}}.into())) {{/each}} {{#if (ne benchmark.base_reads "0")}} - .saturating_add(T::DbWeight::get().reads({{benchmark.base_reads}} as u64)) + .saturating_add(T::DbWeight::get().reads({{benchmark.base_reads}})) {{/if}} {{#each benchmark.component_reads as |cr|}} - .saturating_add(T::DbWeight::get().reads(({{cr.slope}} as u64).saturating_mul({{cr.name}} as u64))) + .saturating_add(T::DbWeight::get().reads(({{cr.slope}}_u64).saturating_mul({{cr.name}}.into()))) {{/each}} {{#if (ne benchmark.base_writes "0")}} - .saturating_add(T::DbWeight::get().writes({{benchmark.base_writes}} as u64)) + .saturating_add(T::DbWeight::get().writes({{benchmark.base_writes}})) {{/if}} {{#each benchmark.component_writes as |cw|}} - .saturating_add(T::DbWeight::get().writes(({{cw.slope}} as u64).saturating_mul({{cw.name}} as u64))) + .saturating_add(T::DbWeight::get().writes(({{cw.slope}}_u64).saturating_mul({{cw.name}}.into()))) + {{/each}} + {{#each benchmark.component_calculated_proof_size as |cp|}} + .saturating_add(Weight::from_parts(0, {{cp.slope}}).saturating_mul({{cp.name}}.into())) {{/each}} } {{/each}} From 0113fd412c8468d8589820e375743c4cc626a056 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 14 Apr 2023 10:38:14 -0300 Subject: [PATCH 08/53] Add reserve_asset_deposited benchmark --- runtime/kusama/src/lib.rs | 5 +++ runtime/polkadot/src/lib.rs | 6 ++++ runtime/rococo/src/lib.rs | 15 ++++---- runtime/rococo/src/xcm_config.rs | 6 ++-- runtime/westend/src/lib.rs | 5 +++ .../src/fungible/benchmarking.rs | 34 +++++++++++++++++++ xcm/pallet-xcm-benchmarks/src/fungible/mod.rs | 4 +++ .../src/generic/benchmarking.rs | 15 -------- 8 files changed, 65 insertions(+), 25 deletions(-) diff --git a/runtime/kusama/src/lib.rs b/runtime/kusama/src/lib.rs index d51c2f08514d..2020127755e2 100644 --- a/runtime/kusama/src/lib.rs +++ b/runtime/kusama/src/lib.rs @@ -2045,6 +2045,10 @@ sp_api::impl_runtime_apis! { Statemine::get(), MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( + Statemine::get(), + MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, + )); } impl pallet_xcm_benchmarks::fungible::Config for Runtime { @@ -2052,6 +2056,7 @@ sp_api::impl_runtime_apis! { type CheckedAccount = LocalCheckAccount; type TrustedTeleporter = TrustedTeleporter; + type TrustedReserve = TrustedReserve; fn get_multi_asset() -> MultiAsset { MultiAsset { diff --git a/runtime/polkadot/src/lib.rs b/runtime/polkadot/src/lib.rs index 234d73b2c07a..326883f5af2b 100644 --- a/runtime/polkadot/src/lib.rs +++ b/runtime/polkadot/src/lib.rs @@ -1996,6 +1996,10 @@ sp_api::impl_runtime_apis! { StatemintLocation::get(), MultiAsset { id: Concrete(TokenLocation::get()), fun: Fungible(1 * UNITS) } )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( + StatemintLocation::get(), + MultiAsset { id: Concrete(TokenLocation::get()), fun: Fungible(1 * UNITS) } + )); } impl pallet_xcm_benchmarks::fungible::Config for Runtime { @@ -2003,6 +2007,8 @@ sp_api::impl_runtime_apis! { type CheckedAccount = LocalCheckAccount; type TrustedTeleporter = TrustedTeleporter; + type TrustedReserve = TrustedReserve; + fn get_multi_asset() -> MultiAsset { MultiAsset { id: Concrete(TokenLocation::get()), diff --git a/runtime/rococo/src/lib.rs b/runtime/rococo/src/lib.rs index 4e7ec5a59693..bc9e974da4ef 100644 --- a/runtime/rococo/src/lib.rs +++ b/runtime/rococo/src/lib.rs @@ -2018,7 +2018,7 @@ sp_api::impl_runtime_apis! { use frame_benchmarking::baseline::Pallet as Baseline; use xcm::latest::prelude::*; use xcm_config::{ - LocalCheckAccount, LocationConverter, Statemine, TokenLocation, XcmConfig, + LocalCheckAccount, LocationConverter, Rockmine, TokenLocation, XcmConfig, }; impl frame_system_benchmarking::Config for Runtime {} @@ -2027,7 +2027,7 @@ sp_api::impl_runtime_apis! { type XcmConfig = XcmConfig; type AccountIdConverter = LocationConverter; fn valid_destination() -> Result { - Ok(Statemine::get()) + Ok(Rockmine::get()) } fn worst_case_holding(_depositable_count: u32) -> MultiAssets { // Rococo only knows about ROC @@ -2040,11 +2040,11 @@ sp_api::impl_runtime_apis! { parameter_types! { pub const TrustedTeleporter: Option<(MultiLocation, MultiAsset)> = Some(( - Statemine::get(), + Rockmine::get(), MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, )); pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( - Statemine::get(), + Rockmine::get(), MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, )); } @@ -2054,6 +2054,7 @@ sp_api::impl_runtime_apis! { type CheckedAccount = LocalCheckAccount; type TrustedTeleporter = TrustedTeleporter; + type TrustedReserve = TrustedReserve; fn get_multi_asset() -> MultiAsset { MultiAsset { @@ -2081,15 +2082,15 @@ sp_api::impl_runtime_apis! { } fn transact_origin_and_runtime_call() -> Result<(MultiLocation, RuntimeCall), BenchmarkError> { - Ok((Statemine::get(), frame_system::Call::remark_with_event { remark: vec![] }.into())) + Ok((Rockmine::get(), frame_system::Call::remark_with_event { remark: vec![] }.into())) } fn subscribe_origin() -> Result { - Ok(Statemine::get()) + Ok(Rockmine::get()) } fn claimable_asset() -> Result<(MultiLocation, MultiLocation, MultiAssets), BenchmarkError> { - let origin = Statemine::get(); + let origin = Rockmine::get(); let assets: MultiAssets = (Concrete(TokenLocation::get()), 1_000 * UNITS).into(); let ticket = MultiLocation { parents: 0, interior: Here }; Ok((origin, ticket, assets)) diff --git a/runtime/rococo/src/xcm_config.rs b/runtime/rococo/src/xcm_config.rs index 872bbbe1a035..c6d1a056136d 100644 --- a/runtime/rococo/src/xcm_config.rs +++ b/runtime/rococo/src/xcm_config.rs @@ -92,7 +92,7 @@ pub type XcmRouter = ( parameter_types! { pub const Roc: MultiAssetFilter = Wild(AllOf { fun: WildFungible, id: Concrete(TokenLocation::get()) }); - pub const Statemine: MultiLocation = Parachain(1000).into_location(); + pub const Rockmine: MultiLocation = Parachain(1000).into_location(); pub const Contracts: MultiLocation = Parachain(1002).into_location(); pub const Encointer: MultiLocation = Parachain(1003).into_location(); pub const Tick: MultiLocation = Parachain(100).into_location(); @@ -101,7 +101,7 @@ parameter_types! { pub const RocForTick: (MultiAssetFilter, MultiLocation) = (Roc::get(), Tick::get()); pub const RocForTrick: (MultiAssetFilter, MultiLocation) = (Roc::get(), Trick::get()); pub const RocForTrack: (MultiAssetFilter, MultiLocation) = (Roc::get(), Track::get()); - pub const RocForStatemine: (MultiAssetFilter, MultiLocation) = (Roc::get(), Statemine::get()); + pub const RocForRockmine: (MultiAssetFilter, MultiLocation) = (Roc::get(), Rockmine::get()); pub const RocForContracts: (MultiAssetFilter, MultiLocation) = (Roc::get(), Contracts::get()); pub const RocForEncointer: (MultiAssetFilter, MultiLocation) = (Roc::get(), Encointer::get()); pub const MaxInstructions: u32 = 100; @@ -111,7 +111,7 @@ pub type TrustedTeleporters = ( xcm_builder::Case, xcm_builder::Case, xcm_builder::Case, - xcm_builder::Case, + xcm_builder::Case, xcm_builder::Case, xcm_builder::Case, ); diff --git a/runtime/westend/src/lib.rs b/runtime/westend/src/lib.rs index 5896d888fbad..18aaa5d28f93 100644 --- a/runtime/westend/src/lib.rs +++ b/runtime/westend/src/lib.rs @@ -1791,6 +1791,10 @@ sp_api::impl_runtime_apis! { Westmint::get(), MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( + Westmint::get(), + MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, + )); } impl pallet_xcm_benchmarks::fungible::Config for Runtime { @@ -1798,6 +1802,7 @@ sp_api::impl_runtime_apis! { type CheckedAccount = xcm_config::LocalCheckAccount; type TrustedTeleporter = TrustedTeleporter; + type TrustedReserve = TrustedReserve; fn get_multi_asset() -> MultiAsset { MultiAsset { diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs index 0a316a3f0aca..5edafa7b917f 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs @@ -131,6 +131,40 @@ benchmarks_instance_pallet! { // TODO: Check sender queue is not empty. #4426 } + reserve_asset_deposited { + let (trusted_reserve, transferable_reserve_asset) = T::TrustedReserve::get() + .ok_or(BenchmarkError::Skip)?; + + let assets: MultiAssets = vec![ transferable_reserve_asset ].into(); + + let mut executor = new_executor::(trusted_reserve); + let instruction = Instruction::ReserveAssetDeposited(assets.clone()); + let xcm = Xcm(vec![instruction]); + }: { + executor.bench_process(xcm).map_err(|_| { + BenchmarkError::Override( + BenchmarkResult::from_weight(T::BlockWeights::get().max_block) + ) + })?; + } verify { + assert!(executor.holding().ensure_contains(&assets).is_ok()); + } + + initiate_reserve_withdraw { + let holding = T::worst_case_holding(1); + let assets_filter = MultiAssetFilter::Definite(holding.clone()); + let reserve = T::valid_destination().map_err(|_| BenchmarkError::Skip)?; + let mut executor = new_executor::(Default::default()); + executor.set_holding(holding.into()); + let instruction = Instruction::InitiateReserveWithdraw { assets: assets_filter, reserve, xcm: Xcm(vec![]) }; + let xcm = Xcm(vec![instruction]); + }: { + executor.bench_process(xcm)?; + } verify { + // The execute completing successfully is as good as we can check. + // TODO: Potentially add new trait to XcmSender to detect a queued outgoing message. #4426 + } + receive_teleported_asset { // If there is no trusted teleporter, then we skip this benchmark. let (trusted_teleporter, teleportable_asset) = T::TrustedTeleporter::get() diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/mod.rs b/xcm/pallet-xcm-benchmarks/src/fungible/mod.rs index 7fa527dffeba..292921eb595f 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/mod.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/mod.rs @@ -39,6 +39,10 @@ pub mod pallet { /// A trusted location which we allow teleports from, and the asset we allow to teleport. type TrustedTeleporter: Get>; + /// A trusted location where reserve assets are stored, and the asset we allow to be + /// reserves. + type TrustedReserve: Get>; + /// Give me a fungible asset that your asset transactor is going to accept. fn get_multi_asset() -> xcm::latest::MultiAsset; } diff --git a/xcm/pallet-xcm-benchmarks/src/generic/benchmarking.rs b/xcm/pallet-xcm-benchmarks/src/generic/benchmarking.rs index b10c924529ba..e358b4bc00d9 100644 --- a/xcm/pallet-xcm-benchmarks/src/generic/benchmarking.rs +++ b/xcm/pallet-xcm-benchmarks/src/generic/benchmarking.rs @@ -281,21 +281,6 @@ benchmarks! { assert!(!::SubscriptionService::is_subscribed(&origin)); } - initiate_reserve_withdraw { - let holding = T::worst_case_holding(1); - let assets_filter = MultiAssetFilter::Definite(holding.clone()); - let reserve = T::valid_destination().map_err(|_| BenchmarkError::Skip)?; - let mut executor = new_executor::(Default::default()); - executor.set_holding(holding.into()); - let instruction = Instruction::InitiateReserveWithdraw { assets: assets_filter, reserve, xcm: Xcm(vec![]) }; - let xcm = Xcm(vec![instruction]); - }: { - executor.bench_process(xcm)?; - } verify { - // The execute completing successfully is as good as we can check. - // TODO: Potentially add new trait to XcmSender to detect a queued outgoing message. #4426 - } - burn_asset { let holding = T::worst_case_holding(0); let assets = holding.clone(); From c7e31e29a75dc5ac7a30d2ea91bee5a1c2f52639 Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Fri, 14 Apr 2023 14:27:09 +0000 Subject: [PATCH 09/53] ".git/.scripts/commands/bench/bench.sh" xcm kusama pallet_xcm_benchmarks::generic --- .../xcm/pallet_xcm_benchmarks_generic.rs | 312 +++++++++++++----- 1 file changed, 222 insertions(+), 90 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index dc078b731ac7..021940390791 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -17,24 +17,25 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::generic` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2022-04-18, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 -// FAIL-CI update me + // Executed Command: // target/production/polkadot // benchmark // pallet -// --chain=kusama-dev // --steps=50 // --repeat=20 -// --pallet=pallet_xcm_benchmarks::generic // --extrinsic=* // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json +// --pallet=pallet_xcm_benchmarks::generic +// --chain=kusama-dev // --header=./file_header.txt // --template=./xcm/pallet-xcm-benchmarks/template.hbs -// --output=./runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +// --output=./runtime/kusama/src/weights/xcm/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -47,140 +48,271 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl WeightInfo { // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn report_holding() -> Weight { - Weight::from_parts(25_878_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_holding() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `14420` + // Minimum execution time: 30_714_000 picoseconds. + Weight::from_parts(31_031_000, 14420) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn buy_execution() -> Weight { - Weight::from_parts(3_697_000 as u64, 0) + pub fn buy_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_102_000 picoseconds. + Weight::from_parts(3_164_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) - pub(crate) fn query_response() -> Weight { - Weight::from_parts(13_458_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) + // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) + pub fn query_response() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `3634` + // Minimum execution time: 11_618_000 picoseconds. + Weight::from_parts(11_905_000, 3634) + .saturating_add(T::DbWeight::get().reads(1)) } - pub(crate) fn transact() -> Weight { - Weight::from_parts(13_597_000 as u64, 0) + pub fn transact() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 13_531_000 picoseconds. + Weight::from_parts(13_805_000, 0) } - pub(crate) fn refund_surplus() -> Weight { - Weight::from_parts(3_839_000 as u64, 0) + pub fn refund_surplus() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_396_000 picoseconds. + Weight::from_parts(3_485_000, 0) } - pub(crate) fn set_error_handler() -> Weight { - Weight::from_parts(3_657_000 as u64, 0) + pub fn set_error_handler() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_093_000 picoseconds. + Weight::from_parts(3_150_000, 0) } - pub(crate) fn set_appendix() -> Weight { - Weight::from_parts(3_757_000 as u64, 0) + pub fn set_appendix() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_121_000 picoseconds. + Weight::from_parts(3_206_000, 0) } - pub(crate) fn clear_error() -> Weight { - Weight::from_parts(3_651_000 as u64, 0) + pub fn clear_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_105_000 picoseconds. + Weight::from_parts(3_219_000, 0) } - pub(crate) fn descend_origin() -> Weight { - Weight::from_parts(4_589_000 as u64, 0) + pub fn descend_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_913_000 picoseconds. + Weight::from_parts(4_000_000, 0) } - pub(crate) fn clear_origin() -> Weight { - Weight::from_parts(3_661_000 as u64, 0) + pub fn clear_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_073_000 picoseconds. + Weight::from_parts(3_149_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn report_error() -> Weight { - Weight::from_parts(21_351_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `14420` + // Minimum execution time: 24_871_000 picoseconds. + Weight::from_parts(25_358_000, 14420) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: XcmPallet AssetTraps (r:1 w:1) - pub(crate) fn claim_asset() -> Weight { - Weight::from_parts(7_674_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof Skipped: XcmPallet AssetTraps (max_values: None, max_size: None, mode: Measured) + pub fn claim_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `226` + // Estimated: `3691` + // Minimum execution time: 16_117_000 picoseconds. + Weight::from_parts(16_338_000, 3691) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - pub(crate) fn trap() -> Weight { - Weight::from_parts(3_606_000 as u64, 0) + pub fn trap() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_024_000 picoseconds. + Weight::from_parts(3_133_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn subscribe_version() -> Weight { - Weight::from_parts(30_453_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn subscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `18096` + // Minimum execution time: 31_053_000 picoseconds. + Weight::from_parts(31_452_000, 18096) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: XcmPallet VersionNotifyTargets (r:0 w:1) - pub(crate) fn unsubscribe_version() -> Weight { - Weight::from_parts(5_543_000 as u64, 0) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) + pub fn unsubscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 5_693_000 picoseconds. + Weight::from_parts(5_877_000, 0) + .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn initiate_reserve_withdraw() -> Weight { - Weight::from_parts(25_464_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + pub fn burn_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_887_000 picoseconds. + Weight::from_parts(5_001_000, 0) } - pub(crate) fn burn_asset() -> Weight { - Weight::from_parts(5_194_000 as u64, 0) + pub fn expect_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_141_000 picoseconds. + Weight::from_parts(3_216_000, 0) } - pub(crate) fn expect_asset() -> Weight { - Weight::from_parts(3_698_000 as u64, 0) + pub fn expect_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_130_000 picoseconds. + Weight::from_parts(3_219_000, 0) } - pub(crate) fn expect_origin() -> Weight { - Weight::from_parts(3_786_000 as u64, 0) + pub fn expect_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_002_000 picoseconds. + Weight::from_parts(3_106_000, 0) } - pub(crate) fn expect_error() -> Weight { - Weight::from_parts(3_645_000 as u64, 0) - } - pub(crate) fn expect_transact_status() -> Weight { - Weight::from_parts(3_645_000 as u64, 0) + pub fn expect_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_175_000 picoseconds. + Weight::from_parts(3_322_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn query_pallet() -> Weight { - Weight::from_parts(22_993_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn query_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `14420` + // Minimum execution time: 32_487_000 picoseconds. + Weight::from_parts(32_785_000, 14420) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn expect_pallet() -> Weight { - Weight::from_parts(4_043_000 as u64, 0) + pub fn expect_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 8_657_000 picoseconds. + Weight::from_parts(8_749_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn report_transact_status() -> Weight { - Weight::from_parts(21_668_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `14420` + // Minimum execution time: 25_238_000 picoseconds. + Weight::from_parts(25_835_000, 14420) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn clear_transact_status() -> Weight { - Weight::from_parts(3_673_000 as u64, 0) + pub fn clear_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_030_000 picoseconds. + Weight::from_parts(3_127_000, 0) } - pub(crate) fn set_topic() -> Weight { - Weight::from_parts(3_661_000 as u64, 0) + pub fn set_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_066_000 picoseconds. + Weight::from_parts(3_177_000, 0) } - pub(crate) fn clear_topic() -> Weight { - Weight::from_parts(3_647_000 as u64, 0) + pub fn clear_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_095_000 picoseconds. + Weight::from_parts(3_151_000, 0) } - pub(crate) fn set_fees_mode() -> Weight { - Weight::from_parts(3_599_000 as u64, 0) + pub fn set_fees_mode() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_083_000 picoseconds. + Weight::from_parts(3_196_000, 0) } - pub(crate) fn unpaid_execution() -> Weight { - Weight::from_parts(3_111_000 as u64, 0) + pub fn unpaid_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_245_000 picoseconds. + Weight::from_parts(3_353_000, 0) } } From 7f4243e786e52c11cfb5a4259f258f1b1a4eaefd Mon Sep 17 00:00:00 2001 From: Oliver Tale-Yazdi Date: Fri, 14 Apr 2023 14:35:53 +0000 Subject: [PATCH 10/53] Update weights Signed-off-by: Oliver Tale-Yazdi --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 159 ++++++--- .../xcm/pallet_xcm_benchmarks_generic.rs | 115 +++--- .../xcm/pallet_xcm_benchmarks_fungible.rs | 119 +++++-- .../xcm/pallet_xcm_benchmarks_generic.rs | 274 ++++++++++----- .../xcm/pallet_xcm_benchmarks_fungible.rs | 168 ++++++--- .../xcm/pallet_xcm_benchmarks_generic.rs | 328 +++++++++++++----- .../xcm/pallet_xcm_benchmarks_fungible.rs | 157 ++++++--- .../xcm/pallet_xcm_benchmarks_generic.rs | 298 +++++++++++----- 8 files changed, 1137 insertions(+), 481 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index e1470d21c278..c710df39ed8d 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,23 +17,24 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2022-03-08, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 // Executed Command: -// target/production/polkadot +// ./target/production/polkadot // benchmark -// --chain=kusama-dev +// pallet // --steps=50 // --repeat=20 -// --pallet=pallet_xcm_benchmarks::fungible // --extrinsic=* // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --pallet=pallet_xcm_benchmarks::fungible +// --chain=kusama-dev // --header=./file_header.txt // --template=./xcm/pallet-xcm-benchmarks/template.hbs -// --output=./runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +// --output=./runtime/kusama/src/weights/xcm/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -46,68 +47,142 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl WeightInfo { // Storage: System Account (r:1 w:1) - pub(crate) fn withdraw_asset() -> Weight { - Weight::from_parts(20_385_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn withdraw_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `3593` + // Minimum execution time: 22_078_000 picoseconds. + Weight::from_parts(22_349_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - // FAIL-CI update me // Storage: System Account (r:2 w:2) - pub(crate) fn transfer_asset() -> Weight { - Weight::from_parts(32_756_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(2 as u64)) - .saturating_add(T::DbWeight::get().writes(2 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn transfer_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `6196` + // Minimum execution time: 45_939_000 picoseconds. + Weight::from_parts(46_397_000, 6196) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:2 w:2) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn transfer_reserve_asset() -> Weight { - Weight::from_parts(50_645_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(8 as u64)) - .saturating_add(T::DbWeight::get().writes(5 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn transfer_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `312` + // Estimated: `21121` + // Minimum execution time: 67_802_000 picoseconds. + Weight::from_parts(68_667_000, 21121) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(5)) } // Storage: Benchmark Override (r:0 w:0) - pub(crate) fn reserve_asset_deposited() -> Weight { - Weight::from_parts(2_000_000_000_000 as u64, 0) + // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub fn reserve_asset_deposited() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) + } + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn initiate_reserve_withdraw() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `14420` + // Minimum execution time: 28_665_000 picoseconds. + Weight::from_parts(29_477_000, 14420) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: System Account (r:1 w:1) - pub(crate) fn receive_teleported_asset() -> Weight { - Weight::from_parts(19_595_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub fn receive_teleported_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `103` + // Estimated: `5094` + // Minimum execution time: 22_223_000 picoseconds. + Weight::from_parts(22_759_000, 5094) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:1 w:1) - pub(crate) fn deposit_asset() -> Weight { - Weight::from_parts(21_763_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn deposit_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3593` + // Minimum execution time: 24_505_000 picoseconds. + Weight::from_parts(24_770_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn deposit_reserve_asset() -> Weight { - Weight::from_parts(40_930_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn deposit_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `18013` + // Minimum execution time: 49_208_000 picoseconds. + Weight::from_parts(49_603_000, 18013) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn initiate_teleport() -> Weight { - Weight::from_parts(40_788_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn initiate_teleport() -> Weight { + // Proof Size summary in bytes: + // Measured: `211` + // Estimated: `19514` + // Minimum execution time: 51_242_000 picoseconds. + Weight::from_parts(51_644_000, 19514) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(5)) } } diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 021940390791..72f3bb5c861f 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -21,7 +21,7 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 // Executed Command: -// target/production/polkadot +// ./target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,7 +30,6 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 -// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::generic // --chain=kusama-dev // --header=./file_header.txt @@ -61,8 +60,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 30_714_000 picoseconds. - Weight::from_parts(31_031_000, 14420) + // Minimum execution time: 29_572_000 picoseconds. + Weight::from_parts(30_281_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -70,8 +69,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_102_000 picoseconds. - Weight::from_parts(3_164_000, 0) + // Minimum execution time: 3_046_000 picoseconds. + Weight::from_parts(3_116_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) @@ -79,58 +78,58 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `3634` - // Minimum execution time: 11_618_000 picoseconds. - Weight::from_parts(11_905_000, 3634) + // Minimum execution time: 11_221_000 picoseconds. + Weight::from_parts(11_588_000, 3634) .saturating_add(T::DbWeight::get().reads(1)) } pub fn transact() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 13_531_000 picoseconds. - Weight::from_parts(13_805_000, 0) + // Minimum execution time: 13_158_000 picoseconds. + Weight::from_parts(13_453_000, 0) } pub fn refund_surplus() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_396_000 picoseconds. - Weight::from_parts(3_485_000, 0) + // Minimum execution time: 3_334_000 picoseconds. + Weight::from_parts(3_394_000, 0) } pub fn set_error_handler() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_093_000 picoseconds. - Weight::from_parts(3_150_000, 0) + // Minimum execution time: 2_984_000 picoseconds. + Weight::from_parts(3_043_000, 0) } pub fn set_appendix() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_121_000 picoseconds. - Weight::from_parts(3_206_000, 0) + // Minimum execution time: 3_000_000 picoseconds. + Weight::from_parts(3_104_000, 0) } pub fn clear_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_105_000 picoseconds. - Weight::from_parts(3_219_000, 0) + // Minimum execution time: 2_991_000 picoseconds. + Weight::from_parts(3_069_000, 0) } pub fn descend_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_913_000 picoseconds. - Weight::from_parts(4_000_000, 0) + // Minimum execution time: 3_862_000 picoseconds. + Weight::from_parts(3_932_000, 0) } pub fn clear_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_073_000 picoseconds. - Weight::from_parts(3_149_000, 0) + // Minimum execution time: 2_983_000 picoseconds. + Weight::from_parts(3_076_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -146,8 +145,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 24_871_000 picoseconds. - Weight::from_parts(25_358_000, 14420) + // Minimum execution time: 24_598_000 picoseconds. + Weight::from_parts(24_938_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -157,8 +156,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `226` // Estimated: `3691` - // Minimum execution time: 16_117_000 picoseconds. - Weight::from_parts(16_338_000, 3691) + // Minimum execution time: 15_675_000 picoseconds. + Weight::from_parts(15_871_000, 3691) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -166,8 +165,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_024_000 picoseconds. - Weight::from_parts(3_133_000, 0) + // Minimum execution time: 3_013_000 picoseconds. + Weight::from_parts(3_059_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) @@ -185,8 +184,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `18096` - // Minimum execution time: 31_053_000 picoseconds. - Weight::from_parts(31_452_000, 18096) + // Minimum execution time: 30_853_000 picoseconds. + Weight::from_parts(31_232_000, 18096) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -196,44 +195,44 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 5_693_000 picoseconds. - Weight::from_parts(5_877_000, 0) + // Minimum execution time: 5_228_000 picoseconds. + Weight::from_parts(5_317_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } pub fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_887_000 picoseconds. - Weight::from_parts(5_001_000, 0) + // Minimum execution time: 4_721_000 picoseconds. + Weight::from_parts(4_861_000, 0) } pub fn expect_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_141_000 picoseconds. - Weight::from_parts(3_216_000, 0) + // Minimum execution time: 3_137_000 picoseconds. + Weight::from_parts(3_193_000, 0) } pub fn expect_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_130_000 picoseconds. - Weight::from_parts(3_219_000, 0) + // Minimum execution time: 3_083_000 picoseconds. + Weight::from_parts(3_148_000, 0) } pub fn expect_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_002_000 picoseconds. - Weight::from_parts(3_106_000, 0) + // Minimum execution time: 2_968_000 picoseconds. + Weight::from_parts(3_059_000, 0) } pub fn expect_transact_status() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_175_000 picoseconds. - Weight::from_parts(3_322_000, 0) + // Minimum execution time: 3_170_000 picoseconds. + Weight::from_parts(3_277_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -249,8 +248,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 32_487_000 picoseconds. - Weight::from_parts(32_785_000, 14420) + // Minimum execution time: 31_659_000 picoseconds. + Weight::from_parts(32_008_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -258,8 +257,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 8_657_000 picoseconds. - Weight::from_parts(8_749_000, 0) + // Minimum execution time: 8_469_000 picoseconds. + Weight::from_parts(8_650_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -275,8 +274,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 25_238_000 picoseconds. - Weight::from_parts(25_835_000, 14420) + // Minimum execution time: 24_819_000 picoseconds. + Weight::from_parts(25_278_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -284,35 +283,35 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_030_000 picoseconds. - Weight::from_parts(3_127_000, 0) + // Minimum execution time: 3_033_000 picoseconds. + Weight::from_parts(3_093_000, 0) } pub fn set_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_066_000 picoseconds. - Weight::from_parts(3_177_000, 0) + // Minimum execution time: 2_996_000 picoseconds. + Weight::from_parts(3_047_000, 0) } pub fn clear_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_095_000 picoseconds. - Weight::from_parts(3_151_000, 0) + // Minimum execution time: 2_951_000 picoseconds. + Weight::from_parts(3_054_000, 0) } pub fn set_fees_mode() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_083_000 picoseconds. - Weight::from_parts(3_196_000, 0) + // Minimum execution time: 3_040_000 picoseconds. + Weight::from_parts(3_135_000, 0) } pub fn unpaid_execution() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_245_000 picoseconds. - Weight::from_parts(3_353_000, 0) + // Minimum execution time: 3_232_000 picoseconds. + Weight::from_parts(3_327_000, 0) } } diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 7b50203486c3..ca985c3efef2 100644 --- a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,11 +17,11 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-04-13, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 // Executed Command: -// target/production/polkadot +// ./target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,7 +30,6 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 -// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::fungible // --chain=polkadot-dev // --header=./file_header.txt @@ -49,17 +48,25 @@ pub struct WeightInfo(PhantomData); impl WeightInfo { // Storage: System Account (r:1 w:1) // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub(crate) fn withdraw_asset() -> Weight { - Weight::from_ref_time(23_068_000 as u64) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + pub fn withdraw_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `3593` + // Minimum execution time: 22_524_000 picoseconds. + Weight::from_parts(22_950_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } // Storage: System Account (r:2 w:2) // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub(crate) fn transfer_asset() -> Weight { - Weight::from_ref_time(47_403_000 as u64) - .saturating_add(T::DbWeight::get().reads(2 as u64)) - .saturating_add(T::DbWeight::get().writes(2 as u64)) + pub fn transfer_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `6196` + // Minimum execution time: 47_108_000 picoseconds. + Weight::from_parts(47_524_000, 6196) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:2 w:2) // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) @@ -75,26 +82,68 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn transfer_reserve_asset() -> Weight { - Weight::from_ref_time(73_056_000 as u64) - .saturating_add(T::DbWeight::get().reads(8 as u64)) - .saturating_add(T::DbWeight::get().writes(5 as u64)) + pub fn transfer_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `615` + // Estimated: `24736` + // Minimum execution time: 72_182_000 picoseconds. + Weight::from_parts(72_771_000, 24736) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(5)) + } + // Storage: Benchmark Override (r:0 w:0) + // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub fn reserve_asset_deposited() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) + } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn initiate_reserve_withdraw() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `17934` + // Minimum execution time: 31_832_000 picoseconds. + Weight::from_parts(32_262_000, 17934) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: System Account (r:1 w:1) // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) // Storage: Balances InactiveIssuance (r:1 w:1) // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - pub(crate) fn receive_teleported_asset() -> Weight { - Weight::from_ref_time(23_922_000 as u64) - .saturating_add(T::DbWeight::get().reads(2 as u64)) - .saturating_add(T::DbWeight::get().writes(2 as u64)) + pub fn receive_teleported_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `103` + // Estimated: `5094` + // Minimum execution time: 23_355_000 picoseconds. + Weight::from_parts(23_641_000, 5094) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:1 w:1) // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub(crate) fn deposit_asset() -> Weight { - Weight::from_ref_time(24_975_000 as u64) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + pub fn deposit_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3593` + // Minimum execution time: 24_496_000 picoseconds. + Weight::from_parts(24_822_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } // Storage: System Account (r:1 w:1) // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) @@ -110,10 +159,14 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn deposit_reserve_asset() -> Weight { - Weight::from_ref_time(55_235_000 as u64) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + pub fn deposit_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `21527` + // Minimum execution time: 53_334_000 picoseconds. + Weight::from_parts(54_116_000, 21527) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: System Account (r:1 w:1) // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) @@ -131,9 +184,13 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn initiate_teleport() -> Weight { - Weight::from_ref_time(57_122_000 as u64) - .saturating_add(T::DbWeight::get().reads(8 as u64)) - .saturating_add(T::DbWeight::get().writes(5 as u64)) + pub fn initiate_teleport() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `23028` + // Minimum execution time: 55_818_000 picoseconds. + Weight::from_parts(56_264_000, 23028) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(5)) } } diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 4428f20a16dd..5d1395104080 100644 --- a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -17,11 +17,11 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::generic` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-04-13, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 // Executed Command: -// target/production/polkadot +// ./target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,7 +30,6 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 -// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::generic // --chain=polkadot-dev // --header=./file_header.txt @@ -59,40 +58,80 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn report_holding() -> Weight { - Weight::from_ref_time(33_538_000 as u64) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + pub fn report_holding() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `17934` + // Minimum execution time: 33_235_000 picoseconds. + Weight::from_parts(33_849_000, 17934) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn buy_execution() -> Weight { - Weight::from_ref_time(3_018_000 as u64) + pub fn buy_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_936_000 picoseconds. + Weight::from_parts(3_075_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) - pub(crate) fn query_response() -> Weight { - Weight::from_ref_time(12_644_000 as u64) - .saturating_add(T::DbWeight::get().reads(1 as u64)) + pub fn query_response() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `3634` + // Minimum execution time: 12_593_000 picoseconds. + Weight::from_parts(12_863_000, 3634) + .saturating_add(T::DbWeight::get().reads(1)) } - pub(crate) fn transact() -> Weight { - Weight::from_ref_time(13_371_000 as u64) + pub fn transact() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 13_311_000 picoseconds. + Weight::from_parts(13_427_000, 0) } - pub(crate) fn refund_surplus() -> Weight { - Weight::from_ref_time(3_236_000 as u64) + pub fn refund_surplus() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_174_000 picoseconds. + Weight::from_parts(3_270_000, 0) } - pub(crate) fn set_error_handler() -> Weight { - Weight::from_ref_time(3_022_000 as u64) + pub fn set_error_handler() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_915_000 picoseconds. + Weight::from_parts(3_053_000, 0) } - pub(crate) fn set_appendix() -> Weight { - Weight::from_ref_time(3_077_000 as u64) + pub fn set_appendix() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_930_000 picoseconds. + Weight::from_parts(2_985_000, 0) } - pub(crate) fn clear_error() -> Weight { - Weight::from_ref_time(2_976_000 as u64) + pub fn clear_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_966_000 picoseconds. + Weight::from_parts(3_093_000, 0) } - pub(crate) fn descend_origin() -> Weight { - Weight::from_ref_time(3_847_000 as u64) + pub fn descend_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_772_000 picoseconds. + Weight::from_parts(3_866_000, 0) } - pub(crate) fn clear_origin() -> Weight { - Weight::from_ref_time(2_928_000 as u64) + pub fn clear_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_895_000 picoseconds. + Weight::from_parts(3_006_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -106,20 +145,32 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn report_error() -> Weight { - Weight::from_ref_time(28_104_000 as u64) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + pub fn report_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `17934` + // Minimum execution time: 27_953_000 picoseconds. + Weight::from_parts(28_353_000, 17934) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: XcmPallet AssetTraps (r:1 w:1) // Proof Skipped: XcmPallet AssetTraps (max_values: None, max_size: None, mode: Measured) - pub(crate) fn claim_asset() -> Weight { - Weight::from_ref_time(16_919_000 as u64) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + pub fn claim_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `226` + // Estimated: `3691` + // Minimum execution time: 16_687_000 picoseconds. + Weight::from_parts(16_826_000, 3691) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - pub(crate) fn trap() -> Weight { - Weight::from_ref_time(2_941_000 as u64) + pub fn trap() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_893_000 picoseconds. + Weight::from_parts(2_993_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) @@ -135,48 +186,59 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn subscribe_version() -> Weight { - Weight::from_ref_time(34_841_000 as u64) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + pub fn subscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `21913` + // Minimum execution time: 34_486_000 picoseconds. + Weight::from_parts(35_154_000, 21913) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: XcmPallet VersionNotifyTargets (r:0 w:1) // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) - pub(crate) fn unsubscribe_version() -> Weight { - Weight::from_ref_time(5_427_000 as u64) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + pub fn unsubscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 5_218_000 picoseconds. + Weight::from_parts(5_377_000, 0) + .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn initiate_reserve_withdraw() -> Weight { - Weight::from_ref_time(32_854_000 as u64) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) - } - pub(crate) fn burn_asset() -> Weight { - Weight::from_ref_time(5_028_000 as u64) + pub fn burn_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_647_000 picoseconds. + Weight::from_parts(4_743_000, 0) } - pub(crate) fn expect_asset() -> Weight { - Weight::from_ref_time(3_206_000 as u64) + pub fn expect_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_056_000 picoseconds. + Weight::from_parts(3_154_000, 0) } - pub(crate) fn expect_origin() -> Weight { - Weight::from_ref_time(3_135_000 as u64) + pub fn expect_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_054_000 picoseconds. + Weight::from_parts(3_134_000, 0) } - pub(crate) fn expect_error() -> Weight { - Weight::from_ref_time(2_977_000 as u64) + pub fn expect_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_890_000 picoseconds. + Weight::from_parts(2_981_000, 0) } - pub(crate) fn expect_transact_status() -> Weight { - Weight::from_ref_time(3_200_000 as u64) + pub fn expect_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_198_000 picoseconds. + Weight::from_parts(3_262_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -190,13 +252,21 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn query_pallet() -> Weight { - Weight::from_ref_time(36_411_000 as u64) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + pub fn query_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `17934` + // Minimum execution time: 35_483_000 picoseconds. + Weight::from_parts(36_117_000, 17934) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn expect_pallet() -> Weight { - Weight::from_ref_time(8_501_000 as u64) + pub fn expect_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 9_136_000 picoseconds. + Weight::from_parts(9_268_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -210,24 +280,48 @@ impl WeightInfo { // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn report_transact_status() -> Weight { - Weight::from_ref_time(28_416_000 as u64) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + pub fn report_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `514` + // Estimated: `17934` + // Minimum execution time: 28_042_000 picoseconds. + Weight::from_parts(28_491_000, 17934) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn clear_transact_status() -> Weight { - Weight::from_ref_time(3_048_000 as u64) + pub fn clear_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_899_000 picoseconds. + Weight::from_parts(3_043_000, 0) } - pub(crate) fn set_topic() -> Weight { - Weight::from_ref_time(2_958_000 as u64) + pub fn set_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_892_000 picoseconds. + Weight::from_parts(2_968_000, 0) } - pub(crate) fn clear_topic() -> Weight { - Weight::from_ref_time(2_945_000 as u64) + pub fn clear_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_928_000 picoseconds. + Weight::from_parts(3_007_000, 0) } - pub(crate) fn set_fees_mode() -> Weight { - Weight::from_ref_time(3_014_000 as u64) + pub fn set_fees_mode() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_047_000 picoseconds. + Weight::from_parts(3_101_000, 0) } - pub(crate) fn unpaid_execution() -> Weight { - Weight::from_ref_time(3_179_000 as u64) + pub fn unpaid_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_156_000 picoseconds. + Weight::from_parts(3_233_000, 0) } } diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 7045186e96d6..ff21dee77cad 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,23 +17,24 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2022-03-08, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 -// FAIL-CI update me + // Executed Command: -// target/production/polkadot +// ./target/production/polkadot // benchmark -// --chain=rococo-dev +// pallet // --steps=50 // --repeat=20 -// --pallet=pallet_xcm_benchmarks::fungible // --extrinsic=* // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --pallet=pallet_xcm_benchmarks::fungible +// --chain=rococo-dev // --header=./file_header.txt // --template=./xcm/pallet-xcm-benchmarks/template.hbs -// --output=./runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +// --output=./runtime/rococo/src/weights/xcm/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -46,67 +47,150 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl WeightInfo { // Storage: System Account (r:1 w:1) - pub(crate) fn withdraw_asset() -> Weight { - Weight::from_parts(20_385_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn withdraw_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `3593` + // Minimum execution time: 23_301_000 picoseconds. + Weight::from_parts(23_528_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } // Storage: System Account (r:2 w:2) - pub(crate) fn transfer_asset() -> Weight { - Weight::from_parts(32_756_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(2 as u64)) - .saturating_add(T::DbWeight::get().writes(2 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn transfer_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `6196` + // Minimum execution time: 47_042_000 picoseconds. + Weight::from_parts(47_730_000, 6196) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:2 w:2) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn transfer_reserve_asset() -> Weight { - Weight::from_parts(50_645_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(8 as u64)) - .saturating_add(T::DbWeight::get().writes(5 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn transfer_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `686` + // Estimated: `25162` + // Minimum execution time: 72_548_000 picoseconds. + Weight::from_parts(73_531_000, 25162) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(5)) } // Storage: Benchmark Override (r:0 w:0) - pub(crate) fn reserve_asset_deposited() -> Weight { - Weight::from_parts(2_000_000_000_000 as u64, 0) + // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub fn reserve_asset_deposited() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) + } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn initiate_reserve_withdraw() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `18360` + // Minimum execution time: 32_189_000 picoseconds. + Weight::from_parts(32_477_000, 18360) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: System Account (r:1 w:1) - pub(crate) fn receive_teleported_asset() -> Weight { - Weight::from_parts(19_595_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub fn receive_teleported_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `103` + // Estimated: `5094` + // Minimum execution time: 23_792_000 picoseconds. + Weight::from_parts(24_115_000, 5094) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:1 w:1) - pub(crate) fn deposit_asset() -> Weight { - Weight::from_parts(21_763_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn deposit_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3593` + // Minimum execution time: 24_350_000 picoseconds. + Weight::from_parts(24_732_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn deposit_reserve_asset() -> Weight { - Weight::from_parts(40_930_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn deposit_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `21953` + // Minimum execution time: 53_928_000 picoseconds. + Weight::from_parts(54_448_000, 21953) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn initiate_teleport() -> Weight { - Weight::from_parts(40_788_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn initiate_teleport() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `23454` + // Minimum execution time: 56_302_000 picoseconds. + Weight::from_parts(56_849_000, 23454) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(5)) } } diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 837cc89880c2..76b43dbf386c 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -17,23 +17,24 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::generic` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2022-03-08, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 -// FAIL-CI update me + // Executed Command: -// target/production/polkadot +// ./target/production/polkadot // benchmark -// --chain=rococo-dev +// pallet // --steps=50 // --repeat=20 -// --pallet=pallet_xcm_benchmarks::generic // --extrinsic=* // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --pallet=pallet_xcm_benchmarks::generic +// --chain=rococo-dev // --header=./file_header.txt // --template=./xcm/pallet-xcm-benchmarks/template.hbs -// --output=./runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +// --output=./runtime/rococo/src/weights/xcm/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -45,145 +46,282 @@ use sp_std::marker::PhantomData; /// Weights for `pallet_xcm_benchmarks::generic`. pub struct WeightInfo(PhantomData); impl WeightInfo { + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn report_holding() -> Weight { - Weight::from_parts(21_822_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_holding() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `18360` + // Minimum execution time: 32_716_000 picoseconds. + Weight::from_parts(33_280_000, 18360) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn buy_execution() -> Weight { - Weight::from_parts(3_109_000 as u64, 0) + pub fn buy_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_930_000 picoseconds. + Weight::from_parts(3_016_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) - pub(crate) fn query_response() -> Weight { - Weight::from_parts(12_087_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) + // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) + pub fn query_response() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `3634` + // Minimum execution time: 11_869_000 picoseconds. + Weight::from_parts(12_139_000, 3634) + .saturating_add(T::DbWeight::get().reads(1)) } - pub(crate) fn transact() -> Weight { - Weight::from_parts(12_398_000 as u64, 0) + pub fn transact() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 13_159_000 picoseconds. + Weight::from_parts(13_328_000, 0) } - pub(crate) fn refund_surplus() -> Weight { - Weight::from_parts(3_247_000 as u64, 0) + pub fn refund_surplus() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_157_000 picoseconds. + Weight::from_parts(3_268_000, 0) } - pub(crate) fn set_error_handler() -> Weight { - Weight::from_parts(3_086_000 as u64, 0) + pub fn set_error_handler() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_885_000 picoseconds. + Weight::from_parts(2_953_000, 0) } - pub(crate) fn set_appendix() -> Weight { - Weight::from_parts(3_112_000 as u64, 0) + pub fn set_appendix() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_884_000 picoseconds. + Weight::from_parts(2_958_000, 0) } - pub(crate) fn clear_error() -> Weight { - Weight::from_parts(3_118_000 as u64, 0) + pub fn clear_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_816_000 picoseconds. + Weight::from_parts(2_885_000, 0) } - pub(crate) fn descend_origin() -> Weight { - Weight::from_parts(4_054_000 as u64, 0) + pub fn descend_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_709_000 picoseconds. + Weight::from_parts(3_807_000, 0) } - pub(crate) fn clear_origin() -> Weight { - Weight::from_parts(3_111_000 as u64, 0) + pub fn clear_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_776_000 picoseconds. + Weight::from_parts(2_871_000, 0) } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn report_error() -> Weight { - Weight::from_parts(18_425_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `18360` + // Minimum execution time: 27_390_000 picoseconds. + Weight::from_parts(27_829_000, 18360) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: XcmPallet AssetTraps (r:1 w:1) - pub(crate) fn claim_asset() -> Weight { - Weight::from_parts(7_144_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof Skipped: XcmPallet AssetTraps (max_values: None, max_size: None, mode: Measured) + pub fn claim_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `226` + // Estimated: `3691` + // Minimum execution time: 16_342_000 picoseconds. + Weight::from_parts(16_686_000, 3691) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - pub(crate) fn trap() -> Weight { - Weight::from_parts(3_060_000 as u64, 0) + pub fn trap() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_791_000 picoseconds. + Weight::from_parts(2_861_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn subscribe_version() -> Weight { - Weight::from_parts(21_642_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn subscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `22410` + // Minimum execution time: 34_328_000 picoseconds. + Weight::from_parts(34_584_000, 22410) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: XcmPallet VersionNotifyTargets (r:0 w:1) - pub(crate) fn unsubscribe_version() -> Weight { - Weight::from_parts(4_873_000 as u64, 0) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) + pub fn unsubscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_954_000 picoseconds. + Weight::from_parts(5_105_000, 0) + .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn initiate_reserve_withdraw() -> Weight { - Weight::from_parts(22_809_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + pub fn burn_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_599_000 picoseconds. + Weight::from_parts(4_668_000, 0) } - pub(crate) fn burn_asset() -> Weight { - Weight::from_parts(5_259_000 as u64, 0) + pub fn expect_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_041_000 picoseconds. + Weight::from_parts(3_141_000, 0) } - pub(crate) fn expect_asset() -> Weight { - Weight::from_parts(3_745_000 as u64, 0) + pub fn expect_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_963_000 picoseconds. + Weight::from_parts(3_048_000, 0) } - pub(crate) fn expect_origin() -> Weight { - Weight::from_parts(3_847_000 as u64, 0) + pub fn expect_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_885_000 picoseconds. + Weight::from_parts(2_949_000, 0) } - pub(crate) fn expect_error() -> Weight { - Weight::from_parts(3_633_000 as u64, 0) - } - pub(crate) fn expect_transact_status() -> Weight { - Weight::from_parts(3_633_000 as u64, 0) + pub fn expect_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_082_000 picoseconds. + Weight::from_parts(3_184_000, 0) } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn query_pallet() -> Weight { - Weight::from_parts(21_645_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn query_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `18360` + // Minimum execution time: 35_270_000 picoseconds. + Weight::from_parts(35_801_000, 18360) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn expect_pallet() -> Weight { - Weight::from_parts(4_017_000 as u64, 0) + pub fn expect_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 8_929_000 picoseconds. + Weight::from_parts(9_031_000, 0) } + // Storage: Configuration ActiveConfig (r:1 w:0) + // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn report_transact_status() -> Weight { - Weight::from_parts(20_465_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `585` + // Estimated: `18360` + // Minimum execution time: 27_699_000 picoseconds. + Weight::from_parts(28_072_000, 18360) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn clear_transact_status() -> Weight { - Weight::from_parts(3_723_000 as u64, 0) + pub fn clear_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_872_000 picoseconds. + Weight::from_parts(2_950_000, 0) } - pub(crate) fn set_topic() -> Weight { - Weight::from_parts(3_687_000 as u64, 0) + pub fn set_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_803_000 picoseconds. + Weight::from_parts(2_936_000, 0) } - pub(crate) fn clear_topic() -> Weight { - Weight::from_parts(3_654_000 as u64, 0) + pub fn clear_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_798_000 picoseconds. + Weight::from_parts(2_907_000, 0) } - pub(crate) fn set_fees_mode() -> Weight { - Weight::from_parts(3_721_000 as u64, 0) + pub fn set_fees_mode() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_889_000 picoseconds. + Weight::from_parts(2_963_000, 0) } - pub(crate) fn unpaid_execution() -> Weight { - Weight::from_parts(3_111_000 as u64, 0) + pub fn unpaid_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_051_000 picoseconds. + Weight::from_parts(3_137_000, 0) } } diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 50530941007a..a0c492e2c676 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,23 +17,24 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2022-03-08, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 -// FAIL-CI update me + // Executed Command: -// target/production/polkadot +// ./target/production/polkadot // benchmark -// --chain=westend-dev +// pallet // --steps=50 // --repeat=20 -// --pallet=pallet_xcm_benchmarks::fungible // --extrinsic=* // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --pallet=pallet_xcm_benchmarks::fungible +// --chain=westend-dev // --header=./file_header.txt // --template=./xcm/pallet-xcm-benchmarks/template.hbs -// --output=./runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +// --output=./runtime/westend/src/weights/xcm/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -46,64 +47,142 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl WeightInfo { // Storage: System Account (r:1 w:1) - pub(crate) fn withdraw_asset() -> Weight { - Weight::from_parts(20_308_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn withdraw_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `3593` + // Minimum execution time: 22_331_000 picoseconds. + Weight::from_parts(22_556_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } // Storage: System Account (r:2 w:2) - pub(crate) fn transfer_asset() -> Weight { - Weight::from_parts(32_193_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(2 as u64)) - .saturating_add(T::DbWeight::get().writes(2 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn transfer_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `101` + // Estimated: `6196` + // Minimum execution time: 46_335_000 picoseconds. + Weight::from_parts(46_863_000, 6196) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:2 w:2) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn transfer_reserve_asset() -> Weight { - Weight::from_parts(50_731_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(7 as u64)) - .saturating_add(T::DbWeight::get().writes(5 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn transfer_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `270` + // Estimated: `20911` + // Minimum execution time: 66_497_000 picoseconds. + Weight::from_parts(66_873_000, 20911) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(5)) } // Storage: Benchmark Override (r:0 w:0) - pub(crate) fn reserve_asset_deposited() -> Weight { - Weight::from_parts(2_000_000_000_000 as u64, 0) + // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub fn reserve_asset_deposited() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) + } + // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn initiate_reserve_withdraw() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `14210` + // Minimum execution time: 26_102_000 picoseconds. + Weight::from_parts(26_572_000, 14210) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: System Account (r:1 w:1) - pub(crate) fn receive_teleported_asset() -> Weight { - Weight::from_parts(19_622_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub fn receive_teleported_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `103` + // Estimated: `5094` + // Minimum execution time: 22_467_000 picoseconds. + Weight::from_parts(22_678_000, 5094) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) } // Storage: System Account (r:1 w:1) - pub(crate) fn deposit_asset() -> Weight { - Weight::from_parts(22_433_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub fn deposit_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3593` + // Minimum execution time: 24_717_000 picoseconds. + Weight::from_parts(25_118_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn deposit_reserve_asset() -> Weight { - Weight::from_parts(41_765_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn deposit_reserve_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `17803` + // Minimum execution time: 47_829_000 picoseconds. + Weight::from_parts(49_168_000, 17803) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: System Account (r:1 w:1) + // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + // Storage: Balances InactiveIssuance (r:1 w:1) + // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) - pub(crate) fn initiate_teleport() -> Weight { - Weight::from_parts(41_204_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn initiate_teleport() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `19304` + // Minimum execution time: 49_272_000 picoseconds. + Weight::from_parts(49_794_000, 19304) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(5)) } } diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 99607abe5a7f..4f406f705ea8 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -17,11 +17,11 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::generic` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2022-12-12, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 -// FAIL-CI update me + // Executed Command: -// /home/benchbot/cargo_target_dir/production/polkadot +// ./target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,7 +30,6 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 -// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::generic // --chain=westend-dev // --header=./file_header.txt @@ -48,140 +47,271 @@ use sp_std::marker::PhantomData; pub struct WeightInfo(PhantomData); impl WeightInfo { // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - pub(crate) fn report_holding() -> Weight { - Weight::from_parts(34_089_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_holding() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `14210` + // Minimum execution time: 28_349_000 picoseconds. + Weight::from_parts(28_616_000, 14210) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn buy_execution() -> Weight { - Weight::from_parts(5_751_000 as u64, 0) + pub fn buy_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_987_000 picoseconds. + Weight::from_parts(3_055_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) - pub(crate) fn query_response() -> Weight { - Weight::from_parts(17_938_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) + // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) + pub fn query_response() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `3634` + // Minimum execution time: 11_226_000 picoseconds. + Weight::from_parts(11_490_000, 3634) + .saturating_add(T::DbWeight::get().reads(1)) } - pub(crate) fn transact() -> Weight { - Weight::from_parts(20_699_000 as u64, 0) + pub fn transact() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 13_092_000 picoseconds. + Weight::from_parts(13_352_000, 0) } - pub(crate) fn refund_surplus() -> Weight { - Weight::from_parts(6_077_000 as u64, 0) + pub fn refund_surplus() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_120_000 picoseconds. + Weight::from_parts(3_240_000, 0) } - pub(crate) fn set_error_handler() -> Weight { - Weight::from_parts(5_747_000 as u64, 0) + pub fn set_error_handler() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_926_000 picoseconds. + Weight::from_parts(3_012_000, 0) } - pub(crate) fn set_appendix() -> Weight { - Weight::from_parts(5_837_000 as u64, 0) + pub fn set_appendix() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_962_000 picoseconds. + Weight::from_parts(3_053_000, 0) } - pub(crate) fn clear_error() -> Weight { - Weight::from_parts(5_712_000 as u64, 0) + pub fn clear_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_882_000 picoseconds. + Weight::from_parts(2_986_000, 0) } - pub(crate) fn descend_origin() -> Weight { - Weight::from_parts(6_471_000 as u64, 0) + pub fn descend_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_838_000 picoseconds. + Weight::from_parts(3_943_000, 0) } - pub(crate) fn clear_origin() -> Weight { - Weight::from_parts(5_725_000 as u64, 0) + pub fn clear_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_845_000 picoseconds. + Weight::from_parts(2_953_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - pub(crate) fn report_error() -> Weight { - Weight::from_parts(29_975_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `14210` + // Minimum execution time: 22_610_000 picoseconds. + Weight::from_parts(22_918_000, 14210) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } // Storage: XcmPallet AssetTraps (r:1 w:1) - pub(crate) fn claim_asset() -> Weight { - Weight::from_parts(21_598_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(1 as u64)) - .saturating_add(T::DbWeight::get().writes(1 as u64)) + // Proof Skipped: XcmPallet AssetTraps (max_values: None, max_size: None, mode: Measured) + pub fn claim_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `226` + // Estimated: `3691` + // Minimum execution time: 15_546_000 picoseconds. + Weight::from_parts(15_948_000, 3691) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - pub(crate) fn trap() -> Weight { - Weight::from_parts(5_665_000 as u64, 0) + pub fn trap() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_932_000 picoseconds. + Weight::from_parts(2_994_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - pub(crate) fn subscribe_version() -> Weight { - Weight::from_parts(38_343_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(6 as u64)) - .saturating_add(T::DbWeight::get().writes(4 as u64)) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn subscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `17844` + // Minimum execution time: 29_311_000 picoseconds. + Weight::from_parts(29_794_000, 17844) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } // Storage: XcmPallet VersionNotifyTargets (r:0 w:1) - pub(crate) fn unsubscribe_version() -> Weight { - Weight::from_parts(8_353_000 as u64, 0) - .saturating_add(T::DbWeight::get().writes(1 as u64)) - } - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - pub(crate) fn initiate_reserve_withdraw() -> Weight { - Weight::from_parts(33_100_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) + pub fn unsubscribe_version() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 5_081_000 picoseconds. + Weight::from_parts(5_248_000, 0) + .saturating_add(T::DbWeight::get().writes(1)) } - pub(crate) fn burn_asset() -> Weight { - Weight::from_parts(7_259_000 as u64, 0) + pub fn burn_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_720_000 picoseconds. + Weight::from_parts(4_773_000, 0) } - pub(crate) fn expect_asset() -> Weight { - Weight::from_parts(5_848_000 as u64, 0) + pub fn expect_asset() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_014_000 picoseconds. + Weight::from_parts(3_109_000, 0) } - pub(crate) fn expect_origin() -> Weight { - Weight::from_parts(5_787_000 as u64, 0) + pub fn expect_origin() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_021_000 picoseconds. + Weight::from_parts(3_077_000, 0) } - pub(crate) fn expect_error() -> Weight { - Weight::from_parts(5_775_000 as u64, 0) + pub fn expect_error() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_903_000 picoseconds. + Weight::from_parts(3_013_000, 0) } - pub(crate) fn expect_transact_status() -> Weight { - Weight::from_parts(5_775_000 as u64, 0) + pub fn expect_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_247_000 picoseconds. + Weight::from_parts(3_424_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - pub(crate) fn query_pallet() -> Weight { - Weight::from_parts(34_846_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn query_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `14210` + // Minimum execution time: 28_942_000 picoseconds. + Weight::from_parts(29_573_000, 14210) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn expect_pallet() -> Weight { - Weight::from_parts(8_844_000 as u64, 0) + pub fn expect_pallet() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 7_633_000 picoseconds. + Weight::from_parts(7_818_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) + // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SafeXcmVersion (r:1 w:0) + // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueues (r:1 w:1) + // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - pub(crate) fn report_transact_status() -> Weight { - Weight::from_parts(50_256_000 as u64, 0) - .saturating_add(T::DbWeight::get().reads(5 as u64)) - .saturating_add(T::DbWeight::get().writes(3 as u64)) + // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub fn report_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `169` + // Estimated: `14210` + // Minimum execution time: 22_860_000 picoseconds. + Weight::from_parts(23_241_000, 14210) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - pub(crate) fn clear_transact_status() -> Weight { - Weight::from_parts(9_959_000 as u64, 0) + pub fn clear_transact_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_896_000 picoseconds. + Weight::from_parts(3_017_000, 0) } - pub(crate) fn set_topic() -> Weight { - Weight::from_parts(10_007_000 as u64, 0) + pub fn set_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_864_000 picoseconds. + Weight::from_parts(2_956_000, 0) } - pub(crate) fn clear_topic() -> Weight { - Weight::from_parts(8_289_000 as u64, 0) + pub fn clear_topic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_893_000 picoseconds. + Weight::from_parts(2_986_000, 0) } - pub(crate) fn set_fees_mode() -> Weight { - Weight::from_parts(5_764_000 as u64, 0) + pub fn set_fees_mode() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_960_000 picoseconds. + Weight::from_parts(3_058_000, 0) } - pub(crate) fn unpaid_execution() -> Weight { - Weight::from_parts(5_924_000 as u64, 0) + pub fn unpaid_execution() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_074_000 picoseconds. + Weight::from_parts(3_164_000, 0) } } From 6401da3fc093750c4e48701f6e8825a73aab60e6 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 14 Apr 2023 12:53:44 -0300 Subject: [PATCH 11/53] Change initiate_reserve_deposit in runtime weights --- runtime/kusama/src/weights/xcm/mod.rs | 2 +- runtime/polkadot/src/weights/xcm/mod.rs | 8 +++----- runtime/rococo/src/weights/xcm/mod.rs | 2 +- runtime/westend/src/weights/xcm/mod.rs | 2 +- 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/mod.rs b/runtime/kusama/src/weights/xcm/mod.rs index 2cb84f4484af..ec73d891ec59 100644 --- a/runtime/kusama/src/weights/xcm/mod.rs +++ b/runtime/kusama/src/weights/xcm/mod.rs @@ -166,7 +166,7 @@ impl XcmWeightInfo for KusamaXcmWeight { _reserve: &MultiLocation, _xcm: &Xcm<()>, ) -> Weight { - assets.weigh_multi_assets(XcmGeneric::::initiate_reserve_withdraw()) + assets.weigh_multi_assets(XcmBalancesWeight::::initiate_reserve_withdraw()) } fn initiate_teleport( assets: &MultiAssetFilter, diff --git a/runtime/polkadot/src/weights/xcm/mod.rs b/runtime/polkadot/src/weights/xcm/mod.rs index 2727d2a35bca..98c12fa7dba3 100644 --- a/runtime/polkadot/src/weights/xcm/mod.rs +++ b/runtime/polkadot/src/weights/xcm/mod.rs @@ -90,10 +90,8 @@ impl XcmWeightInfo for PolkadotXcmWeight fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { - // TODO: The reserve asset deposited benchmark was removed - // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) - Weight::MAX + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) @@ -168,7 +166,7 @@ impl XcmWeightInfo for PolkadotXcmWeight _reserve: &MultiLocation, _xcm: &Xcm<()>, ) -> Weight { - assets.weigh_multi_assets(XcmGeneric::::initiate_reserve_withdraw()) + assets.weigh_multi_assets(XcmBalancesWeight::::initiate_reserve_withdraw()) } fn initiate_teleport( assets: &MultiAssetFilter, diff --git a/runtime/rococo/src/weights/xcm/mod.rs b/runtime/rococo/src/weights/xcm/mod.rs index 77bfabdac0c3..cc485dfbaf7e 100644 --- a/runtime/rococo/src/weights/xcm/mod.rs +++ b/runtime/rococo/src/weights/xcm/mod.rs @@ -166,7 +166,7 @@ impl XcmWeightInfo for RococoXcmWeight { _reserve: &MultiLocation, _xcm: &Xcm<()>, ) -> Weight { - assets.weigh_multi_assets(XcmGeneric::::initiate_reserve_withdraw()) + assets.weigh_multi_assets(XcmBalancesWeight::::initiate_reserve_withdraw()) } fn initiate_teleport( assets: &MultiAssetFilter, diff --git a/runtime/westend/src/weights/xcm/mod.rs b/runtime/westend/src/weights/xcm/mod.rs index 230dab55fbc5..d5b3d8257ba5 100644 --- a/runtime/westend/src/weights/xcm/mod.rs +++ b/runtime/westend/src/weights/xcm/mod.rs @@ -169,7 +169,7 @@ impl XcmWeightInfo for WestendXcmWeight { _reserve: &MultiLocation, _xcm: &Xcm<()>, ) -> Weight { - assets.weigh_multi_assets(XcmGeneric::::initiate_reserve_withdraw()) + assets.weigh_multi_assets(XcmBalancesWeight::::initiate_reserve_withdraw()) } fn initiate_teleport( assets: &MultiAssetFilter, From ad68740bcd686b6d633312b5da12f5ed617fec44 Mon Sep 17 00:00:00 2001 From: Oliver Tale-Yazdi Date: Fri, 14 Apr 2023 17:03:26 +0000 Subject: [PATCH 12/53] Update weights Signed-off-by: Oliver Tale-Yazdi --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 32 ++--- .../xcm/pallet_xcm_benchmarks_generic.rs | 112 +++++++++--------- .../xcm/pallet_xcm_benchmarks_fungible.rs | 32 ++--- .../xcm/pallet_xcm_benchmarks_generic.rs | 110 ++++++++--------- .../xcm/pallet_xcm_benchmarks_fungible.rs | 32 ++--- .../xcm/pallet_xcm_benchmarks_generic.rs | 112 +++++++++--------- .../xcm/pallet_xcm_benchmarks_fungible.rs | 32 ++--- .../xcm/pallet_xcm_benchmarks_generic.rs | 110 ++++++++--------- 8 files changed, 286 insertions(+), 286 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index c710df39ed8d..1bb7980ac146 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -52,8 +52,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 22_078_000 picoseconds. - Weight::from_parts(22_349_000, 3593) + // Minimum execution time: 21_938_000 picoseconds. + Weight::from_parts(22_222_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -63,8 +63,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 45_939_000 picoseconds. - Weight::from_parts(46_397_000, 6196) + // Minimum execution time: 45_662_000 picoseconds. + Weight::from_parts(46_305_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -84,8 +84,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `312` // Estimated: `21121` - // Minimum execution time: 67_802_000 picoseconds. - Weight::from_parts(68_667_000, 21121) + // Minimum execution time: 67_634_000 picoseconds. + Weight::from_parts(68_477_000, 21121) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -112,8 +112,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 28_665_000 picoseconds. - Weight::from_parts(29_477_000, 14420) + // Minimum execution time: 27_863_000 picoseconds. + Weight::from_parts(28_394_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -125,8 +125,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `103` // Estimated: `5094` - // Minimum execution time: 22_223_000 picoseconds. - Weight::from_parts(22_759_000, 5094) + // Minimum execution time: 22_235_000 picoseconds. + Weight::from_parts(22_622_000, 5094) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -136,8 +136,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 24_505_000 picoseconds. - Weight::from_parts(24_770_000, 3593) + // Minimum execution time: 25_006_000 picoseconds. + Weight::from_parts(25_595_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -157,8 +157,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `18013` - // Minimum execution time: 49_208_000 picoseconds. - Weight::from_parts(49_603_000, 18013) + // Minimum execution time: 48_982_000 picoseconds. + Weight::from_parts(49_465_000, 18013) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -180,8 +180,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `19514` - // Minimum execution time: 51_242_000 picoseconds. - Weight::from_parts(51_644_000, 19514) + // Minimum execution time: 51_103_000 picoseconds. + Weight::from_parts(51_607_000, 19514) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 72f3bb5c861f..ac59bc0f57da 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -60,8 +60,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 29_572_000 picoseconds. - Weight::from_parts(30_281_000, 14420) + // Minimum execution time: 30_353_000 picoseconds. + Weight::from_parts(30_785_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -69,8 +69,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_046_000 picoseconds. - Weight::from_parts(3_116_000, 0) + // Minimum execution time: 3_121_000 picoseconds. + Weight::from_parts(3_196_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) @@ -78,58 +78,58 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `3634` - // Minimum execution time: 11_221_000 picoseconds. - Weight::from_parts(11_588_000, 3634) + // Minimum execution time: 11_377_000 picoseconds. + Weight::from_parts(11_753_000, 3634) .saturating_add(T::DbWeight::get().reads(1)) } pub fn transact() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 13_158_000 picoseconds. - Weight::from_parts(13_453_000, 0) + // Minimum execution time: 12_991_000 picoseconds. + Weight::from_parts(13_281_000, 0) } pub fn refund_surplus() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_334_000 picoseconds. - Weight::from_parts(3_394_000, 0) + // Minimum execution time: 3_252_000 picoseconds. + Weight::from_parts(3_383_000, 0) } pub fn set_error_handler() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_984_000 picoseconds. - Weight::from_parts(3_043_000, 0) + // Minimum execution time: 2_987_000 picoseconds. + Weight::from_parts(3_096_000, 0) } pub fn set_appendix() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_000_000 picoseconds. - Weight::from_parts(3_104_000, 0) + // Minimum execution time: 3_030_000 picoseconds. + Weight::from_parts(3_085_000, 0) } pub fn clear_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_991_000 picoseconds. - Weight::from_parts(3_069_000, 0) + // Minimum execution time: 2_963_000 picoseconds. + Weight::from_parts(3_070_000, 0) } pub fn descend_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_862_000 picoseconds. - Weight::from_parts(3_932_000, 0) + // Minimum execution time: 3_847_000 picoseconds. + Weight::from_parts(3_942_000, 0) } pub fn clear_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_983_000 picoseconds. - Weight::from_parts(3_076_000, 0) + // Minimum execution time: 2_958_000 picoseconds. + Weight::from_parts(3_090_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -145,8 +145,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 24_598_000 picoseconds. - Weight::from_parts(24_938_000, 14420) + // Minimum execution time: 24_729_000 picoseconds. + Weight::from_parts(25_072_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -156,8 +156,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `226` // Estimated: `3691` - // Minimum execution time: 15_675_000 picoseconds. - Weight::from_parts(15_871_000, 3691) + // Minimum execution time: 15_505_000 picoseconds. + Weight::from_parts(15_838_000, 3691) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -165,8 +165,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_013_000 picoseconds. - Weight::from_parts(3_059_000, 0) + // Minimum execution time: 3_001_000 picoseconds. + Weight::from_parts(3_062_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) @@ -184,8 +184,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `18096` - // Minimum execution time: 30_853_000 picoseconds. - Weight::from_parts(31_232_000, 18096) + // Minimum execution time: 31_129_000 picoseconds. + Weight::from_parts(31_671_000, 18096) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -195,44 +195,44 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 5_228_000 picoseconds. - Weight::from_parts(5_317_000, 0) + // Minimum execution time: 5_284_000 picoseconds. + Weight::from_parts(5_443_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } pub fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_721_000 picoseconds. - Weight::from_parts(4_861_000, 0) + // Minimum execution time: 4_810_000 picoseconds. + Weight::from_parts(4_880_000, 0) } pub fn expect_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_137_000 picoseconds. - Weight::from_parts(3_193_000, 0) + // Minimum execution time: 3_171_000 picoseconds. + Weight::from_parts(3_274_000, 0) } pub fn expect_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_083_000 picoseconds. - Weight::from_parts(3_148_000, 0) + // Minimum execution time: 3_115_000 picoseconds. + Weight::from_parts(3_156_000, 0) } pub fn expect_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_968_000 picoseconds. - Weight::from_parts(3_059_000, 0) + // Minimum execution time: 3_020_000 picoseconds. + Weight::from_parts(3_086_000, 0) } pub fn expect_transact_status() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_170_000 picoseconds. - Weight::from_parts(3_277_000, 0) + // Minimum execution time: 3_188_000 picoseconds. + Weight::from_parts(3_216_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -248,8 +248,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 31_659_000 picoseconds. - Weight::from_parts(32_008_000, 14420) + // Minimum execution time: 32_313_000 picoseconds. + Weight::from_parts(32_687_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -257,8 +257,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 8_469_000 picoseconds. - Weight::from_parts(8_650_000, 0) + // Minimum execution time: 9_067_000 picoseconds. + Weight::from_parts(9_272_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -274,8 +274,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `211` // Estimated: `14420` - // Minimum execution time: 24_819_000 picoseconds. - Weight::from_parts(25_278_000, 14420) + // Minimum execution time: 25_048_000 picoseconds. + Weight::from_parts(25_468_000, 14420) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -283,35 +283,35 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_033_000 picoseconds. - Weight::from_parts(3_093_000, 0) + // Minimum execution time: 3_005_000 picoseconds. + Weight::from_parts(3_086_000, 0) } pub fn set_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_996_000 picoseconds. - Weight::from_parts(3_047_000, 0) + // Minimum execution time: 3_068_000 picoseconds. + Weight::from_parts(3_118_000, 0) } pub fn clear_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_951_000 picoseconds. - Weight::from_parts(3_054_000, 0) + // Minimum execution time: 2_989_000 picoseconds. + Weight::from_parts(3_084_000, 0) } pub fn set_fees_mode() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_040_000 picoseconds. - Weight::from_parts(3_135_000, 0) + // Minimum execution time: 3_096_000 picoseconds. + Weight::from_parts(3_143_000, 0) } pub fn unpaid_execution() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_232_000 picoseconds. - Weight::from_parts(3_327_000, 0) + // Minimum execution time: 3_227_000 picoseconds. + Weight::from_parts(3_280_000, 0) } } diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index ca985c3efef2..25ec6735234d 100644 --- a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -52,8 +52,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 22_524_000 picoseconds. - Weight::from_parts(22_950_000, 3593) + // Minimum execution time: 22_432_000 picoseconds. + Weight::from_parts(22_938_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -63,8 +63,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 47_108_000 picoseconds. - Weight::from_parts(47_524_000, 6196) + // Minimum execution time: 46_441_000 picoseconds. + Weight::from_parts(46_975_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -86,8 +86,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `615` // Estimated: `24736` - // Minimum execution time: 72_182_000 picoseconds. - Weight::from_parts(72_771_000, 24736) + // Minimum execution time: 71_708_000 picoseconds. + Weight::from_parts(72_580_000, 24736) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -116,8 +116,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `17934` - // Minimum execution time: 31_832_000 picoseconds. - Weight::from_parts(32_262_000, 17934) + // Minimum execution time: 31_541_000 picoseconds. + Weight::from_parts(32_014_000, 17934) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -129,8 +129,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `103` // Estimated: `5094` - // Minimum execution time: 23_355_000 picoseconds. - Weight::from_parts(23_641_000, 5094) + // Minimum execution time: 23_314_000 picoseconds. + Weight::from_parts(23_774_000, 5094) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -140,8 +140,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 24_496_000 picoseconds. - Weight::from_parts(24_822_000, 3593) + // Minimum execution time: 24_430_000 picoseconds. + Weight::from_parts(24_840_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -163,8 +163,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `21527` - // Minimum execution time: 53_334_000 picoseconds. - Weight::from_parts(54_116_000, 21527) + // Minimum execution time: 53_534_000 picoseconds. + Weight::from_parts(53_924_000, 21527) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -188,8 +188,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `23028` - // Minimum execution time: 55_818_000 picoseconds. - Weight::from_parts(56_264_000, 23028) + // Minimum execution time: 55_441_000 picoseconds. + Weight::from_parts(55_988_000, 23028) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(5)) } diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 5d1395104080..0b61e7cd8d1f 100644 --- a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -62,8 +62,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `17934` - // Minimum execution time: 33_235_000 picoseconds. - Weight::from_parts(33_849_000, 17934) + // Minimum execution time: 33_813_000 picoseconds. + Weight::from_parts(34_357_000, 17934) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -71,8 +71,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_936_000 picoseconds. - Weight::from_parts(3_075_000, 0) + // Minimum execution time: 3_067_000 picoseconds. + Weight::from_parts(3_153_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) @@ -80,58 +80,58 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `3634` - // Minimum execution time: 12_593_000 picoseconds. - Weight::from_parts(12_863_000, 3634) + // Minimum execution time: 12_236_000 picoseconds. + Weight::from_parts(12_725_000, 3634) .saturating_add(T::DbWeight::get().reads(1)) } pub fn transact() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 13_311_000 picoseconds. + // Minimum execution time: 13_193_000 picoseconds. Weight::from_parts(13_427_000, 0) } pub fn refund_surplus() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_174_000 picoseconds. - Weight::from_parts(3_270_000, 0) + // Minimum execution time: 3_393_000 picoseconds. + Weight::from_parts(3_464_000, 0) } pub fn set_error_handler() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_915_000 picoseconds. - Weight::from_parts(3_053_000, 0) + // Minimum execution time: 2_955_000 picoseconds. + Weight::from_parts(3_068_000, 0) } pub fn set_appendix() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_930_000 picoseconds. - Weight::from_parts(2_985_000, 0) + // Minimum execution time: 3_004_000 picoseconds. + Weight::from_parts(3_107_000, 0) } pub fn clear_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_966_000 picoseconds. - Weight::from_parts(3_093_000, 0) + // Minimum execution time: 2_981_000 picoseconds. + Weight::from_parts(3_039_000, 0) } pub fn descend_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_772_000 picoseconds. - Weight::from_parts(3_866_000, 0) + // Minimum execution time: 3_814_000 picoseconds. + Weight::from_parts(3_897_000, 0) } pub fn clear_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_895_000 picoseconds. - Weight::from_parts(3_006_000, 0) + // Minimum execution time: 2_921_000 picoseconds. + Weight::from_parts(3_010_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -149,8 +149,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `17934` - // Minimum execution time: 27_953_000 picoseconds. - Weight::from_parts(28_353_000, 17934) + // Minimum execution time: 28_324_000 picoseconds. + Weight::from_parts(28_690_000, 17934) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -160,8 +160,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `226` // Estimated: `3691` - // Minimum execution time: 16_687_000 picoseconds. - Weight::from_parts(16_826_000, 3691) + // Minimum execution time: 16_430_000 picoseconds. + Weight::from_parts(16_774_000, 3691) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -169,8 +169,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_893_000 picoseconds. - Weight::from_parts(2_993_000, 0) + // Minimum execution time: 2_916_000 picoseconds. + Weight::from_parts(3_035_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) @@ -190,8 +190,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `21913` - // Minimum execution time: 34_486_000 picoseconds. - Weight::from_parts(35_154_000, 21913) + // Minimum execution time: 35_915_000 picoseconds. + Weight::from_parts(36_519_000, 21913) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -201,44 +201,44 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 5_218_000 picoseconds. - Weight::from_parts(5_377_000, 0) + // Minimum execution time: 5_344_000 picoseconds. + Weight::from_parts(5_487_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } pub fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_647_000 picoseconds. - Weight::from_parts(4_743_000, 0) + // Minimum execution time: 4_684_000 picoseconds. + Weight::from_parts(4_801_000, 0) } pub fn expect_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_056_000 picoseconds. - Weight::from_parts(3_154_000, 0) + // Minimum execution time: 3_228_000 picoseconds. + Weight::from_parts(3_325_000, 0) } pub fn expect_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_054_000 picoseconds. - Weight::from_parts(3_134_000, 0) + // Minimum execution time: 3_059_000 picoseconds. + Weight::from_parts(3_153_000, 0) } pub fn expect_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_890_000 picoseconds. - Weight::from_parts(2_981_000, 0) + // Minimum execution time: 3_037_000 picoseconds. + Weight::from_parts(3_128_000, 0) } pub fn expect_transact_status() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_198_000 picoseconds. - Weight::from_parts(3_262_000, 0) + // Minimum execution time: 3_287_000 picoseconds. + Weight::from_parts(3_360_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -256,8 +256,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `17934` - // Minimum execution time: 35_483_000 picoseconds. - Weight::from_parts(36_117_000, 17934) + // Minimum execution time: 35_467_000 picoseconds. + Weight::from_parts(36_011_000, 17934) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -265,8 +265,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 9_136_000 picoseconds. - Weight::from_parts(9_268_000, 0) + // Minimum execution time: 8_630_000 picoseconds. + Weight::from_parts(8_870_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -284,8 +284,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `514` // Estimated: `17934` - // Minimum execution time: 28_042_000 picoseconds. - Weight::from_parts(28_491_000, 17934) + // Minimum execution time: 28_630_000 picoseconds. + Weight::from_parts(29_085_000, 17934) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -293,35 +293,35 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_899_000 picoseconds. - Weight::from_parts(3_043_000, 0) + // Minimum execution time: 2_997_000 picoseconds. + Weight::from_parts(3_096_000, 0) } pub fn set_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_892_000 picoseconds. - Weight::from_parts(2_968_000, 0) + // Minimum execution time: 2_984_000 picoseconds. + Weight::from_parts(3_059_000, 0) } pub fn clear_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_928_000 picoseconds. - Weight::from_parts(3_007_000, 0) + // Minimum execution time: 2_969_000 picoseconds. + Weight::from_parts(3_006_000, 0) } pub fn set_fees_mode() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_047_000 picoseconds. - Weight::from_parts(3_101_000, 0) + // Minimum execution time: 3_045_000 picoseconds. + Weight::from_parts(3_087_000, 0) } pub fn unpaid_execution() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_156_000 picoseconds. - Weight::from_parts(3_233_000, 0) + // Minimum execution time: 3_141_000 picoseconds. + Weight::from_parts(3_251_000, 0) } } diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index ff21dee77cad..5e4855ff522b 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -52,8 +52,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 23_301_000 picoseconds. - Weight::from_parts(23_528_000, 3593) + // Minimum execution time: 23_316_000 picoseconds. + Weight::from_parts(23_706_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -63,8 +63,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 47_042_000 picoseconds. - Weight::from_parts(47_730_000, 6196) + // Minimum execution time: 47_324_000 picoseconds. + Weight::from_parts(47_736_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -86,8 +86,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `686` // Estimated: `25162` - // Minimum execution time: 72_548_000 picoseconds. - Weight::from_parts(73_531_000, 25162) + // Minimum execution time: 73_174_000 picoseconds. + Weight::from_parts(73_839_000, 25162) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -116,8 +116,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `18360` - // Minimum execution time: 32_189_000 picoseconds. - Weight::from_parts(32_477_000, 18360) + // Minimum execution time: 32_027_000 picoseconds. + Weight::from_parts(32_680_000, 18360) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -129,8 +129,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `103` // Estimated: `5094` - // Minimum execution time: 23_792_000 picoseconds. - Weight::from_parts(24_115_000, 5094) + // Minimum execution time: 23_807_000 picoseconds. + Weight::from_parts(24_336_000, 5094) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -140,8 +140,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 24_350_000 picoseconds. - Weight::from_parts(24_732_000, 3593) + // Minimum execution time: 24_740_000 picoseconds. + Weight::from_parts(25_165_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -163,8 +163,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `21953` - // Minimum execution time: 53_928_000 picoseconds. - Weight::from_parts(54_448_000, 21953) + // Minimum execution time: 54_219_000 picoseconds. + Weight::from_parts(54_782_000, 21953) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -188,8 +188,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `23454` - // Minimum execution time: 56_302_000 picoseconds. - Weight::from_parts(56_849_000, 23454) + // Minimum execution time: 56_374_000 picoseconds. + Weight::from_parts(56_780_000, 23454) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(5)) } diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 76b43dbf386c..12fbeb7cef80 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -62,8 +62,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `18360` - // Minimum execution time: 32_716_000 picoseconds. - Weight::from_parts(33_280_000, 18360) + // Minimum execution time: 33_748_000 picoseconds. + Weight::from_parts(34_193_000, 18360) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -71,8 +71,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_930_000 picoseconds. - Weight::from_parts(3_016_000, 0) + // Minimum execution time: 3_057_000 picoseconds. + Weight::from_parts(3_107_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) // Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) @@ -80,58 +80,58 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `3634` - // Minimum execution time: 11_869_000 picoseconds. - Weight::from_parts(12_139_000, 3634) + // Minimum execution time: 12_156_000 picoseconds. + Weight::from_parts(12_618_000, 3634) .saturating_add(T::DbWeight::get().reads(1)) } pub fn transact() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 13_159_000 picoseconds. - Weight::from_parts(13_328_000, 0) + // Minimum execution time: 13_239_000 picoseconds. + Weight::from_parts(13_573_000, 0) } pub fn refund_surplus() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_157_000 picoseconds. - Weight::from_parts(3_268_000, 0) + // Minimum execution time: 3_203_000 picoseconds. + Weight::from_parts(3_316_000, 0) } pub fn set_error_handler() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_885_000 picoseconds. - Weight::from_parts(2_953_000, 0) + // Minimum execution time: 2_968_000 picoseconds. + Weight::from_parts(3_046_000, 0) } pub fn set_appendix() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_884_000 picoseconds. - Weight::from_parts(2_958_000, 0) + // Minimum execution time: 3_003_000 picoseconds. + Weight::from_parts(3_058_000, 0) } pub fn clear_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_816_000 picoseconds. - Weight::from_parts(2_885_000, 0) + // Minimum execution time: 2_918_000 picoseconds. + Weight::from_parts(3_019_000, 0) } pub fn descend_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_709_000 picoseconds. - Weight::from_parts(3_807_000, 0) + // Minimum execution time: 3_861_000 picoseconds. + Weight::from_parts(3_927_000, 0) } pub fn clear_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_776_000 picoseconds. - Weight::from_parts(2_871_000, 0) + // Minimum execution time: 2_883_000 picoseconds. + Weight::from_parts(2_991_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -149,8 +149,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `18360` - // Minimum execution time: 27_390_000 picoseconds. - Weight::from_parts(27_829_000, 18360) + // Minimum execution time: 28_109_000 picoseconds. + Weight::from_parts(28_597_000, 18360) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -160,8 +160,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `226` // Estimated: `3691` - // Minimum execution time: 16_342_000 picoseconds. - Weight::from_parts(16_686_000, 3691) + // Minimum execution time: 16_620_000 picoseconds. + Weight::from_parts(16_871_000, 3691) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -169,8 +169,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_791_000 picoseconds. - Weight::from_parts(2_861_000, 0) + // Minimum execution time: 2_897_000 picoseconds. + Weight::from_parts(2_965_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) @@ -190,8 +190,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `22410` - // Minimum execution time: 34_328_000 picoseconds. - Weight::from_parts(34_584_000, 22410) + // Minimum execution time: 34_380_000 picoseconds. + Weight::from_parts(35_099_000, 22410) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -201,44 +201,44 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_954_000 picoseconds. - Weight::from_parts(5_105_000, 0) + // Minimum execution time: 5_246_000 picoseconds. + Weight::from_parts(5_323_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } pub fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_599_000 picoseconds. - Weight::from_parts(4_668_000, 0) + // Minimum execution time: 4_785_000 picoseconds. + Weight::from_parts(4_858_000, 0) } pub fn expect_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_041_000 picoseconds. - Weight::from_parts(3_141_000, 0) + // Minimum execution time: 3_164_000 picoseconds. + Weight::from_parts(3_233_000, 0) } pub fn expect_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_963_000 picoseconds. - Weight::from_parts(3_048_000, 0) + // Minimum execution time: 3_031_000 picoseconds. + Weight::from_parts(3_124_000, 0) } pub fn expect_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_885_000 picoseconds. - Weight::from_parts(2_949_000, 0) + // Minimum execution time: 2_907_000 picoseconds. + Weight::from_parts(3_031_000, 0) } pub fn expect_transact_status() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_082_000 picoseconds. - Weight::from_parts(3_184_000, 0) + // Minimum execution time: 3_215_000 picoseconds. + Weight::from_parts(3_314_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -256,8 +256,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `18360` - // Minimum execution time: 35_270_000 picoseconds. - Weight::from_parts(35_801_000, 18360) + // Minimum execution time: 35_774_000 picoseconds. + Weight::from_parts(36_411_000, 18360) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -265,8 +265,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 8_929_000 picoseconds. - Weight::from_parts(9_031_000, 0) + // Minimum execution time: 8_751_000 picoseconds. + Weight::from_parts(8_835_000, 0) } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) @@ -284,8 +284,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `585` // Estimated: `18360` - // Minimum execution time: 27_699_000 picoseconds. - Weight::from_parts(28_072_000, 18360) + // Minimum execution time: 28_629_000 picoseconds. + Weight::from_parts(29_188_000, 18360) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -293,35 +293,35 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_872_000 picoseconds. - Weight::from_parts(2_950_000, 0) + // Minimum execution time: 2_947_000 picoseconds. + Weight::from_parts(3_053_000, 0) } pub fn set_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_803_000 picoseconds. - Weight::from_parts(2_936_000, 0) + // Minimum execution time: 2_888_000 picoseconds. + Weight::from_parts(2_971_000, 0) } pub fn clear_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_798_000 picoseconds. - Weight::from_parts(2_907_000, 0) + // Minimum execution time: 2_899_000 picoseconds. + Weight::from_parts(2_999_000, 0) } pub fn set_fees_mode() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_889_000 picoseconds. - Weight::from_parts(2_963_000, 0) + // Minimum execution time: 2_968_000 picoseconds. + Weight::from_parts(3_090_000, 0) } pub fn unpaid_execution() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_051_000 picoseconds. - Weight::from_parts(3_137_000, 0) + // Minimum execution time: 3_087_000 picoseconds. + Weight::from_parts(3_174_000, 0) } } diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index a0c492e2c676..d4e33ab8c453 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -52,8 +52,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 22_331_000 picoseconds. - Weight::from_parts(22_556_000, 3593) + // Minimum execution time: 22_158_000 picoseconds. + Weight::from_parts(22_428_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -63,8 +63,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 46_335_000 picoseconds. - Weight::from_parts(46_863_000, 6196) + // Minimum execution time: 46_062_000 picoseconds. + Weight::from_parts(46_579_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -84,8 +84,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `270` // Estimated: `20911` - // Minimum execution time: 66_497_000 picoseconds. - Weight::from_parts(66_873_000, 20911) + // Minimum execution time: 66_610_000 picoseconds. + Weight::from_parts(67_366_000, 20911) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -112,8 +112,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `14210` - // Minimum execution time: 26_102_000 picoseconds. - Weight::from_parts(26_572_000, 14210) + // Minimum execution time: 27_155_000 picoseconds. + Weight::from_parts(27_545_000, 14210) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -125,8 +125,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `103` // Estimated: `5094` - // Minimum execution time: 22_467_000 picoseconds. - Weight::from_parts(22_678_000, 5094) + // Minimum execution time: 22_079_000 picoseconds. + Weight::from_parts(22_664_000, 5094) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -136,8 +136,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 24_717_000 picoseconds. - Weight::from_parts(25_118_000, 3593) + // Minimum execution time: 24_546_000 picoseconds. + Weight::from_parts(24_959_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -157,8 +157,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `17803` - // Minimum execution time: 47_829_000 picoseconds. - Weight::from_parts(49_168_000, 17803) + // Minimum execution time: 47_788_000 picoseconds. + Weight::from_parts(48_039_000, 17803) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -180,8 +180,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `19304` - // Minimum execution time: 49_272_000 picoseconds. - Weight::from_parts(49_794_000, 19304) + // Minimum execution time: 49_509_000 picoseconds. + Weight::from_parts(50_031_000, 19304) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 4f406f705ea8..3b5d903af243 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -60,8 +60,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `14210` - // Minimum execution time: 28_349_000 picoseconds. - Weight::from_parts(28_616_000, 14210) + // Minimum execution time: 27_886_000 picoseconds. + Weight::from_parts(28_250_000, 14210) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -69,7 +69,7 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_987_000 picoseconds. + // Minimum execution time: 2_921_000 picoseconds. Weight::from_parts(3_055_000, 0) } // Storage: XcmPallet Queries (r:1 w:0) @@ -78,58 +78,58 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `3634` - // Minimum execution time: 11_226_000 picoseconds. - Weight::from_parts(11_490_000, 3634) + // Minimum execution time: 11_072_000 picoseconds. + Weight::from_parts(11_232_000, 3634) .saturating_add(T::DbWeight::get().reads(1)) } pub fn transact() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 13_092_000 picoseconds. - Weight::from_parts(13_352_000, 0) + // Minimum execution time: 12_902_000 picoseconds. + Weight::from_parts(13_253_000, 0) } pub fn refund_surplus() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_120_000 picoseconds. - Weight::from_parts(3_240_000, 0) + // Minimum execution time: 3_077_000 picoseconds. + Weight::from_parts(3_209_000, 0) } pub fn set_error_handler() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_926_000 picoseconds. - Weight::from_parts(3_012_000, 0) + // Minimum execution time: 2_847_000 picoseconds. + Weight::from_parts(2_964_000, 0) } pub fn set_appendix() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_962_000 picoseconds. - Weight::from_parts(3_053_000, 0) + // Minimum execution time: 2_879_000 picoseconds. + Weight::from_parts(2_994_000, 0) } pub fn clear_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_882_000 picoseconds. - Weight::from_parts(2_986_000, 0) + // Minimum execution time: 2_873_000 picoseconds. + Weight::from_parts(2_957_000, 0) } pub fn descend_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_838_000 picoseconds. - Weight::from_parts(3_943_000, 0) + // Minimum execution time: 3_741_000 picoseconds. + Weight::from_parts(3_834_000, 0) } pub fn clear_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_845_000 picoseconds. - Weight::from_parts(2_953_000, 0) + // Minimum execution time: 2_831_000 picoseconds. + Weight::from_parts(2_907_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -145,8 +145,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `14210` - // Minimum execution time: 22_610_000 picoseconds. - Weight::from_parts(22_918_000, 14210) + // Minimum execution time: 22_241_000 picoseconds. + Weight::from_parts(22_594_000, 14210) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -156,8 +156,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `226` // Estimated: `3691` - // Minimum execution time: 15_546_000 picoseconds. - Weight::from_parts(15_948_000, 3691) + // Minimum execution time: 15_246_000 picoseconds. + Weight::from_parts(15_533_000, 3691) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -165,8 +165,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_932_000 picoseconds. - Weight::from_parts(2_994_000, 0) + // Minimum execution time: 2_902_000 picoseconds. + Weight::from_parts(3_008_000, 0) } // Storage: XcmPallet VersionNotifyTargets (r:1 w:1) // Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) @@ -184,8 +184,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `17844` - // Minimum execution time: 29_311_000 picoseconds. - Weight::from_parts(29_794_000, 17844) + // Minimum execution time: 28_753_000 picoseconds. + Weight::from_parts(29_185_000, 17844) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -195,44 +195,44 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 5_081_000 picoseconds. - Weight::from_parts(5_248_000, 0) + // Minimum execution time: 5_249_000 picoseconds. + Weight::from_parts(5_407_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } pub fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_720_000 picoseconds. - Weight::from_parts(4_773_000, 0) + // Minimum execution time: 4_591_000 picoseconds. + Weight::from_parts(4_689_000, 0) } pub fn expect_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_014_000 picoseconds. - Weight::from_parts(3_109_000, 0) + // Minimum execution time: 2_983_000 picoseconds. + Weight::from_parts(3_068_000, 0) } pub fn expect_origin() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_021_000 picoseconds. - Weight::from_parts(3_077_000, 0) + // Minimum execution time: 2_919_000 picoseconds. + Weight::from_parts(3_009_000, 0) } pub fn expect_error() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_903_000 picoseconds. - Weight::from_parts(3_013_000, 0) + // Minimum execution time: 2_839_000 picoseconds. + Weight::from_parts(2_973_000, 0) } pub fn expect_transact_status() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_247_000 picoseconds. - Weight::from_parts(3_424_000, 0) + // Minimum execution time: 3_119_000 picoseconds. + Weight::from_parts(3_204_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -248,8 +248,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `14210` - // Minimum execution time: 28_942_000 picoseconds. - Weight::from_parts(29_573_000, 14210) + // Minimum execution time: 28_560_000 picoseconds. + Weight::from_parts(29_117_000, 14210) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -257,8 +257,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 7_633_000 picoseconds. - Weight::from_parts(7_818_000, 0) + // Minimum execution time: 7_756_000 picoseconds. + Weight::from_parts(7_903_000, 0) } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) @@ -274,8 +274,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `169` // Estimated: `14210` - // Minimum execution time: 22_860_000 picoseconds. - Weight::from_parts(23_241_000, 14210) + // Minimum execution time: 22_771_000 picoseconds. + Weight::from_parts(23_288_000, 14210) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -283,35 +283,35 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_896_000 picoseconds. - Weight::from_parts(3_017_000, 0) + // Minimum execution time: 2_885_000 picoseconds. + Weight::from_parts(2_941_000, 0) } pub fn set_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_864_000 picoseconds. - Weight::from_parts(2_956_000, 0) + // Minimum execution time: 2_811_000 picoseconds. + Weight::from_parts(2_933_000, 0) } pub fn clear_topic() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_893_000 picoseconds. - Weight::from_parts(2_986_000, 0) + // Minimum execution time: 2_814_000 picoseconds. + Weight::from_parts(2_900_000, 0) } pub fn set_fees_mode() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_960_000 picoseconds. - Weight::from_parts(3_058_000, 0) + // Minimum execution time: 2_864_000 picoseconds. + Weight::from_parts(2_987_000, 0) } pub fn unpaid_execution() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_074_000 picoseconds. - Weight::from_parts(3_164_000, 0) + // Minimum execution time: 3_083_000 picoseconds. + Weight::from_parts(3_218_000, 0) } } From 47f82dd1c38c519b74beb1598950916a4bee6391 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 14 Apr 2023 15:36:31 -0300 Subject: [PATCH 13/53] Remove trusted reserves from runtimes --- runtime/kusama/src/lib.rs | 5 +---- runtime/polkadot/src/lib.rs | 5 +---- runtime/rococo/src/lib.rs | 5 +---- runtime/westend/src/lib.rs | 5 +---- xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs | 1 + 5 files changed, 5 insertions(+), 16 deletions(-) diff --git a/runtime/kusama/src/lib.rs b/runtime/kusama/src/lib.rs index 2020127755e2..643c81f09052 100644 --- a/runtime/kusama/src/lib.rs +++ b/runtime/kusama/src/lib.rs @@ -2045,10 +2045,7 @@ sp_api::impl_runtime_apis! { Statemine::get(), MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, )); - pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( - Statemine::get(), - MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, - )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = None; } impl pallet_xcm_benchmarks::fungible::Config for Runtime { diff --git a/runtime/polkadot/src/lib.rs b/runtime/polkadot/src/lib.rs index 326883f5af2b..7b1c27d9aaf0 100644 --- a/runtime/polkadot/src/lib.rs +++ b/runtime/polkadot/src/lib.rs @@ -1996,10 +1996,7 @@ sp_api::impl_runtime_apis! { StatemintLocation::get(), MultiAsset { id: Concrete(TokenLocation::get()), fun: Fungible(1 * UNITS) } )); - pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( - StatemintLocation::get(), - MultiAsset { id: Concrete(TokenLocation::get()), fun: Fungible(1 * UNITS) } - )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = None; } impl pallet_xcm_benchmarks::fungible::Config for Runtime { diff --git a/runtime/rococo/src/lib.rs b/runtime/rococo/src/lib.rs index bc9e974da4ef..cc996295a4e9 100644 --- a/runtime/rococo/src/lib.rs +++ b/runtime/rococo/src/lib.rs @@ -2043,10 +2043,7 @@ sp_api::impl_runtime_apis! { Rockmine::get(), MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, )); - pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( - Rockmine::get(), - MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, - )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = None; } impl pallet_xcm_benchmarks::fungible::Config for Runtime { diff --git a/runtime/westend/src/lib.rs b/runtime/westend/src/lib.rs index 18aaa5d28f93..55b35d21db60 100644 --- a/runtime/westend/src/lib.rs +++ b/runtime/westend/src/lib.rs @@ -1791,10 +1791,7 @@ sp_api::impl_runtime_apis! { Westmint::get(), MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, )); - pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( - Westmint::get(), - MultiAsset { fun: Fungible(1 * UNITS), id: Concrete(TokenLocation::get()) }, - )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = None; } impl pallet_xcm_benchmarks::fungible::Config for Runtime { diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs index 5edafa7b917f..1ee8b1c38f18 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs @@ -142,6 +142,7 @@ benchmarks_instance_pallet! { let xcm = Xcm(vec![instruction]); }: { executor.bench_process(xcm).map_err(|_| { + // In case the runtime being benchmarked does not trust any reserve BenchmarkError::Override( BenchmarkResult::from_weight(T::BlockWeights::get().max_block) ) From 98fab3e9255be18ce58e9ae9176de1c4c92cdccc Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 14 Apr 2023 16:03:26 -0300 Subject: [PATCH 14/53] Fix pallet-xcm-benchmarks mock --- xcm/pallet-xcm-benchmarks/src/fungible/mock.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs b/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs index 382434ea1c28..1aeffd8b4519 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs @@ -188,6 +188,10 @@ parameter_types! { ChildTeleporter::get(), MultiAsset { id: Concrete(Here.into_location()), fun: Fungible(100) }, )); + pub const TrustedReserve: Option<(MultiLocation, MultiAsset)> = Some(( + ChildTeleporter::get(), + MultiAsset { id: Concrete(Here.into_location()), fun: Fungible(100) }, + )); pub const TeleportConcreteFungible: (MultiAssetFilter, MultiLocation) = (Wild(AllOf { fun: WildFungible, id: Concrete(Here.into_location()) }), ChildTeleporter::get()); pub const ReserveConcreteFungible: (MultiAssetFilter, MultiLocation) = @@ -198,6 +202,7 @@ impl xcm_balances_benchmark::Config for Test { type TransactAsset = Balances; type CheckedAccount = CheckingAccount; type TrustedTeleporter = TrustedTeleporter; + type TrustedReserve = TrustedReserve; fn get_multi_asset() -> MultiAsset { let amount = From 8e9a998b78ec57b87bd72679313e22ce8a1cdf82 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 14 Apr 2023 16:52:28 -0300 Subject: [PATCH 15/53] Fix test --- runtime/kusama/src/xcm_config.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index 289ea118d7bc..258948649c79 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -425,5 +425,5 @@ fn karura_liquid_staking_xcm_has_sane_weight_upper_limt() { let weight = ::Weigher::weight(&mut xcm) .expect("weighing XCM failed"); - assert_eq!(weight, Weight::from_parts(20_313_281_000, 65536)); + assert_eq!(weight, Weight::from_parts(20_317_677_000, 72_722)); } From 5a01b3433d34383c67237352aac0d92a91665a31 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 14 Apr 2023 17:34:01 -0300 Subject: [PATCH 16/53] Change pallet xcm weigher in kusama --- runtime/kusama/src/xcm_config.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index 258948649c79..8f593111878b 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -395,7 +395,11 @@ impl pallet_xcm::Config for Runtime { // Anyone is able to use reserve transfers regardless of who they are and what they want to // transfer. type XcmReserveTransferFilter = Everything; - type Weigher = FixedWeightBounds; + type Weigher = WeightInfoBounds< + crate::weights::xcm::KusamaXcmWeight, + RuntimeCall, + MaxInstructions, + >; type UniversalLocation = UniversalLocation; type RuntimeOrigin = RuntimeOrigin; type RuntimeCall = RuntimeCall; From 3d31f4c1e0acf8c57c816bdcc42fe81718e8be44 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 14 Apr 2023 17:47:37 -0300 Subject: [PATCH 17/53] Fix --- runtime/kusama/src/xcm_config.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index 8f593111878b..721a5bc1f310 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -33,8 +33,8 @@ use xcm_builder::{ AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowKnownQueryResponses, AllowSubscriptionsFrom, AllowTopLevelPaidExecutionFrom, ChildParachainAsNative, ChildParachainConvertsVia, ChildSystemParachainAsSuperuser, - CurrencyAdapter as XcmCurrencyAdapter, FixedWeightBounds, IsChildSystemParachain, IsConcrete, - MintLocation, OriginToPluralityVoice, SignedAccountId32AsNative, SignedToAccountId32, + CurrencyAdapter as XcmCurrencyAdapter, IsChildSystemParachain, IsConcrete, MintLocation, + OriginToPluralityVoice, SignedAccountId32AsNative, SignedToAccountId32, SovereignSignedViaLocation, TakeWeightCredit, UsingComponents, WeightInfoBounds, WithComputedOrigin, }; From 58241bad22c21d6d8127c772c72787173ac506d4 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 7 Jun 2023 13:43:50 -0300 Subject: [PATCH 18/53] Remove merge conflict artifact --- runtime/polkadot/src/weights/mod.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/runtime/polkadot/src/weights/mod.rs b/runtime/polkadot/src/weights/mod.rs index 9cb6976a04ec..596b594c9370 100644 --- a/runtime/polkadot/src/weights/mod.rs +++ b/runtime/polkadot/src/weights/mod.rs @@ -61,5 +61,4 @@ pub mod runtime_parachains_inclusion; pub mod runtime_parachains_initializer; pub mod runtime_parachains_paras; pub mod runtime_parachains_paras_inherent; -pub mod runtime_parachains_ump; pub mod xcm; From 8271b99e0e0203130551b4b30620678c752a3888 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 7 Jun 2023 15:51:26 -0300 Subject: [PATCH 19/53] Remove initiate_reserve_withdraw from generic benchmarks --- .../xcm/pallet_xcm_benchmarks_generic.rs | 23 ----------------- .../xcm/pallet_xcm_benchmarks_generic.rs | 25 ------------------- .../xcm/pallet_xcm_benchmarks_generic.rs | 23 ----------------- 3 files changed, 71 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 390278157b96..fb0ca3c19f42 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -215,29 +215,6 @@ impl WeightInfo { Weight::from_parts(5_155_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn initiate_reserve_withdraw() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 30_858_000 picoseconds. - Weight::from_parts(31_858_000, 3676) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } pub(crate) fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 1fad2541f9d8..df2f9b2d0e8d 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -221,31 +221,6 @@ impl WeightInfo { Weight::from_parts(5_128_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Configuration ActiveConfig (r:1 w:0) - /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn initiate_reserve_withdraw() -> Weight { - // Proof Size summary in bytes: - // Measured: `565` - // Estimated: `4030` - // Minimum execution time: 35_068_000 picoseconds. - Weight::from_parts(36_124_000, 4030) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(4)) - } pub(crate) fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs index 40f1ccb2ddc8..49beb85c2784 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_generic.rs @@ -214,29 +214,6 @@ impl WeightInfo { Weight::from_parts(5_132_000, 0) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub(crate) fn initiate_reserve_withdraw() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 29_375_000 picoseconds. - Weight::from_parts(30_320_000, 3634) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } pub(crate) fn burn_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` From 6af0b3bd54eeb3a9bfcf00dbd52e0ea95ba38796 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 7 Jun 2023 16:21:34 -0300 Subject: [PATCH 20/53] Add missing implementation to XCM benchmark --- runtime/polkadot/src/lib.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/runtime/polkadot/src/lib.rs b/runtime/polkadot/src/lib.rs index 9b30bee43112..3ddb71a0313e 100644 --- a/runtime/polkadot/src/lib.rs +++ b/runtime/polkadot/src/lib.rs @@ -2190,6 +2190,11 @@ sp_api::impl_runtime_apis! { // Polkadot doesn't support exporting messages Err(BenchmarkError::Skip) } + + fn alias_origin() -> Result<(MultiLocation, MultiLocation), BenchmarkError> { + // The XCM executor of Polkadot doesn't have a configured `Aliasers` + Err(BenchmarkError::Skip) + } } let whitelist: Vec = vec![ From c705e150c560c1f3f0eb5333b002db028c3604ef Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 7 Jun 2023 17:50:38 -0300 Subject: [PATCH 21/53] Fix failing karura test --- runtime/kusama/src/xcm_config.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index 9cd350c7c77a..0afe997921c5 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -451,9 +451,11 @@ fn karura_liquid_staking_xcm_has_sane_weight_upper_limt() { let weight = ::Weigher::weight(&mut xcm) .expect("weighing XCM failed"); + dbg!(&weight); + // Test that the weigher gives us a sensible weight but don't exactly hard-code it, otherwise it // will be out of date after each re-run. - assert!(weight.all_lte(Weight::from_parts(30_313_281_000, 65536))); + assert!(weight.all_lte(Weight::from_parts(30_313_281_000, 72_722))); let Some(Transact { require_weight_at_most, call, .. }) = xcm.inner_mut().into_iter().find(|inst| matches!(inst, Transact { .. })) else { From 6a81593afaa4cf1c1b9b9adadbada382f9a9b8b9 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 14 Jun 2023 04:51:17 -0300 Subject: [PATCH 22/53] Remove dbg! Co-authored-by: Keith Yeung --- runtime/kusama/src/xcm_config.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index 0afe997921c5..0d7cda7c39d6 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -451,7 +451,6 @@ fn karura_liquid_staking_xcm_has_sane_weight_upper_limt() { let weight = ::Weigher::weight(&mut xcm) .expect("weighing XCM failed"); - dbg!(&weight); // Test that the weigher gives us a sensible weight but don't exactly hard-code it, otherwise it // will be out of date after each re-run. From 676f2d8db07d7427750c79f95494d4988d06fda5 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 14 Jun 2023 05:33:23 -0300 Subject: [PATCH 23/53] Fix fmt --- .../dispute-coordinator/src/initialized.rs | 101 +++++++++--------- runtime/kusama/src/xcm_config.rs | 1 - 2 files changed, 51 insertions(+), 51 deletions(-) diff --git a/node/core/dispute-coordinator/src/initialized.rs b/node/core/dispute-coordinator/src/initialized.rs index 25bbcde6ee7f..4498b522d079 100644 --- a/node/core/dispute-coordinator/src/initialized.rs +++ b/node/core/dispute-coordinator/src/initialized.rs @@ -217,61 +217,62 @@ impl Initialized { gum::trace!(target: LOG_TARGET, "Waiting for message"); let mut overlay_db = OverlayedBackend::new(backend); let default_confirm = Box::new(|| Ok(())); - let confirm_write = - match MuxedMessage::receive(ctx, &mut self.participation_receiver).await? { - MuxedMessage::Participation(msg) => { - gum::trace!(target: LOG_TARGET, "MuxedMessage::Participation"); - let ParticipationStatement { - session, + let confirm_write = match MuxedMessage::receive(ctx, &mut self.participation_receiver) + .await? + { + MuxedMessage::Participation(msg) => { + gum::trace!(target: LOG_TARGET, "MuxedMessage::Participation"); + let ParticipationStatement { + session, + candidate_hash, + candidate_receipt, + outcome, + } = self.participation.get_participation_result(ctx, msg).await?; + if let Some(valid) = outcome.validity() { + gum::trace!( + target: LOG_TARGET, + ?session, + ?candidate_hash, + ?valid, + "Issuing local statement based on participation outcome." + ); + self.issue_local_statement( + ctx, + &mut overlay_db, candidate_hash, candidate_receipt, - outcome, - } = self.participation.get_participation_result(ctx, msg).await?; - if let Some(valid) = outcome.validity() { - gum::trace!( - target: LOG_TARGET, - ?session, - ?candidate_hash, - ?valid, - "Issuing local statement based on participation outcome." - ); - self.issue_local_statement( - ctx, - &mut overlay_db, - candidate_hash, - candidate_receipt, - session, - valid, - clock.now(), - ) - .await?; - } else { - gum::warn!(target: LOG_TARGET, ?outcome, "Dispute participation failed"); - } + session, + valid, + clock.now(), + ) + .await?; + } else { + gum::warn!(target: LOG_TARGET, ?outcome, "Dispute participation failed"); + } + default_confirm + }, + MuxedMessage::Subsystem(msg) => match msg { + FromOrchestra::Signal(OverseerSignal::Conclude) => return Ok(()), + FromOrchestra::Signal(OverseerSignal::ActiveLeaves(update)) => { + gum::trace!(target: LOG_TARGET, "OverseerSignal::ActiveLeaves"); + self.process_active_leaves_update( + ctx, + &mut overlay_db, + update, + clock.now(), + ) + .await?; default_confirm }, - MuxedMessage::Subsystem(msg) => match msg { - FromOrchestra::Signal(OverseerSignal::Conclude) => return Ok(()), - FromOrchestra::Signal(OverseerSignal::ActiveLeaves(update)) => { - gum::trace!(target: LOG_TARGET, "OverseerSignal::ActiveLeaves"); - self.process_active_leaves_update( - ctx, - &mut overlay_db, - update, - clock.now(), - ) - .await?; - default_confirm - }, - FromOrchestra::Signal(OverseerSignal::BlockFinalized(_, n)) => { - gum::trace!(target: LOG_TARGET, "OverseerSignal::BlockFinalized"); - self.scraper.process_finalized_block(&n); - default_confirm - }, - FromOrchestra::Communication { msg } => - self.handle_incoming(ctx, &mut overlay_db, msg, clock.now()).await?, + FromOrchestra::Signal(OverseerSignal::BlockFinalized(_, n)) => { + gum::trace!(target: LOG_TARGET, "OverseerSignal::BlockFinalized"); + self.scraper.process_finalized_block(&n); + default_confirm }, - }; + FromOrchestra::Communication { msg } => + self.handle_incoming(ctx, &mut overlay_db, msg, clock.now()).await?, + }, + }; if !overlay_db.is_empty() { let ops = overlay_db.into_write_ops(); diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index 0d7cda7c39d6..eaaea1576d04 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -451,7 +451,6 @@ fn karura_liquid_staking_xcm_has_sane_weight_upper_limt() { let weight = ::Weigher::weight(&mut xcm) .expect("weighing XCM failed"); - // Test that the weigher gives us a sensible weight but don't exactly hard-code it, otherwise it // will be out of date after each re-run. assert!(weight.all_lte(Weight::from_parts(30_313_281_000, 72_722))); From 1126ffea844a9797235310bbe2f9594a1e5c3514 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 14 Jun 2023 05:40:44 -0300 Subject: [PATCH 24/53] Revert "Fix fmt" This reverts commit 676f2d8db07d7427750c79f95494d4988d06fda5. --- .../dispute-coordinator/src/initialized.rs | 101 +++++++++--------- runtime/kusama/src/xcm_config.rs | 1 + 2 files changed, 51 insertions(+), 51 deletions(-) diff --git a/node/core/dispute-coordinator/src/initialized.rs b/node/core/dispute-coordinator/src/initialized.rs index 4498b522d079..25bbcde6ee7f 100644 --- a/node/core/dispute-coordinator/src/initialized.rs +++ b/node/core/dispute-coordinator/src/initialized.rs @@ -217,62 +217,61 @@ impl Initialized { gum::trace!(target: LOG_TARGET, "Waiting for message"); let mut overlay_db = OverlayedBackend::new(backend); let default_confirm = Box::new(|| Ok(())); - let confirm_write = match MuxedMessage::receive(ctx, &mut self.participation_receiver) - .await? - { - MuxedMessage::Participation(msg) => { - gum::trace!(target: LOG_TARGET, "MuxedMessage::Participation"); - let ParticipationStatement { - session, - candidate_hash, - candidate_receipt, - outcome, - } = self.participation.get_participation_result(ctx, msg).await?; - if let Some(valid) = outcome.validity() { - gum::trace!( - target: LOG_TARGET, - ?session, - ?candidate_hash, - ?valid, - "Issuing local statement based on participation outcome." - ); - self.issue_local_statement( - ctx, - &mut overlay_db, + let confirm_write = + match MuxedMessage::receive(ctx, &mut self.participation_receiver).await? { + MuxedMessage::Participation(msg) => { + gum::trace!(target: LOG_TARGET, "MuxedMessage::Participation"); + let ParticipationStatement { + session, candidate_hash, candidate_receipt, - session, - valid, - clock.now(), - ) - .await?; - } else { - gum::warn!(target: LOG_TARGET, ?outcome, "Dispute participation failed"); - } - default_confirm - }, - MuxedMessage::Subsystem(msg) => match msg { - FromOrchestra::Signal(OverseerSignal::Conclude) => return Ok(()), - FromOrchestra::Signal(OverseerSignal::ActiveLeaves(update)) => { - gum::trace!(target: LOG_TARGET, "OverseerSignal::ActiveLeaves"); - self.process_active_leaves_update( - ctx, - &mut overlay_db, - update, - clock.now(), - ) - .await?; + outcome, + } = self.participation.get_participation_result(ctx, msg).await?; + if let Some(valid) = outcome.validity() { + gum::trace!( + target: LOG_TARGET, + ?session, + ?candidate_hash, + ?valid, + "Issuing local statement based on participation outcome." + ); + self.issue_local_statement( + ctx, + &mut overlay_db, + candidate_hash, + candidate_receipt, + session, + valid, + clock.now(), + ) + .await?; + } else { + gum::warn!(target: LOG_TARGET, ?outcome, "Dispute participation failed"); + } default_confirm }, - FromOrchestra::Signal(OverseerSignal::BlockFinalized(_, n)) => { - gum::trace!(target: LOG_TARGET, "OverseerSignal::BlockFinalized"); - self.scraper.process_finalized_block(&n); - default_confirm + MuxedMessage::Subsystem(msg) => match msg { + FromOrchestra::Signal(OverseerSignal::Conclude) => return Ok(()), + FromOrchestra::Signal(OverseerSignal::ActiveLeaves(update)) => { + gum::trace!(target: LOG_TARGET, "OverseerSignal::ActiveLeaves"); + self.process_active_leaves_update( + ctx, + &mut overlay_db, + update, + clock.now(), + ) + .await?; + default_confirm + }, + FromOrchestra::Signal(OverseerSignal::BlockFinalized(_, n)) => { + gum::trace!(target: LOG_TARGET, "OverseerSignal::BlockFinalized"); + self.scraper.process_finalized_block(&n); + default_confirm + }, + FromOrchestra::Communication { msg } => + self.handle_incoming(ctx, &mut overlay_db, msg, clock.now()).await?, }, - FromOrchestra::Communication { msg } => - self.handle_incoming(ctx, &mut overlay_db, msg, clock.now()).await?, - }, - }; + }; if !overlay_db.is_empty() { let ops = overlay_db.into_write_ops(); diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index eaaea1576d04..0d7cda7c39d6 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -451,6 +451,7 @@ fn karura_liquid_staking_xcm_has_sane_weight_upper_limt() { let weight = ::Weigher::weight(&mut xcm) .expect("weighing XCM failed"); + // Test that the weigher gives us a sensible weight but don't exactly hard-code it, otherwise it // will be out of date after each re-run. assert!(weight.all_lte(Weight::from_parts(30_313_281_000, 72_722))); From 1981d5ae01dfee366edec783343792ec01a80d67 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 14 Jun 2023 05:41:15 -0300 Subject: [PATCH 25/53] Fix fmt --- runtime/kusama/src/xcm_config.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/runtime/kusama/src/xcm_config.rs b/runtime/kusama/src/xcm_config.rs index 0d7cda7c39d6..eaaea1576d04 100644 --- a/runtime/kusama/src/xcm_config.rs +++ b/runtime/kusama/src/xcm_config.rs @@ -451,7 +451,6 @@ fn karura_liquid_staking_xcm_has_sane_weight_upper_limt() { let weight = ::Weigher::weight(&mut xcm) .expect("weighing XCM failed"); - // Test that the weigher gives us a sensible weight but don't exactly hard-code it, otherwise it // will be out of date after each re-run. assert!(weight.all_lte(Weight::from_parts(30_313_281_000, 72_722))); From 3e615def8f926994725a1e6f1e80e7f8d78e4ac8 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Mon, 19 Jun 2023 21:13:08 -0300 Subject: [PATCH 26/53] Remove duplicated template code --- xcm/pallet-xcm-benchmarks/template.hbs | 3 --- 1 file changed, 3 deletions(-) diff --git a/xcm/pallet-xcm-benchmarks/template.hbs b/xcm/pallet-xcm-benchmarks/template.hbs index a52e5e98b534..82115cd44ff3 100644 --- a/xcm/pallet-xcm-benchmarks/template.hbs +++ b/xcm/pallet-xcm-benchmarks/template.hbs @@ -30,9 +30,6 @@ impl WeightInfo { {{#each benchmark.component_ranges as |range|}} /// The range of component `{{range.name}}` is `[{{range.min}}, {{range.max}}]`. {{/each}} - {{#each benchmark.component_ranges as |range|}} - /// The range of component `{{range.name}}` is `[{{range.min}}, {{range.max}}]`. - {{/each}} pub fn {{benchmark.name~}} ( {{~#each benchmark.components as |c| ~}} From 625ecd91379a8d2d4eac5f753d2f7479d321ea53 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Mon, 19 Jun 2023 21:50:41 -0300 Subject: [PATCH 27/53] Add back part of the template --- xcm/pallet-xcm-benchmarks/template.hbs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xcm/pallet-xcm-benchmarks/template.hbs b/xcm/pallet-xcm-benchmarks/template.hbs index 82115cd44ff3..a0ba5173258f 100644 --- a/xcm/pallet-xcm-benchmarks/template.hbs +++ b/xcm/pallet-xcm-benchmarks/template.hbs @@ -30,7 +30,7 @@ impl WeightInfo { {{#each benchmark.component_ranges as |range|}} /// The range of component `{{range.name}}` is `[{{range.min}}, {{range.max}}]`. {{/each}} - pub fn {{benchmark.name~}} + pub(crate) fn {{benchmark.name~}} ( {{~#each benchmark.components as |c| ~}} {{~#if (not c.is_used)}}_{{/if}}{{c.name}}: u32, {{/each~}} From d6118704f43aedb548307b619b72fe416cd865ba Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Tue, 20 Jun 2023 01:44:00 +0000 Subject: [PATCH 28/53] ".git/.scripts/commands/bench-vm/bench-vm.sh" xcm polkadot pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 235 +++++++++--------- 1 file changed, 119 insertions(+), 116 deletions(-) diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 25ec6735234d..0c14dd09261c 100644 --- a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,11 +17,13 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-06-20, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `runner-e8ezs4ez-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,6 +32,7 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --json-file=/builds/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::fungible // --chain=polkadot-dev // --header=./file_header.txt @@ -39,158 +42,158 @@ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] #![allow(unused_imports)] +#![allow(missing_docs)] use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; +use core::marker::PhantomData; -/// Weights for `pallet_xcm_benchmarks::fungible`. +/// Weight functions for `pallet_xcm_benchmarks::fungible`. pub struct WeightInfo(PhantomData); impl WeightInfo { - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn withdraw_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn withdraw_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 22_432_000 picoseconds. - Weight::from_parts(22_938_000, 3593) + // Minimum execution time: 25_544_000 picoseconds. + Weight::from_parts(25_969_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn transfer_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn transfer_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 46_441_000 picoseconds. - Weight::from_parts(46_975_000, 6196) + // Minimum execution time: 54_838_000 picoseconds. + Weight::from_parts(56_132_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn transfer_reserve_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `615` - // Estimated: `24736` - // Minimum execution time: 71_708_000 picoseconds. - Weight::from_parts(72_580_000, 24736) - .saturating_add(T::DbWeight::get().reads(8)) + // Measured: `628` + // Estimated: `6196` + // Minimum execution time: 81_160_000 picoseconds. + Weight::from_parts(82_916_000, 6196) + .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(5)) } - // Storage: Benchmark Override (r:0 w:0) - // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) - pub fn reserve_asset_deposited() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_000_000_000_000 picoseconds. - Weight::from_parts(2_000_000_000_000, 0) - } - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_reserve_withdraw() -> Weight { + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_reserve_withdraw() -> Weight { // Proof Size summary in bytes: - // Measured: `514` - // Estimated: `17934` - // Minimum execution time: 31_541_000 picoseconds. - Weight::from_parts(32_014_000, 17934) - .saturating_add(T::DbWeight::get().reads(6)) + // Measured: `527` + // Estimated: `3992` + // Minimum execution time: 33_186_000 picoseconds. + Weight::from_parts(33_976_000, 3992) + .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(3)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - pub fn receive_teleported_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` - // Estimated: `5094` - // Minimum execution time: 23_314_000 picoseconds. - Weight::from_parts(23_774_000, 5094) + // Estimated: `3593` + // Minimum execution time: 24_769_000 picoseconds. + Weight::from_parts(25_466_000, 3593) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn deposit_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn deposit_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 24_430_000 picoseconds. - Weight::from_parts(24_840_000, 3593) + // Minimum execution time: 26_378_000 picoseconds. + Weight::from_parts(26_753_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn deposit_reserve_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `514` - // Estimated: `21527` - // Minimum execution time: 53_534_000 picoseconds. - Weight::from_parts(53_924_000, 21527) - .saturating_add(T::DbWeight::get().reads(7)) + // Measured: `527` + // Estimated: `3992` + // Minimum execution time: 57_284_000 picoseconds. + Weight::from_parts(58_807_000, 3992) + .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(4)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_teleport() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: - // Measured: `514` - // Estimated: `23028` - // Minimum execution time: 55_441_000 picoseconds. - Weight::from_parts(55_988_000, 23028) - .saturating_add(T::DbWeight::get().reads(8)) + // Measured: `527` + // Estimated: `3992` + // Minimum execution time: 58_928_000 picoseconds. + Weight::from_parts(60_162_000, 3992) + .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(5)) } } From ed9744c9eeaf9083e34c52413584bf6aa7345117 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 23 Jun 2023 08:23:51 -0300 Subject: [PATCH 29/53] Don't skip reserve asset deposited benchmark --- xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs index 86167fbab00f..6515aadd4654 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs @@ -132,8 +132,9 @@ benchmarks_instance_pallet! { } reserve_asset_deposited { + // If the runtime being benchmarked does not trust any reserve, we default to max weight let (trusted_reserve, transferable_reserve_asset) = T::TrustedReserve::get() - .ok_or(BenchmarkError::Skip)?; + .ok_or(BenchmarkError::Override(BenchmarkResult::from_weight(Weight::MAX)))?; let assets: MultiAssets = vec![ transferable_reserve_asset ].into(); @@ -141,12 +142,7 @@ benchmarks_instance_pallet! { let instruction = Instruction::ReserveAssetDeposited(assets.clone()); let xcm = Xcm(vec![instruction]); }: { - executor.bench_process(xcm).map_err(|_| { - // In case the runtime being benchmarked does not trust any reserve - BenchmarkError::Override( - BenchmarkResult::from_weight(T::BlockWeights::get().max_block) - ) - })?; + executor.bench_process(xcm)?; } verify { assert!(executor.holding().ensure_contains(&assets).is_ok()); } From 89a350fc67eabadec38b7667c1efee49280b226d Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 23 Jun 2023 08:49:34 -0300 Subject: [PATCH 30/53] Remove call to non-generated benchmark yet --- runtime/polkadot/src/weights/xcm/mod.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/runtime/polkadot/src/weights/xcm/mod.rs b/runtime/polkadot/src/weights/xcm/mod.rs index 98c12fa7dba3..f77812b08f75 100644 --- a/runtime/polkadot/src/weights/xcm/mod.rs +++ b/runtime/polkadot/src/weights/xcm/mod.rs @@ -91,7 +91,8 @@ impl XcmWeightInfo for PolkadotXcmWeight assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { - assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) From 8ef3669183c75350eab8c9ed82e8869ab1734a13 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 23 Jun 2023 09:30:56 -0300 Subject: [PATCH 31/53] Underscore unused parameter --- runtime/polkadot/src/weights/xcm/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/polkadot/src/weights/xcm/mod.rs b/runtime/polkadot/src/weights/xcm/mod.rs index f77812b08f75..6d96d3e82352 100644 --- a/runtime/polkadot/src/weights/xcm/mod.rs +++ b/runtime/polkadot/src/weights/xcm/mod.rs @@ -90,7 +90,7 @@ impl XcmWeightInfo for PolkadotXcmWeight fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { + fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) Weight::MAX } From 9351a3e097cdc49ff963077114b74e103953a93d Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 23 Jun 2023 10:25:01 -0300 Subject: [PATCH 32/53] Skip not supported benchmarks and hardcode value --- runtime/kusama/src/weights/xcm/mod.rs | 5 +++-- .../src/weights/xcm/pallet_xcm_benchmarks_fungible.rs | 9 --------- runtime/polkadot/src/weights/xcm/mod.rs | 4 ++-- runtime/rococo/src/weights/xcm/mod.rs | 5 +++-- .../src/weights/xcm/pallet_xcm_benchmarks_fungible.rs | 9 --------- runtime/westend/src/weights/xcm/mod.rs | 5 +++-- .../src/weights/xcm/pallet_xcm_benchmarks_fungible.rs | 9 --------- xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs | 4 ++-- 8 files changed, 13 insertions(+), 37 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/mod.rs b/runtime/kusama/src/weights/xcm/mod.rs index ec73d891ec59..24a93ac30116 100644 --- a/runtime/kusama/src/weights/xcm/mod.rs +++ b/runtime/kusama/src/weights/xcm/mod.rs @@ -90,8 +90,9 @@ impl XcmWeightInfo for KusamaXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { - assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + // Kusama doesn't support ReserveAssetDeposited + Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 1bb7980ac146..1f6473ac5f57 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -89,15 +89,6 @@ impl WeightInfo { .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } - // Storage: Benchmark Override (r:0 w:0) - // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) - pub fn reserve_asset_deposited() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_000_000_000_000 picoseconds. - Weight::from_parts(2_000_000_000_000, 0) - } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) diff --git a/runtime/polkadot/src/weights/xcm/mod.rs b/runtime/polkadot/src/weights/xcm/mod.rs index 6d96d3e82352..791efbd153e8 100644 --- a/runtime/polkadot/src/weights/xcm/mod.rs +++ b/runtime/polkadot/src/weights/xcm/mod.rs @@ -90,8 +90,8 @@ impl XcmWeightInfo for PolkadotXcmWeight fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { - // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + // Polkadot doesn't support ReserveAssetDeposited Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { diff --git a/runtime/rococo/src/weights/xcm/mod.rs b/runtime/rococo/src/weights/xcm/mod.rs index cc485dfbaf7e..4607480eef7f 100644 --- a/runtime/rococo/src/weights/xcm/mod.rs +++ b/runtime/rococo/src/weights/xcm/mod.rs @@ -90,8 +90,9 @@ impl XcmWeightInfo for RococoXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { - assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + // Rococo doesn't support ReserveAssetDeposited + Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 5e4855ff522b..f89d687f212a 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -91,15 +91,6 @@ impl WeightInfo { .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(5)) } - // Storage: Benchmark Override (r:0 w:0) - // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) - pub fn reserve_asset_deposited() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_000_000_000_000 picoseconds. - Weight::from_parts(2_000_000_000_000, 0) - } // Storage: Configuration ActiveConfig (r:1 w:0) // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) // Storage: XcmPallet SupportedVersion (r:1 w:0) diff --git a/runtime/westend/src/weights/xcm/mod.rs b/runtime/westend/src/weights/xcm/mod.rs index d5b3d8257ba5..1bb27af37683 100644 --- a/runtime/westend/src/weights/xcm/mod.rs +++ b/runtime/westend/src/weights/xcm/mod.rs @@ -93,8 +93,9 @@ impl XcmWeightInfo for WestendXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { - assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + // Westend doesn't support ReserveAssetDeposited + Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index d4e33ab8c453..9fd39692f2a2 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -89,15 +89,6 @@ impl WeightInfo { .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } - // Storage: Benchmark Override (r:0 w:0) - // Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) - pub fn reserve_asset_deposited() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_000_000_000_000 picoseconds. - Weight::from_parts(2_000_000_000_000, 0) - } // Storage: XcmPallet SupportedVersion (r:1 w:0) // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs index 6515aadd4654..f4c40292642d 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs @@ -132,9 +132,9 @@ benchmarks_instance_pallet! { } reserve_asset_deposited { - // If the runtime being benchmarked does not trust any reserve, we default to max weight + // If the runtime being benchmarked does not trust any reserve, we skip let (trusted_reserve, transferable_reserve_asset) = T::TrustedReserve::get() - .ok_or(BenchmarkError::Override(BenchmarkResult::from_weight(Weight::MAX)))?; + .ok_or(BenchmarkError::Skip)?; let assets: MultiAssets = vec![ transferable_reserve_asset ].into(); From 4a032f19bdc260e78a86c1b021f3367cff6fba9b Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 23 Jun 2023 11:03:25 -0300 Subject: [PATCH 33/53] Remove ReserveAssetDeposited benchmark --- .../src/fungible/benchmarking.rs | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs index f4c40292642d..7e93d0b012e4 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs @@ -131,22 +131,6 @@ benchmarks_instance_pallet! { // TODO: Check sender queue is not empty. #4426 } - reserve_asset_deposited { - // If the runtime being benchmarked does not trust any reserve, we skip - let (trusted_reserve, transferable_reserve_asset) = T::TrustedReserve::get() - .ok_or(BenchmarkError::Skip)?; - - let assets: MultiAssets = vec![ transferable_reserve_asset ].into(); - - let mut executor = new_executor::(trusted_reserve); - let instruction = Instruction::ReserveAssetDeposited(assets.clone()); - let xcm = Xcm(vec![instruction]); - }: { - executor.bench_process(xcm)?; - } verify { - assert!(executor.holding().ensure_contains(&assets).is_ok()); - } - initiate_reserve_withdraw { let holding = T::worst_case_holding(1); let assets_filter = MultiAssetFilter::Definite(holding.clone()); From a34c96ae27f5df62fa2a7d05734012a9fa222d0a Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Fri, 23 Jun 2023 14:59:56 +0000 Subject: [PATCH 34/53] ".git/.scripts/commands/bench-vm/bench-vm.sh" xcm polkadot pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 36 +++++++++---------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 0c14dd09261c..d879d0f0c5eb 100644 --- a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,9 +17,9 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-20, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-06-23, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner-e8ezs4ez-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` +//! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 // Executed Command: @@ -56,8 +56,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 25_544_000 picoseconds. - Weight::from_parts(25_969_000, 3593) + // Minimum execution time: 26_045_000 picoseconds. + Weight::from_parts(26_409_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -67,8 +67,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 54_838_000 picoseconds. - Weight::from_parts(56_132_000, 6196) + // Minimum execution time: 54_741_000 picoseconds. + Weight::from_parts(55_293_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -92,8 +92,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `628` // Estimated: `6196` - // Minimum execution time: 81_160_000 picoseconds. - Weight::from_parts(82_916_000, 6196) + // Minimum execution time: 80_483_000 picoseconds. + Weight::from_parts(81_949_000, 6196) .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -115,8 +115,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `527` // Estimated: `3992` - // Minimum execution time: 33_186_000 picoseconds. - Weight::from_parts(33_976_000, 3992) + // Minimum execution time: 33_645_000 picoseconds. + Weight::from_parts(33_977_000, 3992) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -128,8 +128,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `103` // Estimated: `3593` - // Minimum execution time: 24_769_000 picoseconds. - Weight::from_parts(25_466_000, 3593) + // Minimum execution time: 24_729_000 picoseconds. + Weight::from_parts(25_418_000, 3593) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -139,8 +139,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 26_378_000 picoseconds. - Weight::from_parts(26_753_000, 3593) + // Minimum execution time: 26_234_000 picoseconds. + Weight::from_parts(26_841_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -164,8 +164,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `527` // Estimated: `3992` - // Minimum execution time: 57_284_000 picoseconds. - Weight::from_parts(58_807_000, 3992) + // Minimum execution time: 56_476_000 picoseconds. + Weight::from_parts(57_589_000, 3992) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -191,8 +191,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `527` // Estimated: `3992` - // Minimum execution time: 58_928_000 picoseconds. - Weight::from_parts(60_162_000, 3992) + // Minimum execution time: 58_277_000 picoseconds. + Weight::from_parts(60_107_000, 3992) .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(5)) } From d3ef591d0d1f01da8c2117a30c6164d2ef87f73f Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 23 Jun 2023 14:04:59 -0300 Subject: [PATCH 35/53] Add back ReserveAssetDeposited --- .../weights/pallet_xcm_benchmarks_fungible.rs | 183 -------- .../weights/pallet_xcm_benchmarks_generic.rs | 393 ------------------ .../weights/pallet_xcm_benchmarks_fungible.rs | 183 -------- .../weights/pallet_xcm_benchmarks_generic.rs | 393 ------------------ .../src/fungible/benchmarking.rs | 17 + 5 files changed, 17 insertions(+), 1152 deletions(-) delete mode 100644 runtime/kusama/src/weights/pallet_xcm_benchmarks_fungible.rs delete mode 100644 runtime/kusama/src/weights/pallet_xcm_benchmarks_generic.rs delete mode 100644 runtime/westend/src/weights/pallet_xcm_benchmarks_fungible.rs delete mode 100644 runtime/westend/src/weights/pallet_xcm_benchmarks_generic.rs diff --git a/runtime/kusama/src/weights/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/pallet_xcm_benchmarks_fungible.rs deleted file mode 100644 index 5cc9b7e68577..000000000000 --- a/runtime/kusama/src/weights/pallet_xcm_benchmarks_fungible.rs +++ /dev/null @@ -1,183 +0,0 @@ -// Copyright (C) Parity Technologies (UK) Ltd. -// This file is part of Polkadot. - -// Polkadot is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Polkadot is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Polkadot. If not, see . - -//! Autogenerated weights for `pallet_xcm_benchmarks::fungible` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-19, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner-e8ezs4ez-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/production/polkadot -// benchmark -// pallet -// --chain=kusama-dev -// --steps=50 -// --repeat=20 -// --no-storage-info -// --no-median-slopes -// --no-min-squares -// --pallet=pallet_xcm_benchmarks::fungible -// --extrinsic=* -// --execution=wasm -// --wasm-execution=compiled -// --header=./file_header.txt -// --output=./runtime/kusama/src/weights/pallet_xcm_benchmarks_fungible.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] -#![allow(missing_docs)] - -use frame_support::{traits::Get, weights::Weight}; -use core::marker::PhantomData; - -/// Weight functions for `pallet_xcm_benchmarks::fungible`. -pub struct WeightInfo(PhantomData); -impl pallet_xcm_benchmarks::fungible::WeightInfo for WeightInfo { - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - fn withdraw_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `101` - // Estimated: `3593` - // Minimum execution time: 24_725_000 picoseconds. - Weight::from_parts(25_253_000, 0) - .saturating_add(Weight::from_parts(0, 3593)) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - fn transfer_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `101` - // Estimated: `6196` - // Minimum execution time: 53_699_000 picoseconds. - Weight::from_parts(54_162_000, 0) - .saturating_add(Weight::from_parts(0, 6196)) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn transfer_reserve_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `312` - // Estimated: `6196` - // Minimum execution time: 79_408_000 picoseconds. - Weight::from_parts(81_430_000, 0) - .saturating_add(Weight::from_parts(0, 6196)) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - fn receive_teleported_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `103` - // Estimated: `3593` - // Minimum execution time: 23_619_000 picoseconds. - Weight::from_parts(24_055_000, 0) - .saturating_add(Weight::from_parts(0, 3593)) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - fn deposit_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `3593` - // Minimum execution time: 26_405_000 picoseconds. - Weight::from_parts(26_700_000, 0) - .saturating_add(Weight::from_parts(0, 3593)) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn deposit_reserve_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 55_304_000 picoseconds. - Weight::from_parts(56_324_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn initiate_teleport() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 57_377_000 picoseconds. - Weight::from_parts(58_420_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) - } -} diff --git a/runtime/kusama/src/weights/pallet_xcm_benchmarks_generic.rs b/runtime/kusama/src/weights/pallet_xcm_benchmarks_generic.rs deleted file mode 100644 index 7b5d81343de8..000000000000 --- a/runtime/kusama/src/weights/pallet_xcm_benchmarks_generic.rs +++ /dev/null @@ -1,393 +0,0 @@ -// Copyright (C) Parity Technologies (UK) Ltd. -// This file is part of Polkadot. - -// Polkadot is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Polkadot is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Polkadot. If not, see . - -//! Autogenerated weights for `pallet_xcm_benchmarks::generic` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-19, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner-e8ezs4ez-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/production/polkadot -// benchmark -// pallet -// --chain=kusama-dev -// --steps=50 -// --repeat=20 -// --no-storage-info -// --no-median-slopes -// --no-min-squares -// --pallet=pallet_xcm_benchmarks::generic -// --extrinsic=* -// --execution=wasm -// --wasm-execution=compiled -// --header=./file_header.txt -// --output=./runtime/kusama/src/weights/pallet_xcm_benchmarks_generic.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] -#![allow(missing_docs)] - -use frame_support::{traits::Get, weights::Weight}; -use core::marker::PhantomData; - -/// Weight functions for `pallet_xcm_benchmarks::generic`. -pub struct WeightInfo(PhantomData); -impl pallet_xcm_benchmarks::generic::WeightInfo for WeightInfo { - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn report_holding() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 34_471_000 picoseconds. - Weight::from_parts(35_000_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn buy_execution() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_115_000 picoseconds. - Weight::from_parts(3_227_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: XcmPallet Queries (r:1 w:0) - /// Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) - fn query_response() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 11_905_000 picoseconds. - Weight::from_parts(12_199_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(1)) - } - fn transact() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 12_426_000 picoseconds. - Weight::from_parts(12_740_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn refund_surplus() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_099_000 picoseconds. - Weight::from_parts(3_200_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_error_handler() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_960_000 picoseconds. - Weight::from_parts(3_060_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_appendix() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_947_000 picoseconds. - Weight::from_parts(3_048_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn clear_error() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_861_000 picoseconds. - Weight::from_parts(2_990_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn descend_origin() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_843_000 picoseconds. - Weight::from_parts(4_005_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn clear_origin() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_915_000 picoseconds. - Weight::from_parts(3_037_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn report_error() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 29_177_000 picoseconds. - Weight::from_parts(29_561_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: XcmPallet AssetTraps (r:1 w:1) - /// Proof Skipped: XcmPallet AssetTraps (max_values: None, max_size: None, mode: Measured) - fn claim_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `226` - // Estimated: `3691` - // Minimum execution time: 16_170_000 picoseconds. - Weight::from_parts(16_629_000, 0) - .saturating_add(Weight::from_parts(0, 3691)) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - fn trap() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_881_000 picoseconds. - Weight::from_parts(3_014_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: XcmPallet VersionNotifyTargets (r:1 w:1) - /// Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn subscribe_version() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 35_499_000 picoseconds. - Weight::from_parts(36_678_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: XcmPallet VersionNotifyTargets (r:0 w:1) - /// Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) - fn unsubscribe_version() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 5_005_000 picoseconds. - Weight::from_parts(5_176_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn initiate_reserve_withdraw() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 33_017_000 picoseconds. - Weight::from_parts(33_514_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn burn_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 4_645_000 picoseconds. - Weight::from_parts(4_827_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_116_000 picoseconds. - Weight::from_parts(3_239_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_origin() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_930_000 picoseconds. - Weight::from_parts(3_118_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_error() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_871_000 picoseconds. - Weight::from_parts(2_990_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_transact_status() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_136_000 picoseconds. - Weight::from_parts(3_240_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn query_pallet() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 36_940_000 picoseconds. - Weight::from_parts(37_766_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn expect_pallet() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 8_735_000 picoseconds. - Weight::from_parts(8_957_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn report_transact_status() -> Weight { - // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 28_967_000 picoseconds. - Weight::from_parts(29_937_000, 0) - .saturating_add(Weight::from_parts(0, 3676)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn clear_transact_status() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_907_000 picoseconds. - Weight::from_parts(3_023_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_topic() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_866_000 picoseconds. - Weight::from_parts(2_960_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn clear_topic() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_872_000 picoseconds. - Weight::from_parts(3_022_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_fees_mode() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_936_000 picoseconds. - Weight::from_parts(3_021_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn unpaid_execution() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_063_000 picoseconds. - Weight::from_parts(3_153_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } -} diff --git a/runtime/westend/src/weights/pallet_xcm_benchmarks_fungible.rs b/runtime/westend/src/weights/pallet_xcm_benchmarks_fungible.rs deleted file mode 100644 index f868793b59c4..000000000000 --- a/runtime/westend/src/weights/pallet_xcm_benchmarks_fungible.rs +++ /dev/null @@ -1,183 +0,0 @@ -// Copyright (C) Parity Technologies (UK) Ltd. -// This file is part of Polkadot. - -// Polkadot is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Polkadot is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Polkadot. If not, see . - -//! Autogenerated weights for `pallet_xcm_benchmarks::fungible` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-14, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner--ss9ysm1-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/production/polkadot -// benchmark -// pallet -// --chain=westend-dev -// --steps=50 -// --repeat=20 -// --no-storage-info -// --no-median-slopes -// --no-min-squares -// --pallet=pallet_xcm_benchmarks::fungible -// --extrinsic=* -// --execution=wasm -// --wasm-execution=compiled -// --header=./file_header.txt -// --output=./runtime/westend/src/weights/pallet_xcm_benchmarks_fungible.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] -#![allow(missing_docs)] - -use frame_support::{traits::Get, weights::Weight}; -use core::marker::PhantomData; - -/// Weight functions for `pallet_xcm_benchmarks::fungible`. -pub struct WeightInfo(PhantomData); -impl pallet_xcm_benchmarks::fungible::WeightInfo for WeightInfo { - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - fn withdraw_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `101` - // Estimated: `3593` - // Minimum execution time: 24_885_000 picoseconds. - Weight::from_parts(25_316_000, 0) - .saturating_add(Weight::from_parts(0, 3593)) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - fn transfer_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `101` - // Estimated: `6196` - // Minimum execution time: 51_715_000 picoseconds. - Weight::from_parts(53_006_000, 0) - .saturating_add(Weight::from_parts(0, 6196)) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn transfer_reserve_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `270` - // Estimated: `6196` - // Minimum execution time: 76_546_000 picoseconds. - Weight::from_parts(78_742_000, 0) - .saturating_add(Weight::from_parts(0, 6196)) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - fn receive_teleported_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `103` - // Estimated: `3593` - // Minimum execution time: 23_106_000 picoseconds. - Weight::from_parts(23_848_000, 0) - .saturating_add(Weight::from_parts(0, 3593)) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - fn deposit_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `3593` - // Minimum execution time: 26_306_000 picoseconds. - Weight::from_parts(26_875_000, 0) - .saturating_add(Weight::from_parts(0, 3593)) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn deposit_reserve_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 53_271_000 picoseconds. - Weight::from_parts(54_820_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn initiate_teleport() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 55_312_000 picoseconds. - Weight::from_parts(56_390_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) - } -} diff --git a/runtime/westend/src/weights/pallet_xcm_benchmarks_generic.rs b/runtime/westend/src/weights/pallet_xcm_benchmarks_generic.rs deleted file mode 100644 index dc9d0dc682fc..000000000000 --- a/runtime/westend/src/weights/pallet_xcm_benchmarks_generic.rs +++ /dev/null @@ -1,393 +0,0 @@ -// Copyright (C) Parity Technologies (UK) Ltd. -// This file is part of Polkadot. - -// Polkadot is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Polkadot is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Polkadot. If not, see . - -//! Autogenerated weights for `pallet_xcm_benchmarks::generic` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-14, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner--ss9ysm1-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 - -// Executed Command: -// ./target/production/polkadot -// benchmark -// pallet -// --chain=westend-dev -// --steps=50 -// --repeat=20 -// --no-storage-info -// --no-median-slopes -// --no-min-squares -// --pallet=pallet_xcm_benchmarks::generic -// --extrinsic=* -// --execution=wasm -// --wasm-execution=compiled -// --header=./file_header.txt -// --output=./runtime/westend/src/weights/pallet_xcm_benchmarks_generic.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] -#![allow(missing_docs)] - -use frame_support::{traits::Get, weights::Weight}; -use core::marker::PhantomData; - -/// Weight functions for `pallet_xcm_benchmarks::generic`. -pub struct WeightInfo(PhantomData); -impl pallet_xcm_benchmarks::generic::WeightInfo for WeightInfo { - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn report_holding() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 32_591_000 picoseconds. - Weight::from_parts(33_164_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn buy_execution() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_080_000 picoseconds. - Weight::from_parts(3_205_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: XcmPallet Queries (r:1 w:0) - /// Proof Skipped: XcmPallet Queries (max_values: None, max_size: None, mode: Measured) - fn query_response() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 11_799_000 picoseconds. - Weight::from_parts(12_129_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(1)) - } - fn transact() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 12_576_000 picoseconds. - Weight::from_parts(12_996_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn refund_surplus() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_113_000 picoseconds. - Weight::from_parts(3_197_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_error_handler() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_872_000 picoseconds. - Weight::from_parts(2_992_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_appendix() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_946_000 picoseconds. - Weight::from_parts(3_044_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn clear_error() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_818_000 picoseconds. - Weight::from_parts(2_988_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn descend_origin() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_819_000 picoseconds. - Weight::from_parts(3_944_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn clear_origin() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_880_000 picoseconds. - Weight::from_parts(2_990_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn report_error() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 27_570_000 picoseconds. - Weight::from_parts(28_178_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - /// Storage: XcmPallet AssetTraps (r:1 w:1) - /// Proof Skipped: XcmPallet AssetTraps (max_values: None, max_size: None, mode: Measured) - fn claim_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `226` - // Estimated: `3691` - // Minimum execution time: 16_109_000 picoseconds. - Weight::from_parts(16_476_000, 0) - .saturating_add(Weight::from_parts(0, 3691)) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(1)) - } - fn trap() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_871_000 picoseconds. - Weight::from_parts(2_965_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: XcmPallet VersionNotifyTargets (r:1 w:1) - /// Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn subscribe_version() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 33_914_000 picoseconds. - Weight::from_parts(34_693_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) - } - /// Storage: XcmPallet VersionNotifyTargets (r:0 w:1) - /// Proof Skipped: XcmPallet VersionNotifyTargets (max_values: None, max_size: None, mode: Measured) - fn unsubscribe_version() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 4_940_000 picoseconds. - Weight::from_parts(5_245_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn initiate_reserve_withdraw() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 31_121_000 picoseconds. - Weight::from_parts(32_053_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn burn_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 4_527_000 picoseconds. - Weight::from_parts(4_706_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_asset() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_057_000 picoseconds. - Weight::from_parts(3_137_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_origin() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_977_000 picoseconds. - Weight::from_parts(3_089_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_error() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_877_000 picoseconds. - Weight::from_parts(3_031_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn expect_transact_status() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 3_155_000 picoseconds. - Weight::from_parts(3_259_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn query_pallet() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 34_206_000 picoseconds. - Weight::from_parts(34_798_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn expect_pallet() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 7_946_000 picoseconds. - Weight::from_parts(8_154_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - fn report_transact_status() -> Weight { - // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 27_990_000 picoseconds. - Weight::from_parts(28_458_000, 0) - .saturating_add(Weight::from_parts(0, 3634)) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) - } - fn clear_transact_status() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_899_000 picoseconds. - Weight::from_parts(3_068_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_topic() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_828_000 picoseconds. - Weight::from_parts(2_900_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn clear_topic() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_879_000 picoseconds. - Weight::from_parts(2_998_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn set_fees_mode() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_849_000 picoseconds. - Weight::from_parts(2_945_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } - fn unpaid_execution() -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 2_975_000 picoseconds. - Weight::from_parts(3_104_000, 0) - .saturating_add(Weight::from_parts(0, 0)) - } -} diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs index 7e93d0b012e4..504b79540399 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/benchmarking.rs @@ -131,6 +131,23 @@ benchmarks_instance_pallet! { // TODO: Check sender queue is not empty. #4426 } + reserve_asset_deposited { + let (trusted_reserve, transferable_reserve_asset) = T::TrustedReserve::get() + .ok_or(BenchmarkError::Override( + BenchmarkResult::from_weight(T::BlockWeights::get().max_block) + ))?; + + let assets: MultiAssets = vec![ transferable_reserve_asset ].into(); + + let mut executor = new_executor::(trusted_reserve); + let instruction = Instruction::ReserveAssetDeposited(assets.clone()); + let xcm = Xcm(vec![instruction]); + }: { + executor.bench_process(xcm)?; + } verify { + assert!(executor.holding().ensure_contains(&assets).is_ok()); + } + initiate_reserve_withdraw { let holding = T::worst_case_holding(1); let assets_filter = MultiAssetFilter::Definite(holding.clone()); From 7604826e0bcb2ad36948f26dd033b4c153203849 Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Fri, 23 Jun 2023 18:10:54 +0000 Subject: [PATCH 36/53] ".git/.scripts/commands/bench-vm/bench-vm.sh" xcm polkadot pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 41 +++++++++++-------- 1 file changed, 25 insertions(+), 16 deletions(-) diff --git a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index d879d0f0c5eb..038e9f17361b 100644 --- a/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/polkadot/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -56,8 +56,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 26_045_000 picoseconds. - Weight::from_parts(26_409_000, 3593) + // Minimum execution time: 24_801_000 picoseconds. + Weight::from_parts(25_567_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -67,8 +67,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 54_741_000 picoseconds. - Weight::from_parts(55_293_000, 6196) + // Minimum execution time: 53_090_000 picoseconds. + Weight::from_parts(54_157_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -92,11 +92,20 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `628` // Estimated: `6196` - // Minimum execution time: 80_483_000 picoseconds. - Weight::from_parts(81_949_000, 6196) + // Minimum execution time: 80_084_000 picoseconds. + Weight::from_parts(81_110_000, 6196) .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(5)) } + /// Storage: Benchmark Override (r:0 w:0) + /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub(crate) fn reserve_asset_deposited() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) + } /// Storage: Configuration ActiveConfig (r:1 w:0) /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) @@ -115,8 +124,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `527` // Estimated: `3992` - // Minimum execution time: 33_645_000 picoseconds. - Weight::from_parts(33_977_000, 3992) + // Minimum execution time: 32_535_000 picoseconds. + Weight::from_parts(33_276_000, 3992) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -128,8 +137,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `103` // Estimated: `3593` - // Minimum execution time: 24_729_000 picoseconds. - Weight::from_parts(25_418_000, 3593) + // Minimum execution time: 24_283_000 picoseconds. + Weight::from_parts(25_042_000, 3593) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -139,8 +148,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 26_234_000 picoseconds. - Weight::from_parts(26_841_000, 3593) + // Minimum execution time: 25_002_000 picoseconds. + Weight::from_parts(25_816_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -164,8 +173,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `527` // Estimated: `3992` - // Minimum execution time: 56_476_000 picoseconds. - Weight::from_parts(57_589_000, 3992) + // Minimum execution time: 55_355_000 picoseconds. + Weight::from_parts(56_410_000, 3992) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -191,8 +200,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `527` // Estimated: `3992` - // Minimum execution time: 58_277_000 picoseconds. - Weight::from_parts(60_107_000, 3992) + // Minimum execution time: 57_258_000 picoseconds. + Weight::from_parts(58_205_000, 3992) .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(5)) } From d35c70494c9b4ca7d85c4b0400b4f9e9da2fb9b5 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Tue, 27 Jun 2023 05:46:32 -0300 Subject: [PATCH 37/53] Use default benchmark for ReserveAssetDeposited --- runtime/kusama/src/weights/xcm/mod.rs | 4 ++-- runtime/polkadot/src/weights/xcm/mod.rs | 4 ++-- runtime/rococo/src/weights/xcm/mod.rs | 4 ++-- runtime/westend/src/weights/xcm/mod.rs | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/mod.rs b/runtime/kusama/src/weights/xcm/mod.rs index 24a93ac30116..2e310f9163e4 100644 --- a/runtime/kusama/src/weights/xcm/mod.rs +++ b/runtime/kusama/src/weights/xcm/mod.rs @@ -91,8 +91,8 @@ impl XcmWeightInfo for KusamaXcmWeight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } fn reserve_asset_deposited(_: &MultiAssets) -> Weight { - // Kusama doesn't support ReserveAssetDeposited - Weight::MAX + // Kusama doesn't support ReserveAssetDeposited, so this benchmark has a default weight + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/polkadot/src/weights/xcm/mod.rs b/runtime/polkadot/src/weights/xcm/mod.rs index 791efbd153e8..1d1c76dcacc8 100644 --- a/runtime/polkadot/src/weights/xcm/mod.rs +++ b/runtime/polkadot/src/weights/xcm/mod.rs @@ -91,8 +91,8 @@ impl XcmWeightInfo for PolkadotXcmWeight assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } fn reserve_asset_deposited(_: &MultiAssets) -> Weight { - // Polkadot doesn't support ReserveAssetDeposited - Weight::MAX + // Polkadot doesn't support ReserveAssetDeposited, so this benchmark has a default weight + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/rococo/src/weights/xcm/mod.rs b/runtime/rococo/src/weights/xcm/mod.rs index 4607480eef7f..e0beada2307b 100644 --- a/runtime/rococo/src/weights/xcm/mod.rs +++ b/runtime/rococo/src/weights/xcm/mod.rs @@ -91,8 +91,8 @@ impl XcmWeightInfo for RococoXcmWeight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } fn reserve_asset_deposited(_: &MultiAssets) -> Weight { - // Rococo doesn't support ReserveAssetDeposited - Weight::MAX + // Rococo doesn't support ReserveAssetDeposited, so this benchmark has a default weight + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/westend/src/weights/xcm/mod.rs b/runtime/westend/src/weights/xcm/mod.rs index 1bb27af37683..4f7ea593a69f 100644 --- a/runtime/westend/src/weights/xcm/mod.rs +++ b/runtime/westend/src/weights/xcm/mod.rs @@ -94,8 +94,8 @@ impl XcmWeightInfo for WestendXcmWeight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } fn reserve_asset_deposited(_: &MultiAssets) -> Weight { - // Westend doesn't support ReserveAssetDeposited - Weight::MAX + // Westend doesn't support ReserveAssetDeposited, so this benchmark has a default weight + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) From b91460af8b0a81ebc2700e80db4430f3a94fc8f5 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Tue, 27 Jun 2023 06:04:01 -0300 Subject: [PATCH 38/53] Add missing parameter --- runtime/kusama/src/weights/xcm/mod.rs | 2 +- runtime/polkadot/src/weights/xcm/mod.rs | 2 +- runtime/rococo/src/weights/xcm/mod.rs | 2 +- runtime/westend/src/weights/xcm/mod.rs | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/mod.rs b/runtime/kusama/src/weights/xcm/mod.rs index 2e310f9163e4..5958abe40df9 100644 --- a/runtime/kusama/src/weights/xcm/mod.rs +++ b/runtime/kusama/src/weights/xcm/mod.rs @@ -90,7 +90,7 @@ impl XcmWeightInfo for KusamaXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { // Kusama doesn't support ReserveAssetDeposited, so this benchmark has a default weight assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } diff --git a/runtime/polkadot/src/weights/xcm/mod.rs b/runtime/polkadot/src/weights/xcm/mod.rs index 1d1c76dcacc8..acef102b446f 100644 --- a/runtime/polkadot/src/weights/xcm/mod.rs +++ b/runtime/polkadot/src/weights/xcm/mod.rs @@ -90,7 +90,7 @@ impl XcmWeightInfo for PolkadotXcmWeight fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { // Polkadot doesn't support ReserveAssetDeposited, so this benchmark has a default weight assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } diff --git a/runtime/rococo/src/weights/xcm/mod.rs b/runtime/rococo/src/weights/xcm/mod.rs index e0beada2307b..1d613717dc52 100644 --- a/runtime/rococo/src/weights/xcm/mod.rs +++ b/runtime/rococo/src/weights/xcm/mod.rs @@ -90,7 +90,7 @@ impl XcmWeightInfo for RococoXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { // Rococo doesn't support ReserveAssetDeposited, so this benchmark has a default weight assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } diff --git a/runtime/westend/src/weights/xcm/mod.rs b/runtime/westend/src/weights/xcm/mod.rs index 4f7ea593a69f..c6fa6bb93eb6 100644 --- a/runtime/westend/src/weights/xcm/mod.rs +++ b/runtime/westend/src/weights/xcm/mod.rs @@ -93,7 +93,7 @@ impl XcmWeightInfo for WestendXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_: &MultiAssets) -> Weight { + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { // Westend doesn't support ReserveAssetDeposited, so this benchmark has a default weight assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } From 87d916b3432a1118302c6e4caad1cf1dbabf3143 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Tue, 27 Jun 2023 06:12:46 -0300 Subject: [PATCH 39/53] Revert reserve asset deposited benchmark --- runtime/kusama/src/weights/xcm/mod.rs | 5 +++-- runtime/rococo/src/weights/xcm/mod.rs | 5 +++-- runtime/westend/src/weights/xcm/mod.rs | 5 +++-- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/mod.rs b/runtime/kusama/src/weights/xcm/mod.rs index 5958abe40df9..ccb9776087de 100644 --- a/runtime/kusama/src/weights/xcm/mod.rs +++ b/runtime/kusama/src/weights/xcm/mod.rs @@ -90,9 +90,10 @@ impl XcmWeightInfo for KusamaXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { + fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { // Kusama doesn't support ReserveAssetDeposited, so this benchmark has a default weight - assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/rococo/src/weights/xcm/mod.rs b/runtime/rococo/src/weights/xcm/mod.rs index 1d613717dc52..4e0f8c202222 100644 --- a/runtime/rococo/src/weights/xcm/mod.rs +++ b/runtime/rococo/src/weights/xcm/mod.rs @@ -90,9 +90,10 @@ impl XcmWeightInfo for RococoXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { + fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { // Rococo doesn't support ReserveAssetDeposited, so this benchmark has a default weight - assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/westend/src/weights/xcm/mod.rs b/runtime/westend/src/weights/xcm/mod.rs index c6fa6bb93eb6..edd823ef9165 100644 --- a/runtime/westend/src/weights/xcm/mod.rs +++ b/runtime/westend/src/weights/xcm/mod.rs @@ -93,9 +93,10 @@ impl XcmWeightInfo for WestendXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { + fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { // Westend doesn't support ReserveAssetDeposited, so this benchmark has a default weight - assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) + Weight::MAX } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) From 49c7d64bced6243dbc4addeae17121ccd4007789 Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Tue, 27 Jun 2023 13:01:56 +0000 Subject: [PATCH 40/53] ".git/.scripts/commands/bench-vm/bench-vm.sh" xcm kusama pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 227 ++++++++++-------- 1 file changed, 128 insertions(+), 99 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 1f6473ac5f57..1abc6e2401a1 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,11 +17,13 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-06-27, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,6 +32,7 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --json-file=/builds/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::fungible // --chain=kusama-dev // --header=./file_header.txt @@ -39,141 +42,167 @@ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] #![allow(unused_imports)] +#![allow(missing_docs)] use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; +use core::marker::PhantomData; -/// Weights for `pallet_xcm_benchmarks::fungible`. +/// Weight functions for `pallet_xcm_benchmarks::fungible`. pub struct WeightInfo(PhantomData); impl WeightInfo { - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn withdraw_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn withdraw_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 21_938_000 picoseconds. - Weight::from_parts(22_222_000, 3593) + // Minimum execution time: 24_218_000 picoseconds. + Weight::from_parts(24_985_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn transfer_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn transfer_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 45_662_000 picoseconds. - Weight::from_parts(46_305_000, 6196) + // Minimum execution time: 52_173_000 picoseconds. + Weight::from_parts(53_082_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn transfer_reserve_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: // Measured: `312` - // Estimated: `21121` - // Minimum execution time: 67_634_000 picoseconds. - Weight::from_parts(68_477_000, 21121) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(5)) + // Estimated: `6196` + // Minimum execution time: 78_383_000 picoseconds. + Weight::from_parts(80_342_000, 6196) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(6)) } - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_reserve_withdraw() -> Weight { + /// Storage: Benchmark Override (r:0 w:0) + /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub(crate) fn reserve_asset_deposited() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) + } + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_reserve_withdraw() -> Weight { // Proof Size summary in bytes: // Measured: `211` - // Estimated: `14420` - // Minimum execution time: 27_863_000 picoseconds. - Weight::from_parts(28_394_000, 14420) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(3)) + // Estimated: `3676` + // Minimum execution time: 31_820_000 picoseconds. + Weight::from_parts(32_451_000, 3676) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - pub fn receive_teleported_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` - // Estimated: `5094` - // Minimum execution time: 22_235_000 picoseconds. - Weight::from_parts(22_622_000, 5094) + // Estimated: `3593` + // Minimum execution time: 22_630_000 picoseconds. + Weight::from_parts(23_452_000, 3593) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn deposit_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn deposit_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 25_006_000 picoseconds. - Weight::from_parts(25_595_000, 3593) + // Minimum execution time: 25_624_000 picoseconds. + Weight::from_parts(26_291_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn deposit_reserve_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: // Measured: `211` - // Estimated: `18013` - // Minimum execution time: 48_982_000 picoseconds. - Weight::from_parts(49_465_000, 18013) - .saturating_add(T::DbWeight::get().reads(6)) - .saturating_add(T::DbWeight::get().writes(4)) + // Estimated: `3676` + // Minimum execution time: 54_048_000 picoseconds. + Weight::from_parts(54_735_000, 3676) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(5)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_teleport() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: // Measured: `211` - // Estimated: `19514` - // Minimum execution time: 51_103_000 picoseconds. - Weight::from_parts(51_607_000, 19514) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(5)) + // Estimated: `3676` + // Minimum execution time: 55_663_000 picoseconds. + Weight::from_parts(57_146_000, 3676) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(6)) } } From 63850bd68e27398e4c206651ccd158e5a7dbccd8 Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Tue, 27 Jun 2023 14:11:37 +0000 Subject: [PATCH 41/53] ".git/.scripts/commands/bench-vm/bench-vm.sh" xcm westend pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 227 ++++++++++-------- 1 file changed, 128 insertions(+), 99 deletions(-) diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 9fd39692f2a2..658eaa248bf3 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,11 +17,13 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-06-27, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,6 +32,7 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --json-file=/builds/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::fungible // --chain=westend-dev // --header=./file_header.txt @@ -39,141 +42,167 @@ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] #![allow(unused_imports)] +#![allow(missing_docs)] use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; +use core::marker::PhantomData; -/// Weights for `pallet_xcm_benchmarks::fungible`. +/// Weight functions for `pallet_xcm_benchmarks::fungible`. pub struct WeightInfo(PhantomData); impl WeightInfo { - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn withdraw_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn withdraw_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 22_158_000 picoseconds. - Weight::from_parts(22_428_000, 3593) + // Minimum execution time: 25_450_000 picoseconds. + Weight::from_parts(25_774_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn transfer_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn transfer_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 46_062_000 picoseconds. - Weight::from_parts(46_579_000, 6196) + // Minimum execution time: 53_613_000 picoseconds. + Weight::from_parts(54_213_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn transfer_reserve_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: // Measured: `270` - // Estimated: `20911` - // Minimum execution time: 66_610_000 picoseconds. - Weight::from_parts(67_366_000, 20911) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(5)) + // Estimated: `6196` + // Minimum execution time: 77_943_000 picoseconds. + Weight::from_parts(79_070_000, 6196) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(6)) } - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_reserve_withdraw() -> Weight { + /// Storage: Benchmark Override (r:0 w:0) + /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub(crate) fn reserve_asset_deposited() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) + } + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_reserve_withdraw() -> Weight { // Proof Size summary in bytes: // Measured: `169` - // Estimated: `14210` - // Minimum execution time: 27_155_000 picoseconds. - Weight::from_parts(27_545_000, 14210) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(3)) + // Estimated: `3634` + // Minimum execution time: 30_917_000 picoseconds. + Weight::from_parts(31_560_000, 3634) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - pub fn receive_teleported_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` - // Estimated: `5094` - // Minimum execution time: 22_079_000 picoseconds. - Weight::from_parts(22_664_000, 5094) + // Estimated: `3593` + // Minimum execution time: 23_632_000 picoseconds. + Weight::from_parts(24_127_000, 3593) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn deposit_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn deposit_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 24_546_000 picoseconds. - Weight::from_parts(24_959_000, 3593) + // Minimum execution time: 26_677_000 picoseconds. + Weight::from_parts(27_157_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn deposit_reserve_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: // Measured: `169` - // Estimated: `17803` - // Minimum execution time: 47_788_000 picoseconds. - Weight::from_parts(48_039_000, 17803) - .saturating_add(T::DbWeight::get().reads(6)) - .saturating_add(T::DbWeight::get().writes(4)) + // Estimated: `3634` + // Minimum execution time: 53_833_000 picoseconds. + Weight::from_parts(54_712_000, 3634) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(5)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_teleport() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: // Measured: `169` - // Estimated: `19304` - // Minimum execution time: 49_509_000 picoseconds. - Weight::from_parts(50_031_000, 19304) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(5)) + // Estimated: `3634` + // Minimum execution time: 55_803_000 picoseconds. + Weight::from_parts(57_258_000, 3634) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(6)) } } From 41f6b2c9734b0e38eed7e7843feb9176f59ebc16 Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Tue, 27 Jun 2023 22:21:34 +0000 Subject: [PATCH 42/53] ".git/.scripts/commands/bench/bench.sh" xcm rococo pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 251 ++++++++++-------- 1 file changed, 140 insertions(+), 111 deletions(-) diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index f89d687f212a..8771cf7a02fd 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,11 +17,13 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-04-14, STEPS: `50`, REPEAT: 20, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-06-27, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet // --steps=50 @@ -30,6 +32,7 @@ // --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 +// --json-file=/builds/parity/mirrors/polkadot/.git/.artifacts/bench.json // --pallet=pallet_xcm_benchmarks::fungible // --chain=rococo-dev // --header=./file_header.txt @@ -39,149 +42,175 @@ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] #![allow(unused_imports)] +#![allow(missing_docs)] use frame_support::{traits::Get, weights::Weight}; -use sp_std::marker::PhantomData; +use core::marker::PhantomData; -/// Weights for `pallet_xcm_benchmarks::fungible`. +/// Weight functions for `pallet_xcm_benchmarks::fungible`. pub struct WeightInfo(PhantomData); impl WeightInfo { - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn withdraw_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn withdraw_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 23_316_000 picoseconds. - Weight::from_parts(23_706_000, 3593) + // Minimum execution time: 25_184_000 picoseconds. + Weight::from_parts(25_763_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn transfer_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn transfer_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 47_324_000 picoseconds. - Weight::from_parts(47_736_000, 6196) + // Minimum execution time: 52_392_000 picoseconds. + Weight::from_parts(53_032_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:2 w:2) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn transfer_reserve_asset() -> Weight { + /// Storage: System Account (r:2 w:2) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `686` - // Estimated: `25162` - // Minimum execution time: 73_174_000 picoseconds. - Weight::from_parts(73_839_000, 25162) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) + // Measured: `666` + // Estimated: `6196` + // Minimum execution time: 79_960_000 picoseconds. + Weight::from_parts(82_422_000, 6196) + .saturating_add(T::DbWeight::get().reads(10)) + .saturating_add(T::DbWeight::get().writes(6)) } - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_reserve_withdraw() -> Weight { + /// Storage: Benchmark Override (r:0 w:0) + /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + pub(crate) fn reserve_asset_deposited() -> Weight { // Proof Size summary in bytes: - // Measured: `585` - // Estimated: `18360` - // Minimum execution time: 32_027_000 picoseconds. - Weight::from_parts(32_680_000, 18360) - .saturating_add(T::DbWeight::get().reads(6)) - .saturating_add(T::DbWeight::get().writes(3)) + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_000_000_000_000 picoseconds. + Weight::from_parts(2_000_000_000_000, 0) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - pub fn receive_teleported_asset() -> Weight { + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_reserve_withdraw() -> Weight { + // Proof Size summary in bytes: + // Measured: `565` + // Estimated: `4030` + // Minimum execution time: 34_401_000 picoseconds. + Weight::from_parts(35_053_000, 4030) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` - // Estimated: `5094` - // Minimum execution time: 23_807_000 picoseconds. - Weight::from_parts(24_336_000, 5094) + // Estimated: `3593` + // Minimum execution time: 23_763_000 picoseconds. + Weight::from_parts(24_447_000, 3593) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - pub fn deposit_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + pub(crate) fn deposit_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 24_740_000 picoseconds. - Weight::from_parts(25_165_000, 3593) + // Minimum execution time: 25_099_000 picoseconds. + Weight::from_parts(25_425_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn deposit_reserve_asset() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `585` - // Estimated: `21953` - // Minimum execution time: 54_219_000 picoseconds. - Weight::from_parts(54_782_000, 21953) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) + // Measured: `565` + // Estimated: `4030` + // Minimum execution time: 57_552_000 picoseconds. + Weight::from_parts(58_922_000, 4030) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(5)) } - // Storage: System Account (r:1 w:1) - // Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - // Storage: Balances InactiveIssuance (r:1 w:1) - // Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - // Storage: Configuration ActiveConfig (r:1 w:0) - // Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SupportedVersion (r:1 w:0) - // Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - // Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - // Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - // Storage: XcmPallet SafeXcmVersion (r:1 w:0) - // Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueues (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - // Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - // Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) - pub fn initiate_teleport() -> Weight { + /// Storage: System Account (r:1 w:1) + /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: Balances InactiveIssuance (r:1 w:1) + /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) + /// Storage: Configuration ActiveConfig (r:1 w:0) + /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) + /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet SupportedVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) + /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) + /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) + /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueues (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) + /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) + /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: - // Measured: `585` - // Estimated: `23454` - // Minimum execution time: 56_374_000 picoseconds. - Weight::from_parts(56_780_000, 23454) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) + // Measured: `565` + // Estimated: `4030` + // Minimum execution time: 58_641_000 picoseconds. + Weight::from_parts(60_736_000, 4030) + .saturating_add(T::DbWeight::get().reads(10)) + .saturating_add(T::DbWeight::get().writes(6)) } } From e8a1855d2b2d34de384d4ec9b70c773fa88bfb47 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Fri, 30 Jun 2023 07:24:25 -0300 Subject: [PATCH 43/53] Add 'real' benchmarks --- runtime/kusama/src/weights/xcm/mod.rs | 5 ++--- runtime/rococo/src/weights/xcm/mod.rs | 5 ++--- runtime/westend/src/weights/xcm/mod.rs | 5 ++--- 3 files changed, 6 insertions(+), 9 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/mod.rs b/runtime/kusama/src/weights/xcm/mod.rs index ccb9776087de..5958abe40df9 100644 --- a/runtime/kusama/src/weights/xcm/mod.rs +++ b/runtime/kusama/src/weights/xcm/mod.rs @@ -90,10 +90,9 @@ impl XcmWeightInfo for KusamaXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { // Kusama doesn't support ReserveAssetDeposited, so this benchmark has a default weight - // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) - Weight::MAX + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/rococo/src/weights/xcm/mod.rs b/runtime/rococo/src/weights/xcm/mod.rs index 4e0f8c202222..1d613717dc52 100644 --- a/runtime/rococo/src/weights/xcm/mod.rs +++ b/runtime/rococo/src/weights/xcm/mod.rs @@ -90,10 +90,9 @@ impl XcmWeightInfo for RococoXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { // Rococo doesn't support ReserveAssetDeposited, so this benchmark has a default weight - // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) - Weight::MAX + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) diff --git a/runtime/westend/src/weights/xcm/mod.rs b/runtime/westend/src/weights/xcm/mod.rs index edd823ef9165..c6fa6bb93eb6 100644 --- a/runtime/westend/src/weights/xcm/mod.rs +++ b/runtime/westend/src/weights/xcm/mod.rs @@ -93,10 +93,9 @@ impl XcmWeightInfo for WestendXcmWeight { fn withdraw_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::withdraw_asset()) } - fn reserve_asset_deposited(_assets: &MultiAssets) -> Weight { + fn reserve_asset_deposited(assets: &MultiAssets) -> Weight { // Westend doesn't support ReserveAssetDeposited, so this benchmark has a default weight - // assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) - Weight::MAX + assets.weigh_multi_assets(XcmBalancesWeight::::reserve_asset_deposited()) } fn receive_teleported_asset(assets: &MultiAssets) -> Weight { assets.weigh_multi_assets(XcmBalancesWeight::::receive_teleported_asset()) From 665e8d26e711a81253cf1930e83d7299d900e588 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Sun, 2 Jul 2023 07:43:53 -0300 Subject: [PATCH 44/53] Add TrustedReserve to actual XcmConfig --- xcm/pallet-xcm-benchmarks/src/fungible/mock.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs b/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs index 9f6a34650887..e17508e43551 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs @@ -140,7 +140,7 @@ impl xcm_executor::Config for XcmConfig { type XcmSender = DevNull; type AssetTransactor = AssetTransactor; type OriginConverter = (); - type IsReserve = (); + type IsReserve = TrustedReserve; type IsTeleporter = TrustedTeleporters; type UniversalLocation = UniversalLocation; type Barrier = AllowUnpaidExecutionFrom; From e8774b91e08df51e1034e6ea224d250cbe54285d Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Sun, 2 Jul 2023 08:11:45 -0300 Subject: [PATCH 45/53] Add TrustedReserve to actual XcmConfig (fix) --- xcm/pallet-xcm-benchmarks/src/fungible/mock.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs b/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs index e17508e43551..1e1161cdd3e0 100644 --- a/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs +++ b/xcm/pallet-xcm-benchmarks/src/fungible/mock.rs @@ -140,7 +140,7 @@ impl xcm_executor::Config for XcmConfig { type XcmSender = DevNull; type AssetTransactor = AssetTransactor; type OriginConverter = (); - type IsReserve = TrustedReserve; + type IsReserve = TrustedReserves; type IsTeleporter = TrustedTeleporters; type UniversalLocation = UniversalLocation; type Barrier = AllowUnpaidExecutionFrom; @@ -179,7 +179,8 @@ impl crate::Config for Test { } } -pub type TrustedTeleporters = (xcm_builder::Case,); +pub type TrustedTeleporters = xcm_builder::Case; +pub type TrustedReserves = xcm_builder::Case; parameter_types! { pub const CheckingAccount: Option<(u64, MintLocation)> = Some((100, MintLocation::Local)); From e80414454b540e769c78475ba59a6402dc3166d6 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Sun, 2 Jul 2023 22:55:25 +0200 Subject: [PATCH 46/53] Whitelist from benchmarking XCM storage keys read each block (#6871) * Whitelist from benchmarking XCM storage keys read each block * ".git/.scripts/commands/bench/bench.sh" runtime polkadot pallet_xcm * ".git/.scripts/commands/bench/bench.sh" runtime polkadot pallet_xcm * ".git/.scripts/commands/bench/bench.sh" runtime westend pallet_xcm * ".git/.scripts/commands/bench/bench.sh" runtime rococo pallet_xcm * Remove XcmPallet SupportedVersion from the benchmark whitelist * ".git/.scripts/commands/bench/bench.sh" runtime polkadot pallet_xcm * ".git/.scripts/commands/bench/bench.sh" runtime kusama pallet_xcm * ".git/.scripts/commands/bench/bench.sh" runtime westend pallet_xcm * ".git/.scripts/commands/bench/bench.sh" runtime rococo pallet_xcm * WIP * Add necessary traits, remove unnecessary whitelisted keys * Fix tests * Remove unused file * Remove unused import --------- Co-authored-by: command-bot <> --- runtime/kusama/src/lib.rs | 22 ++----- runtime/kusama/src/tests.rs | 31 ++++++++- runtime/kusama/src/weights/pallet_xcm.rs | 30 ++------- runtime/parachains/src/configuration.rs | 1 + runtime/polkadot/src/lib.rs | 61 +++++++++++++----- runtime/polkadot/src/weights/pallet_xcm.rs | 30 ++------- runtime/rococo/src/lib.rs | 75 +++++++++++++++------- runtime/rococo/src/weights/pallet_xcm.rs | 31 ++------- runtime/westend/src/lib.rs | 24 +------ runtime/westend/src/tests.rs | 29 +++++++++ runtime/westend/src/weights/pallet_xcm.rs | 30 ++------- xcm/pallet-xcm/src/lib.rs | 2 + 12 files changed, 187 insertions(+), 179 deletions(-) diff --git a/runtime/kusama/src/lib.rs b/runtime/kusama/src/lib.rs index 47367053c277..332e08835075 100644 --- a/runtime/kusama/src/lib.rs +++ b/runtime/kusama/src/lib.rs @@ -2131,6 +2131,7 @@ sp_api::impl_runtime_apis! { Vec, sp_runtime::RuntimeString, > { + use frame_support::traits::WhitelistedStorageKeys; use frame_benchmarking::{Benchmarking, BenchmarkBatch, TrackedStorageKey, BenchmarkError}; // Trying to add benchmarks directly to some pallets caused cyclic dependency issues. // To get around that, we separated the benchmarks into its own crate. @@ -2240,24 +2241,9 @@ sp_api::impl_runtime_apis! { } } - let whitelist: Vec = vec![ - // Block Number - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(), - // Total Issuance - hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(), - // Execution Phase - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(), - // Event Count - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(), - // System Events - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(), - // Treasury Account - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da95ecffd7b6c0f78751baa9d281e0bfa3a6d6f646c70792f74727372790000000000000000000000000000000000000000").to_vec().into(), - // Configuration ActiveConfig - hex_literal::hex!("06de3d8a54d27e44a9d5ce189618f22db4b49d95320d9021994c850f25b8e385").to_vec().into(), - // The transactional storage limit. - hex_literal::hex!("3a7472616e73616374696f6e5f6c6576656c3a").to_vec().into(), - ]; + let mut whitelist: Vec = AllPalletsWithSystem::whitelisted_storage_keys(); + let treasury_key = frame_system::Account::::hashed_key_for(Treasury::account_id()); + whitelist.push(treasury_key.to_vec().into()); let mut batches = Vec::::new(); let params = (&config, &whitelist); diff --git a/runtime/kusama/src/tests.rs b/runtime/kusama/src/tests.rs index f126185dedbe..c4f1d5a6a40e 100644 --- a/runtime/kusama/src/tests.rs +++ b/runtime/kusama/src/tests.rs @@ -17,13 +17,17 @@ //! Tests for the Kusama Runtime Configuration use crate::*; -use frame_support::{dispatch::GetDispatchInfo, weights::WeightToFee as WeightToFeeT}; +use frame_support::{ + dispatch::GetDispatchInfo, traits::WhitelistedStorageKeys, weights::WeightToFee as WeightToFeeT, +}; use keyring::Sr25519Keyring::Charlie; use pallet_transaction_payment::Multiplier; use parity_scale_codec::Encode; use runtime_common::MinimumMultiplier; use separator::Separatable; +use sp_core::hexdisplay::HexDisplay; use sp_runtime::FixedPointNumber; +use std::collections::HashSet; #[test] fn nis_hold_reason_encoding_is_correct() { @@ -154,3 +158,28 @@ fn max_upward_message_size() { pallet_message_queue::MaxMessageLenOf::::get() ); } + +#[test] +fn check_whitelist() { + let whitelist: HashSet = AllPalletsWithSystem::whitelisted_storage_keys() + .iter() + .map(|e| HexDisplay::from(&e.key).to_string()) + .collect(); + + // Block number + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac")); + // Total issuance + assert!(whitelist.contains("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80")); + // Execution phase + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a")); + // Event count + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850")); + // System events + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7")); + // Configuration ActiveConfig + assert!(whitelist.contains("06de3d8a54d27e44a9d5ce189618f22db4b49d95320d9021994c850f25b8e385")); + // XcmPallet VersionDiscoveryQueue + assert!(whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d194a222ba0333561192e474c59ed8e30e1")); + // XcmPallet SafeXcmVersion + assert!(whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d196323ae84c43568be0d1394d5d0d522c4")); +} diff --git a/runtime/kusama/src/weights/pallet_xcm.rs b/runtime/kusama/src/weights/pallet_xcm.rs index 8559f45bbadc..4b1a790a57a1 100644 --- a/runtime/kusama/src/weights/pallet_xcm.rs +++ b/runtime/kusama/src/weights/pallet_xcm.rs @@ -23,10 +23,9 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet -// --chain=kusama-dev // --steps=50 // --repeat=20 // --no-storage-info @@ -36,6 +35,10 @@ // --extrinsic=* // --execution=wasm // --wasm-execution=compiled +// --heap-pages=4096 +// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json +// --pallet=pallet_xcm +// --chain=kusama-dev // --header=./file_header.txt // --output=./runtime/kusama/src/weights/ @@ -56,10 +59,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -109,8 +108,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: XcmPallet SafeXcmVersion (r:0 w:1) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) fn force_default_xcm_version() -> Weight { // Proof Size summary in bytes: // Measured: `0` @@ -118,7 +115,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { // Minimum execution time: 2_939_000 picoseconds. Weight::from_parts(3_022_000, 0) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: XcmPallet VersionNotifiers (r:1 w:1) /// Proof Skipped: XcmPallet VersionNotifiers (max_values: None, max_size: None, mode: Measured) @@ -130,10 +126,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -158,10 +150,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -232,10 +220,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -281,10 +265,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) diff --git a/runtime/parachains/src/configuration.rs b/runtime/parachains/src/configuration.rs index 5317c18f8962..d0bb1193d09b 100644 --- a/runtime/parachains/src/configuration.rs +++ b/runtime/parachains/src/configuration.rs @@ -508,6 +508,7 @@ pub mod pallet { /// The active configuration for the current session. #[pallet::storage] + #[pallet::whitelist_storage] #[pallet::getter(fn config)] pub(crate) type ActiveConfig = StorageValue<_, HostConfiguration, ValueQuery>; diff --git a/runtime/polkadot/src/lib.rs b/runtime/polkadot/src/lib.rs index e21ab849dd7d..d5c2d2c4649a 100644 --- a/runtime/polkadot/src/lib.rs +++ b/runtime/polkadot/src/lib.rs @@ -2119,6 +2119,7 @@ sp_api::impl_runtime_apis! { Vec, sp_runtime::RuntimeString, > { + use frame_support::traits::WhitelistedStorageKeys; use frame_benchmarking::{Benchmarking, BenchmarkBatch, TrackedStorageKey, BenchmarkError}; // Trying to add benchmarks directly to some pallets caused cyclic dependency issues. // To get around that, we separated the benchmarks into its own crate. @@ -2139,6 +2140,10 @@ sp_api::impl_runtime_apis! { impl pallet_nomination_pools_benchmarking::Config for Runtime {} impl runtime_parachains::disputes::slashing::benchmarking::Config for Runtime {} + let mut whitelist: Vec = AllPalletsWithSystem::whitelisted_storage_keys(); + let treasury_key = frame_system::Account::::hashed_key_for(Treasury::account_id()); + whitelist.push(treasury_key.to_vec().into()); + impl pallet_xcm_benchmarks::Config for Runtime { type XcmConfig = XcmConfig; type AccountIdConverter = SovereignAccountOf; @@ -2223,21 +2228,6 @@ sp_api::impl_runtime_apis! { } } - let whitelist: Vec = vec![ - // Block Number - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(), - // Total Issuance - hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(), - // Execution Phase - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(), - // Event Count - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(), - // System Events - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(), - // Treasury Account - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da95ecffd7b6c0f78751baa9d281e0bfa3a6d6f646c70792f74727372790000000000000000000000000000000000000000").to_vec().into(), - ]; - let mut batches = Vec::::new(); let params = (&config, &whitelist); @@ -2426,7 +2416,11 @@ mod test_fees { #[cfg(test)] mod test { + use std::collections::HashSet; + use super::*; + use frame_support::traits::WhitelistedStorageKeys; + use sp_core::hexdisplay::HexDisplay; #[test] fn call_size() { @@ -2438,6 +2432,43 @@ mod test { ); } + #[test] + fn check_whitelist() { + let whitelist: HashSet = AllPalletsWithSystem::whitelisted_storage_keys() + .iter() + .map(|e| HexDisplay::from(&e.key).to_string()) + .collect(); + + // Block number + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac") + ); + // Total issuance + assert!( + whitelist.contains("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80") + ); + // Execution phase + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a") + ); + // Event count + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850") + ); + // System events + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7") + ); + // XcmPallet VersionDiscoveryQueue + assert!( + whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d194a222ba0333561192e474c59ed8e30e1") + ); + // XcmPallet SafeXcmVersion + assert!( + whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d196323ae84c43568be0d1394d5d0d522c4") + ); + } + #[test] fn max_upward_message_size() { assert_eq!( diff --git a/runtime/polkadot/src/weights/pallet_xcm.rs b/runtime/polkadot/src/weights/pallet_xcm.rs index 214ec0920d75..abbd5b1f2b96 100644 --- a/runtime/polkadot/src/weights/pallet_xcm.rs +++ b/runtime/polkadot/src/weights/pallet_xcm.rs @@ -23,10 +23,9 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("polkadot-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet -// --chain=polkadot-dev // --steps=50 // --repeat=20 // --no-storage-info @@ -36,6 +35,10 @@ // --extrinsic=* // --execution=wasm // --wasm-execution=compiled +// --heap-pages=4096 +// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json +// --pallet=pallet_xcm +// --chain=polkadot-dev // --header=./file_header.txt // --output=./runtime/polkadot/src/weights/ @@ -56,10 +59,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -111,8 +110,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: XcmPallet SafeXcmVersion (r:0 w:1) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) fn force_default_xcm_version() -> Weight { // Proof Size summary in bytes: // Measured: `0` @@ -120,7 +117,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { // Minimum execution time: 2_769_000 picoseconds. Weight::from_parts(3_001_000, 0) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: XcmPallet VersionNotifiers (r:1 w:1) /// Proof Skipped: XcmPallet VersionNotifiers (max_values: None, max_size: None, mode: Measured) @@ -132,10 +128,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -160,10 +152,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -234,10 +222,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -283,10 +267,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) diff --git a/runtime/rococo/src/lib.rs b/runtime/rococo/src/lib.rs index 92fefd87db68..ba23a268f740 100644 --- a/runtime/rococo/src/lib.rs +++ b/runtime/rococo/src/lib.rs @@ -2204,6 +2204,7 @@ sp_api::impl_runtime_apis! { Vec, sp_runtime::RuntimeString, > { + use frame_support::traits::WhitelistedStorageKeys; use frame_benchmarking::{Benchmarking, BenchmarkBatch, TrackedStorageKey, BenchmarkError}; use frame_system_benchmarking::Pallet as SystemBench; use frame_benchmarking::baseline::Pallet as Baseline; @@ -2301,20 +2302,9 @@ sp_api::impl_runtime_apis! { } } - let whitelist: Vec = vec![ - // Block Number - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(), - // Total Issuance - hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(), - // Execution Phase - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(), - // Event Count - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(), - // System Events - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(), - // Treasury Account - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da95ecffd7b6c0f78751baa9d281e0bfa3a6d6f646c70792f74727372790000000000000000000000000000000000000000").to_vec().into(), - ]; + let mut whitelist: Vec = AllPalletsWithSystem::whitelisted_storage_keys(); + let treasury_key = frame_system::Account::::hashed_key_for(Treasury::account_id()); + whitelist.push(treasury_key.to_vec().into()); let mut batches = Vec::::new(); let params = (&config, &whitelist); @@ -2327,18 +2317,49 @@ sp_api::impl_runtime_apis! { } #[cfg(test)] -mod encoding_tests { +mod tests { + use std::collections::HashSet; + use super::*; + use frame_support::traits::WhitelistedStorageKeys; + use sp_core::hexdisplay::HexDisplay; #[test] - fn nis_hold_reason_encoding_is_correct() { - assert_eq!(RuntimeHoldReason::Nis(pallet_nis::HoldReason::NftReceipt).encode(), [38, 0]); - } -} + fn check_whitelist() { + let whitelist: HashSet = AllPalletsWithSystem::whitelisted_storage_keys() + .iter() + .map(|e| HexDisplay::from(&e.key).to_string()) + .collect(); -#[cfg(test)] -mod test { - use super::*; + // Block number + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac") + ); + // Total issuance + assert!( + whitelist.contains("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80") + ); + // Execution phase + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a") + ); + // Event count + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850") + ); + // System events + assert!( + whitelist.contains("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7") + ); + // XcmPallet VersionDiscoveryQueue + assert!( + whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d194a222ba0333561192e474c59ed8e30e1") + ); + // XcmPallet SafeXcmVersion + assert!( + whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d196323ae84c43568be0d1394d5d0d522c4") + ); + } #[test] fn max_upward_message_size() { @@ -2350,6 +2371,16 @@ mod test { } } +#[cfg(test)] +mod encoding_tests { + use super::*; + + #[test] + fn nis_hold_reason_encoding_is_correct() { + assert_eq!(RuntimeHoldReason::Nis(pallet_nis::HoldReason::NftReceipt).encode(), [38, 0]); + } +} + #[cfg(all(test, feature = "try-runtime"))] mod remote_tests { use super::*; diff --git a/runtime/rococo/src/weights/pallet_xcm.rs b/runtime/rococo/src/weights/pallet_xcm.rs index f24e3f10c2f7..43b4358b8903 100644 --- a/runtime/rococo/src/weights/pallet_xcm.rs +++ b/runtime/rococo/src/weights/pallet_xcm.rs @@ -23,16 +23,18 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet -// --chain=rococo-dev // --steps=50 // --repeat=20 -// --pallet=pallet_xcm // --extrinsic=* // --execution=wasm // --wasm-execution=compiled +// --heap-pages=4096 +// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json +// --pallet=pallet_xcm +// --chain=rococo-dev // --header=./file_header.txt // --output=./runtime/rococo/src/weights/ @@ -53,10 +55,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -106,8 +104,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: XcmPallet SafeXcmVersion (r:0 w:1) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) fn force_default_xcm_version() -> Weight { // Proof Size summary in bytes: // Measured: `0` @@ -115,7 +111,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { // Minimum execution time: 3_163_000 picoseconds. Weight::from_parts(3_298_000, 0) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: XcmPallet VersionNotifiers (r:1 w:1) /// Proof Skipped: XcmPallet VersionNotifiers (max_values: None, max_size: None, mode: Measured) @@ -127,10 +122,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -155,10 +146,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -229,10 +216,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -278,10 +261,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) diff --git a/runtime/westend/src/lib.rs b/runtime/westend/src/lib.rs index 4e633730e173..471570637e51 100644 --- a/runtime/westend/src/lib.rs +++ b/runtime/westend/src/lib.rs @@ -1891,6 +1891,7 @@ sp_api::impl_runtime_apis! { Vec, sp_runtime::RuntimeString, > { + use frame_support::traits::WhitelistedStorageKeys; use frame_benchmarking::{Benchmarking, BenchmarkBatch, TrackedStorageKey, BenchmarkError}; // Trying to add benchmarks directly to some pallets caused cyclic dependency issues. // To get around that, we separated the benchmarks into its own crate. @@ -2003,28 +2004,7 @@ sp_api::impl_runtime_apis! { type XcmBalances = pallet_xcm_benchmarks::fungible::Pallet::; type XcmGeneric = pallet_xcm_benchmarks::generic::Pallet::; - let whitelist: Vec = vec![ - // Block Number - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac").to_vec().into(), - // Total Issuance - hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(), - // Execution Phase - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(), - // Event Count - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(), - // System Events - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(), - // Treasury Account - hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da95ecffd7b6c0f78751baa9d281e0bfa3a6d6f646c70792f74727372790000000000000000000000000000000000000000").to_vec().into(), - // Dmp DownwardMessageQueueHeads - hex_literal::hex!("63f78c98723ddc9073523ef3beefda0c4d7fefc408aac59dbfe80a72ac8e3ce5").to_vec().into(), - // Dmp DownwardMessageQueues - hex_literal::hex!("63f78c98723ddc9073523ef3beefda0ca95dac46c07a40d91506e7637ec4ba57").to_vec().into(), - // Configuration ActiveConfig - hex_literal::hex!("06de3d8a54d27e44a9d5ce189618f22db4b49d95320d9021994c850f25b8e385").to_vec().into(), - // The transactional storage limit. - hex_literal::hex!("3a7472616e73616374696f6e5f6c6576656c3a").to_vec().into(), - ]; + let whitelist: Vec = AllPalletsWithSystem::whitelisted_storage_keys(); let mut batches = Vec::::new(); let params = (&config, &whitelist); diff --git a/runtime/westend/src/tests.rs b/runtime/westend/src/tests.rs index 8f835ea49a86..9aeca7ab8aec 100644 --- a/runtime/westend/src/tests.rs +++ b/runtime/westend/src/tests.rs @@ -16,7 +16,11 @@ //! Tests for the Westend Runtime Configuration +use std::collections::HashSet; + use crate::*; +use frame_support::traits::WhitelistedStorageKeys; +use sp_core::hexdisplay::HexDisplay; use xcm::latest::prelude::*; #[test] @@ -75,3 +79,28 @@ fn sanity_check_teleport_assets_weight() { assert!((weight * 50).all_lt(BlockWeights::get().max_block)); } + +#[test] +fn check_whitelist() { + let whitelist: HashSet = AllPalletsWithSystem::whitelisted_storage_keys() + .iter() + .map(|e| HexDisplay::from(&e.key).to_string()) + .collect(); + + // Block number + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef702a5c1b19ab7a04f536c519aca4983ac")); + // Total issuance + assert!(whitelist.contains("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80")); + // Execution phase + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a")); + // Event count + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850")); + // System events + assert!(whitelist.contains("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7")); + // Configuration ActiveConfig + assert!(whitelist.contains("06de3d8a54d27e44a9d5ce189618f22db4b49d95320d9021994c850f25b8e385")); + // XcmPallet VersionDiscoveryQueue + assert!(whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d194a222ba0333561192e474c59ed8e30e1")); + // XcmPallet SafeXcmVersion + assert!(whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d196323ae84c43568be0d1394d5d0d522c4")); +} diff --git a/runtime/westend/src/weights/pallet_xcm.rs b/runtime/westend/src/weights/pallet_xcm.rs index 6505276655e2..7f2a1de44e93 100644 --- a/runtime/westend/src/weights/pallet_xcm.rs +++ b/runtime/westend/src/weights/pallet_xcm.rs @@ -23,10 +23,9 @@ //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 // Executed Command: -// ./target/production/polkadot +// target/production/polkadot // benchmark // pallet -// --chain=westend-dev // --steps=50 // --repeat=20 // --no-storage-info @@ -36,6 +35,10 @@ // --extrinsic=* // --execution=wasm // --wasm-execution=compiled +// --heap-pages=4096 +// --json-file=/var/lib/gitlab-runner/builds/zyw4fam_/0/parity/mirrors/polkadot/.git/.artifacts/bench.json +// --pallet=pallet_xcm +// --chain=westend-dev // --header=./file_header.txt // --output=./runtime/westend/src/weights/ @@ -56,10 +59,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -111,8 +110,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: XcmPallet SafeXcmVersion (r:0 w:1) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) fn force_default_xcm_version() -> Weight { // Proof Size summary in bytes: // Measured: `0` @@ -120,7 +117,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { // Minimum execution time: 2_824_000 picoseconds. Weight::from_parts(2_935_000, 0) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: XcmPallet VersionNotifiers (r:1 w:1) /// Proof Skipped: XcmPallet VersionNotifiers (max_values: None, max_size: None, mode: Measured) @@ -132,10 +128,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -160,10 +152,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -234,10 +222,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) @@ -283,10 +267,6 @@ impl pallet_xcm::WeightInfo for WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) diff --git a/xcm/pallet-xcm/src/lib.rs b/xcm/pallet-xcm/src/lib.rs index c53c9119bbd2..5167d1a72dc2 100644 --- a/xcm/pallet-xcm/src/lib.rs +++ b/xcm/pallet-xcm/src/lib.rs @@ -521,6 +521,7 @@ pub mod pallet { /// Default version to encode XCM when latest version of destination is unknown. If `None`, /// then the destinations whose XCM version is unknown are considered unreachable. #[pallet::storage] + #[pallet::whitelist_storage] pub(super) type SafeXcmVersion = StorageValue<_, XcmVersion, OptionQuery>; /// The Latest versions that we know various locations support. @@ -571,6 +572,7 @@ pub mod pallet { /// the `u32` counter is the number of times that a send to the destination has been attempted, /// which is used as a prioritization. #[pallet::storage] + #[pallet::whitelist_storage] pub(super) type VersionDiscoveryQueue = StorageValue< _, BoundedVec<(VersionedMultiLocation, u32), VersionDiscoveryQueueSize>, From 37bb831237378cc541b2d3d67d0a477cb63166ca Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Sun, 2 Jul 2023 21:51:35 +0000 Subject: [PATCH 47/53] ".git/.scripts/commands/bench/bench.sh" xcm kusama pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 88 +++++++------------ 1 file changed, 34 insertions(+), 54 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 1abc6e2401a1..e1d9082af184 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-27, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-07-02, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 @@ -56,8 +56,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 24_218_000 picoseconds. - Weight::from_parts(24_985_000, 3593) + // Minimum execution time: 24_640_000 picoseconds. + Weight::from_parts(25_291_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -67,8 +67,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 52_173_000 picoseconds. - Weight::from_parts(53_082_000, 6196) + // Minimum execution time: 51_938_000 picoseconds. + Weight::from_parts(53_368_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -80,22 +80,18 @@ impl WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `312` + // Measured: `143` // Estimated: `6196` - // Minimum execution time: 78_383_000 picoseconds. - Weight::from_parts(80_342_000, 6196) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) + // Minimum execution time: 75_385_000 picoseconds. + Weight::from_parts(76_624_000, 6196) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: Benchmark Override (r:0 w:0) /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) @@ -112,35 +108,29 @@ impl WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) pub(crate) fn initiate_reserve_withdraw() -> Weight { // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 31_820_000 picoseconds. - Weight::from_parts(32_451_000, 3676) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) + // Measured: `42` + // Estimated: `3507` + // Minimum execution time: 29_312_000 picoseconds. + Weight::from_parts(29_777_000, 3507) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } /// Storage: System Account (r:1 w:1) /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` // Estimated: `3593` - // Minimum execution time: 22_630_000 picoseconds. - Weight::from_parts(23_452_000, 3593) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(2)) + // Minimum execution time: 22_820_000 picoseconds. + Weight::from_parts(23_329_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: System Account (r:1 w:1) /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) @@ -148,8 +138,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 25_624_000 picoseconds. - Weight::from_parts(26_291_000, 3593) + // Minimum execution time: 26_097_000 picoseconds. + Weight::from_parts(26_780_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -161,48 +151,38 @@ impl WeightInfo { /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 54_048_000 picoseconds. - Weight::from_parts(54_735_000, 3676) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) + // Measured: `42` + // Estimated: `3593` + // Minimum execution time: 51_776_000 picoseconds. + Weight::from_parts(52_870_000, 3593) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: System Account (r:1 w:1) /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) /// Storage: XcmPallet SupportedVersion (r:1 w:0) /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueues (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: - // Measured: `211` - // Estimated: `3676` - // Minimum execution time: 55_663_000 picoseconds. - Weight::from_parts(57_146_000, 3676) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) + // Measured: `42` + // Estimated: `3593` + // Minimum execution time: 53_577_000 picoseconds. + Weight::from_parts(54_409_000, 3593) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } } From 1541d37be8a879a7415852c4c4ae31c185d0764c Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Mon, 3 Jul 2023 13:58:24 +0000 Subject: [PATCH 48/53] ".git/.scripts/commands/bench/bench.sh" xcm kusama pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index e1d9082af184..c62a86d3b453 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-07-02, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-07-03, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 @@ -56,8 +56,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 24_640_000 picoseconds. - Weight::from_parts(25_291_000, 3593) + // Minimum execution time: 24_730_000 picoseconds. + Weight::from_parts(25_343_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -67,8 +67,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 51_938_000 picoseconds. - Weight::from_parts(53_368_000, 6196) + // Minimum execution time: 52_664_000 picoseconds. + Weight::from_parts(53_641_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -88,8 +88,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `143` // Estimated: `6196` - // Minimum execution time: 75_385_000 picoseconds. - Weight::from_parts(76_624_000, 6196) + // Minimum execution time: 75_792_000 picoseconds. + Weight::from_parts(77_577_000, 6196) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -116,8 +116,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `42` // Estimated: `3507` - // Minimum execution time: 29_312_000 picoseconds. - Weight::from_parts(29_777_000, 3507) + // Minimum execution time: 29_410_000 picoseconds. + Weight::from_parts(30_133_000, 3507) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -127,8 +127,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `103` // Estimated: `3593` - // Minimum execution time: 22_820_000 picoseconds. - Weight::from_parts(23_329_000, 3593) + // Minimum execution time: 23_318_000 picoseconds. + Weight::from_parts(23_737_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -138,8 +138,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 26_097_000 picoseconds. - Weight::from_parts(26_780_000, 3593) + // Minimum execution time: 26_277_000 picoseconds. + Weight::from_parts(26_773_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -159,8 +159,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `42` // Estimated: `3593` - // Minimum execution time: 51_776_000 picoseconds. - Weight::from_parts(52_870_000, 3593) + // Minimum execution time: 52_299_000 picoseconds. + Weight::from_parts(53_068_000, 3593) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -180,8 +180,8 @@ impl WeightInfo { // Proof Size summary in bytes: // Measured: `42` // Estimated: `3593` - // Minimum execution time: 53_577_000 picoseconds. - Weight::from_parts(54_409_000, 3593) + // Minimum execution time: 54_269_000 picoseconds. + Weight::from_parts(55_290_000, 3593) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) } From 76382a231157f35f2997c75f0b15993173cf2662 Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Mon, 17 Jul 2023 19:40:42 +0000 Subject: [PATCH 49/53] ".git/.scripts/commands/bench/bench.sh" xcm kusama pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 169 +++++++++--------- 1 file changed, 80 insertions(+), 89 deletions(-) diff --git a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index c62a86d3b453..07f3ccb48d92 100644 --- a/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/kusama/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,10 +17,10 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-07-03, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-07-17, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 +//! HOSTNAME: `runner-gghbxkbs-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("kusama-dev"), DB CACHE: 1024 // Executed Command: // target/production/polkadot @@ -29,7 +29,6 @@ // --steps=50 // --repeat=20 // --extrinsic=* -// --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 // --json-file=/builds/parity/mirrors/polkadot/.git/.artifacts/bench.json @@ -50,51 +49,49 @@ use core::marker::PhantomData; /// Weight functions for `pallet_xcm_benchmarks::fungible`. pub struct WeightInfo(PhantomData); impl WeightInfo { - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn withdraw_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 24_730_000 picoseconds. - Weight::from_parts(25_343_000, 3593) + // Minimum execution time: 23_950_000 picoseconds. + Weight::from_parts(24_720_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn transfer_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 52_664_000 picoseconds. - Weight::from_parts(53_641_000, 6196) + // Minimum execution time: 51_687_000 picoseconds. + Weight::from_parts(52_490_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `143` + // Measured: `177` // Estimated: `6196` - // Minimum execution time: 75_792_000 picoseconds. - Weight::from_parts(77_577_000, 6196) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(5)) + // Minimum execution time: 75_438_000 picoseconds. + Weight::from_parts(77_495_000, 6196) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } - /// Storage: Benchmark Override (r:0 w:0) - /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + /// Storage: `Benchmark::Override` (r:0 w:0) + /// Proof: `Benchmark::Override` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn reserve_asset_deposited() -> Weight { // Proof Size summary in bytes: // Measured: `0` @@ -102,87 +99,81 @@ impl WeightInfo { // Minimum execution time: 2_000_000_000_000 picoseconds. Weight::from_parts(2_000_000_000_000, 0) } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn initiate_reserve_withdraw() -> Weight { // Proof Size summary in bytes: - // Measured: `42` - // Estimated: `3507` - // Minimum execution time: 29_410_000 picoseconds. - Weight::from_parts(30_133_000, 3507) - .saturating_add(T::DbWeight::get().reads(5)) - .saturating_add(T::DbWeight::get().writes(3)) + // Measured: `76` + // Estimated: `3541` + // Minimum execution time: 28_370_000 picoseconds. + Weight::from_parts(29_100_000, 3541) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` // Estimated: `3593` - // Minimum execution time: 23_318_000 picoseconds. - Weight::from_parts(23_737_000, 3593) + // Minimum execution time: 23_041_000 picoseconds. + Weight::from_parts(23_433_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn deposit_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 26_277_000 picoseconds. - Weight::from_parts(26_773_000, 3593) + // Minimum execution time: 25_386_000 picoseconds. + Weight::from_parts(25_904_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `42` + // Measured: `76` // Estimated: `3593` - // Minimum execution time: 52_299_000 picoseconds. - Weight::from_parts(53_068_000, 3593) - .saturating_add(T::DbWeight::get().reads(6)) - .saturating_add(T::DbWeight::get().writes(4)) + // Minimum execution time: 50_645_000 picoseconds. + Weight::from_parts(51_719_000, 3593) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: - // Measured: `42` + // Measured: `76` // Estimated: `3593` - // Minimum execution time: 54_269_000 picoseconds. - Weight::from_parts(55_290_000, 3593) - .saturating_add(T::DbWeight::get().reads(6)) - .saturating_add(T::DbWeight::get().writes(4)) + // Minimum execution time: 53_055_000 picoseconds. + Weight::from_parts(54_214_000, 3593) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } } From 87b5fd9b04c6f67348a9ca5a69544d01955b6326 Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Mon, 17 Jul 2023 20:32:48 +0000 Subject: [PATCH 50/53] ".git/.scripts/commands/bench/bench.sh" xcm rococo pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 205 +++++++----------- 1 file changed, 84 insertions(+), 121 deletions(-) diff --git a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 8771cf7a02fd..59c49e4f8c82 100644 --- a/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/rococo/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,10 +17,10 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-27, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-07-17, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 +//! HOSTNAME: `runner-gghbxkbs-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("rococo-dev"), DB CACHE: 1024 // Executed Command: // target/production/polkadot @@ -29,7 +29,6 @@ // --steps=50 // --repeat=20 // --extrinsic=* -// --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 // --json-file=/builds/parity/mirrors/polkadot/.git/.artifacts/bench.json @@ -50,57 +49,49 @@ use core::marker::PhantomData; /// Weight functions for `pallet_xcm_benchmarks::fungible`. pub struct WeightInfo(PhantomData); impl WeightInfo { - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn withdraw_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 25_184_000 picoseconds. - Weight::from_parts(25_763_000, 3593) + // Minimum execution time: 24_892_000 picoseconds. + Weight::from_parts(25_219_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn transfer_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 52_392_000 picoseconds. - Weight::from_parts(53_032_000, 6196) + // Minimum execution time: 52_112_000 picoseconds. + Weight::from_parts(53_104_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Configuration ActiveConfig (r:1 w:0) - /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `666` + // Measured: `210` // Estimated: `6196` - // Minimum execution time: 79_960_000 picoseconds. - Weight::from_parts(82_422_000, 6196) - .saturating_add(T::DbWeight::get().reads(10)) - .saturating_add(T::DbWeight::get().writes(6)) + // Minimum execution time: 76_459_000 picoseconds. + Weight::from_parts(79_152_000, 6196) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } - /// Storage: Benchmark Override (r:0 w:0) - /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + /// Storage: `Benchmark::Override` (r:0 w:0) + /// Proof: `Benchmark::Override` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn reserve_asset_deposited() -> Weight { // Proof Size summary in bytes: // Measured: `0` @@ -108,109 +99,81 @@ impl WeightInfo { // Minimum execution time: 2_000_000_000_000 picoseconds. Weight::from_parts(2_000_000_000_000, 0) } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Configuration ActiveConfig (r:1 w:0) - /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn initiate_reserve_withdraw() -> Weight { // Proof Size summary in bytes: - // Measured: `565` - // Estimated: `4030` - // Minimum execution time: 34_401_000 picoseconds. - Weight::from_parts(35_053_000, 4030) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(4)) + // Measured: `109` + // Estimated: `3574` + // Minimum execution time: 29_734_000 picoseconds. + Weight::from_parts(30_651_000, 3574) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` // Estimated: `3593` - // Minimum execution time: 23_763_000 picoseconds. - Weight::from_parts(24_447_000, 3593) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(2)) + // Minimum execution time: 23_028_000 picoseconds. + Weight::from_parts(23_687_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn deposit_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 25_099_000 picoseconds. - Weight::from_parts(25_425_000, 3593) + // Minimum execution time: 26_399_000 picoseconds. + Weight::from_parts(27_262_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Configuration ActiveConfig (r:1 w:0) - /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `565` - // Estimated: `4030` - // Minimum execution time: 57_552_000 picoseconds. - Weight::from_parts(58_922_000, 4030) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(5)) + // Measured: `109` + // Estimated: `3593` + // Minimum execution time: 52_015_000 picoseconds. + Weight::from_parts(53_498_000, 3593) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Configuration ActiveConfig (r:1 w:0) - /// Proof Skipped: Configuration ActiveConfig (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: - // Measured: `565` - // Estimated: `4030` - // Minimum execution time: 58_641_000 picoseconds. - Weight::from_parts(60_736_000, 4030) - .saturating_add(T::DbWeight::get().reads(10)) - .saturating_add(T::DbWeight::get().writes(6)) + // Measured: `109` + // Estimated: `3593` + // Minimum execution time: 53_833_000 picoseconds. + Weight::from_parts(55_688_000, 3593) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } } From 06033d3bb06ff66b9b244b2848db1e0d9a1960ad Mon Sep 17 00:00:00 2001 From: command-bot <> Date: Mon, 17 Jul 2023 21:43:26 +0000 Subject: [PATCH 51/53] ".git/.scripts/commands/bench/bench.sh" xcm westend pallet_xcm_benchmarks::fungible --- .../xcm/pallet_xcm_benchmarks_fungible.rs | 197 ++++++++---------- 1 file changed, 84 insertions(+), 113 deletions(-) diff --git a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs index 658eaa248bf3..b92749bfa15b 100644 --- a/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs +++ b/runtime/westend/src/weights/xcm/pallet_xcm_benchmarks_fungible.rs @@ -17,10 +17,10 @@ //! Autogenerated weights for `pallet_xcm_benchmarks::fungible` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2023-06-27, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2023-07-17, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `runner-xerhrdyb-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` -//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 +//! HOSTNAME: `runner-gghbxkbs-project-163-concurrent-0`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` +//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("westend-dev"), DB CACHE: 1024 // Executed Command: // target/production/polkadot @@ -29,7 +29,6 @@ // --steps=50 // --repeat=20 // --extrinsic=* -// --execution=wasm // --wasm-execution=compiled // --heap-pages=4096 // --json-file=/builds/parity/mirrors/polkadot/.git/.artifacts/bench.json @@ -50,55 +49,49 @@ use core::marker::PhantomData; /// Weight functions for `pallet_xcm_benchmarks::fungible`. pub struct WeightInfo(PhantomData); impl WeightInfo { - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn withdraw_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `3593` - // Minimum execution time: 25_450_000 picoseconds. - Weight::from_parts(25_774_000, 3593) + // Minimum execution time: 24_887_000 picoseconds. + Weight::from_parts(25_361_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn transfer_asset() -> Weight { // Proof Size summary in bytes: // Measured: `101` // Estimated: `6196` - // Minimum execution time: 53_613_000 picoseconds. - Weight::from_parts(54_213_000, 6196) + // Minimum execution time: 52_408_000 picoseconds. + Weight::from_parts(53_387_000, 6196) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: System Account (r:2 w:2) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn transfer_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `270` + // Measured: `177` // Estimated: `6196` - // Minimum execution time: 77_943_000 picoseconds. - Weight::from_parts(79_070_000, 6196) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) + // Minimum execution time: 74_753_000 picoseconds. + Weight::from_parts(76_838_000, 6196) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(4)) } - /// Storage: Benchmark Override (r:0 w:0) - /// Proof Skipped: Benchmark Override (max_values: None, max_size: None, mode: Measured) + /// Storage: `Benchmark::Override` (r:0 w:0) + /// Proof: `Benchmark::Override` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn reserve_asset_deposited() -> Weight { // Proof Size summary in bytes: // Measured: `0` @@ -106,103 +99,81 @@ impl WeightInfo { // Minimum execution time: 2_000_000_000_000 picoseconds. Weight::from_parts(2_000_000_000_000, 0) } - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn initiate_reserve_withdraw() -> Weight { // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 30_917_000 picoseconds. - Weight::from_parts(31_560_000, 3634) - .saturating_add(T::DbWeight::get().reads(7)) - .saturating_add(T::DbWeight::get().writes(4)) + // Measured: `76` + // Estimated: `3541` + // Minimum execution time: 29_272_000 picoseconds. + Weight::from_parts(30_061_000, 3541) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(2)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn receive_teleported_asset() -> Weight { // Proof Size summary in bytes: // Measured: `103` // Estimated: `3593` - // Minimum execution time: 23_632_000 picoseconds. - Weight::from_parts(24_127_000, 3593) - .saturating_add(T::DbWeight::get().reads(2)) - .saturating_add(T::DbWeight::get().writes(2)) + // Minimum execution time: 23_112_000 picoseconds. + Weight::from_parts(23_705_000, 3593) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) pub(crate) fn deposit_asset() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3593` - // Minimum execution time: 26_677_000 picoseconds. - Weight::from_parts(27_157_000, 3593) + // Minimum execution time: 26_077_000 picoseconds. + Weight::from_parts(26_486_000, 3593) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn deposit_reserve_asset() -> Weight { // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 53_833_000 picoseconds. - Weight::from_parts(54_712_000, 3634) - .saturating_add(T::DbWeight::get().reads(8)) - .saturating_add(T::DbWeight::get().writes(5)) + // Measured: `76` + // Estimated: `3593` + // Minimum execution time: 51_022_000 picoseconds. + Weight::from_parts(52_498_000, 3593) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } - /// Storage: System Account (r:1 w:1) - /// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen) - /// Storage: Balances InactiveIssuance (r:1 w:1) - /// Proof: Balances InactiveIssuance (max_values: Some(1), max_size: Some(16), added: 511, mode: MaxEncodedLen) - /// Storage: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Proof Skipped: unknown `0x3a696e747261626c6f636b5f656e74726f7079` (r:1 w:1) - /// Storage: Dmp DeliveryFeeFactor (r:1 w:0) - /// Proof Skipped: Dmp DeliveryFeeFactor (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet SupportedVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SupportedVersion (max_values: None, max_size: None, mode: Measured) - /// Storage: XcmPallet VersionDiscoveryQueue (r:1 w:1) - /// Proof Skipped: XcmPallet VersionDiscoveryQueue (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: XcmPallet SafeXcmVersion (r:1 w:0) - /// Proof Skipped: XcmPallet SafeXcmVersion (max_values: Some(1), max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueues (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueues (max_values: None, max_size: None, mode: Measured) - /// Storage: Dmp DownwardMessageQueueHeads (r:1 w:1) - /// Proof Skipped: Dmp DownwardMessageQueueHeads (max_values: None, max_size: None, mode: Measured) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) + /// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0) + /// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `XcmPallet::SupportedVersion` (r:1 w:0) + /// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1) + /// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`) pub(crate) fn initiate_teleport() -> Weight { // Proof Size summary in bytes: - // Measured: `169` - // Estimated: `3634` - // Minimum execution time: 55_803_000 picoseconds. - Weight::from_parts(57_258_000, 3634) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(6)) + // Measured: `76` + // Estimated: `3593` + // Minimum execution time: 53_062_000 picoseconds. + Weight::from_parts(54_300_000, 3593) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) } } From 3a29cb627ae86fdd4fef0e9874d2d14c9cc5ddb0 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Tue, 18 Jul 2023 16:02:26 -0300 Subject: [PATCH 52/53] Fix spellchecker issues --- node/collation-generation/src/lib.rs | 2 +- node/core/dispute-coordinator/src/initialized.rs | 2 +- node/core/dispute-coordinator/src/metrics.rs | 4 ++-- .../src/participation/queues/tests.rs | 6 +++--- node/core/dispute-coordinator/src/scraping/mod.rs | 8 ++++---- node/core/pvf/common/src/worker/mod.rs | 2 +- node/core/pvf/common/src/worker/security.rs | 2 +- node/network/approval-distribution/src/lib.rs | 2 +- node/service/src/fake_runtime_api.rs | 6 +++--- node/subsystem-util/src/nesting_sender.rs | 2 +- node/subsystem-util/src/reputation.rs | 2 +- runtime/parachains/src/runtime_api_impl/v5.rs | 2 +- scripts/ci/gitlab/spellcheck.toml | 9 ++++++++- xcm/src/v3/mod.rs | 4 ++-- xcm/src/v3/multiasset.rs | 2 +- xcm/src/v3/traits.rs | 2 +- xcm/xcm-builder/src/barriers.rs | 2 +- xcm/xcm-builder/src/location_conversion.rs | 12 ++++++------ xcm/xcm-builder/src/origin_aliases.rs | 6 +++--- xcm/xcm-builder/src/pay.rs | 8 ++++---- xcm/xcm-builder/src/process_xcm_message.rs | 2 +- 21 files changed, 47 insertions(+), 40 deletions(-) diff --git a/node/collation-generation/src/lib.rs b/node/collation-generation/src/lib.rs index 03935732d719..02a0e8df8f61 100644 --- a/node/collation-generation/src/lib.rs +++ b/node/collation-generation/src/lib.rs @@ -25,7 +25,7 @@ //! * Determine if the para is scheduled on any core by fetching the `availability_cores` Runtime API. //! * Use the Runtime API subsystem to fetch the full validation data. //! * Invoke the `collator`, and use its outputs to produce a [`CandidateReceipt`], signed with the configuration's `key`. -//! * Dispatch a [`CollatorProtocolMessage::DistributeCollation`](receipt, pov)`. +//! * Dispatch a [`CollatorProtocolMessage::DistributeCollation`]`(receipt, pov)`. #![deny(missing_docs)] diff --git a/node/core/dispute-coordinator/src/initialized.rs b/node/core/dispute-coordinator/src/initialized.rs index 9efd47946790..2a1d8fd4b83c 100644 --- a/node/core/dispute-coordinator/src/initialized.rs +++ b/node/core/dispute-coordinator/src/initialized.rs @@ -92,7 +92,7 @@ pub struct InitialData { pub(crate) struct Initialized { keystore: Arc, runtime_info: RuntimeInfo, - /// This is the highest `SessionIndex` seen via `ActiveLeavesUpdate`. It doen't matter if it was + /// This is the highest `SessionIndex` seen via `ActiveLeavesUpdate`. It doesn't matter if it was /// cached successfully or not. It is used to detect ancient disputes. highest_session_seen: SessionIndex, /// Will be set to `true` if an error occured during the last caching attempt diff --git a/node/core/dispute-coordinator/src/metrics.rs b/node/core/dispute-coordinator/src/metrics.rs index 7c13614ff885..c9454fb1d3ce 100644 --- a/node/core/dispute-coordinator/src/metrics.rs +++ b/node/core/dispute-coordinator/src/metrics.rs @@ -123,14 +123,14 @@ impl Metrics { .map(|metrics| metrics.participation_pipeline_durations.start_timer()) } - /// Set the priority_queue_size metric + /// Set the `priority_queue_size` metric pub fn report_priority_queue_size(&self, size: u64) { if let Some(metrics) = &self.0 { metrics.participation_priority_queue_size.set(size); } } - /// Set the best_effort_queue_size metric + /// Set the `best_effort_queue_size` metric pub fn report_best_effort_queue_size(&self, size: u64) { if let Some(metrics) = &self.0 { metrics.participation_best_effort_queue_size.set(size); diff --git a/node/core/dispute-coordinator/src/participation/queues/tests.rs b/node/core/dispute-coordinator/src/participation/queues/tests.rs index ec549d1f5130..8293a935d11a 100644 --- a/node/core/dispute-coordinator/src/participation/queues/tests.rs +++ b/node/core/dispute-coordinator/src/participation/queues/tests.rs @@ -38,9 +38,9 @@ fn make_dummy_comparator( CandidateComparator::new_dummy(relay_parent, *req.candidate_hash()) } -/// Make a partial clone of the given ParticipationRequest, just missing -/// the request_timer field. We prefer this helper to implementing Clone -/// for ParticipationRequest, since we only clone requests in tests. +/// Make a partial clone of the given `ParticipationRequest`, just missing +/// the `request_timer` field. We prefer this helper to implementing Clone +/// for `ParticipationRequest`, since we only clone requests in tests. fn clone_request(request: &ParticipationRequest) -> ParticipationRequest { ParticipationRequest { candidate_receipt: request.candidate_receipt.clone(), diff --git a/node/core/dispute-coordinator/src/scraping/mod.rs b/node/core/dispute-coordinator/src/scraping/mod.rs index 01240a7e8b4b..a1e385b5ff85 100644 --- a/node/core/dispute-coordinator/src/scraping/mod.rs +++ b/node/core/dispute-coordinator/src/scraping/mod.rs @@ -57,13 +57,13 @@ const LRU_OBSERVED_BLOCKS_CAPACITY: NonZeroUsize = match NonZeroUsize::new(20) { None => panic!("Observed blocks cache size must be non-zero"), }; -/// ScrapedUpdates +/// `ScrapedUpdates` /// -/// Updates to on_chain_votes and included receipts for new active leaf and its unprocessed +/// Updates to `on_chain_votes` and included receipts for new active leaf and its unprocessed /// ancestors. /// -/// on_chain_votes: New votes as seen on chain -/// included_receipts: Newly included parachain block candidate receipts as seen on chain +/// `on_chain_votes`: New votes as seen on chain +/// `included_receipts`: Newly included parachain block candidate receipts as seen on chain pub struct ScrapedUpdates { pub on_chain_votes: Vec, pub included_receipts: Vec, diff --git a/node/core/pvf/common/src/worker/mod.rs b/node/core/pvf/common/src/worker/mod.rs index 458dd3157e2a..3a0dd85089e1 100644 --- a/node/core/pvf/common/src/worker/mod.rs +++ b/node/core/pvf/common/src/worker/mod.rs @@ -178,7 +178,7 @@ pub fn stringify_panic_payload(payload: Box) -> String /// In case of node and worker version mismatch (as a result of in-place upgrade), send `SIGTERM` /// to the node to tear it down and prevent it from raising disputes on valid candidates. Node -/// restart should be handled by the node owner. As node exits, unix sockets opened to workers +/// restart should be handled by the node owner. As node exits, Unix sockets opened to workers /// get closed by the OS and other workers receive error on socket read and also exit. Preparation /// jobs are written to the temporary files that are renamed to real artifacts on the node side, so /// no leftover artifacts are possible. diff --git a/node/core/pvf/common/src/worker/security.rs b/node/core/pvf/common/src/worker/security.rs index 5ba42915238c..6c5f96e0b5db 100644 --- a/node/core/pvf/common/src/worker/security.rs +++ b/node/core/pvf/common/src/worker/security.rs @@ -94,7 +94,7 @@ pub mod landlock { } } - /// Basaed on the given `status`, returns a single bool indicating whether the given landlock + /// Based on the given `status`, returns a single bool indicating whether the given landlock /// ABI is fully enabled on the current Linux environment. pub fn status_is_fully_enabled( status: &Result>, diff --git a/node/network/approval-distribution/src/lib.rs b/node/network/approval-distribution/src/lib.rs index 79aa090a140f..14196a13d688 100644 --- a/node/network/approval-distribution/src/lib.rs +++ b/node/network/approval-distribution/src/lib.rs @@ -186,7 +186,7 @@ struct State { /// Config for aggression. aggression_config: AggressionConfig, - /// HashMap from active leaves to spans + /// `HashMap` from active leaves to spans spans: HashMap, /// Current approval checking finality lag. diff --git a/node/service/src/fake_runtime_api.rs b/node/service/src/fake_runtime_api.rs index f4864d5c2010..f9d7799d8262 100644 --- a/node/service/src/fake_runtime_api.rs +++ b/node/service/src/fake_runtime_api.rs @@ -14,9 +14,9 @@ // You should have received a copy of the GNU General Public License // along with Polkadot. If not, see . -//! Provides "fake" runtime api implementations +//! Provides "fake" runtime API implementations //! -//! These are used to provide a type that implements these runtime apis without requiring to import the native runtimes. +//! These are used to provide a type that implements these runtime APIs without requiring to import the native runtimes. use beefy_primitives::crypto::{AuthorityId as BeefyId, Signature as BeefySignature}; use grandpa_primitives::AuthorityId as GrandpaId; @@ -40,7 +40,7 @@ use sp_weights::Weight; use std::collections::BTreeMap; sp_api::decl_runtime_apis! { - /// This runtime api is only implemented for the test runtime! + /// This runtime API is only implemented for the test runtime! pub trait GetLastTimestamp { /// Returns the last timestamp of a runtime. fn get_last_timestamp() -> u64; diff --git a/node/subsystem-util/src/nesting_sender.rs b/node/subsystem-util/src/nesting_sender.rs index 97c95aae419e..4417efbefb04 100644 --- a/node/subsystem-util/src/nesting_sender.rs +++ b/node/subsystem-util/src/nesting_sender.rs @@ -81,7 +81,7 @@ //! this approach to put back pressure on only a single source (as all are the same). If a module //! has a task that requires this, it indeed has to spawn a long running task which can do the //! back-pressure on that message source or we make it its own subsystem. This is just one of the -//! situations that justifies the complexity of asynchronism. +//! situations that justifies the complexity of asynchrony. use std::{convert::identity, sync::Arc}; diff --git a/node/subsystem-util/src/reputation.rs b/node/subsystem-util/src/reputation.rs index d1010f000ed5..09c00bb4688a 100644 --- a/node/subsystem-util/src/reputation.rs +++ b/node/subsystem-util/src/reputation.rs @@ -42,7 +42,7 @@ impl Default for ReputationAggregator { } impl ReputationAggregator { - /// New ReputationAggregator + /// New `ReputationAggregator` /// /// # Arguments /// diff --git a/runtime/parachains/src/runtime_api_impl/v5.rs b/runtime/parachains/src/runtime_api_impl/v5.rs index 7708bbd69b73..1257c0c91702 100644 --- a/runtime/parachains/src/runtime_api_impl/v5.rs +++ b/runtime/parachains/src/runtime_api_impl/v5.rs @@ -11,7 +11,7 @@ // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. -//! A module exporting runtime API implementation functions for all runtime APIs using v5 +//! A module exporting runtime API implementation functions for all runtime APIs using `v5` //! primitives. //! //! Runtimes implementing the v2 runtime API are recommended to forward directly to these diff --git a/scripts/ci/gitlab/spellcheck.toml b/scripts/ci/gitlab/spellcheck.toml index 025c7a0a461b..636cafa2cc4e 100644 --- a/scripts/ci/gitlab/spellcheck.toml +++ b/scripts/ci/gitlab/spellcheck.toml @@ -21,7 +21,14 @@ transform_regex = [ # single char `=` `>` `%` .. "^=|>|<|%$", # 22_100 - "^(?:[0-9]+_)+[0-9]+$" + "^(?:[0-9]+_)+[0-9]+$", +# V5, v5, P1.2, etc + "[A-Za-z][0-9]", +# ~50 + "~[0-9]+", + "ABI", + "bool", + "sigil", ] allow_concatenation = true allow_dashes = true diff --git a/xcm/src/v3/mod.rs b/xcm/src/v3/mod.rs index 7e28c0cac652..b1d134ae082c 100644 --- a/xcm/src/v3/mod.rs +++ b/xcm/src/v3/mod.rs @@ -337,12 +337,12 @@ impl TryFrom for WeightLimit { /// Contextual data pertaining to a specific list of XCM instructions. #[derive(Clone, Eq, PartialEq, Encode, Decode, Debug)] pub struct XcmContext { - /// The current value of the Origin register of the XCVM. + /// The current value of the Origin register of the `XCVM`. pub origin: Option, /// The identity of the XCM; this may be a hash of its versioned encoding but could also be /// a high-level identity set by an appropriate barrier. pub message_id: XcmHash, - /// The current value of the Topic register of the XCVM. + /// The current value of the Topic register of the `XCVM`. pub topic: Option<[u8; 32]>, } diff --git a/xcm/src/v3/multiasset.rs b/xcm/src/v3/multiasset.rs index 06cd2c8b5b82..a7a658f06017 100644 --- a/xcm/src/v3/multiasset.rs +++ b/xcm/src/v3/multiasset.rs @@ -406,7 +406,7 @@ pub struct MultiAsset { /// The overall asset identity (aka *class*, in the case of a non-fungible). pub id: AssetId, /// The fungibility of the asset, which contains either the amount (in the case of a fungible - /// asset) or the *insance ID`, the secondary asset identifier. + /// asset) or the *instance ID`, the secondary asset identifier. pub fun: Fungibility, } diff --git a/xcm/src/v3/traits.rs b/xcm/src/v3/traits.rs index 0f4c87ac6ec0..966fb724ed11 100644 --- a/xcm/src/v3/traits.rs +++ b/xcm/src/v3/traits.rs @@ -510,7 +510,7 @@ pub type SendResult = result::Result<(T, MultiAssets), SendError>; /// # } /// ``` pub trait SendXcm { - /// Intermediate value which connects the two phaases of the send operation. + /// Intermediate value which connects the two phases of the send operation. type Ticket; /// Check whether the given `_message` is deliverable to the given `_destination` and if so diff --git a/xcm/xcm-builder/src/barriers.rs b/xcm/xcm-builder/src/barriers.rs index c29dd6c685ae..13c1caca5ff6 100644 --- a/xcm/xcm-builder/src/barriers.rs +++ b/xcm/xcm-builder/src/barriers.rs @@ -255,7 +255,7 @@ where /// Allows execution from any origin that is contained in `T` (i.e. `T::Contains(origin)`). /// -/// Use only for executions from completely trusted origins, from which no unpermissioned messages +/// Use only for executions from completely trusted origins, from which no permissionless messages /// can be sent. pub struct AllowUnpaidExecutionFrom(PhantomData); impl> ShouldExecute for AllowUnpaidExecutionFrom { diff --git a/xcm/xcm-builder/src/location_conversion.rs b/xcm/xcm-builder/src/location_conversion.rs index dc327c08d067..3a95884328a1 100644 --- a/xcm/xcm-builder/src/location_conversion.rs +++ b/xcm/xcm-builder/src/location_conversion.rs @@ -192,7 +192,7 @@ impl LegacyDescribeForeignChainAccount { } } -/// This is deprecated in favour of the more modular `HashedDescription` converter. If +/// This is deprecated in favor of the more modular `HashedDescription` converter. If /// your chain has previously used this, then you can retain backwards compatibility using /// `HashedDescription` and a tuple with `LegacyDescribeForeignChainAccount` as the first /// element. For example: @@ -235,12 +235,12 @@ impl LegacyDescribeForeignChainAccount { /// same plane. So, it is important which chain account A acts from. /// E.g. /// * From P1.2 A will act as -/// * hash(ParaPrefix, A, 1, 1) on P1.2 -/// * hash(ParaPrefix, A, 1, 0) on P1 +/// * hash(`ParaPrefix`, A, 1, 1) on P1.2 +/// * hash(`ParaPrefix`, A, 1, 0) on P1 /// * From P1 A will act as -/// * hash(RelayPrefix, A, 1) on P1.2 & P1.1 -/// * hash(ParaPrefix, A, 1, 1) on P2 -/// * hash(ParaPrefix, A, 1, 0) on R +/// * hash(`RelayPrefix`, A, 1) on P1.2 & P1.1 +/// * hash(`ParaPrefix`, A, 1, 1) on P2 +/// * hash(`ParaPrefix`, A, 1, 0) on R /// /// Note that the alias accounts have overlaps but never on the same /// chain when the sender comes from different chains. diff --git a/xcm/xcm-builder/src/origin_aliases.rs b/xcm/xcm-builder/src/origin_aliases.rs index d9e3ee3dfc4f..12bcdad3dfea 100644 --- a/xcm/xcm-builder/src/origin_aliases.rs +++ b/xcm/xcm-builder/src/origin_aliases.rs @@ -14,15 +14,15 @@ // You should have received a copy of the GNU General Public License // along with Polkadot. If not, see . -//! Implementation for ContainsPair. +//! Implementation for `ContainsPair`. use frame_support::traits::{Contains, ContainsPair}; use sp_std::marker::PhantomData; use xcm::latest::prelude::*; -/// Alias a Foreign AccountId32 with a local AccountId32 if the Foreign AccountId32 matches the `Prefix` pattern. +/// Alias a Foreign `AccountId32` with a local `AccountId32` if the foreign `AccountId32` matches the `Prefix` pattern. /// -/// Requires that the prefixed origin AccountId32 matches the target AccountId32. +/// Requires that the prefixed origin `AccountId32` matches the target `AccountId32`. pub struct AliasForeignAccountId32(PhantomData); impl> ContainsPair for AliasForeignAccountId32 diff --git a/xcm/xcm-builder/src/pay.rs b/xcm/xcm-builder/src/pay.rs index 77c082e2f25b..e36d26e425be 100644 --- a/xcm/xcm-builder/src/pay.rs +++ b/xcm/xcm-builder/src/pay.rs @@ -151,10 +151,10 @@ impl< } } -/// Specialization of the [PayOverXcm] trait to allow `[u8; 32]`-based `AccountId` values to be +/// Specialization of the [`PayOverXcm`] trait to allow `[u8; 32]`-based `AccountId` values to be /// paid on a remote chain. /// -/// Implementation of the [frame_support::traits::tokens::Pay] trait, to allow +/// Implementation of the [`frame_support::traits::tokens::Pay`] trait, to allow /// for XCM payments of a given `Balance` of `AssetKind` existing on a `DestinationChain` under /// ownership of some `Interior` location of the local chain to a particular `Beneficiary`. /// @@ -184,7 +184,7 @@ pub type PayAccountId32OnChainOverXcm< FixedLocation, >; -/// Simple struct which contains both an XCM `location` and `asset_id` to identift an asset which +/// Simple struct which contains both an XCM `location` and `asset_id` to identify an asset which /// exists on some chain. pub struct LocatableAssetId { /// The asset's ID. @@ -193,7 +193,7 @@ pub struct LocatableAssetId { pub location: MultiLocation, } -/// Adapter `struct` which implements a conversion from any `AssetKind` into a [LocatableAsset] +/// Adapter `struct` which implements a conversion from any `AssetKind` into a [`LocatableAsset`] /// value using a fixed `Location` for the `location` field. pub struct FixedLocation(sp_std::marker::PhantomData); impl, AssetKind: Into> Convert diff --git a/xcm/xcm-builder/src/process_xcm_message.rs b/xcm/xcm-builder/src/process_xcm_message.rs index 1d5343c5ac98..8130d1732935 100644 --- a/xcm/xcm-builder/src/process_xcm_message.rs +++ b/xcm/xcm-builder/src/process_xcm_message.rs @@ -26,7 +26,7 @@ use sp_std::{fmt::Debug, marker::PhantomData}; use sp_weights::{Weight, WeightMeter}; use xcm::prelude::*; -/// A message processor that delegates execution to an [XcmExecutor]. +/// A message processor that delegates execution to an [`XcmExecutor`]. pub struct ProcessXcmMessage( PhantomData<(MessageOrigin, XcmExecutor, Call)>, ); From 0aa22d0726eb70f597e1e454d449dce68a2db317 Mon Sep 17 00:00:00 2001 From: Francisco Aguirre Date: Wed, 19 Jul 2023 10:40:53 -0300 Subject: [PATCH 53/53] Remove unused migration code --- runtime/kusama/src/tests.rs | 8 -------- runtime/polkadot/src/lib.rs | 8 -------- runtime/rococo/src/lib.rs | 9 --------- 3 files changed, 25 deletions(-) diff --git a/runtime/kusama/src/tests.rs b/runtime/kusama/src/tests.rs index c4f1d5a6a40e..5383e2824687 100644 --- a/runtime/kusama/src/tests.rs +++ b/runtime/kusama/src/tests.rs @@ -151,14 +151,6 @@ fn call_size() { RuntimeCall::assert_size_under(230); } -#[test] -fn max_upward_message_size() { - assert_eq!( - ump_migrations::MAX_UPWARD_MESSAGE_SIZE, - pallet_message_queue::MaxMessageLenOf::::get() - ); -} - #[test] fn check_whitelist() { let whitelist: HashSet = AllPalletsWithSystem::whitelisted_storage_keys() diff --git a/runtime/polkadot/src/lib.rs b/runtime/polkadot/src/lib.rs index 8be3d720f171..55ddb4707791 100644 --- a/runtime/polkadot/src/lib.rs +++ b/runtime/polkadot/src/lib.rs @@ -2422,14 +2422,6 @@ mod test { whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d196323ae84c43568be0d1394d5d0d522c4") ); } - - #[test] - fn max_upward_message_size() { - assert_eq!( - ump_migrations::MAX_UPWARD_MESSAGE_SIZE, - pallet_message_queue::MaxMessageLenOf::::get() - ); - } } #[cfg(test)] diff --git a/runtime/rococo/src/lib.rs b/runtime/rococo/src/lib.rs index f16fa51983b2..9800fe0ff754 100644 --- a/runtime/rococo/src/lib.rs +++ b/runtime/rococo/src/lib.rs @@ -2242,15 +2242,6 @@ mod tests { whitelist.contains("1405f2411d0af5a7ff397e7c9dc68d196323ae84c43568be0d1394d5d0d522c4") ); } - - #[test] - fn max_upward_message_size() { - use sp_core::Get; - assert_eq!( - ump_migrations::MAX_UPWARD_MESSAGE_SIZE, - pallet_message_queue::MaxMessageLenOf::::get() - ); - } } #[cfg(test)]