diff --git a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_staking_async.rs b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_staking_async.rs index b9a7783696006..b3a6f31b048a2 100644 --- a/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_staking_async.rs +++ b/cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_staking_async.rs @@ -15,10 +15,10 @@ //! Autogenerated weights for `pallet_staking_async` //! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2025-12-30, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 53.0.0 +//! DATE: 2026-02-04, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `73347b332137`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` +//! HOSTNAME: `75dbeac523b6`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` //! WASM-EXECUTION: `Compiled`, CHAIN: `None`, DB CACHE: 1024 // Executed Command: @@ -66,10 +66,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) fn bond() -> Weight { // Proof Size summary in bytes: - // Measured: `6793` + // Measured: `6813` // Estimated: `4218` - // Minimum execution time: 152_824_000 picoseconds. - Weight::from_parts(156_739_000, 0) + // Minimum execution time: 148_479_000 picoseconds. + Weight::from_parts(154_412_000, 0) .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) @@ -94,10 +94,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) fn bond_extra() -> Weight { // Proof Size summary in bytes: - // Measured: `8254` + // Measured: `8274` // Estimated: `8877` - // Minimum execution time: 9_652_949_000 picoseconds. - Weight::from_parts(12_848_087_000, 0) + // Minimum execution time: 8_768_396_000 picoseconds. + Weight::from_parts(10_330_197_000, 0) .saturating_add(Weight::from_parts(0, 8877)) .saturating_add(T::DbWeight::get().reads(12)) .saturating_add(T::DbWeight::get().writes(7)) @@ -110,10 +110,12 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) /// Storage: `Staking::MinNominatorBond` (r:1 w:0) /// Proof: `Staking::MinNominatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) - /// Storage: `Staking::AreNominatorsSlashable` (r:1 w:0) - /// Proof: `Staking::AreNominatorsSlashable` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) /// Storage: `Staking::ActiveEra` (r:1 w:0) /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `MaxEncodedLen`) + /// Storage: `Staking::LastValidatorEra` (r:1 w:0) + /// Proof: `Staking::LastValidatorEra` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `Staking::AreNominatorsSlashable` (r:1 w:0) + /// Proof: `Staking::AreNominatorsSlashable` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) /// Storage: `Staking::VirtualStakers` (r:1 w:0) /// Proof: `Staking::VirtualStakers` (`max_values`: None, `max_size`: Some(40), added: 2515, mode: `MaxEncodedLen`) /// Storage: `Balances::Holds` (r:1 w:0) @@ -126,12 +128,12 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) fn unbond() -> Weight { // Proof Size summary in bytes: - // Measured: `8402` + // Measured: `8435` // Estimated: `8877` - // Minimum execution time: 10_094_134_000 picoseconds. - Weight::from_parts(11_660_161_000, 0) + // Minimum execution time: 6_772_963_000 picoseconds. + Weight::from_parts(8_380_016_000, 0) .saturating_add(Weight::from_parts(0, 8877)) - .saturating_add(T::DbWeight::get().reads(14)) + .saturating_add(T::DbWeight::get().reads(15)) .saturating_add(T::DbWeight::get().writes(6)) } /// Storage: `Staking::Ledger` (r:1 w:1) @@ -158,10 +160,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `DelegatedStaking::Agents` (`max_values`: None, `max_size`: Some(120), added: 2595, mode: `MaxEncodedLen`) fn withdraw_unbonded_update() -> Weight { // Proof Size summary in bytes: - // Measured: `7393` + // Measured: `7413` // Estimated: `6696` - // Minimum execution time: 180_198_000 picoseconds. - Weight::from_parts(187_893_000, 0) + // Minimum execution time: 169_983_000 picoseconds. + Weight::from_parts(174_443_000, 0) .saturating_add(Weight::from_parts(0, 6696)) .saturating_add(T::DbWeight::get().reads(11)) .saturating_add(T::DbWeight::get().writes(2)) @@ -200,15 +202,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) /// Storage: `Staking::Payee` (r:0 w:1) /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) + /// Storage: `Staking::LastValidatorEra` (r:0 w:1) + /// Proof: `Staking::LastValidatorEra` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) fn withdraw_unbonded_kill() -> Weight { // Proof Size summary in bytes: - // Measured: `8340` + // Measured: `8360` // Estimated: `6696` - // Minimum execution time: 11_837_120_000 picoseconds. - Weight::from_parts(16_508_868_000, 0) + // Minimum execution time: 8_213_582_000 picoseconds. + Weight::from_parts(10_806_637_000, 0) .saturating_add(Weight::from_parts(0, 6696)) .saturating_add(T::DbWeight::get().reads(17)) - .saturating_add(T::DbWeight::get().writes(11)) + .saturating_add(T::DbWeight::get().writes(12)) } /// Storage: `Staking::Ledger` (r:1 w:0) /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) @@ -236,10 +240,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::CounterForValidators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn validate() -> Weight { // Proof Size summary in bytes: - // Measured: `9885` + // Measured: `9905` // Estimated: `4218` - // Minimum execution time: 160_960_000 picoseconds. - Weight::from_parts(169_897_000, 0) + // Minimum execution time: 157_547_000 picoseconds. + Weight::from_parts(162_977_000, 0) .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(12)) .saturating_add(T::DbWeight::get().writes(5)) @@ -253,13 +257,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `k` is `[1, 128]`. fn kick(k: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `12187 + k * (1121 ±0)` + // Measured: `12207 + k * (1121 ±0)` // Estimated: `4218 + k * (3033 ±0)` - // Minimum execution time: 112_128_000 picoseconds. - Weight::from_parts(150_312_691, 0) + // Minimum execution time: 95_868_000 picoseconds. + Weight::from_parts(85_408_591, 0) .saturating_add(Weight::from_parts(0, 4218)) - // Standard Error: 39_948 - .saturating_add(Weight::from_parts(18_937_703, 0).saturating_mul(k.into())) + // Standard Error: 35_128 + .saturating_add(Weight::from_parts(16_893_058, 0).saturating_mul(k.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(k.into()))) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(k.into()))) @@ -292,13 +296,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `n` is `[1, 16]`. fn nominate(n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `5074 + n * (68 ±0)` + // Measured: `5094 + n * (68 ±0)` // Estimated: `6248 + n * (2520 ±0)` - // Minimum execution time: 6_400_313_000 picoseconds. - Weight::from_parts(11_995_370_368, 0) + // Minimum execution time: 3_915_622_000 picoseconds. + Weight::from_parts(9_358_633_135, 0) .saturating_add(Weight::from_parts(0, 6248)) - // Standard Error: 11_519_980 - .saturating_add(Weight::from_parts(188_097_202, 0).saturating_mul(n.into())) + // Standard Error: 10_758_800 + .saturating_add(Weight::from_parts(128_769_289, 0).saturating_mul(n.into())) .saturating_add(T::DbWeight::get().reads(13)) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(n.into()))) .saturating_add(T::DbWeight::get().writes(6)) @@ -324,10 +328,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn chill() -> Weight { // Proof Size summary in bytes: - // Measured: `5217` + // Measured: `5237` // Estimated: `6248` - // Minimum execution time: 6_784_259_000 picoseconds. - Weight::from_parts(11_202_862_000, 0) + // Minimum execution time: 4_296_652_000 picoseconds. + Weight::from_parts(5_364_675_000, 0) .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(10)) .saturating_add(T::DbWeight::get().writes(6)) @@ -340,10 +344,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) fn set_payee() -> Weight { // Proof Size summary in bytes: - // Measured: `4040` + // Measured: `4060` // Estimated: `4218` - // Minimum execution time: 65_476_000 picoseconds. - Weight::from_parts(69_808_000, 0) + // Minimum execution time: 58_690_000 picoseconds. + Weight::from_parts(61_361_000, 0) .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -356,10 +360,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) fn update_payee() -> Weight { // Proof Size summary in bytes: - // Measured: `5712` + // Measured: `5732` // Estimated: `4218` - // Minimum execution time: 82_124_000 picoseconds. - Weight::from_parts(87_015_000, 0) + // Minimum execution time: 71_527_000 picoseconds. + Weight::from_parts(74_297_000, 0) .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(1)) @@ -370,10 +374,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) fn set_controller() -> Weight { // Proof Size summary in bytes: - // Measured: `5383` + // Measured: `5403` // Estimated: `7446` - // Minimum execution time: 80_885_000 picoseconds. - Weight::from_parts(84_849_000, 0) + // Minimum execution time: 73_043_000 picoseconds. + Weight::from_parts(76_801_000, 0) .saturating_add(Weight::from_parts(0, 7446)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) @@ -384,8 +388,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 5_412_000 picoseconds. - Weight::from_parts(6_116_000, 0) + // Minimum execution time: 3_656_000 picoseconds. + Weight::from_parts(3_972_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -395,8 +399,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 23_694_000 picoseconds. - Weight::from_parts(25_770_000, 0) + // Minimum execution time: 20_178_000 picoseconds. + Weight::from_parts(21_307_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -406,8 +410,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 22_468_000 picoseconds. - Weight::from_parts(24_741_000, 0) + // Minimum execution time: 20_064_000 picoseconds. + Weight::from_parts(21_212_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -417,8 +421,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 24_145_000 picoseconds. - Weight::from_parts(26_233_000, 0) + // Minimum execution time: 20_256_000 picoseconds. + Weight::from_parts(21_568_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -429,11 +433,11 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_826_000 picoseconds. - Weight::from_parts(3_433_272, 0) + // Minimum execution time: 3_855_000 picoseconds. + Weight::from_parts(4_789_713, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 967 - .saturating_add(Weight::from_parts(17_572, 0).saturating_mul(v.into())) + // Standard Error: 2_363 + .saturating_add(Weight::from_parts(30_014, 0).saturating_mul(v.into())) .saturating_add(T::DbWeight::get().writes(1)) } /// Storage: `Staking::Ledger` (r:1502 w:1502) @@ -445,13 +449,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `u` is `[0, 751]`. fn deprecate_controller_batch(u: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `195432 + u * (1105 ±0)` + // Measured: `195452 + u * (1105 ±0)` // Estimated: `990 + u * (6456 ±0)` - // Minimum execution time: 9_823_000 picoseconds. - Weight::from_parts(653_198_594, 0) + // Minimum execution time: 6_910_000 picoseconds. + Weight::from_parts(388_846_959, 0) .saturating_add(Weight::from_parts(0, 990)) - // Standard Error: 85_433 - .saturating_add(Weight::from_parts(65_276_677, 0).saturating_mul(u.into())) + // Standard Error: 69_895 + .saturating_add(Weight::from_parts(52_526_808, 0).saturating_mul(u.into())) .saturating_add(T::DbWeight::get().reads((4_u64).saturating_mul(u.into()))) .saturating_add(T::DbWeight::get().writes((3_u64).saturating_mul(u.into()))) .saturating_add(Weight::from_parts(0, 6456).saturating_mul(u.into())) @@ -482,28 +486,30 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) /// Storage: `Staking::Payee` (r:0 w:1) /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) + /// Storage: `Staking::LastValidatorEra` (r:0 w:1) + /// Proof: `Staking::LastValidatorEra` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) fn force_unstake() -> Weight { // Proof Size summary in bytes: - // Measured: `8285` + // Measured: `8305` // Estimated: `6248` - // Minimum execution time: 13_101_369_000 picoseconds. - Weight::from_parts(19_226_646_000, 0) + // Minimum execution time: 9_133_590_000 picoseconds. + Weight::from_parts(13_013_472_000, 0) .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(13)) - .saturating_add(T::DbWeight::get().writes(12)) + .saturating_add(T::DbWeight::get().writes(13)) } /// Storage: `Staking::CancelledSlashes` (r:1 w:1) /// Proof: `Staking::CancelledSlashes` (`max_values`: None, `max_size`: Some(36014), added: 38489, mode: `MaxEncodedLen`) /// The range of component `s` is `[1, 1000]`. fn cancel_deferred_slash(s: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `633` + // Measured: `653` // Estimated: `39479` - // Minimum execution time: 25_616_000 picoseconds. - Weight::from_parts(26_920_000, 0) + // Minimum execution time: 23_503_000 picoseconds. + Weight::from_parts(24_702_000, 0) .saturating_add(Weight::from_parts(0, 39479)) - // Standard Error: 7_904 - .saturating_add(Weight::from_parts(3_170_547, 0).saturating_mul(s.into())) + // Standard Error: 8_160 + .saturating_add(Weight::from_parts(3_076_280, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -536,13 +542,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `n` is `[0, 64]`. fn payout_stakers_alive_staked(n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `32987 + n * (3657 ±0)` + // Measured: `33007 + n * (3657 ±0)` // Estimated: `39483 + n * (3228 ±0)` - // Minimum execution time: 8_149_991_000 picoseconds. - Weight::from_parts(24_203_821_263, 0) + // Minimum execution time: 6_926_965_000 picoseconds. + Weight::from_parts(19_672_312_229, 0) .saturating_add(Weight::from_parts(0, 39483)) - // Standard Error: 8_927_591 - .saturating_add(Weight::from_parts(213_936_089, 0).saturating_mul(n.into())) + // Standard Error: 7_681_540 + .saturating_add(Weight::from_parts(223_887_388, 0).saturating_mul(n.into())) .saturating_add(T::DbWeight::get().reads(13)) .saturating_add(T::DbWeight::get().reads((6_u64).saturating_mul(n.into()))) .saturating_add(T::DbWeight::get().writes(4)) @@ -568,13 +574,15 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Storage: `VoterList::ListBags` (r:2 w:2) /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) /// The range of component `l` is `[1, 32]`. - fn rebond(_l: u32, ) -> Weight { + fn rebond(l: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `8255 + l * (5 ±0)` + // Measured: `8275 + l * (5 ±0)` // Estimated: `8877` - // Minimum execution time: 7_354_091_000 picoseconds. - Weight::from_parts(12_988_930_990, 0) + // Minimum execution time: 5_894_168_000 picoseconds. + Weight::from_parts(8_716_404_838, 0) .saturating_add(Weight::from_parts(0, 8877)) + // Standard Error: 5_683_036 + .saturating_add(Weight::from_parts(19_865_933, 0).saturating_mul(l.into())) .saturating_add(T::DbWeight::get().reads(12)) .saturating_add(T::DbWeight::get().writes(6)) } @@ -606,15 +614,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) /// Storage: `Staking::Payee` (r:0 w:1) /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) + /// Storage: `Staking::LastValidatorEra` (r:0 w:1) + /// Proof: `Staking::LastValidatorEra` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) fn reap_stash() -> Weight { // Proof Size summary in bytes: - // Measured: `8348` + // Measured: `8368` // Estimated: `6248` - // Minimum execution time: 12_231_599_000 picoseconds. - Weight::from_parts(16_715_163_000, 0) + // Minimum execution time: 9_653_555_000 picoseconds. + Weight::from_parts(11_371_755_000, 0) .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(14)) - .saturating_add(T::DbWeight::get().writes(11)) + .saturating_add(T::DbWeight::get().writes(12)) } /// Storage: `Staking::AreNominatorsSlashable` (r:0 w:1) /// Proof: `Staking::AreNominatorsSlashable` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) @@ -636,8 +646,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 11_412_000 picoseconds. - Weight::from_parts(13_559_000, 0) + // Minimum execution time: 8_146_000 picoseconds. + Weight::from_parts(8_904_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(8)) } @@ -661,8 +671,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 11_001_000 picoseconds. - Weight::from_parts(11_909_000, 0) + // Minimum execution time: 7_192_000 picoseconds. + Weight::from_parts(7_769_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(8)) } @@ -692,10 +702,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn chill_other() -> Weight { // Proof Size summary in bytes: - // Measured: `5350` + // Measured: `5360` // Estimated: `6248` - // Minimum execution time: 9_771_157_000 picoseconds. - Weight::from_parts(12_649_351_000, 0) + // Minimum execution time: 7_090_064_000 picoseconds. + Weight::from_parts(9_174_165_000, 0) .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(13)) .saturating_add(T::DbWeight::get().writes(6)) @@ -706,10 +716,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) fn force_apply_min_commission() -> Weight { // Proof Size summary in bytes: - // Measured: `640` + // Measured: `663` // Estimated: `3510` - // Minimum execution time: 67_341_000 picoseconds. - Weight::from_parts(1_409_997_000, 0) + // Minimum execution time: 52_996_000 picoseconds. + Weight::from_parts(61_427_000, 0) .saturating_add(Weight::from_parts(0, 3510)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -720,8 +730,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 5_600_000 picoseconds. - Weight::from_parts(6_248_000, 0) + // Minimum execution time: 3_587_000 picoseconds. + Weight::from_parts(4_080_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -739,10 +749,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) fn restore_ledger() -> Weight { // Proof Size summary in bytes: - // Measured: `6948` + // Measured: `6968` // Estimated: `4764` - // Minimum execution time: 113_591_000 picoseconds. - Weight::from_parts(118_738_000, 0) + // Minimum execution time: 108_119_000 picoseconds. + Weight::from_parts(112_008_000, 0) .saturating_add(Weight::from_parts(0, 4764)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(2)) @@ -761,10 +771,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) fn migrate_currency() -> Weight { // Proof Size summary in bytes: - // Measured: `7019` + // Measured: `7039` // Estimated: `4764` - // Minimum execution time: 167_986_000 picoseconds. - Weight::from_parts(175_287_000, 0) + // Minimum execution time: 166_165_000 picoseconds. + Weight::from_parts(172_969_000, 0) .saturating_add(Weight::from_parts(0, 4764)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(2)) @@ -783,7 +793,7 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `NominationPools::ReversePoolIdLookup` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) /// Storage: `DelegatedStaking::Agents` (r:65 w:65) /// Proof: `DelegatedStaking::Agents` (`max_values`: None, `max_size`: Some(120), added: 2595, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:65 w:65) + /// Storage: `System::Account` (r:66 w:66) /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) /// Storage: `Staking::VirtualStakers` (r:65 w:0) /// Proof: `Staking::VirtualStakers` (`max_values`: None, `max_size`: Some(40), added: 2515, mode: `MaxEncodedLen`) @@ -792,16 +802,16 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `n` is `[0, 64]`. fn apply_slash(n: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `26786 + n * (2979 ±0)` + // Measured: `27546 + n * (2979 ±0)` // Estimated: `39479 + n * (3228 ±0)` - // Minimum execution time: 5_711_189_000 picoseconds. - Weight::from_parts(20_746_457_977, 0) + // Minimum execution time: 6_093_833_000 picoseconds. + Weight::from_parts(18_285_801_932, 0) .saturating_add(Weight::from_parts(0, 39479)) - // Standard Error: 8_226_117 - .saturating_add(Weight::from_parts(211_611_951, 0).saturating_mul(n.into())) - .saturating_add(T::DbWeight::get().reads(10)) + // Standard Error: 7_041_312 + .saturating_add(Weight::from_parts(206_268_666, 0).saturating_mul(n.into())) + .saturating_add(T::DbWeight::get().reads(11)) .saturating_add(T::DbWeight::get().reads((7_u64).saturating_mul(n.into()))) - .saturating_add(T::DbWeight::get().writes(5)) + .saturating_add(T::DbWeight::get().writes(6)) .saturating_add(T::DbWeight::get().writes((4_u64).saturating_mul(n.into()))) .saturating_add(Weight::from_parts(0, 3228).saturating_mul(n.into())) } @@ -821,10 +831,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::UnappliedSlashes` (`max_values`: None, `max_size`: Some(3231), added: 5706, mode: `MaxEncodedLen`) fn process_offence_queue() -> Weight { // Proof Size summary in bytes: - // Measured: `3602` + // Measured: `3622` // Estimated: `6617` - // Minimum execution time: 9_117_247_000 picoseconds. - Weight::from_parts(13_844_678_000, 0) + // Minimum execution time: 4_931_437_000 picoseconds. + Weight::from_parts(11_534_992_000, 0) .saturating_add(Weight::from_parts(0, 6617)) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(4)) @@ -833,6 +843,8 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `MaxEncodedLen`) /// Storage: `Staking::BondedEras` (r:1 w:0) /// Proof: `Staking::BondedEras` (`max_values`: Some(1), `max_size`: Some(25), added: 520, mode: `MaxEncodedLen`) + /// Storage: `Staking::Invulnerables` (r:1 w:0) + /// Proof: `Staking::Invulnerables` (`max_values`: Some(1), `max_size`: Some(641), added: 1136, mode: `MaxEncodedLen`) /// Storage: `Staking::ErasStakersOverview` (r:500 w:0) /// Proof: `Staking::ErasStakersOverview` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) /// Storage: `Staking::ValidatorSlashInEra` (r:500 w:500) @@ -844,14 +856,14 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `v` is `[2, 500]`. fn rc_on_offence(v: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `667 + v * (96 ±0)` - // Estimated: `1510 + v * (2576 ±0)` - // Minimum execution time: 5_838_315_000 picoseconds. - Weight::from_parts(28_870_568_920, 0) - .saturating_add(Weight::from_parts(0, 1510)) - // Standard Error: 1_525_708 - .saturating_add(Weight::from_parts(58_357_673, 0).saturating_mul(v.into())) - .saturating_add(T::DbWeight::get().reads(3)) + // Measured: `687 + v * (96 ±0)` + // Estimated: `2126 + v * (2576 ±0)` + // Minimum execution time: 3_912_656_000 picoseconds. + Weight::from_parts(25_718_789_639, 0) + .saturating_add(Weight::from_parts(0, 2126)) + // Standard Error: 1_422_286 + .saturating_add(Weight::from_parts(56_669_706, 0).saturating_mul(v.into())) + .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().reads((3_u64).saturating_mul(v.into()))) .saturating_add(T::DbWeight::get().writes(1)) .saturating_add(T::DbWeight::get().writes((2_u64).saturating_mul(v.into()))) @@ -887,10 +899,10 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::ElectableStashes` (`max_values`: Some(1), `max_size`: Some(32002), added: 32497, mode: `MaxEncodedLen`) fn rc_on_session_report() -> Weight { // Proof Size summary in bytes: - // Measured: `1157` + // Measured: `1210` // Estimated: `39483` - // Minimum execution time: 11_096_329_000 picoseconds. - Weight::from_parts(12_967_641_000, 0) + // Minimum execution time: 8_385_725_000 picoseconds. + Weight::from_parts(10_432_297_000, 0) .saturating_add(Weight::from_parts(0, 39483)) .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(10)) @@ -904,13 +916,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `v` is `[1, 1000]`. fn prune_era_stakers_paged(v: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `7912 + v * (3 ±0)` - // Estimated: `258665 + v * (4 ±0)` - // Minimum execution time: 231_888_000 picoseconds. - Weight::from_parts(302_995_850, 0) - .saturating_add(Weight::from_parts(0, 258665)) - // Standard Error: 3_473 - .saturating_add(Weight::from_parts(87_000, 0).saturating_mul(v.into())) + // Measured: `7932 + v * (3 ±0)` + // Estimated: `258685 + v * (4 ±0)` + // Minimum execution time: 211_105_000 picoseconds. + Weight::from_parts(253_044_617, 0) + .saturating_add(Weight::from_parts(0, 258685)) + // Standard Error: 2_328 + .saturating_add(Weight::from_parts(96_252, 0).saturating_mul(v.into())) .saturating_add(T::DbWeight::get().reads(103)) .saturating_add(T::DbWeight::get().writes(100)) .saturating_add(Weight::from_parts(0, 4).saturating_mul(v.into())) @@ -924,13 +936,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `v` is `[1, 1000]`. fn prune_era_stakers_overview(v: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `7425` - // Estimated: `202015 + v * (83 ±6)` - // Minimum execution time: 58_866_000 picoseconds. - Weight::from_parts(298_821_262, 0) - .saturating_add(Weight::from_parts(0, 202015)) - // Standard Error: 8_407 - .saturating_add(Weight::from_parts(118_977, 0).saturating_mul(v.into())) + // Measured: `7445` + // Estimated: `202035 + v * (83 ±6)` + // Minimum execution time: 50_603_000 picoseconds. + Weight::from_parts(244_583_252, 0) + .saturating_add(Weight::from_parts(0, 202035)) + // Standard Error: 6_711 + .saturating_add(Weight::from_parts(134_813, 0).saturating_mul(v.into())) .saturating_add(T::DbWeight::get().reads(81)) .saturating_add(T::DbWeight::get().writes(79)) .saturating_add(Weight::from_parts(0, 83).saturating_mul(v.into())) @@ -944,13 +956,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `v` is `[1, 1000]`. fn prune_era_validator_prefs(v: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `5865` - // Estimated: `200811 + v * (83 ±6)` - // Minimum execution time: 59_906_000 picoseconds. - Weight::from_parts(293_753_492, 0) - .saturating_add(Weight::from_parts(0, 200811)) - // Standard Error: 8_180 - .saturating_add(Weight::from_parts(117_927, 0).saturating_mul(v.into())) + // Measured: `5885` + // Estimated: `200831 + v * (83 ±0)` + // Minimum execution time: 47_487_000 picoseconds. + Weight::from_parts(243_102_910, 0) + .saturating_add(Weight::from_parts(0, 200831)) + // Standard Error: 6_618 + .saturating_add(Weight::from_parts(129_797, 0).saturating_mul(v.into())) .saturating_add(T::DbWeight::get().reads(81)) .saturating_add(T::DbWeight::get().writes(79)) .saturating_add(Weight::from_parts(0, 83).saturating_mul(v.into())) @@ -964,13 +976,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `v` is `[1, 1000]`. fn prune_era_claimed_rewards(v: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `8873` - // Estimated: `203149 + v * (84 ±0)` - // Minimum execution time: 58_638_000 picoseconds. - Weight::from_parts(300_701_147, 0) - .saturating_add(Weight::from_parts(0, 203149)) - // Standard Error: 8_476 - .saturating_add(Weight::from_parts(121_615, 0).saturating_mul(v.into())) + // Measured: `8893` + // Estimated: `203169 + v * (84 ±6)` + // Minimum execution time: 51_670_000 picoseconds. + Weight::from_parts(256_416_028, 0) + .saturating_add(Weight::from_parts(0, 203169)) + // Standard Error: 6_969 + .saturating_add(Weight::from_parts(123_988, 0).saturating_mul(v.into())) .saturating_add(T::DbWeight::get().reads(81)) .saturating_add(T::DbWeight::get().writes(79)) .saturating_add(Weight::from_parts(0, 84).saturating_mul(v.into())) @@ -983,11 +995,11 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::ErasValidatorReward` (`max_values`: None, `max_size`: Some(28), added: 2503, mode: `Measured`) fn prune_era_validator_reward() -> Weight { // Proof Size summary in bytes: - // Measured: `789` - // Estimated: `4254` - // Minimum execution time: 49_683_000 picoseconds. - Weight::from_parts(53_648_000, 0) - .saturating_add(Weight::from_parts(0, 4254)) + // Measured: `809` + // Estimated: `4274` + // Minimum execution time: 36_260_000 picoseconds. + Weight::from_parts(39_183_000, 0) + .saturating_add(Weight::from_parts(0, 4274)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -999,11 +1011,11 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::ErasRewardPoints` (`max_values`: None, `max_size`: Some(36018), added: 38493, mode: `Measured`) fn prune_era_reward_points() -> Weight { // Proof Size summary in bytes: - // Measured: `789` - // Estimated: `4254` - // Minimum execution time: 47_161_000 picoseconds. - Weight::from_parts(51_132_000, 0) - .saturating_add(Weight::from_parts(0, 4254)) + // Measured: `809` + // Estimated: `4274` + // Minimum execution time: 38_554_000 picoseconds. + Weight::from_parts(43_384_000, 0) + .saturating_add(Weight::from_parts(0, 4274)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -1017,11 +1029,11 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// Proof: `Staking::ErasTotalStake` (`max_values`: None, `max_size`: Some(28), added: 2503, mode: `Measured`) fn prune_era_single_entry_cleanups() -> Weight { // Proof Size summary in bytes: - // Measured: `789` - // Estimated: `4254` - // Minimum execution time: 49_902_000 picoseconds. - Weight::from_parts(53_736_000, 0) - .saturating_add(Weight::from_parts(0, 4254)) + // Measured: `809` + // Estimated: `4274` + // Minimum execution time: 39_314_000 picoseconds. + Weight::from_parts(41_058_000, 0) + .saturating_add(Weight::from_parts(0, 4274)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -1034,13 +1046,13 @@ impl pallet_staking_async::WeightInfo for WeightInfo /// The range of component `v` is `[1, 1000]`. fn prune_era_validator_slash_in_era(v: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `5499 + v * (3 ±0)` - // Estimated: `132078 + v * (177 ±7)` - // Minimum execution time: 70_448_000 picoseconds. - Weight::from_parts(215_077_611, 0) - .saturating_add(Weight::from_parts(0, 132078)) - // Standard Error: 8_579 - .saturating_add(Weight::from_parts(219_102, 0).saturating_mul(v.into())) + // Measured: `5519 + v * (3 ±0)` + // Estimated: `132098 + v * (177 ±0)` + // Minimum execution time: 58_306_000 picoseconds. + Weight::from_parts(180_775_367, 0) + .saturating_add(Weight::from_parts(0, 132098)) + // Standard Error: 7_525 + .saturating_add(Weight::from_parts(220_673, 0).saturating_mul(v.into())) .saturating_add(T::DbWeight::get().reads(49)) .saturating_add(T::DbWeight::get().writes(48)) .saturating_add(Weight::from_parts(0, 177).saturating_mul(v.into())) diff --git a/prdoc/pr_10947.prdoc b/prdoc/pr_10947.prdoc new file mode 100644 index 0000000000000..a05705f1363cb --- /dev/null +++ b/prdoc/pr_10947.prdoc @@ -0,0 +1,12 @@ +title: 'benchmarking: fix DB read/write counts' +doc: +- audience: Runtime Dev + description: |- + PR #10802 added `reset_read_write_count()` at the end of commit_db() to prevent warmup operations from appearing in benchmarking results. However, commit_db is called twice: one on `on_before_start()` closure before benchmark, and one after benchmark execution after benchmark. + This PR whitelists warmup key so that it doesn't appear in the read/write count. + We also regenerate staking-async and pallet-conviction-voting benchmarks (testing both v1 and v2) +crates: +- name: frame-benchmarking + bump: patch +- name: asset-hub-westend-runtime + bump: patch diff --git a/substrate/frame/benchmarking/src/utils.rs b/substrate/frame/benchmarking/src/utils.rs index c41c6a99854cd..c081bc7af682c 100644 --- a/substrate/frame/benchmarking/src/utils.rs +++ b/substrate/frame/benchmarking/src/utils.rs @@ -293,13 +293,16 @@ pub trait Benchmarking { // Warmup the memory allocator after bulk deallocation. // After draining the overlay with many entries, the first new allocation can trigger memory - // defragmentation. + // defragmentation. The warmup key is whitelisted so these operations don't appear in + // benchmark results. const WARMUP_KEY: &[u8] = b":benchmark_warmup:"; + let mut whitelist = self.get_whitelist(); + if !whitelist.iter().any(|k| k.key == WARMUP_KEY) { + whitelist.push(WARMUP_KEY.to_vec().into()); + self.set_whitelist(whitelist); + } self.place_storage(WARMUP_KEY.to_vec(), Some(vec![0u8; 32])); self.place_storage(WARMUP_KEY.to_vec(), None); - - // Reset tracking so warmup operations don't appear in benchmark results. - self.reset_read_write_count(); } /// Get the read/write count.