referrerpolicy=no-referrer-when-downgrade

rococo_runtime/weights/
polkadot_runtime_parachains_paras.rs

1// Copyright (C) Parity Technologies (UK) Ltd.
2// This file is part of Polkadot.
3
4// Polkadot 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// Polkadot 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 Polkadot.  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-03-04, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
21//! WORST CASE MAP SIZE: `1000000`
22//! HOSTNAME: `299f3957073a`, 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/rococo-runtime/rococo_runtime.wasm
32// --pallet=polkadot_runtime_parachains::paras
33// --header=/__w/polkadot-sdk/polkadot-sdk/polkadot/file_header.txt
34// --output=./polkadot/runtime/rococo/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: 34_344_000 picoseconds.
72		Weight::from_parts(35_086_000, 0)
73			.saturating_add(Weight::from_parts(0, 11774))
74			// Standard Error: 101
75			.saturating_add(Weight::from_parts(10_734, 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_032_000 picoseconds.
87		Weight::from_parts(7_232_000, 0)
88			.saturating_add(Weight::from_parts(0, 0))
89			// Standard Error: 31
90			.saturating_add(Weight::from_parts(3_618, 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_545_000 picoseconds.
100		Weight::from_parts(3_822_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: 50_046_000 picoseconds.
128		Weight::from_parts(50_780_000, 0)
129			.saturating_add(Weight::from_parts(0, 11917))
130			// Standard Error: 101
131			.saturating_add(Weight::from_parts(10_685, 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: `Registrar::Paras` (r:1 w:0)
138	/// Proof: `Registrar::Paras` (`max_values`: None, `max_size`: None, mode: `Measured`)
139	/// Storage: `Paras::Heads` (r:0 w:1)
140	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
141	/// Storage: `Paras::UpgradeGoAheadSignal` (r:0 w:1)
142	/// Proof: `Paras::UpgradeGoAheadSignal` (`max_values`: None, `max_size`: None, mode: `Measured`)
143	/// Storage: `Paras::MostRecentContext` (r:0 w:1)
144	/// Proof: `Paras::MostRecentContext` (`max_values`: None, `max_size`: None, mode: `Measured`)
145	/// The range of component `s` is `[9, 1048576]`.
146	fn force_note_new_head(s: u32, ) -> Weight {
147		// Proof Size summary in bytes:
148		//  Measured:  `299`
149		//  Estimated: `3764`
150		// Minimum execution time: 18_737_000 picoseconds.
151		Weight::from_parts(18_995_000, 0)
152			.saturating_add(Weight::from_parts(0, 3764))
153			// Standard Error: 31
154			.saturating_add(Weight::from_parts(3_645, 0).saturating_mul(s.into()))
155			.saturating_add(T::DbWeight::get().reads(2))
156			.saturating_add(T::DbWeight::get().writes(3))
157	}
158	/// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
159	/// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
160	/// Storage: `Paras::ActionsQueue` (r:1 w:1)
161	/// Proof: `Paras::ActionsQueue` (`max_values`: None, `max_size`: None, mode: `Measured`)
162	fn force_queue_action() -> Weight {
163		// Proof Size summary in bytes:
164		//  Measured:  `4312`
165		//  Estimated: `7777`
166		// Minimum execution time: 21_058_000 picoseconds.
167		Weight::from_parts(21_657_000, 0)
168			.saturating_add(Weight::from_parts(0, 7777))
169			.saturating_add(T::DbWeight::get().reads(2))
170			.saturating_add(T::DbWeight::get().writes(1))
171	}
172	/// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
173	/// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
174	/// Storage: `Paras::PvfActiveVoteList` (r:1 w:1)
175	/// Proof: `Paras::PvfActiveVoteList` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
176	/// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
177	/// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
178	/// Storage: `Paras::ActionsQueue` (r:1 w:1)
179	/// Proof: `Paras::ActionsQueue` (`max_values`: None, `max_size`: None, mode: `Measured`)
180	/// The range of component `c` is `[9, 3145728]`.
181	fn add_trusted_validation_code(c: u32, ) -> Weight {
182		// Proof Size summary in bytes:
183		//  Measured:  `683`
184		//  Estimated: `4148`
185		// Minimum execution time: 85_102_000 picoseconds.
186		Weight::from_parts(86_779_000, 0)
187			.saturating_add(Weight::from_parts(0, 4148))
188			// Standard Error: 96
189			.saturating_add(Weight::from_parts(10_226, 0).saturating_mul(c.into()))
190			.saturating_add(T::DbWeight::get().reads(4))
191			.saturating_add(T::DbWeight::get().writes(3))
192	}
193	/// Storage: `Paras::CodeByHashRefs` (r:1 w:0)
194	/// Proof: `Paras::CodeByHashRefs` (`max_values`: None, `max_size`: None, mode: `Measured`)
195	/// Storage: `Paras::CodeByHash` (r:0 w:1)
196	/// Proof: `Paras::CodeByHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
197	fn poke_unused_validation_code() -> Weight {
198		// Proof Size summary in bytes:
199		//  Measured:  `28`
200		//  Estimated: `3493`
201		// Minimum execution time: 7_005_000 picoseconds.
202		Weight::from_parts(7_242_000, 0)
203			.saturating_add(Weight::from_parts(0, 3493))
204			.saturating_add(T::DbWeight::get().reads(1))
205			.saturating_add(T::DbWeight::get().writes(1))
206	}
207	/// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
208	/// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
209	/// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
210	/// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
211	/// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
212	/// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
213	fn include_pvf_check_statement() -> Weight {
214		// Proof Size summary in bytes:
215		//  Measured:  `26706`
216		//  Estimated: `30171`
217		// Minimum execution time: 114_183_000 picoseconds.
218		Weight::from_parts(117_660_000, 0)
219			.saturating_add(Weight::from_parts(0, 30171))
220			.saturating_add(T::DbWeight::get().reads(3))
221			.saturating_add(T::DbWeight::get().writes(1))
222	}
223	/// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
224	/// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
225	/// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
226	/// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
227	/// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
228	/// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
229	/// Storage: `Paras::PvfActiveVoteList` (r:1 w:1)
230	/// Proof: `Paras::PvfActiveVoteList` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
231	/// Storage: `Paras::UpcomingUpgrades` (r:1 w:1)
232	/// Proof: `Paras::UpcomingUpgrades` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
233	/// Storage: `Paras::FutureCodeUpgrades` (r:0 w:100)
234	/// Proof: `Paras::FutureCodeUpgrades` (`max_values`: None, `max_size`: None, mode: `Measured`)
235	fn include_pvf_check_statement_finalize_upgrade_accept() -> Weight {
236		// Proof Size summary in bytes:
237		//  Measured:  `27360`
238		//  Estimated: `30825`
239		// Minimum execution time: 701_780_000 picoseconds.
240		Weight::from_parts(717_725_000, 0)
241			.saturating_add(Weight::from_parts(0, 30825))
242			.saturating_add(T::DbWeight::get().reads(5))
243			.saturating_add(T::DbWeight::get().writes(103))
244	}
245	/// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
246	/// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
247	/// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
248	/// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
249	/// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
250	/// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
251	fn include_pvf_check_statement_finalize_upgrade_reject() -> Weight {
252		// Proof Size summary in bytes:
253		//  Measured:  `27338`
254		//  Estimated: `30803`
255		// Minimum execution time: 111_232_000 picoseconds.
256		Weight::from_parts(116_478_000, 0)
257			.saturating_add(Weight::from_parts(0, 30803))
258			.saturating_add(T::DbWeight::get().reads(3))
259			.saturating_add(T::DbWeight::get().writes(1))
260	}
261	/// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
262	/// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
263	/// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
264	/// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
265	/// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
266	/// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
267	/// Storage: `Paras::PvfActiveVoteList` (r:1 w:1)
268	/// Proof: `Paras::PvfActiveVoteList` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
269	/// Storage: `Paras::ActionsQueue` (r:1 w:1)
270	/// Proof: `Paras::ActionsQueue` (`max_values`: None, `max_size`: None, mode: `Measured`)
271	fn include_pvf_check_statement_finalize_onboarding_accept() -> Weight {
272		// Proof Size summary in bytes:
273		//  Measured:  `26728`
274		//  Estimated: `30193`
275		// Minimum execution time: 566_791_000 picoseconds.
276		Weight::from_parts(588_058_000, 0)
277			.saturating_add(Weight::from_parts(0, 30193))
278			.saturating_add(T::DbWeight::get().reads(5))
279			.saturating_add(T::DbWeight::get().writes(3))
280	}
281	/// Storage: `ParasShared::ActiveValidatorKeys` (r:1 w:0)
282	/// Proof: `ParasShared::ActiveValidatorKeys` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
283	/// Storage: `ParasShared::CurrentSessionIndex` (r:1 w:0)
284	/// Proof: `ParasShared::CurrentSessionIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
285	/// Storage: `Paras::PvfActiveVoteMap` (r:1 w:1)
286	/// Proof: `Paras::PvfActiveVoteMap` (`max_values`: None, `max_size`: None, mode: `Measured`)
287	fn include_pvf_check_statement_finalize_onboarding_reject() -> Weight {
288		// Proof Size summary in bytes:
289		//  Measured:  `26706`
290		//  Estimated: `30171`
291		// Minimum execution time: 106_546_000 picoseconds.
292		Weight::from_parts(112_236_000, 0)
293			.saturating_add(Weight::from_parts(0, 30171))
294			.saturating_add(T::DbWeight::get().reads(3))
295			.saturating_add(T::DbWeight::get().writes(1))
296	}
297
298	fn remove_upgrade_cooldown() -> Weight {
299		// JUST COPIED AND WILL BE UPDATED NEXT TIME
300		Weight::from_parts(107_759_000, 0)
301			.saturating_add(Weight::from_parts(0, 30171))
302			.saturating_add(T::DbWeight::get().reads(3))
303			.saturating_add(T::DbWeight::get().writes(1))
304	}
305
306	/// Storage: `Paras::AuthorizedCodeHash` (r:0 w:1)
307	/// Proof: `Paras::AuthorizedCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
308	fn authorize_force_set_current_code_hash() -> Weight {
309		// Proof Size summary in bytes:
310		//  Measured:  `0`
311		//  Estimated: `0`
312		// Minimum execution time: 8_217_000 picoseconds.
313		Weight::from_parts(8_415_000, 0)
314			.saturating_add(Weight::from_parts(0, 0))
315			.saturating_add(T::DbWeight::get().writes(1))
316	}
317	/// Storage: `Paras::AuthorizedCodeHash` (r:1 w:1)
318	/// Proof: `Paras::AuthorizedCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
319	/// Storage: `Paras::CodeByHashRefs` (r:1 w:1)
320	/// Proof: `Paras::CodeByHashRefs` (`max_values`: None, `max_size`: None, mode: `Measured`)
321	/// Storage: `Paras::CurrentCodeHash` (r:1 w:1)
322	/// Proof: `Paras::CurrentCodeHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
323	/// Storage: `Paras::CodeByHash` (r:0 w:1)
324	/// Proof: `Paras::CodeByHash` (`max_values`: None, `max_size`: None, mode: `Measured`)
325	/// The range of component `c` is `[9, 3145728]`.
326	fn apply_authorized_force_set_current_code(c: u32, ) -> Weight {
327		// Proof Size summary in bytes:
328		//  Measured:  `132`
329		//  Estimated: `3597`
330		// Minimum execution time: 29_238_000 picoseconds.
331		Weight::from_parts(29_741_000, 0)
332			.saturating_add(Weight::from_parts(0, 3597))
333			// Standard Error: 103
334			.saturating_add(Weight::from_parts(12_157, 0).saturating_mul(c.into()))
335			.saturating_add(T::DbWeight::get().reads(3))
336			.saturating_add(T::DbWeight::get().writes(4))
337	}
338}