pallet_hotfix_sufficients/weights.rs
1// This file is part of Frontier.
2
3// Copyright (C) Parity Technologies (UK) Ltd.
4// SPDX-License-Identifier: Apache-2.0
5
6// Licensed under the Apache License, Version 2.0 (the "License");
7// you may not use this file except in compliance with the License.
8// You may obtain a copy of the License at
9//
10// http://www.apache.org/licenses/LICENSE-2.0
11//
12// Unless required by applicable law or agreed to in writing, software
13// distributed under the License is distributed on an "AS IS" BASIS,
14// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15// See the License for the specific language governing permissions and
16// limitations under the License.
17
18//! Autogenerated weights for pallet_hotfix_sufficients
19//!
20//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev
21//! DATE: 2023-05-06, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
22//! WORST CASE MAP SIZE: `1000000`
23//! HOSTNAME: `archlinux`, CPU: `AMD Ryzen 9 5900X 12-Core Processor`
24//! EXECUTION: Some(Wasm), WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024
25
26// Executed Command:
27// ./target/release/frontier-template-node
28// benchmark
29// pallet
30// --chain=dev
31// --steps=50
32// --repeat=20
33// --pallet=pallet_hotfix_sufficients
34// --extrinsic=hotfix_inc_account_sufficients
35// --execution=wasm
36// --wasm-execution=compiled
37// --output=weights.rs
38// --header=./.maintain/HEADER-APACHE2
39// --template=./.maintain/frame-weight-template.hbs
40
41#![cfg_attr(rustfmt, rustfmt_skip)]
42#![allow(unused_parens)]
43#![allow(unused_imports)]
44#![allow(missing_docs)]
45
46use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
47use core::marker::PhantomData;
48
49/// Weight functions needed for pallet_hotfix_sufficients.
50pub trait WeightInfo {
51 fn hotfix_inc_account_sufficients(n: u32, ) -> Weight;
52}
53
54/// Weights for pallet_hotfix_sufficients using the Substrate node and recommended hardware.
55pub struct SubstrateWeight<T>(PhantomData<T>);
56impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
57 /// Storage: System Account (r:1000 w:1000)
58 /// Proof: System Account (max_values: None, max_size: Some(116), added: 2591, mode: MaxEncodedLen)
59 /// Storage: System Number (r:1 w:0)
60 /// Proof: System Number (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)
61 /// Storage: System ExecutionPhase (r:1 w:0)
62 /// Proof: System ExecutionPhase (max_values: Some(1), max_size: Some(5), added: 500, mode: MaxEncodedLen)
63 /// Storage: System EventCount (r:1 w:1)
64 /// Proof: System EventCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)
65 /// Storage: System Events (r:1 w:1)
66 /// Proof Skipped: System Events (max_values: Some(1), max_size: None, mode: Measured)
67 /// The range of component `n` is `[0, 1000]`.
68 fn hotfix_inc_account_sufficients(n: u32, ) -> Weight {
69 // Proof Size summary in bytes:
70 // Measured: `0 + n * (124 ±0)`
71 // Estimated: `6572 + n * (2715 ±0)`
72 // Minimum execution time: 2_000_000 picoseconds.
73 Weight::from_parts(2_000_000, 6572)
74 // Standard Error: 12_231
75 .saturating_add(Weight::from_parts(15_224_397, 0).saturating_mul(n.into()))
76 .saturating_add(T::DbWeight::get().reads(4_u64))
77 .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(n.into())))
78 .saturating_add(T::DbWeight::get().writes(2_u64))
79 .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(n.into())))
80 .saturating_add(Weight::from_parts(0, 2715).saturating_mul(n.into()))
81 }
82}
83
84// For backwards compatibility and tests
85impl WeightInfo for () {
86 /// Storage: System Account (r:1000 w:1000)
87 /// Proof: System Account (max_values: None, max_size: Some(116), added: 2591, mode: MaxEncodedLen)
88 /// Storage: System Number (r:1 w:0)
89 /// Proof: System Number (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)
90 /// Storage: System ExecutionPhase (r:1 w:0)
91 /// Proof: System ExecutionPhase (max_values: Some(1), max_size: Some(5), added: 500, mode: MaxEncodedLen)
92 /// Storage: System EventCount (r:1 w:1)
93 /// Proof: System EventCount (max_values: Some(1), max_size: Some(4), added: 499, mode: MaxEncodedLen)
94 /// Storage: System Events (r:1 w:1)
95 /// Proof Skipped: System Events (max_values: Some(1), max_size: None, mode: Measured)
96 /// The range of component `n` is `[0, 1000]`.
97 fn hotfix_inc_account_sufficients(n: u32, ) -> Weight {
98 // Proof Size summary in bytes:
99 // Measured: `0 + n * (124 ±0)`
100 // Estimated: `6572 + n * (2715 ±0)`
101 // Minimum execution time: 2_000_000 picoseconds.
102 Weight::from_parts(2_000_000, 6572)
103 // Standard Error: 12_231
104 .saturating_add(Weight::from_parts(15_224_397, 0).saturating_mul(n.into()))
105 .saturating_add(RocksDbWeight::get().reads(4_u64))
106 .saturating_add(RocksDbWeight::get().reads((1_u64).saturating_mul(n.into())))
107 .saturating_add(RocksDbWeight::get().writes(2_u64))
108 .saturating_add(RocksDbWeight::get().writes((1_u64).saturating_mul(n.into())))
109 .saturating_add(Weight::from_parts(0, 2715).saturating_mul(n.into()))
110 }
111}