pallet_staking_async_rc_runtime/weights/polkadot_runtime_parachains_paras.rs
1// Copyright (C) Parity Technologies (UK) Ltd.
2// This file is part of Substrate.
3
4// Substrate is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8
9// Substrate is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13
14// You should have received a copy of the GNU General Public License
15// along with Substrate. If not, see <http://www.gnu.org/licenses/>.
16
17//! Autogenerated weights for `polkadot_runtime_parachains::paras`
18//!
19//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0
20//! DATE: 2025-02-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
21//! WORST CASE MAP SIZE: `1000000`
22//! HOSTNAME: `3a2e9ae8a8f5`, CPU: `Intel(R) Xeon(R) CPU @ 2.60GHz`
23//! WASM-EXECUTION: `Compiled`, CHAIN: `None`, DB CACHE: 1024
24
25// Executed Command:
26// frame-omni-bencher
27// v1
28// benchmark
29// pallet
30// --extrinsic=*
31// --runtime=target/production/wbuild/westend-runtime/westend_runtime.wasm
32// --pallet=polkadot_runtime_parachains::paras
33// --header=/__w/polkadot-sdk/polkadot-sdk/polkadot/file_header.txt
34// --output=./polkadot/runtime/westend/src/weights
35// --wasm-execution=compiled
36// --steps=50
37// --repeat=20
38// --heap-pages=4096
39// --no-storage-info
40// --no-min-squares
41// --no-median-slopes
42
43#![cfg_attr(rustfmt, rustfmt_skip)]
44#![allow(unused_parens)]
45#![allow(unused_imports)]
46#![allow(missing_docs)]
47
48use frame_support::{traits::Get, weights::Weight};
49use core::marker::PhantomData;
50
51/// Weight functions for `polkadot_runtime_parachains::paras`.
52pub struct WeightInfo<T>(PhantomData<T>);
53impl<T: frame_system::Config> polkadot_runtime_parachains::paras::WeightInfo for WeightInfo<T> {
54 /// Storage: `Paras::CodeByHashRefs` (r:1 w:1)
55 /// Proof: `Paras::CodeByHashRefs` (`max_values`: None, `max_size`: None, mode: `Measured`)
56 /// Storage: `Paras::CurrentCodeHash` (r:1 w:1)
57 /// Proof: `Paras::CurrentCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
58 /// Storage: `Paras::PastCodeMeta` (r:1 w:1)
59 /// Proof: `Paras::PastCodeMeta` (`max_values`: None, `max_size`: None, mode: `Measured`)
60 /// Storage: `Paras::PastCodePruning` (r:1 w:1)
61 /// Proof: `Paras::PastCodePruning` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
62 /// Storage: `Paras::PastCodeHash` (r:0 w:1)
63 /// Proof: `Paras::PastCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
64 /// Storage: `Paras::CodeByHash` (r:0 w:1)
65 /// Proof: `Paras::CodeByHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
66 /// The range of component `c` is `[9, 3145728]`.
67 fn force_set_current_code(c: u32, ) -> Weight {
68 // Proof Size summary in bytes:
69 // Measured: `8309`
70 // Estimated: `11774`
71 // Minimum execution time: 38_573_000 picoseconds.
72 Weight::from_parts(39_400_000, 0)
73 .saturating_add(Weight::from_parts(0, 11774))
74 // Standard Error: 128
75 .saturating_add(Weight::from_parts(13_197, 0).saturating_mul(c.into()))
76 .saturating_add(T::DbWeight::get().reads(4))
77 .saturating_add(T::DbWeight::get().writes(6))
78 }
79 /// Storage: `Paras::Heads` (r:0 w:1)
80 /// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
81 /// The range of component `s` is `[9, 1048576]`.
82 fn force_set_current_head(s: u32, ) -> Weight {
83 // Proof Size summary in bytes:
84 // Measured: `0`
85 // Estimated: `0`
86 // Minimum execution time: 7_110_000 picoseconds.
87 Weight::from_parts(7_328_000, 0)
88 .saturating_add(Weight::from_parts(0, 0))
89 // Standard Error: 41
90 .saturating_add(Weight::from_parts(4_535, 0).saturating_mul(s.into()))
91 .saturating_add(T::DbWeight::get().writes(1))
92 }
93 /// Storage: `Paras::MostRecentContext` (r:0 w:1)
94 /// Proof: `Paras::MostRecentContext` (`max_values`: None, `max_size`: None, mode: `Measured`)
95 fn force_set_most_recent_context() -> Weight {
96 // Proof Size summary in bytes:
97 // Measured: `0`
98 // Estimated: `0`
99 // Minimum execution time: 3_564_000 picoseconds.
100 Weight::from_parts(3_677_000, 0)
101 .saturating_add(Weight::from_parts(0, 0))
102 .saturating_add(T::DbWeight::get().writes(1))
103 }
104 /// Storage: `Paras::FutureCodeHash` (r:1 w:1)
105 /// Proof: `Paras::FutureCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
106 /// Storage: `Paras::CurrentCodeHash` (r:1 w:0)
107 /// Proof: `Paras::CurrentCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
108 /// Storage: `Paras::UpgradeCooldowns` (r:1 w:1)
109 /// Proof: `Paras::UpgradeCooldowns` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
110 /// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
111 /// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
112 /// Storage: `Paras::CodeByHash` (r:1 w:1)
113 /// Proof: `Paras::CodeByHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
114 /// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
115 /// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
116 /// Storage: `Paras::PvfActiveVoteList` (r:1 w:1)
117 /// Proof: `Paras::PvfActiveVoteList` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
118 /// Storage: `Paras::CodeByHashRefs` (r:1 w:1)
119 /// Proof: `Paras::CodeByHashRefs` (`max_values`: None, `max_size`: None, mode: `Measured`)
120 /// Storage: `Paras::UpgradeRestrictionSignal` (r:0 w:1)
121 /// Proof: `Paras::UpgradeRestrictionSignal` (`max_values`: None, `max_size`: None, mode: `Measured`)
122 /// The range of component `c` is `[9, 3145728]`.
123 fn force_schedule_code_upgrade(c: u32, ) -> Weight {
124 // Proof Size summary in bytes:
125 // Measured: `8452`
126 // Estimated: `11917`
127 // Minimum execution time: 52_408_000 picoseconds.
128 Weight::from_parts(53_467_000, 0)
129 .saturating_add(Weight::from_parts(0, 11917))
130 // Standard Error: 129
131 .saturating_add(Weight::from_parts(13_193, 0).saturating_mul(c.into()))
132 .saturating_add(T::DbWeight::get().reads(8))
133 .saturating_add(T::DbWeight::get().writes(7))
134 }
135 /// Storage: `Paras::FutureCodeUpgrades` (r:1 w:0)
136 /// Proof: `Paras::FutureCodeUpgrades` (`max_values`: None, `max_size`: None, mode: `Measured`)
137 /// Storage: `Paras::Heads` (r:0 w:1)
138 /// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
139 /// Storage: `Paras::UpgradeGoAheadSignal` (r:0 w:1)
140 /// Proof: `Paras::UpgradeGoAheadSignal` (`max_values`: None, `max_size`: None, mode: `Measured`)
141 /// Storage: `Paras::MostRecentContext` (r:0 w:1)
142 /// Proof: `Paras::MostRecentContext` (`max_values`: None, `max_size`: None, mode: `Measured`)
143 /// The range of component `s` is `[9, 1048576]`.
144 fn force_note_new_head(s: u32, ) -> Weight {
145 // Proof Size summary in bytes:
146 // Measured: `268`
147 // Estimated: `3733`
148 // Minimum execution time: 14_751_000 picoseconds.
149 Weight::from_parts(15_033_000, 0)
150 .saturating_add(Weight::from_parts(0, 3733))
151 // Standard Error: 41
152 .saturating_add(Weight::from_parts(4_536, 0).saturating_mul(s.into()))
153 .saturating_add(T::DbWeight::get().reads(1))
154 .saturating_add(T::DbWeight::get().writes(3))
155 }
156 /// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
157 /// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
158 /// Storage: `Paras::ActionsQueue` (r:1 w:1)
159 /// Proof: `Paras::ActionsQueue` (`max_values`: None, `max_size`: None, mode: `Measured`)
160 fn force_queue_action() -> Weight {
161 // Proof Size summary in bytes:
162 // Measured: `4312`
163 // Estimated: `7777`
164 // Minimum execution time: 24_624_000 picoseconds.
165 Weight::from_parts(25_772_000, 0)
166 .saturating_add(Weight::from_parts(0, 7777))
167 .saturating_add(T::DbWeight::get().reads(2))
168 .saturating_add(T::DbWeight::get().writes(1))
169 }
170 /// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
171 /// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
172 /// Storage: `Paras::PvfActiveVoteList` (r:1 w:1)
173 /// Proof: `Paras::PvfActiveVoteList` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
174 /// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
175 /// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
176 /// Storage: `Paras::ActionsQueue` (r:1 w:1)
177 /// Proof: `Paras::ActionsQueue` (`max_values`: None, `max_size`: None, mode: `Measured`)
178 /// The range of component `c` is `[9, 3145728]`.
179 fn add_trusted_validation_code(c: u32, ) -> Weight {
180 // Proof Size summary in bytes:
181 // Measured: `683`
182 // Estimated: `4148`
183 // Minimum execution time: 89_347_000 picoseconds.
184 Weight::from_parts(91_876_000, 0)
185 .saturating_add(Weight::from_parts(0, 4148))
186 // Standard Error: 127
187 .saturating_add(Weight::from_parts(12_741, 0).saturating_mul(c.into()))
188 .saturating_add(T::DbWeight::get().reads(4))
189 .saturating_add(T::DbWeight::get().writes(3))
190 }
191 /// Storage: `Paras::CodeByHashRefs` (r:1 w:0)
192 /// Proof: `Paras::CodeByHashRefs` (`max_values`: None, `max_size`: None, mode: `Measured`)
193 /// Storage: `Paras::CodeByHash` (r:0 w:1)
194 /// Proof: `Paras::CodeByHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
195 fn poke_unused_validation_code() -> Weight {
196 // Proof Size summary in bytes:
197 // Measured: `28`
198 // Estimated: `3493`
199 // Minimum execution time: 6_736_000 picoseconds.
200 Weight::from_parts(7_018_000, 0)
201 .saturating_add(Weight::from_parts(0, 3493))
202 .saturating_add(T::DbWeight::get().reads(1))
203 .saturating_add(T::DbWeight::get().writes(1))
204 }
205 /// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
206 /// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
207 /// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
208 /// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
209 /// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
210 /// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
211 fn include_pvf_check_statement() -> Weight {
212 // Proof Size summary in bytes:
213 // Measured: `26706`
214 // Estimated: `30171`
215 // Minimum execution time: 112_868_000 picoseconds.
216 Weight::from_parts(115_588_000, 0)
217 .saturating_add(Weight::from_parts(0, 30171))
218 .saturating_add(T::DbWeight::get().reads(3))
219 .saturating_add(T::DbWeight::get().writes(1))
220 }
221 /// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
222 /// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
223 /// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
224 /// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
225 /// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
226 /// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
227 /// Storage: `Paras::PvfActiveVoteList` (r:1 w:1)
228 /// Proof: `Paras::PvfActiveVoteList` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
229 /// Storage: `Paras::UpcomingUpgrades` (r:1 w:1)
230 /// Proof: `Paras::UpcomingUpgrades` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
231 /// Storage: `Paras::FutureCodeUpgrades` (r:0 w:100)
232 /// Proof: `Paras::FutureCodeUpgrades` (`max_values`: None, `max_size`: None, mode: `Measured`)
233 fn include_pvf_check_statement_finalize_upgrade_accept() -> Weight {
234 // Proof Size summary in bytes:
235 // Measured: `27360`
236 // Estimated: `30825`
237 // Minimum execution time: 773_659_000 picoseconds.
238 Weight::from_parts(794_204_000, 0)
239 .saturating_add(Weight::from_parts(0, 30825))
240 .saturating_add(T::DbWeight::get().reads(5))
241 .saturating_add(T::DbWeight::get().writes(103))
242 }
243 /// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
244 /// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
245 /// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
246 /// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
247 /// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
248 /// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
249 fn include_pvf_check_statement_finalize_upgrade_reject() -> Weight {
250 // Proof Size summary in bytes:
251 // Measured: `27338`
252 // Estimated: `30803`
253 // Minimum execution time: 108_485_000 picoseconds.
254 Weight::from_parts(113_249_000, 0)
255 .saturating_add(Weight::from_parts(0, 30803))
256 .saturating_add(T::DbWeight::get().reads(3))
257 .saturating_add(T::DbWeight::get().writes(1))
258 }
259 /// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
260 /// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
261 /// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
262 /// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
263 /// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
264 /// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
265 /// Storage: `Paras::PvfActiveVoteList` (r:1 w:1)
266 /// Proof: `Paras::PvfActiveVoteList` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
267 /// Storage: `Paras::ActionsQueue` (r:1 w:1)
268 /// Proof: `Paras::ActionsQueue` (`max_values`: None, `max_size`: None, mode: `Measured`)
269 fn include_pvf_check_statement_finalize_onboarding_accept() -> Weight {
270 // Proof Size summary in bytes:
271 // Measured: `26728`
272 // Estimated: `30193`
273 // Minimum execution time: 635_656_000 picoseconds.
274 Weight::from_parts(643_507_000, 0)
275 .saturating_add(Weight::from_parts(0, 30193))
276 .saturating_add(T::DbWeight::get().reads(5))
277 .saturating_add(T::DbWeight::get().writes(3))
278 }
279 /// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
280 /// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
281 /// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
282 /// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
283 /// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
284 /// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
285 fn include_pvf_check_statement_finalize_onboarding_reject() -> Weight {
286 // Proof Size summary in bytes:
287 // Measured: `26706`
288 // Estimated: `30171`
289 // Minimum execution time: 103_358_000 picoseconds.
290 Weight::from_parts(107_759_000, 0)
291 .saturating_add(Weight::from_parts(0, 30171))
292 .saturating_add(T::DbWeight::get().reads(3))
293 .saturating_add(T::DbWeight::get().writes(1))
294 }
295
296 fn remove_upgrade_cooldown() -> Weight {
297 // Proof Size summary in bytes:
298 // Measured: `26706`
299 // Estimated: `30171`
300 // Minimum execution time: 103_358_000 picoseconds.
301 Weight::from_parts(107_759_000, 0)
302 .saturating_add(Weight::from_parts(0, 30171))
303 .saturating_add(T::DbWeight::get().reads(3))
304 .saturating_add(T::DbWeight::get().writes(1))
305 }
306
307 /// Storage: `Paras::AuthorizedCodeHash` (r:0 w:1)
308 /// Proof: `Paras::AuthorizedCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
309 fn authorize_force_set_current_code_hash() -> Weight {
310 // Proof Size summary in bytes:
311 // Measured: `0`
312 // Estimated: `0`
313 // Minimum execution time: 8_112_000 picoseconds.
314 Weight::from_parts(8_401_000, 0)
315 .saturating_add(Weight::from_parts(0, 0))
316 .saturating_add(T::DbWeight::get().writes(1))
317 }
318 /// Storage: `Paras::AuthorizedCodeHash` (r:1 w:1)
319 /// Proof: `Paras::AuthorizedCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
320 /// Storage: `Paras::CodeByHashRefs` (r:1 w:1)
321 /// Proof: `Paras::CodeByHashRefs` (`max_values`: None, `max_size`: None, mode: `Measured`)
322 /// Storage: `Paras::CurrentCodeHash` (r:1 w:1)
323 /// Proof: `Paras::CurrentCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
324 /// Storage: `Paras::CodeByHash` (r:0 w:1)
325 /// Proof: `Paras::CodeByHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
326 /// The range of component `c` is `[9, 3145728]`.
327 fn apply_authorized_force_set_current_code(c: u32, ) -> Weight {
328 // Proof Size summary in bytes:
329 // Measured: `132`
330 // Estimated: `3597`
331 // Minimum execution time: 32_733_000 picoseconds.
332 Weight::from_parts(33_172_000, 0)
333 .saturating_add(Weight::from_parts(0, 3597))
334 // Standard Error: 133
335 .saturating_add(Weight::from_parts(14_731, 0).saturating_mul(c.into()))
336 .saturating_add(T::DbWeight::get().reads(3))
337 .saturating_add(T::DbWeight::get().writes(4))
338 }
339}