diff --git a/.github/scripts/cmd/cmd.py b/.github/scripts/cmd/cmd.py index 9614f332a1368..24f1265b3b705 100755 --- a/.github/scripts/cmd/cmd.py +++ b/.github/scripts/cmd/cmd.py @@ -462,6 +462,7 @@ def main(): f"--no-storage-info --no-min-squares --no-median-slopes " \ f"{config['bench_flags']}" print(f'-- Running: {cmd} \n') + os.environ['RUNTIME_LOG'] = 'off' # Turn off annoying logs during benchmarking status = os.system(cmd) if status != 0 and args.fail_fast: diff --git a/.github/workflows/check-frame-omni-bencher.yml b/.github/workflows/check-frame-omni-bencher.yml index 0ce3891cbc9c0..dd0630908d6b7 100644 --- a/.github/workflows/check-frame-omni-bencher.yml +++ b/.github/workflows/check-frame-omni-bencher.yml @@ -42,7 +42,7 @@ jobs: id: required run: | forklift cargo build --locked --quiet --release -p asset-hub-westend-runtime --features runtime-benchmarks - forklift cargo run --locked --release -p frame-omni-bencher --quiet -- v1 benchmark pallet --runtime target/release/wbuild/asset-hub-westend-runtime/asset_hub_westend_runtime.compact.compressed.wasm --all --steps 2 --repeat 1 --quiet + forklift cargo run --locked --release -p frame-omni-bencher --quiet -- v1 benchmark pallet --runtime target/release/wbuild/asset-hub-westend-runtime/asset_hub_westend_runtime.compact.compressed.wasm --all --steps 2 --repeat 1 --quiet --min-duration 0 - name: Stop all workflows if failed if: ${{ failure() && steps.required.conclusion == 'failure' && !github.event.pull_request.head.repo.fork }} uses: ./.github/actions/workflow-stopper @@ -102,7 +102,7 @@ jobs: ls -lrt $RUNTIME_BLOB_PATH if [[ "$BENCH_CMD" == "pallet" ]]; then - cmd="./target/release/frame-omni-bencher v1 benchmark pallet --runtime $RUNTIME_BLOB_PATH --all --steps 2 --repeat 1 $FLAGS" + cmd="./target/release/frame-omni-bencher v1 benchmark pallet --runtime $RUNTIME_BLOB_PATH --all --steps 2 --repeat 1 --min-duration 0 $FLAGS" elif [[ "$BENCH_CMD" == "overhead" ]]; then cmd="./target/release/frame-omni-bencher v1 benchmark overhead --runtime $RUNTIME_BLOB_PATH" else diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4f746ad2a8288..c84bded2d138e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -35,7 +35,7 @@ jobs: - name: Checkout uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 - name: script - run: forklift cargo run --locked --release -p staging-node-cli --bin substrate-node --features runtime-benchmarks --quiet -- benchmark pallet --chain dev --pallet "*" --extrinsic "*" --steps 2 --repeat 1 --quiet + run: forklift cargo run --locked --release -p staging-node-cli --bin substrate-node --features runtime-benchmarks --quiet -- benchmark pallet --chain dev --pallet "*" --extrinsic "*" --steps 2 --repeat 1 --min-duration 0 --quiet # cf https://github.com/paritytech/polkadot-sdk/issues/1652 test-syscalls: 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 b3a6f31b048a2..5acfb8621f20a 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,17 @@ //! Autogenerated weights for `pallet_staking_async` //! +<<<<<<< HEAD //! 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: `75dbeac523b6`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` +======= +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2026-01-17, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `ad005bf13d98`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz` +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) //! WASM-EXECUTION: `Compiled`, CHAIN: `None`, DB CACHE: 1024 // Executed Command: @@ -50,22 +57,9 @@ use core::marker::PhantomData; /// Weight functions for `pallet_staking_async`. pub struct WeightInfo(PhantomData); impl pallet_staking_async::WeightInfo for WeightInfo { - /// Storage: `Staking::Bonded` (r:1 w:1) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:1 w:0) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, 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::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:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `Staking::Payee` (r:0 w:1) - /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) fn bond() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `6813` // Estimated: `4218` // Minimum execution time: 148_479_000 picoseconds. @@ -73,27 +67,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(4)) +======= + // Measured: `6793` + // Estimated: `0` + // Minimum execution time: 151_823_000 picoseconds. + Weight::from_parts(162_698_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::VirtualStakers` (r:1 w:0) - /// Proof: `Staking::VirtualStakers` (`max_values`: None, `max_size`: Some(40), added: 2515, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:1 w:0) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, 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: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:3 w:3) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:2 w:2) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) fn bond_extra() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `8274` // Estimated: `8877` // Minimum execution time: 8_768_396_000 picoseconds. @@ -101,33 +85,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 8877)) .saturating_add(T::DbWeight::get().reads(12)) .saturating_add(T::DbWeight::get().writes(7)) +======= + // Measured: `8254` + // Estimated: `0` + // Minimum execution time: 9_824_370_000 picoseconds. + Weight::from_parts(13_177_169_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:1 w:0) - /// 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::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) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:3 w:3) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:2 w:2) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) fn unbond() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `8435` // Estimated: `8877` // Minimum execution time: 6_772_963_000 picoseconds. @@ -135,31 +103,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 8877)) .saturating_add(T::DbWeight::get().reads(15)) .saturating_add(T::DbWeight::get().writes(6)) +======= + // Measured: `8415` + // Estimated: `0` + // Minimum execution time: 6_984_740_000 picoseconds. + Weight::from_parts(10_286_473_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, 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::UnappliedSlashes` (r:1 w:0) - /// Proof: `Staking::UnappliedSlashes` (`max_values`: None, `max_size`: Some(3231), added: 5706, mode: `MaxEncodedLen`) - /// Storage: `Staking::OffenceQueueEras` (r:1 w:0) - /// Proof: `Staking::OffenceQueueEras` (`max_values`: Some(1), `max_size`: Some(9), added: 504, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:1 w:0) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, 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::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:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `NominationPools::ReversePoolIdLookup` (r:1 w:0) - /// Proof: `NominationPools::ReversePoolIdLookup` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) - /// Storage: `DelegatedStaking::Agents` (r:1 w:0) - /// Proof: `DelegatedStaking::Agents` (`max_values`: None, `max_size`: Some(120), added: 2595, mode: `MaxEncodedLen`) fn withdraw_unbonded_update() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `7413` // Estimated: `6696` // Minimum execution time: 169_983_000 picoseconds. @@ -167,45 +121,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 6696)) .saturating_add(T::DbWeight::get().reads(11)) .saturating_add(T::DbWeight::get().writes(2)) +======= + // Measured: `7393` + // Estimated: `0` + // Minimum execution time: 171_540_000 picoseconds. + Weight::from_parts(181_106_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:1) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, 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::UnappliedSlashes` (r:1 w:0) - /// Proof: `Staking::UnappliedSlashes` (`max_values`: None, `max_size`: Some(3231), added: 5706, mode: `MaxEncodedLen`) - /// Storage: `Staking::OffenceQueueEras` (r:1 w:0) - /// Proof: `Staking::OffenceQueueEras` (`max_values`: Some(1), `max_size`: Some(9), added: 504, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:1 w:0) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, 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::VirtualStakers` (r:1 w:1) - /// Proof: `Staking::VirtualStakers` (`max_values`: None, `max_size`: Some(40), added: 2515, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `Staking::Validators` (r:1 w:0) - /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:1 w:1) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) - /// Storage: `Staking::CounterForNominators` (r:1 w:1) - /// Proof: `Staking::CounterForNominators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:2 w:2) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:1 w:1) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) - /// Storage: `VoterList::CounterForListNodes` (r:1 w:1) - /// 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: +<<<<<<< HEAD // Measured: `8360` // Estimated: `6696` // Minimum execution time: 8_213_582_000 picoseconds. @@ -213,33 +139,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 6696)) .saturating_add(T::DbWeight::get().reads(17)) .saturating_add(T::DbWeight::get().writes(12)) +======= + // Measured: `8340` + // Estimated: `0` + // Minimum execution time: 10_719_434_000 picoseconds. + Weight::from_parts(14_830_140_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:1 w:0) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinCommission` (r:1 w:0) - /// Proof: `Staking::MinCommission` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::Validators` (r:1 w:1) - /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxValidatorsCount` (r:1 w:0) - /// Proof: `Staking::MaxValidatorsCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:1 w:0) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:1 w:1) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:1 w:1) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) - /// Storage: `VoterList::CounterForListNodes` (r:1 w:1) - /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::CounterForValidators` (r:1 w:1) - /// Proof: `Staking::CounterForValidators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn validate() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `9905` // Estimated: `4218` // Minimum execution time: 157_547_000 picoseconds. @@ -247,16 +157,18 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(12)) .saturating_add(T::DbWeight::get().writes(5)) +======= + // Measured: `9885` + // Estimated: `0` + // Minimum execution time: 155_256_000 picoseconds. + Weight::from_parts(161_416_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:128 w:128) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) /// The range of component `k` is `[1, 128]`. fn kick(k: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `12207 + k * (1121 ±0)` // Estimated: `4218 + k * (3033 ±0)` // Minimum execution time: 95_868_000 picoseconds. @@ -268,34 +180,20 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(k.into()))) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(k.into()))) .saturating_add(Weight::from_parts(0, 3033).saturating_mul(k.into())) +======= + // Measured: `12187 + k * (1121 ±0)` + // Estimated: `0` + // Minimum execution time: 98_146_000 picoseconds. + Weight::from_parts(145_793_776, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 55_127 + .saturating_add(Weight::from_parts(17_280_864, 0).saturating_mul(k.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, 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::Nominators` (r:1 w:1) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxNominatorsCount` (r:1 w:0) - /// Proof: `Staking::MaxNominatorsCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::Validators` (r:17 w:0) - /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) - /// Storage: `Staking::CurrentEra` (r:1 w:0) - /// Proof: `Staking::CurrentEra` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:2 w:2) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:1 w:1) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) - /// Storage: `VoterList::CounterForListNodes` (r:1 w:1) - /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::CounterForNominators` (r:1 w:1) - /// Proof: `Staking::CounterForNominators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) /// The range of component `n` is `[1, 16]`. fn nominate(n: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `5094 + n * (68 ±0)` // Estimated: `6248 + n * (2520 ±0)` // Minimum execution time: 3_915_622_000 picoseconds. @@ -307,27 +205,19 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(n.into()))) .saturating_add(T::DbWeight::get().writes(6)) .saturating_add(Weight::from_parts(0, 2520).saturating_mul(n.into())) +======= + // Measured: `5074 + n * (68 ±0)` + // Estimated: `0` + // Minimum execution time: 3_951_847_000 picoseconds. + Weight::from_parts(11_093_536_278, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 12_371_015 + .saturating_add(Weight::from_parts(134_071_422, 0).saturating_mul(n.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Validators` (r:1 w:0) - /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:1 w:1) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) - /// Storage: `Staking::CounterForNominators` (r:1 w:1) - /// Proof: `Staking::CounterForNominators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:2 w:2) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:1 w:1) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) - /// Storage: `VoterList::CounterForListNodes` (r:1 w:1) - /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn chill() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `5237` // Estimated: `6248` // Minimum execution time: 4_296_652_000 picoseconds. @@ -335,15 +225,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(10)) .saturating_add(T::DbWeight::get().writes(6)) +======= + // Measured: `5217` + // Estimated: `0` + // Minimum execution time: 5_461_816_000 picoseconds. + Weight::from_parts(5_964_595_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Payee` (r:0 w:1) - /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) fn set_payee() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `4060` // Estimated: `4218` // Minimum execution time: 58_690_000 picoseconds. @@ -351,15 +243,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) +======= + // Measured: `4040` + // Estimated: `0` + // Minimum execution time: 57_034_000 picoseconds. + Weight::from_parts(61_302_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Payee` (r:1 w:1) - /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) fn update_payee() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `5732` // Estimated: `4218` // Minimum execution time: 71_527_000 picoseconds. @@ -367,13 +261,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4218)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(1)) +======= + // Measured: `5712` + // Estimated: `0` + // Minimum execution time: 73_677_000 picoseconds. + Weight::from_parts(75_535_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Bonded` (r:1 w:1) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:2 w:2) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) fn set_controller() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `5403` // Estimated: `7446` // Minimum execution time: 73_043_000 picoseconds. @@ -381,51 +279,67 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 7446)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) +======= + // Measured: `5383` + // Estimated: `0` + // Minimum execution time: 73_550_000 picoseconds. + Weight::from_parts(77_231_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ValidatorCount` (r:0 w:1) - /// Proof: `Staking::ValidatorCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn set_validator_count() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` +<<<<<<< HEAD // Minimum execution time: 3_656_000 picoseconds. Weight::from_parts(3_972_000, 0) +======= + // Minimum execution time: 3_820_000 picoseconds. + Weight::from_parts(4_032_000, 0) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `Staking::ForceEra` (r:0 w:1) - /// Proof: `Staking::ForceEra` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) fn force_no_eras() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` +<<<<<<< HEAD // Minimum execution time: 20_178_000 picoseconds. Weight::from_parts(21_307_000, 0) +======= + // Minimum execution time: 20_612_000 picoseconds. + Weight::from_parts(22_653_000, 0) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `Staking::ForceEra` (r:0 w:1) - /// Proof: `Staking::ForceEra` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) fn force_new_era() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` +<<<<<<< HEAD // Minimum execution time: 20_064_000 picoseconds. Weight::from_parts(21_212_000, 0) +======= + // Minimum execution time: 20_353_000 picoseconds. + Weight::from_parts(21_738_000, 0) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `Staking::ForceEra` (r:0 w:1) - /// Proof: `Staking::ForceEra` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) fn force_new_era_always() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` +<<<<<<< HEAD // Minimum execution time: 20_256_000 picoseconds. Weight::from_parts(21_568_000, 0) +======= + // Minimum execution time: 20_237_000 picoseconds. + Weight::from_parts(22_012_000, 0) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } +<<<<<<< HEAD /// Storage: `Staking::Invulnerables` (r:0 w:1) /// Proof: `Staking::Invulnerables` (`max_values`: Some(1), `max_size`: Some(641), added: 1136, mode: `MaxEncodedLen`) /// The range of component `v` is `[0, 20]`. @@ -459,37 +373,22 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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())) +======= + /// 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)` + // Estimated: `0` + // Minimum execution time: 7_164_000 picoseconds. + Weight::from_parts(223_480_099, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 165_663 + .saturating_add(Weight::from_parts(60_652_060, 0).saturating_mul(u.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Bonded` (r:1 w:1) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::VirtualStakers` (r:1 w:1) - /// Proof: `Staking::VirtualStakers` (`max_values`: None, `max_size`: Some(40), added: 2515, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:1 w:1) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`) - /// Storage: `Staking::Validators` (r:1 w:0) - /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:1 w:1) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) - /// Storage: `Staking::CounterForNominators` (r:1 w:1) - /// Proof: `Staking::CounterForNominators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:2 w:2) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:1 w:1) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) - /// Storage: `VoterList::CounterForListNodes` (r:1 w:1) - /// 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: +<<<<<<< HEAD // Measured: `8305` // Estimated: `6248` // Minimum execution time: 9_133_590_000 picoseconds. @@ -497,12 +396,18 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(13)) .saturating_add(T::DbWeight::get().writes(13)) +======= + // Measured: `8285` + // Estimated: `0` + // Minimum execution time: 10_921_590_000 picoseconds. + Weight::from_parts(16_176_391_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// 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: +<<<<<<< HEAD // Measured: `653` // Estimated: `39479` // Minimum execution time: 23_503_000 picoseconds. @@ -512,36 +417,20 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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)) +======= + // Measured: `633` + // Estimated: `0` + // Minimum execution time: 21_117_000 picoseconds. + Weight::from_parts(21_937_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 8_007 + .saturating_add(Weight::from_parts(3_054_448, 0).saturating_mul(s.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ErasStakersOverview` (r:1 w:0) - /// Proof: `Staking::ErasStakersOverview` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) - /// Storage: `Staking::ClaimedRewards` (r:1 w:1) - /// Proof: `Staking::ClaimedRewards` (`max_values`: None, `max_size`: Some(1462), added: 3937, mode: `MaxEncodedLen`) - /// Storage: `Staking::CurrentEra` (r:1 w:0) - /// Proof: `Staking::CurrentEra` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasValidatorReward` (r:1 w:0) - /// Proof: `Staking::ErasValidatorReward` (`max_values`: None, `max_size`: Some(28), added: 2503, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:65 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:65 w:65) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `System::Account` (r:65 w:65) - /// 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`) - /// Storage: `Balances::Holds` (r:65 w:65) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasStakersPaged` (r:1 w:0) - /// Proof: `Staking::ErasStakersPaged` (`max_values`: None, `max_size`: Some(3152), added: 5627, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasRewardPoints` (r:1 w:0) - /// Proof: `Staking::ErasRewardPoints` (`max_values`: None, `max_size`: Some(36018), added: 38493, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasValidatorPrefs` (r:1 w:0) - /// Proof: `Staking::ErasValidatorPrefs` (`max_values`: None, `max_size`: Some(57), added: 2532, mode: `MaxEncodedLen`) - /// Storage: `Staking::Payee` (r:65 w:0) - /// Proof: `Staking::Payee` (`max_values`: None, `max_size`: Some(73), added: 2548, mode: `MaxEncodedLen`) /// The range of component `n` is `[0, 64]`. fn payout_stakers_alive_staked(n: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `33007 + n * (3657 ±0)` // Estimated: `39483 + n * (3228 ±0)` // Minimum execution time: 6_926_965_000 picoseconds. @@ -554,28 +443,20 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(T::DbWeight::get().writes(4)) .saturating_add(T::DbWeight::get().writes((3_u64).saturating_mul(n.into()))) .saturating_add(Weight::from_parts(0, 3228).saturating_mul(n.into())) +======= + // Measured: `32987 + n * (3657 ±0)` + // Estimated: `0` + // Minimum execution time: 6_909_131_000 picoseconds. + Weight::from_parts(20_652_651_092, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 8_042_660 + .saturating_add(Weight::from_parts(264_186_902, 0).saturating_mul(n.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:1 w:0) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, 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::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) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:3 w:3) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// 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: +<<<<<<< HEAD // Measured: `8275 + l * (5 ±0)` // Estimated: `8877` // Minimum execution time: 5_894_168_000 picoseconds. @@ -585,39 +466,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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)) +======= + // Measured: `8255 + l * (5 ±0)` + // Estimated: `0` + // Minimum execution time: 6_909_067_000 picoseconds. + Weight::from_parts(10_699_364_610, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::VirtualStakers` (r:1 w:1) - /// Proof: `Staking::VirtualStakers` (`max_values`: None, `max_size`: Some(40), added: 2515, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:1 w:0) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, 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::Bonded` (r:1 w:1) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `Staking::Validators` (r:1 w:0) - /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:1 w:1) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) - /// Storage: `Staking::CounterForNominators` (r:1 w:1) - /// Proof: `Staking::CounterForNominators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:2 w:2) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:1 w:1) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) - /// Storage: `VoterList::CounterForListNodes` (r:1 w:1) - /// 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: +<<<<<<< HEAD // Measured: `8368` // Estimated: `6248` // Minimum execution time: 9_653_555_000 picoseconds. @@ -625,83 +484,43 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(14)) .saturating_add(T::DbWeight::get().writes(12)) +======= + // Measured: `8348` + // Estimated: `0` + // Minimum execution time: 10_927_055_000 picoseconds. + Weight::from_parts(13_398_080_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::AreNominatorsSlashable` (r:0 w:1) - /// Proof: `Staking::AreNominatorsSlashable` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinCommission` (r:0 w:1) - /// Proof: `Staking::MinCommission` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:0 w:1) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxValidatorsCount` (r:0 w:1) - /// Proof: `Staking::MaxValidatorsCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxStakedRewards` (r:0 w:1) - /// Proof: `Staking::MaxStakedRewards` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::ChillThreshold` (r:0 w:1) - /// Proof: `Staking::ChillThreshold` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxNominatorsCount` (r:0 w:1) - /// Proof: `Staking::MaxNominatorsCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinNominatorBond` (r:0 w:1) - /// Proof: `Staking::MinNominatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) fn set_staking_configs_all_set() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` +<<<<<<< HEAD // Minimum execution time: 8_146_000 picoseconds. Weight::from_parts(8_904_000, 0) +======= + // Minimum execution time: 8_168_000 picoseconds. + Weight::from_parts(8_893_000, 0) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(8)) } - /// Storage: `Staking::AreNominatorsSlashable` (r:0 w:1) - /// Proof: `Staking::AreNominatorsSlashable` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinCommission` (r:0 w:1) - /// Proof: `Staking::MinCommission` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinValidatorBond` (r:0 w:1) - /// Proof: `Staking::MinValidatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxValidatorsCount` (r:0 w:1) - /// Proof: `Staking::MaxValidatorsCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxStakedRewards` (r:0 w:1) - /// Proof: `Staking::MaxStakedRewards` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::ChillThreshold` (r:0 w:1) - /// Proof: `Staking::ChillThreshold` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxNominatorsCount` (r:0 w:1) - /// Proof: `Staking::MaxNominatorsCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::MinNominatorBond` (r:0 w:1) - /// Proof: `Staking::MinNominatorBond` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) fn set_staking_configs_all_remove() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` +<<<<<<< HEAD // Minimum execution time: 7_192_000 picoseconds. Weight::from_parts(7_769_000, 0) +======= + // Minimum execution time: 7_548_000 picoseconds. + Weight::from_parts(8_120_000, 0) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(8)) } - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Staking::Nominators` (r:1 w:1) - /// Proof: `Staking::Nominators` (`max_values`: None, `max_size`: Some(558), added: 3033, mode: `MaxEncodedLen`) - /// Storage: `Staking::ChillThreshold` (r:1 w:0) - /// Proof: `Staking::ChillThreshold` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxNominatorsCount` (r:1 w:0) - /// Proof: `Staking::MaxNominatorsCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::CounterForNominators` (r:1 w:1) - /// Proof: `Staking::CounterForNominators` (`max_values`: Some(1), `max_size`: Some(4), added: 499, 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::Validators` (r:1 w:0) - /// Proof: `Staking::Validators` (`max_values`: None, `max_size`: Some(45), added: 2520, mode: `MaxEncodedLen`) - /// Storage: `VoterList::Lock` (r:1 w:0) - /// Proof: `VoterList::Lock` (`max_values`: Some(1), `max_size`: Some(0), added: 495, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListNodes` (r:2 w:2) - /// Proof: `VoterList::ListNodes` (`max_values`: None, `max_size`: Some(154), added: 2629, mode: `MaxEncodedLen`) - /// Storage: `VoterList::ListBags` (r:1 w:1) - /// Proof: `VoterList::ListBags` (`max_values`: None, `max_size`: Some(82), added: 2557, mode: `MaxEncodedLen`) - /// Storage: `VoterList::CounterForListNodes` (r:1 w:1) - /// Proof: `VoterList::CounterForListNodes` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn chill_other() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `5360` // Estimated: `6248` // Minimum execution time: 7_090_064_000 picoseconds. @@ -709,13 +528,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 6248)) .saturating_add(T::DbWeight::get().reads(13)) .saturating_add(T::DbWeight::get().writes(6)) +======= + // Measured: `5350` + // Estimated: `0` + // Minimum execution time: 8_972_274_000 picoseconds. + Weight::from_parts(12_286_705_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::MinCommission` (r:1 w:0) - /// Proof: `Staking::MinCommission` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::Validators` (r:1 w:1) - /// 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: +<<<<<<< HEAD // Measured: `663` // Estimated: `3510` // Minimum execution time: 52_996_000 picoseconds. @@ -723,32 +546,30 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 3510)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) +======= + // Measured: `640` + // Estimated: `0` + // Minimum execution time: 57_429_000 picoseconds. + Weight::from_parts(67_310_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::MinCommission` (r:0 w:1) - /// Proof: `Staking::MinCommission` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) fn set_min_commission() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` +<<<<<<< HEAD // Minimum execution time: 3_587_000 picoseconds. Weight::from_parts(4_080_000, 0) +======= + // Minimum execution time: 3_827_000 picoseconds. + Weight::from_parts(4_098_000, 0) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) } - /// Storage: `System::Account` (r:1 w:0) - /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, 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) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) - /// Storage: `Balances::Locks` (r:1 w:0) - /// Proof: `Balances::Locks` (`max_values`: None, `max_size`: Some(1299), added: 3774, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:1) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:1 w:1) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) fn restore_ledger() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `6968` // Estimated: `4764` // Minimum execution time: 108_119_000 picoseconds. @@ -756,21 +577,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4764)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(2)) +======= + // Measured: `6948` + // Estimated: `0` + // Minimum execution time: 109_614_000 picoseconds. + Weight::from_parts(114_855_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::VirtualStakers` (r:1 w:0) - /// Proof: `Staking::VirtualStakers` (`max_values`: None, `max_size`: Some(40), added: 2515, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:1 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:1 w:0) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `Balances::Locks` (r:1 w:1) - /// Proof: `Balances::Locks` (`max_values`: None, `max_size`: Some(1299), added: 3774, mode: `MaxEncodedLen`) - /// Storage: `Balances::Freezes` (r:1 w:0) - /// Proof: `Balances::Freezes` (`max_values`: None, `max_size`: Some(85), added: 2560, mode: `MaxEncodedLen`) - /// Storage: `Balances::Holds` (r:1 w:1) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) fn migrate_currency() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `7039` // Estimated: `4764` // Minimum execution time: 166_165_000 picoseconds. @@ -778,30 +595,18 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4764)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(2)) +======= + // Measured: `7019` + // Estimated: `0` + // Minimum execution time: 162_554_000 picoseconds. + Weight::from_parts(169_846_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `MaxEncodedLen`) - /// Storage: `Staking::CancelledSlashes` (r:1 w:0) - /// Proof: `Staking::CancelledSlashes` (`max_values`: None, `max_size`: Some(36014), added: 38489, mode: `MaxEncodedLen`) - /// Storage: `Staking::UnappliedSlashes` (r:1 w:1) - /// Proof: `Staking::UnappliedSlashes` (`max_values`: None, `max_size`: Some(3231), added: 5706, mode: `MaxEncodedLen`) - /// Storage: `Staking::Bonded` (r:65 w:0) - /// Proof: `Staking::Bonded` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// Storage: `Staking::Ledger` (r:65 w:65) - /// Proof: `Staking::Ledger` (`max_values`: None, `max_size`: Some(753), added: 3228, mode: `MaxEncodedLen`) - /// Storage: `NominationPools::ReversePoolIdLookup` (r:65 w:0) - /// 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: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`) - /// Storage: `Balances::Holds` (r:65 w:65) - /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(301), added: 2776, mode: `MaxEncodedLen`) /// The range of component `n` is `[0, 64]`. fn apply_slash(n: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `27546 + n * (2979 ±0)` // Estimated: `39479 + n * (3228 ±0)` // Minimum execution time: 6_093_833_000 picoseconds. @@ -814,23 +619,19 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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())) +======= + // Measured: `27526 + n * (2979 ±0)` + // Estimated: `0` + // Minimum execution time: 7_428_074_000 picoseconds. + Weight::from_parts(19_830_764_737, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 7_880_082 + .saturating_add(Weight::from_parts(228_874_767, 0).saturating_mul(n.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ProcessingOffence` (r:1 w:1) - /// Proof: `Staking::ProcessingOffence` (`max_values`: Some(1), `max_size`: Some(85), added: 580, mode: `MaxEncodedLen`) - /// Storage: `Staking::OffenceQueueEras` (r:1 w:1) - /// Proof: `Staking::OffenceQueueEras` (`max_values`: Some(1), `max_size`: Some(9), added: 504, mode: `MaxEncodedLen`) - /// Storage: `Staking::OffenceQueue` (r:2 w:1) - /// Proof: `Staking::OffenceQueue` (`max_values`: None, `max_size`: Some(101), added: 2576, mode: `MaxEncodedLen`) - /// Storage: `Staking::SlashRewardFraction` (r:1 w:0) - /// Proof: `Staking::SlashRewardFraction` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasStakersOverview` (r:1 w:0) - /// Proof: `Staking::ErasStakersOverview` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasStakersPaged` (r:1 w:0) - /// Proof: `Staking::ErasStakersPaged` (`max_values`: None, `max_size`: Some(3152), added: 5627, mode: `MaxEncodedLen`) - /// Storage: `Staking::UnappliedSlashes` (r:0 w:1) - /// Proof: `Staking::UnappliedSlashes` (`max_values`: None, `max_size`: Some(3231), added: 5706, mode: `MaxEncodedLen`) fn process_offence_queue() -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `3622` // Estimated: `6617` // Minimum execution time: 4_931_437_000 picoseconds. @@ -868,37 +669,28 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(T::DbWeight::get().writes(1)) .saturating_add(T::DbWeight::get().writes((2_u64).saturating_mul(v.into()))) .saturating_add(Weight::from_parts(0, 2576).saturating_mul(v.into())) +======= + // Measured: `3602` + // Estimated: `0` + // Minimum execution time: 5_027_278_000 picoseconds. + Weight::from_parts(12_923_992_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// 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: `0` + // Minimum execution time: 3_997_424_000 picoseconds. + Weight::from_parts(28_149_718_556, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 1_586_636 + .saturating_add(Weight::from_parts(57_924_737, 0).saturating_mul(v.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:1) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasRewardPoints` (r:1 w:1) - /// Proof: `Staking::ErasRewardPoints` (`max_values`: None, `max_size`: Some(36018), added: 38493, mode: `MaxEncodedLen`) - /// Storage: `Staking::CurrentEra` (r:1 w:1) - /// Proof: `Staking::CurrentEra` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasTotalStake` (r:1 w:0) - /// Proof: `Staking::ErasTotalStake` (`max_values`: None, `max_size`: Some(28), added: 2503, mode: `MaxEncodedLen`) - /// Storage: `Staking::MaxStakedRewards` (r:1 w:0) - /// Proof: `Staking::MaxStakedRewards` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `Staking::BondedEras` (r:1 w:1) - /// Proof: `Staking::BondedEras` (`max_values`: Some(1), `max_size`: Some(25), added: 520, 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::ForceEra` (r:1 w:0) - /// Proof: `Staking::ForceEra` (`max_values`: Some(1), `max_size`: Some(1), added: 496, mode: `MaxEncodedLen`) - /// Storage: `MultiBlockElection::CurrentPhase` (r:1 w:1) - /// Proof: `MultiBlockElection::CurrentPhase` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasNominatorsSlashable` (r:0 w:1) - /// Proof: `Staking::ErasNominatorsSlashable` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `MaxEncodedLen`) - /// Storage: `Staking::VoterSnapshotStatus` (r:0 w:1) - /// Proof: `Staking::VoterSnapshotStatus` (`max_values`: Some(1), `max_size`: Some(33), added: 528, mode: `MaxEncodedLen`) - /// Storage: `Staking::ErasValidatorReward` (r:0 w:1) - /// Proof: `Staking::ErasValidatorReward` (`max_values`: None, `max_size`: Some(28), added: 2503, mode: `MaxEncodedLen`) - /// Storage: `Staking::NextElectionPage` (r:0 w:1) - /// Proof: `Staking::NextElectionPage` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `Staking::ElectableStashes` (r:0 w:1) - /// 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: +<<<<<<< HEAD // Measured: `1210` // Estimated: `39483` // Minimum execution time: 8_385_725_000 picoseconds. @@ -906,16 +698,18 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 39483)) .saturating_add(T::DbWeight::get().reads(9)) .saturating_add(T::DbWeight::get().writes(10)) +======= + // Measured: `1190` + // Estimated: `0` + // Minimum execution time: 10_892_087_000 picoseconds. + Weight::from_parts(11_439_807_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:0) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ErasStakersPaged` (r:101 w:100) - /// Proof: `Staking::ErasStakersPaged` (`max_values`: None, `max_size`: Some(3152), added: 5627, mode: `Measured`) /// The range of component `v` is `[1, 1000]`. fn prune_era_stakers_paged(v: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `7932 + v * (3 ±0)` // Estimated: `258685 + v * (4 ±0)` // Minimum execution time: 211_105_000 picoseconds. @@ -926,16 +720,20 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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())) +======= + // Measured: `7912 + v * (3 ±0)` + // Estimated: `0` + // Minimum execution time: 233_582_000 picoseconds. + Weight::from_parts(302_127_414, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 3_585 + .saturating_add(Weight::from_parts(83_794, 0).saturating_mul(v.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:0) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ErasStakersOverview` (r:101 w:100) - /// Proof: `Staking::ErasStakersOverview` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `Measured`) /// The range of component `v` is `[1, 1000]`. fn prune_era_stakers_overview(v: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `7445` // Estimated: `202035 + v * (83 ±6)` // Minimum execution time: 50_603_000 picoseconds. @@ -946,16 +744,20 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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())) +======= + // Measured: `7425` + // Estimated: `0` + // Minimum execution time: 57_623_000 picoseconds. + Weight::from_parts(308_108_210, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 9_129 + .saturating_add(Weight::from_parts(91_683, 0).saturating_mul(v.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:0) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ErasValidatorPrefs` (r:101 w:100) - /// Proof: `Staking::ErasValidatorPrefs` (`max_values`: None, `max_size`: Some(57), added: 2532, mode: `Measured`) /// The range of component `v` is `[1, 1000]`. fn prune_era_validator_prefs(v: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `5885` // Estimated: `200831 + v * (83 ±0)` // Minimum execution time: 47_487_000 picoseconds. @@ -966,16 +768,20 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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())) +======= + // Measured: `5865` + // Estimated: `0` + // Minimum execution time: 53_173_000 picoseconds. + Weight::from_parts(278_592_462, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 8_591 + .saturating_add(Weight::from_parts(147_948, 0).saturating_mul(v.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:0) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ClaimedRewards` (r:101 w:100) - /// Proof: `Staking::ClaimedRewards` (`max_values`: None, `max_size`: Some(1462), added: 3937, mode: `Measured`) /// The range of component `v` is `[1, 1000]`. fn prune_era_claimed_rewards(v: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `8893` // Estimated: `203169 + v * (84 ±6)` // Minimum execution time: 51_670_000 picoseconds. @@ -986,15 +792,19 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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())) +======= + // Measured: `8873` + // Estimated: `0` + // Minimum execution time: 55_821_000 picoseconds. + Weight::from_parts(297_039_564, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 8_692 + .saturating_add(Weight::from_parts(122_602, 0).saturating_mul(v.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:1) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ErasValidatorReward` (r:0 w:1) - /// 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: +<<<<<<< HEAD // Measured: `809` // Estimated: `4274` // Minimum execution time: 36_260_000 picoseconds. @@ -1002,15 +812,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4274)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) +======= + // Measured: `789` + // Estimated: `0` + // Minimum execution time: 42_821_000 picoseconds. + Weight::from_parts(46_037_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:1) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ErasRewardPoints` (r:0 w:1) - /// 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: +<<<<<<< HEAD // Measured: `809` // Estimated: `4274` // Minimum execution time: 38_554_000 picoseconds. @@ -1018,17 +830,17 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4274)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) +======= + // Measured: `789` + // Estimated: `0` + // Minimum execution time: 41_525_000 picoseconds. + Weight::from_parts(46_113_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:1) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ErasNominatorsSlashable` (r:0 w:1) - /// Proof: `Staking::ErasNominatorsSlashable` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ErasTotalStake` (r:0 w:1) - /// 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: +<<<<<<< HEAD // Measured: `809` // Estimated: `4274` // Minimum execution time: 39_314_000 picoseconds. @@ -1036,16 +848,18 @@ impl pallet_staking_async::WeightInfo for WeightInfo .saturating_add(Weight::from_parts(0, 4274)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(3)) +======= + // Measured: `789` + // Estimated: `0` + // Minimum execution time: 45_910_000 picoseconds. + Weight::from_parts(48_324_000, 0) + .saturating_add(Weight::from_parts(0, 0)) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } - /// Storage: `Staking::ActiveEra` (r:1 w:0) - /// Proof: `Staking::ActiveEra` (`max_values`: Some(1), `max_size`: Some(13), added: 508, mode: `Measured`) - /// Storage: `Staking::EraPruningState` (r:1 w:0) - /// Proof: `Staking::EraPruningState` (`max_values`: None, `max_size`: Some(13), added: 2488, mode: `Measured`) - /// Storage: `Staking::ValidatorSlashInEra` (r:101 w:100) - /// Proof: `Staking::ValidatorSlashInEra` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `Measured`) /// The range of component `v` is `[1, 1000]`. fn prune_era_validator_slash_in_era(v: u32, ) -> Weight { // Proof Size summary in bytes: +<<<<<<< HEAD // Measured: `5519 + v * (3 ±0)` // Estimated: `132098 + v * (177 ±0)` // Minimum execution time: 58_306_000 picoseconds. @@ -1056,5 +870,14 @@ impl pallet_staking_async::WeightInfo for WeightInfo .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())) +======= + // Measured: `5499 + v * (3 ±0)` + // Estimated: `0` + // Minimum execution time: 60_851_000 picoseconds. + Weight::from_parts(210_957_237, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 9_601 + .saturating_add(Weight::from_parts(206_498, 0).saturating_mul(v.into())) +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) } } diff --git a/prdoc/pr_10794.prdoc b/prdoc/pr_10794.prdoc new file mode 100644 index 0000000000000..9f62e05de3f6a --- /dev/null +++ b/prdoc/pr_10794.prdoc @@ -0,0 +1,11 @@ +title: '[FRAME] Omni bencher run each benchmark at least 10 secs' +doc: +- audience: Runtime Dev + description: |- + - Ensure all benchmarks run for at least 10 seconds. Configurable with `--min-duration ` + - Turn off runtime logging in bench bot to reduce spam log output +crates: +- name: frame-benchmarking-cli + bump: major +- name: asset-hub-westend-runtime + bump: patch diff --git a/substrate/utils/frame/benchmarking-cli/src/pallet/command.rs b/substrate/utils/frame/benchmarking-cli/src/pallet/command.rs index 578dabf48fda8..c77e891730398 100644 --- a/substrate/utils/frame/benchmarking-cli/src/pallet/command.rs +++ b/substrate/utils/frame/benchmarking-cli/src/pallet/command.rs @@ -58,6 +58,7 @@ use std::{ fs, str::FromStr, time, + time::Duration, }; type SubstrateAndExtraHF = ( @@ -350,7 +351,7 @@ impl PalletCmd { // Run the benchmarks let mut batches = Vec::new(); let mut batches_db = Vec::new(); - let mut timer = time::SystemTime::now(); + let mut progress_timer = time::Instant::now(); // Maps (pallet, extrinsic) to its component ranges. let mut component_ranges = HashMap::<(String, String), Vec>::new(); let pov_modes = @@ -412,30 +413,103 @@ impl PalletCmd { all_components }; - for (s, selected_components) in all_components.iter().enumerate() { - let params = |verify: bool, repeats: u32| -> Vec { - if benchmark_api_version >= 2 { - ( - pallet.as_bytes(), - instance.as_bytes(), - extrinsic.as_bytes(), - &selected_components.clone(), - verify, - repeats, - ) - .encode() - } else { - ( - pallet.as_bytes(), - extrinsic.as_bytes(), - &selected_components.clone(), - verify, - repeats, - ) - .encode() - } - }; + // Ensure each benchmark runs for at least its minimum duration. + let start = time::Instant::now(); + let mut first = true; + + loop { + for (s, selected_components) in all_components.iter().enumerate() { + let params = |verify: bool, repeats: u32| -> Vec { + if benchmark_api_version >= 2 { + ( + pallet.as_bytes(), + instance.as_bytes(), + extrinsic.as_bytes(), + &selected_components.clone(), + verify, + repeats, + ) + .encode() + } else { + ( + pallet.as_bytes(), + extrinsic.as_bytes(), + &selected_components.clone(), + verify, + repeats, + ) + .encode() + } + }; + // Maybe run a verification if we are the first iteration. + if !self.no_verify && first { + let state = &state_without_tracking; + // Don't use these results since verification code will add overhead. + let _batch: Vec = match Self::exec_state_machine::< + std::result::Result, String>, + _, + _, + >( + StateMachine::new( + state, + &mut Default::default(), + &executor, + "Benchmark_dispatch_benchmark", + ¶ms(true, 1), + &mut Self::build_extensions(executor.clone(), state.recorder()), + &runtime_code, + CallContext::Offchain, + ), + "dispatch a benchmark", + ) { + Err(e) => { + log::error!(target: LOG_TARGET, "Benchmark {pallet}::{extrinsic} failed: {e}"); + failed.push((pallet.clone(), extrinsic.clone())); + continue 'outer; + }, + Ok(Err(e)) => { + log::error!(target: LOG_TARGET, "Benchmark {pallet}::{extrinsic} failed: {e}"); + failed.push((pallet.clone(), extrinsic.clone())); + continue 'outer; + }, + Ok(Ok(b)) => b, + }; + } + // Do one loop of DB tracking. + { + let state = &state_with_tracking; + let batch: Vec = match Self::exec_state_machine::< + std::result::Result, String>, + _, + _, + >( + StateMachine::new( + state, + &mut Default::default(), + &executor, + "Benchmark_dispatch_benchmark", + ¶ms(false, 1), + &mut Self::build_extensions(executor.clone(), state.recorder()), + &runtime_code, + CallContext::Offchain, + ), + "dispatch a benchmark", + ) { + Err(e) => { + log::error!(target: LOG_TARGET, "Benchmark {pallet}::{extrinsic} failed: {e}"); + failed.push((pallet.clone(), extrinsic.clone())); + continue 'outer; + }, + Ok(Err(e)) => { + log::error!(target: LOG_TARGET, "Benchmark {pallet}::{extrinsic} failed: {e}"); + failed.push((pallet.clone(), extrinsic.clone())); + continue 'outer; + }, + Ok(Ok(b)) => b, + }; + +<<<<<<< HEAD // First we run a verification if !self.no_verify { let state = &state_without_tracking; @@ -502,11 +576,12 @@ impl PalletCmd { }, Ok(Ok(b)) => b, }; +======= + batches_db.extend(batch); + } +>>>>>>> 822c6f6f ([FRAME] Omni bencher run each benchmark at least 10 secs (#10794)) - batches_db.extend(batch); - } - // Finally run a bunch of loops to get extrinsic timing information. - for r in 0..self.external_repeat { + // Finally run a bunch of loops to get extrinsic timing information. let state = &state_without_tracking; let batch = match Self::exec_state_machine::< std::result::Result, String>, @@ -514,7 +589,7 @@ impl PalletCmd { _, >( StateMachine::new( - state, // todo remove tracking + state, &mut Default::default(), &executor, "Benchmark_dispatch_benchmark", @@ -540,29 +615,35 @@ impl PalletCmd { batches.extend(batch); - // Show progress information - if let Ok(elapsed) = timer.elapsed() { - if elapsed >= time::Duration::from_secs(5) { - timer = time::SystemTime::now(); + // Show progress information at most every 5 seconds. + if progress_timer.elapsed() >= time::Duration::from_secs(5) { + progress_timer = time::Instant::now(); - log::info!( - target: LOG_TARGET, - "[{: >3} % ] Running benchmark: {pallet}::{extrinsic}({} args) {}/{} {}/{}", - (i * 100) / benchmarks_to_run.len(), - components.len(), + let msg = if first { + format!( + "{}/{}", s + 1, // s starts at 0. - all_components.len(), - r + 1, - self.external_repeat, - ); - } + all_components.len() + ) + } else { + "(overtime)".to_string() + }; + + log::info!( + target: LOG_TARGET, + "[{: >3} % ] Running benchmark: {pallet}::{extrinsic} {msg}", + (i * 100) / benchmarks_to_run.len() + ); } } + + first = false; + if start.elapsed() >= Duration::from_secs(self.min_duration) { + break; + } } } - assert!(batches_db.len() == batches.len() / self.external_repeat as usize); - if !failed.is_empty() { failed.sort(); eprintln!( @@ -1019,6 +1100,10 @@ impl PalletCmd { unreachable!("Clap should not allow both `--runtime` and `--chain` to be provided.") } + if self.external_repeat.is_some() { + log::warn!(target: LOG_TARGET, "The `--external-repeat` argument is deprecated and will be removed in a future release."); + } + if chain_spec.is_none() && self.runtime.is_none() && self.shared_params.chain.is_none() { return Err(( ErrorKind::MissingRequiredArgument, diff --git a/substrate/utils/frame/benchmarking-cli/src/pallet/mod.rs b/substrate/utils/frame/benchmarking-cli/src/pallet/mod.rs index 7ac5c4436837a..9d390a5b298cc 100644 --- a/substrate/utils/frame/benchmarking-cli/src/pallet/mod.rs +++ b/substrate/utils/frame/benchmarking-cli/src/pallet/mod.rs @@ -87,15 +87,21 @@ pub struct PalletCmd { #[arg(long = "high", value_delimiter = ',')] pub highest_range_values: Vec, - /// Select how many repetitions of this benchmark should run from within the wasm. + /// Minimum number of repetitions of this benchmark should run from within the wasm. + /// + /// It may run more often than this to reach its `min_duration`. #[arg(short, long, default_value_t = 20)] pub repeat: u32, - /// Select how many repetitions of this benchmark should run from the client. + /// DEPRECATED: Please remove usage. + #[arg(long)] + pub external_repeat: Option, + + /// Minimum duration in seconds for each benchmark. /// - /// NOTE: Using this alone may give slower results, but will afford you maximum Wasm memory. - #[arg(long, default_value_t = 1)] - pub external_repeat: u32, + /// Can be set to 0 to disable the feature and solely rely on the `repeat` parameter. + #[arg(long, default_value_t = 10)] + pub min_duration: u64, /// Print the raw results in JSON format. #[arg(long = "json")]