1
// Copyright (C) Moondance Labs Ltd.
2
// This file is part of Tanssi.
3

            
4
// Tanssi 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
// Tanssi 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 Tanssi.  If not, see <http://www.gnu.org/licenses/>
16

            
17

            
18
//! Autogenerated weights for pallet_xcm
19
//!
20
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 47.0.0
21
//! DATE: 2025-07-10, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
22
//! WORST CASE MAP SIZE: `1000000`
23
//! HOSTNAME: `benchmark-1`, CPU: `Intel(R) Xeon(R) Platinum 8375C CPU @ 2.90GHz`
24
//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("starlight-dev"), DB CACHE: 1024
25

            
26
// Executed Command:
27
// target/release/tanssi-relay
28
// benchmark
29
// pallet
30
// --execution=wasm
31
// --wasm-execution=compiled
32
// --pallet
33
// pallet_xcm
34
// --extrinsic
35
// *
36
// --chain=starlight-dev
37
// --steps
38
// 50
39
// --repeat
40
// 20
41
// --template=benchmarking/frame-weight-runtime-template.hbs
42
// --json-file
43
// raw.json
44
// --output
45
// tmp/starlight_weights/pallet_xcm.rs
46

            
47
#![cfg_attr(rustfmt, rustfmt_skip)]
48
#![allow(unused_parens)]
49
#![allow(unused_imports)]
50

            
51
use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
52
use core::marker::PhantomData;
53

            
54
/// Weights for pallet_xcm using the Substrate node and recommended hardware.
55
pub struct SubstrateWeight<T>(PhantomData<T>);
56
impl<T: frame_system::Config> pallet_xcm::WeightInfo for SubstrateWeight<T> {
57
	/// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0)
58
	/// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`)
59
	/// Storage: `XcmPallet::SupportedVersion` (r:1 w:0)
60
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
61
	/// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1)
62
	/// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`)
63
	/// Storage: `Paras::Heads` (r:1 w:0)
64
	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
65
	/// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1)
66
	/// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`)
67
	fn send() -> Weight {
68
		// Proof Size summary in bytes:
69
		//  Measured:  `141`
70
		//  Estimated: `3606`
71
		// Minimum execution time: 49_434_000 picoseconds.
72
		Weight::from_parts(51_333_000, 3606)
73
			.saturating_add(T::DbWeight::get().reads(5_u64))
74
			.saturating_add(T::DbWeight::get().writes(2_u64))
75
	}
76
	/// Storage: `Benchmark::Override` (r:0 w:0)
77
	/// Proof: `Benchmark::Override` (`max_values`: None, `max_size`: None, mode: `Measured`)
78
	fn teleport_assets() -> Weight {
79
		// Proof Size summary in bytes:
80
		//  Measured:  `0`
81
		//  Estimated: `0`
82
		// Minimum execution time: 18_446_744_073_709_551_000 picoseconds.
83
		Weight::from_parts(18_446_744_073_709_551_000, 0)
84
	}
85
	/// Storage: `System::Account` (r:1 w:1)
86
	/// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
87
	/// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0)
88
	/// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`)
89
	/// Storage: `XcmPallet::SupportedVersion` (r:1 w:0)
90
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
91
	/// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1)
92
	/// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`)
93
	/// Storage: `Paras::Heads` (r:1 w:0)
94
	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
95
	/// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1)
96
	/// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`)
97
	fn reserve_transfer_assets() -> Weight {
98
		// Proof Size summary in bytes:
99
		//  Measured:  `193`
100
		//  Estimated: `3658`
101
		// Minimum execution time: 167_420_000 picoseconds.
102
		Weight::from_parts(171_653_000, 3658)
103
			.saturating_add(T::DbWeight::get().reads(6_u64))
104
			.saturating_add(T::DbWeight::get().writes(3_u64))
105
	}
106
	/// Storage: `System::Account` (r:1 w:1)
107
	/// Proof: `System::Account` (`max_values`: None, `max_size`: Some(128), added: 2603, mode: `MaxEncodedLen`)
108
	/// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0)
109
	/// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`)
110
	/// Storage: `XcmPallet::SupportedVersion` (r:1 w:0)
111
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
112
	/// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1)
113
	/// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`)
114
	/// Storage: `Paras::Heads` (r:1 w:0)
115
	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
116
	/// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1)
117
	/// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`)
118
	fn transfer_assets() -> Weight {
119
		// Proof Size summary in bytes:
120
		//  Measured:  `244`
121
		//  Estimated: `3709`
122
		// Minimum execution time: 168_785_000 picoseconds.
123
		Weight::from_parts(172_249_000, 3709)
124
			.saturating_add(T::DbWeight::get().reads(6_u64))
125
			.saturating_add(T::DbWeight::get().writes(3_u64))
126
	}
127
1
	fn execute() -> Weight {
128
1
		// Proof Size summary in bytes:
129
1
		//  Measured:  `0`
130
1
		//  Estimated: `0`
131
1
		// Minimum execution time: 12_587_000 picoseconds.
132
1
		Weight::from_parts(12_840_000, 0)
133
1
	}
134
	/// Storage: `XcmPallet::SupportedVersion` (r:0 w:1)
135
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
136
	fn force_xcm_version() -> Weight {
137
		// Proof Size summary in bytes:
138
		//  Measured:  `0`
139
		//  Estimated: `0`
140
		// Minimum execution time: 11_345_000 picoseconds.
141
		Weight::from_parts(11_697_000, 0)
142
			.saturating_add(T::DbWeight::get().writes(1_u64))
143
	}
144
	fn force_default_xcm_version() -> Weight {
145
		// Proof Size summary in bytes:
146
		//  Measured:  `0`
147
		//  Estimated: `0`
148
		// Minimum execution time: 3_642_000 picoseconds.
149
		Weight::from_parts(3_829_000, 0)
150
	}
151
	/// Storage: `XcmPallet::VersionNotifiers` (r:1 w:1)
152
	/// Proof: `XcmPallet::VersionNotifiers` (`max_values`: None, `max_size`: None, mode: `Measured`)
153
	/// Storage: `XcmPallet::QueryCounter` (r:1 w:1)
154
	/// Proof: `XcmPallet::QueryCounter` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
155
	/// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0)
156
	/// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`)
157
	/// Storage: `XcmPallet::SupportedVersion` (r:1 w:0)
158
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
159
	/// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1)
160
	/// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`)
161
	/// Storage: `Paras::Heads` (r:1 w:0)
162
	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
163
	/// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1)
164
	/// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`)
165
	/// Storage: `XcmPallet::Queries` (r:0 w:1)
166
	/// Proof: `XcmPallet::Queries` (`max_values`: None, `max_size`: None, mode: `Measured`)
167
	fn force_subscribe_version_notify() -> Weight {
168
		// Proof Size summary in bytes:
169
		//  Measured:  `141`
170
		//  Estimated: `3606`
171
		// Minimum execution time: 57_989_000 picoseconds.
172
		Weight::from_parts(59_055_000, 3606)
173
			.saturating_add(T::DbWeight::get().reads(7_u64))
174
			.saturating_add(T::DbWeight::get().writes(5_u64))
175
	}
176
	/// Storage: `XcmPallet::VersionNotifiers` (r:1 w:1)
177
	/// Proof: `XcmPallet::VersionNotifiers` (`max_values`: None, `max_size`: None, mode: `Measured`)
178
	/// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0)
179
	/// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`)
180
	/// Storage: `XcmPallet::SupportedVersion` (r:1 w:0)
181
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
182
	/// Storage: `Dmp::DownwardMessageQueues` (r:1 w:1)
183
	/// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`)
184
	/// Storage: `Paras::Heads` (r:1 w:0)
185
	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
186
	/// Storage: `Dmp::DownwardMessageQueueHeads` (r:1 w:1)
187
	/// Proof: `Dmp::DownwardMessageQueueHeads` (`max_values`: None, `max_size`: None, mode: `Measured`)
188
	/// Storage: `XcmPallet::Queries` (r:0 w:1)
189
	/// Proof: `XcmPallet::Queries` (`max_values`: None, `max_size`: None, mode: `Measured`)
190
	fn force_unsubscribe_version_notify() -> Weight {
191
		// Proof Size summary in bytes:
192
		//  Measured:  `321`
193
		//  Estimated: `3786`
194
		// Minimum execution time: 60_737_000 picoseconds.
195
		Weight::from_parts(62_128_000, 3786)
196
			.saturating_add(T::DbWeight::get().reads(6_u64))
197
			.saturating_add(T::DbWeight::get().writes(4_u64))
198
	}
199
	/// Storage: `XcmPallet::XcmExecutionSuspended` (r:0 w:1)
200
	/// Proof: `XcmPallet::XcmExecutionSuspended` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
201
	fn force_suspension() -> Weight {
202
		// Proof Size summary in bytes:
203
		//  Measured:  `0`
204
		//  Estimated: `0`
205
		// Minimum execution time: 3_703_000 picoseconds.
206
		Weight::from_parts(3_867_000, 0)
207
			.saturating_add(T::DbWeight::get().writes(1_u64))
208
	}
209
	/// Storage: `XcmPallet::SupportedVersion` (r:6 w:2)
210
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
211
	fn migrate_supported_version() -> Weight {
212
		// Proof Size summary in bytes:
213
		//  Measured:  `22`
214
		//  Estimated: `15862`
215
		// Minimum execution time: 27_216_000 picoseconds.
216
		Weight::from_parts(27_810_000, 15862)
217
			.saturating_add(T::DbWeight::get().reads(6_u64))
218
			.saturating_add(T::DbWeight::get().writes(2_u64))
219
	}
220
	/// Storage: `XcmPallet::VersionNotifiers` (r:6 w:2)
221
	/// Proof: `XcmPallet::VersionNotifiers` (`max_values`: None, `max_size`: None, mode: `Measured`)
222
	fn migrate_version_notifiers() -> Weight {
223
		// Proof Size summary in bytes:
224
		//  Measured:  `26`
225
		//  Estimated: `15866`
226
		// Minimum execution time: 26_969_000 picoseconds.
227
		Weight::from_parts(27_319_000, 15866)
228
			.saturating_add(T::DbWeight::get().reads(6_u64))
229
			.saturating_add(T::DbWeight::get().writes(2_u64))
230
	}
231
	/// Storage: `XcmPallet::VersionNotifyTargets` (r:7 w:0)
232
	/// Proof: `XcmPallet::VersionNotifyTargets` (`max_values`: None, `max_size`: None, mode: `Measured`)
233
	fn already_notified_target() -> Weight {
234
		// Proof Size summary in bytes:
235
		//  Measured:  `78`
236
		//  Estimated: `18393`
237
		// Minimum execution time: 33_807_000 picoseconds.
238
		Weight::from_parts(34_531_000, 18393)
239
			.saturating_add(T::DbWeight::get().reads(7_u64))
240
	}
241
	/// Storage: `XcmPallet::VersionNotifyTargets` (r:2 w:1)
242
	/// Proof: `XcmPallet::VersionNotifyTargets` (`max_values`: None, `max_size`: None, mode: `Measured`)
243
	/// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0)
244
	/// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`)
245
	/// Storage: `XcmPallet::SupportedVersion` (r:1 w:0)
246
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
247
	/// Storage: `Dmp::DownwardMessageQueues` (r:1 w:0)
248
	/// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`)
249
	/// Storage: `Paras::Heads` (r:1 w:0)
250
	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
251
	fn notify_current_targets() -> Weight {
252
		// Proof Size summary in bytes:
253
		//  Measured:  `140`
254
		//  Estimated: `6080`
255
		// Minimum execution time: 41_714_000 picoseconds.
256
		Weight::from_parts(42_674_000, 6080)
257
			.saturating_add(T::DbWeight::get().reads(6_u64))
258
			.saturating_add(T::DbWeight::get().writes(1_u64))
259
	}
260
	/// Storage: `XcmPallet::VersionNotifyTargets` (r:5 w:0)
261
	/// Proof: `XcmPallet::VersionNotifyTargets` (`max_values`: None, `max_size`: None, mode: `Measured`)
262
	fn notify_target_migration_fail() -> Weight {
263
		// Proof Size summary in bytes:
264
		//  Measured:  `78`
265
		//  Estimated: `13443`
266
		// Minimum execution time: 24_596_000 picoseconds.
267
		Weight::from_parts(25_218_000, 13443)
268
			.saturating_add(T::DbWeight::get().reads(5_u64))
269
	}
270
	/// Storage: `XcmPallet::VersionNotifyTargets` (r:6 w:2)
271
	/// Proof: `XcmPallet::VersionNotifyTargets` (`max_values`: None, `max_size`: None, mode: `Measured`)
272
	fn migrate_version_notify_targets() -> Weight {
273
		// Proof Size summary in bytes:
274
		//  Measured:  `33`
275
		//  Estimated: `15873`
276
		// Minimum execution time: 27_535_000 picoseconds.
277
		Weight::from_parts(28_100_000, 15873)
278
			.saturating_add(T::DbWeight::get().reads(6_u64))
279
			.saturating_add(T::DbWeight::get().writes(2_u64))
280
	}
281
	/// Storage: `XcmPallet::VersionNotifyTargets` (r:6 w:1)
282
	/// Proof: `XcmPallet::VersionNotifyTargets` (`max_values`: None, `max_size`: None, mode: `Measured`)
283
	/// Storage: `Dmp::DeliveryFeeFactor` (r:1 w:0)
284
	/// Proof: `Dmp::DeliveryFeeFactor` (`max_values`: None, `max_size`: None, mode: `Measured`)
285
	/// Storage: `XcmPallet::SupportedVersion` (r:1 w:0)
286
	/// Proof: `XcmPallet::SupportedVersion` (`max_values`: None, `max_size`: None, mode: `Measured`)
287
	/// Storage: `Dmp::DownwardMessageQueues` (r:1 w:0)
288
	/// Proof: `Dmp::DownwardMessageQueues` (`max_values`: None, `max_size`: None, mode: `Measured`)
289
	/// Storage: `Paras::Heads` (r:1 w:0)
290
	/// Proof: `Paras::Heads` (`max_values`: None, `max_size`: None, mode: `Measured`)
291
	fn migrate_and_notify_old_targets() -> Weight {
292
		// Proof Size summary in bytes:
293
		//  Measured:  `140`
294
		//  Estimated: `15980`
295
		// Minimum execution time: 55_218_000 picoseconds.
296
		Weight::from_parts(56_369_000, 15980)
297
			.saturating_add(T::DbWeight::get().reads(10_u64))
298
			.saturating_add(T::DbWeight::get().writes(1_u64))
299
	}
300
	/// Storage: `XcmPallet::QueryCounter` (r:1 w:1)
301
	/// Proof: `XcmPallet::QueryCounter` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
302
	/// Storage: `XcmPallet::Queries` (r:0 w:1)
303
	/// Proof: `XcmPallet::Queries` (`max_values`: None, `max_size`: None, mode: `Measured`)
304
	fn new_query() -> Weight {
305
		// Proof Size summary in bytes:
306
		//  Measured:  `0`
307
		//  Estimated: `1485`
308
		// Minimum execution time: 3_904_000 picoseconds.
309
		Weight::from_parts(4_078_000, 1485)
310
			.saturating_add(T::DbWeight::get().reads(1_u64))
311
			.saturating_add(T::DbWeight::get().writes(2_u64))
312
	}
313
	/// Storage: `XcmPallet::Queries` (r:1 w:1)
314
	/// Proof: `XcmPallet::Queries` (`max_values`: None, `max_size`: None, mode: `Measured`)
315
	fn take_response() -> Weight {
316
		// Proof Size summary in bytes:
317
		//  Measured:  `7576`
318
		//  Estimated: `11041`
319
		// Minimum execution time: 33_564_000 picoseconds.
320
		Weight::from_parts(34_148_000, 11041)
321
			.saturating_add(T::DbWeight::get().reads(1_u64))
322
			.saturating_add(T::DbWeight::get().writes(1_u64))
323
	}
324
	/// Storage: `XcmPallet::AssetTraps` (r:1 w:1)
325
	/// Proof: `XcmPallet::AssetTraps` (`max_values`: None, `max_size`: None, mode: `Measured`)
326
	fn claim_assets() -> Weight {
327
		// Proof Size summary in bytes:
328
		//  Measured:  `23`
329
		//  Estimated: `3488`
330
		// Minimum execution time: 51_057_000 picoseconds.
331
		Weight::from_parts(52_086_000, 3488)
332
			.saturating_add(T::DbWeight::get().reads(1_u64))
333
			.saturating_add(T::DbWeight::get().writes(1_u64))
334
	}
335
	/// Storage: `Benchmark::Override` (r:0 w:0)
336
	/// Proof: `Benchmark::Override` (`max_values`: None, `max_size`: None, mode: `Measured`)
337
	fn add_authorized_alias() -> Weight {
338
		// Proof Size summary in bytes:
339
		//  Measured:  `0`
340
		//  Estimated: `0`
341
		// Minimum execution time: 18_446_744_073_709_551_000 picoseconds.
342
		Weight::from_parts(18_446_744_073_709_551_000, 0)
343
	}
344
	/// Storage: `Benchmark::Override` (r:0 w:0)
345
	/// Proof: `Benchmark::Override` (`max_values`: None, `max_size`: None, mode: `Measured`)
346
	fn remove_authorized_alias() -> Weight {
347
		// Proof Size summary in bytes:
348
		//  Measured:  `0`
349
		//  Estimated: `0`
350
		// Minimum execution time: 18_446_744_073_709_551_000 picoseconds.
351
		Weight::from_parts(18_446_744_073_709_551_000, 0)
352
	}
353
}