moonbase_runtime/weights/cumulus_pallet_xcmp_queue.rs
1// Copyright 2025 Moonbeam foundation
2// This file is part of Moonbeam.
3
4// Moonbeam 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// Moonbeam 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 Moonbeam. If not, see <http://www.gnu.org/licenses/>.
16
17
18//! Autogenerated weights for `cumulus_pallet_xcmp_queue`
19//!
20//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 49.0.0
21//! DATE: 2025-12-09, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
22//! WORST CASE MAP SIZE: `1000000`
23//! HOSTNAME: `ip-10-0-0-198`, CPU: `Intel(R) Xeon(R) Platinum 8375C CPU @ 2.90GHz`
24//! WASM-EXECUTION: Compiled, CHAIN: None, DB CACHE: 1024
25
26// Executed Command:
27// ./frame-omni-bencher
28// v1
29// benchmark
30// pallet
31// --runtime=./target/production/wbuild/moonbase-runtime/moonbase_runtime.wasm
32// --genesis-builder=runtime
33// --genesis-builder-preset=development
34// --steps=50
35// --repeat=20
36// --pallet=cumulus_pallet_xcmp_queue
37// --extrinsic=*
38// --wasm-execution=compiled
39// --header=./file_header.txt
40// --template=./benchmarking/frame-weight-template.hbs
41// --output=./runtime/moonbase/src/weights
42
43#![cfg_attr(rustfmt, rustfmt_skip)]
44#![allow(unused_parens)]
45#![allow(unused_imports)]
46
47use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
48use sp_std::marker::PhantomData;
49
50/// Weights for `cumulus_pallet_xcmp_queue`.
51pub struct WeightInfo<T>(PhantomData<T>);
52impl<T: frame_system::Config> cumulus_pallet_xcmp_queue::WeightInfo for WeightInfo<T> {
53 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:1)
54 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
55 fn set_config_with_u32() -> Weight {
56 // Proof Size summary in bytes:
57 // Measured: `142`
58 // Estimated: `1497`
59 // Minimum execution time: 4_960_000 picoseconds.
60 Weight::from_parts(5_191_000, 1497)
61 .saturating_add(T::DbWeight::get().reads(1_u64))
62 .saturating_add(T::DbWeight::get().writes(1_u64))
63 }
64 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
65 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
66 /// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
67 /// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
68 /// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
69 /// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
70 /// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
71 /// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
72 /// Storage: `MessageQueue::Pages` (r:0 w:1)
73 /// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(105521), added: 107996, mode: `MaxEncodedLen`)
74 /// The range of component `n` is `[0, 105467]`.
75 fn enqueue_n_bytes_xcmp_message(n: u32, ) -> Weight {
76 // Proof Size summary in bytes:
77 // Measured: `148`
78 // Estimated: `5487`
79 // Minimum execution time: 13_186_000 picoseconds.
80 Weight::from_parts(10_136_247, 5487)
81 // Standard Error: 5
82 .saturating_add(Weight::from_parts(931, 0).saturating_mul(n.into()))
83 .saturating_add(T::DbWeight::get().reads(4_u64))
84 .saturating_add(T::DbWeight::get().writes(3_u64))
85 }
86 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
87 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
88 /// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
89 /// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
90 /// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
91 /// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
92 /// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
93 /// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
94 /// Storage: `MessageQueue::Pages` (r:0 w:1)
95 /// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(105521), added: 107996, mode: `MaxEncodedLen`)
96 /// The range of component `n` is `[0, 1000]`.
97 fn enqueue_n_empty_xcmp_messages(n: u32, ) -> Weight {
98 // Proof Size summary in bytes:
99 // Measured: `148`
100 // Estimated: `5487`
101 // Minimum execution time: 11_043_000 picoseconds.
102 Weight::from_parts(14_886_365, 5487)
103 // Standard Error: 184
104 .saturating_add(Weight::from_parts(114_479, 0).saturating_mul(n.into()))
105 .saturating_add(T::DbWeight::get().reads(4_u64))
106 .saturating_add(T::DbWeight::get().writes(3_u64))
107 }
108 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
109 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `Measured`)
110 /// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
111 /// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `Measured`)
112 /// Storage: `MessageQueue::Pages` (r:1 w:1)
113 /// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(105521), added: 107996, mode: `Measured`)
114 /// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
115 /// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `Measured`)
116 /// The range of component `n` is `[0, 105457]`.
117 fn enqueue_empty_xcmp_message_at(n: u32, ) -> Weight {
118 // Proof Size summary in bytes:
119 // Measured: `330 + n * (1 ±0)`
120 // Estimated: `3793 + n * (1 ±0)`
121 // Minimum execution time: 19_612_000 picoseconds.
122 Weight::from_parts(13_113_412, 3793)
123 // Standard Error: 9
124 .saturating_add(Weight::from_parts(2_075, 0).saturating_mul(n.into()))
125 .saturating_add(T::DbWeight::get().reads(4_u64))
126 .saturating_add(T::DbWeight::get().writes(2_u64))
127 .saturating_add(Weight::from_parts(0, 1).saturating_mul(n.into()))
128 }
129 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
130 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
131 /// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
132 /// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
133 /// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
134 /// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
135 /// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
136 /// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
137 /// Storage: `MessageQueue::Pages` (r:0 w:100)
138 /// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(105521), added: 107996, mode: `MaxEncodedLen`)
139 /// The range of component `n` is `[0, 100]`.
140 fn enqueue_n_full_pages(n: u32, ) -> Weight {
141 // Proof Size summary in bytes:
142 // Measured: `183`
143 // Estimated: `5487`
144 // Minimum execution time: 12_363_000 picoseconds.
145 Weight::from_parts(12_607_000, 5487)
146 // Standard Error: 64_686
147 .saturating_add(Weight::from_parts(94_552_144, 0).saturating_mul(n.into()))
148 .saturating_add(T::DbWeight::get().reads(4_u64))
149 .saturating_add(T::DbWeight::get().writes(2_u64))
150 .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(n.into())))
151 }
152 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
153 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `Measured`)
154 /// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
155 /// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `Measured`)
156 /// Storage: `MessageQueue::Pages` (r:1 w:1)
157 /// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(105521), added: 107996, mode: `Measured`)
158 /// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
159 /// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `Measured`)
160 fn enqueue_1000_small_xcmp_messages() -> Weight {
161 // Proof Size summary in bytes:
162 // Measured: `53063`
163 // Estimated: `56528`
164 // Minimum execution time: 233_167_000 picoseconds.
165 Weight::from_parts(241_893_000, 56528)
166 .saturating_add(T::DbWeight::get().reads(4_u64))
167 .saturating_add(T::DbWeight::get().writes(2_u64))
168 }
169 /// Storage: `XcmpQueue::OutboundXcmpStatus` (r:1 w:1)
170 /// Proof: `XcmpQueue::OutboundXcmpStatus` (`max_values`: Some(1), `max_size`: Some(1282), added: 1777, mode: `MaxEncodedLen`)
171 fn suspend_channel() -> Weight {
172 // Proof Size summary in bytes:
173 // Measured: `142`
174 // Estimated: `2767`
175 // Minimum execution time: 3_151_000 picoseconds.
176 Weight::from_parts(3_405_000, 2767)
177 .saturating_add(T::DbWeight::get().reads(1_u64))
178 .saturating_add(T::DbWeight::get().writes(1_u64))
179 }
180 /// Storage: `XcmpQueue::OutboundXcmpStatus` (r:1 w:1)
181 /// Proof: `XcmpQueue::OutboundXcmpStatus` (`max_values`: Some(1), `max_size`: Some(1282), added: 1777, mode: `MaxEncodedLen`)
182 fn resume_channel() -> Weight {
183 // Proof Size summary in bytes:
184 // Measured: `177`
185 // Estimated: `2767`
186 // Minimum execution time: 4_418_000 picoseconds.
187 Weight::from_parts(4_628_000, 2767)
188 .saturating_add(T::DbWeight::get().reads(1_u64))
189 .saturating_add(T::DbWeight::get().writes(1_u64))
190 }
191 fn take_first_concatenated_xcm() -> Weight {
192 // Proof Size summary in bytes:
193 // Measured: `0`
194 // Estimated: `0`
195 // Minimum execution time: 5_408_000 picoseconds.
196 Weight::from_parts(5_589_000, 0)
197 }
198 /// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
199 /// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
200 /// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
201 /// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
202 /// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
203 /// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
204 /// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
205 /// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
206 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
207 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
208 /// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
209 /// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
210 /// Storage: `MessageQueue::Pages` (r:0 w:1)
211 /// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(105521), added: 107996, mode: `MaxEncodedLen`)
212 fn on_idle_good_msg() -> Weight {
213 // Proof Size summary in bytes:
214 // Measured: `105713`
215 // Estimated: `109178`
216 // Minimum execution time: 177_671_000 picoseconds.
217 Weight::from_parts(182_049_000, 109178)
218 .saturating_add(T::DbWeight::get().reads(6_u64))
219 .saturating_add(T::DbWeight::get().writes(5_u64))
220 }
221 /// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
222 /// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
223 /// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
224 /// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
225 /// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
226 /// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
227 /// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
228 /// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
229 /// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
230 /// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
231 /// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
232 /// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
233 /// Storage: `MessageQueue::Pages` (r:0 w:1)
234 /// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(105521), added: 107996, mode: `MaxEncodedLen`)
235 fn on_idle_large_msg() -> Weight {
236 // Proof Size summary in bytes:
237 // Measured: `65782`
238 // Estimated: `69247`
239 // Minimum execution time: 112_833_000 picoseconds.
240 Weight::from_parts(121_164_000, 69247)
241 .saturating_add(T::DbWeight::get().reads(6_u64))
242 .saturating_add(T::DbWeight::get().writes(5_u64))
243 }
244}