pallet_registrar_para/weights.rs
1// This file is part of Substrate.
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// This file is part of Substrate.
19
20// Copyright (C) Parity Technologies (UK) Ltd.
21// SPDX-License-Identifier: Apache-2.0
22
23// Licensed under the Apache License, Version 2.0 (the "License");
24// you may not use this file except in compliance with the License.
25// You may obtain a copy of the License at
26//
27// http://www.apache.org/licenses/LICENSE-2.0
28//
29// Unless required by applicable law or agreed to in writing, software
30// distributed under the License is distributed on an "AS IS" BASIS,
31// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
32// See the License for the specific language governing permissions and
33// limitations under the License.
34
35//! Autogenerated weights for `pallet_registrar_para`
36//!
37//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0
38//! DATE: 2026-09-03, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
39//! WORST CASE MAP SIZE: `1000000`
40//! HOSTNAME: `unknown`, CPU: `<UNKNOWN>`
41//! WASM-EXECUTION: `Compiled`, CHAIN: `None`, DB CACHE: `1024`
42
43// Executed Command:
44// ./target/release/frame-omni-bencher
45// v1
46// benchmark
47// pallet
48// --extrinsic=*
49// --runtime=target/release/wbuild/kitchensink-runtime/kitchensink_runtime.wasm
50// --pallet=pallet_registrar_para
51// --header=substrate/HEADER-APACHE2
52// --output=substrate/frame/registrar/para/src/weights.rs
53// --wasm-execution=compiled
54// --steps=50
55// --repeat=20
56// --heap-pages=4096
57// --template=substrate/.maintain/frame-weight-template.hbs
58// --no-storage-info
59// --no-min-squares
60// --no-median-slopes
61// --genesis-builder-policy=none
62
63#![cfg_attr(rustfmt, rustfmt_skip)]
64#![allow(unused_parens)]
65#![allow(unused_imports)]
66#![allow(missing_docs)]
67#![allow(dead_code)]
68
69use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
70use core::marker::PhantomData;
71
72/// Weight functions needed for `pallet_registrar_para`.
73pub trait WeightInfo {
74 fn reserve() -> Weight;
75 fn register(h: u32, ) -> Weight;
76 fn cancel_registration() -> Weight;
77 fn receive() -> Weight;
78 fn add_lock() -> Weight;
79 fn remove_lock() -> Weight;
80}
81
82/// Weights for `pallet_registrar_para` using the Substrate node and recommended hardware.
83pub struct SubstrateWeight<T>(PhantomData<T>);
84impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
85 /// Storage: `RegistrarPara::NextFreeParaId` (r:1 w:1)
86 /// Proof: `RegistrarPara::NextFreeParaId` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
87 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
88 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
89 /// Storage: `System::Account` (r:1 w:1)
90 /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
91 /// Storage: `Balances::Holds` (r:1 w:1)
92 /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(607), added: 3082, mode: `MaxEncodedLen`)
93 fn reserve() -> Weight {
94 // Proof Size summary in bytes:
95 // Measured: `52`
96 // Estimated: `4072`
97 // Minimum execution time: 32_000_000 picoseconds.
98 Weight::from_parts(34_000_000, 4072)
99 .saturating_add(T::DbWeight::get().reads(4_u64))
100 .saturating_add(T::DbWeight::get().writes(4_u64))
101 }
102 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
103 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
104 /// Storage: `System::Account` (r:1 w:1)
105 /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
106 /// Storage: `Balances::Holds` (r:1 w:1)
107 /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(607), added: 3082, mode: `MaxEncodedLen`)
108 /// Storage: `RegistrarPara::NextMessageId` (r:1 w:1)
109 /// Proof: `RegistrarPara::NextMessageId` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`)
110 /// The range of component `h` is `[0, 1048576]`.
111 fn register(h: u32, ) -> Weight {
112 // Proof Size summary in bytes:
113 // Measured: `212`
114 // Estimated: `4072`
115 // Minimum execution time: 36_000_000 picoseconds.
116 Weight::from_parts(44_960_199, 4072)
117 // Standard Error: 0
118 .saturating_add(Weight::from_parts(157, 0).saturating_mul(h.into()))
119 .saturating_add(T::DbWeight::get().reads(4_u64))
120 .saturating_add(T::DbWeight::get().writes(4_u64))
121 }
122 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
123 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
124 /// Storage: `RegistrarPara::NextMessageId` (r:1 w:1)
125 /// Proof: `RegistrarPara::NextMessageId` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`)
126 fn cancel_registration() -> Weight {
127 // Proof Size summary in bytes:
128 // Measured: `153`
129 // Estimated: `3555`
130 // Minimum execution time: 8_000_000 picoseconds.
131 Weight::from_parts(9_000_000, 3555)
132 .saturating_add(T::DbWeight::get().reads(2_u64))
133 .saturating_add(T::DbWeight::get().writes(2_u64))
134 }
135 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
136 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
137 /// Storage: `System::Account` (r:1 w:1)
138 /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
139 /// Storage: `Balances::Holds` (r:1 w:1)
140 /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(607), added: 3082, mode: `MaxEncodedLen`)
141 fn receive() -> Weight {
142 // Proof Size summary in bytes:
143 // Measured: `281`
144 // Estimated: `4072`
145 // Minimum execution time: 29_000_000 picoseconds.
146 Weight::from_parts(33_000_000, 4072)
147 .saturating_add(T::DbWeight::get().reads(3_u64))
148 .saturating_add(T::DbWeight::get().writes(3_u64))
149 }
150 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
151 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
152 fn add_lock() -> Weight {
153 // Proof Size summary in bytes:
154 // Measured: `149`
155 // Estimated: `3555`
156 // Minimum execution time: 8_000_000 picoseconds.
157 Weight::from_parts(9_000_000, 3555)
158 .saturating_add(T::DbWeight::get().reads(1_u64))
159 .saturating_add(T::DbWeight::get().writes(1_u64))
160 }
161 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
162 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
163 fn remove_lock() -> Weight {
164 // Proof Size summary in bytes:
165 // Measured: `149`
166 // Estimated: `3555`
167 // Minimum execution time: 7_000_000 picoseconds.
168 Weight::from_parts(8_000_000, 3555)
169 .saturating_add(T::DbWeight::get().reads(1_u64))
170 .saturating_add(T::DbWeight::get().writes(1_u64))
171 }
172}
173
174// For backwards compatibility and tests.
175impl WeightInfo for () {
176 /// Storage: `RegistrarPara::NextFreeParaId` (r:1 w:1)
177 /// Proof: `RegistrarPara::NextFreeParaId` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
178 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
179 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
180 /// Storage: `System::Account` (r:1 w:1)
181 /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
182 /// Storage: `Balances::Holds` (r:1 w:1)
183 /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(607), added: 3082, mode: `MaxEncodedLen`)
184 fn reserve() -> Weight {
185 // Proof Size summary in bytes:
186 // Measured: `52`
187 // Estimated: `4072`
188 // Minimum execution time: 32_000_000 picoseconds.
189 Weight::from_parts(34_000_000, 4072)
190 .saturating_add(RocksDbWeight::get().reads(4_u64))
191 .saturating_add(RocksDbWeight::get().writes(4_u64))
192 }
193 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
194 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
195 /// Storage: `System::Account` (r:1 w:1)
196 /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
197 /// Storage: `Balances::Holds` (r:1 w:1)
198 /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(607), added: 3082, mode: `MaxEncodedLen`)
199 /// Storage: `RegistrarPara::NextMessageId` (r:1 w:1)
200 /// Proof: `RegistrarPara::NextMessageId` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`)
201 /// The range of component `h` is `[0, 1048576]`.
202 fn register(h: u32, ) -> Weight {
203 // Proof Size summary in bytes:
204 // Measured: `212`
205 // Estimated: `4072`
206 // Minimum execution time: 36_000_000 picoseconds.
207 Weight::from_parts(44_960_199, 4072)
208 // Standard Error: 0
209 .saturating_add(Weight::from_parts(157, 0).saturating_mul(h.into()))
210 .saturating_add(RocksDbWeight::get().reads(4_u64))
211 .saturating_add(RocksDbWeight::get().writes(4_u64))
212 }
213 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
214 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
215 /// Storage: `RegistrarPara::NextMessageId` (r:1 w:1)
216 /// Proof: `RegistrarPara::NextMessageId` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`)
217 fn cancel_registration() -> Weight {
218 // Proof Size summary in bytes:
219 // Measured: `153`
220 // Estimated: `3555`
221 // Minimum execution time: 8_000_000 picoseconds.
222 Weight::from_parts(9_000_000, 3555)
223 .saturating_add(RocksDbWeight::get().reads(2_u64))
224 .saturating_add(RocksDbWeight::get().writes(2_u64))
225 }
226 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
227 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
228 /// Storage: `System::Account` (r:1 w:1)
229 /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
230 /// Storage: `Balances::Holds` (r:1 w:1)
231 /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(607), added: 3082, mode: `MaxEncodedLen`)
232 fn receive() -> Weight {
233 // Proof Size summary in bytes:
234 // Measured: `281`
235 // Estimated: `4072`
236 // Minimum execution time: 29_000_000 picoseconds.
237 Weight::from_parts(33_000_000, 4072)
238 .saturating_add(RocksDbWeight::get().reads(3_u64))
239 .saturating_add(RocksDbWeight::get().writes(3_u64))
240 }
241 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
242 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
243 fn add_lock() -> Weight {
244 // Proof Size summary in bytes:
245 // Measured: `149`
246 // Estimated: `3555`
247 // Minimum execution time: 8_000_000 picoseconds.
248 Weight::from_parts(9_000_000, 3555)
249 .saturating_add(RocksDbWeight::get().reads(1_u64))
250 .saturating_add(RocksDbWeight::get().writes(1_u64))
251 }
252 /// Storage: `RegistrarPara::Paras` (r:1 w:1)
253 /// Proof: `RegistrarPara::Paras` (`max_values`: None, `max_size`: Some(90), added: 2565, mode: `MaxEncodedLen`)
254 fn remove_lock() -> Weight {
255 // Proof Size summary in bytes:
256 // Measured: `149`
257 // Estimated: `3555`
258 // Minimum execution time: 7_000_000 picoseconds.
259 Weight::from_parts(8_000_000, 3555)
260 .saturating_add(RocksDbWeight::get().reads(1_u64))
261 .saturating_add(RocksDbWeight::get().writes(1_u64))
262 }
263}