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 cumulus_pallet_xcmp_queue
19
//!
20
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 47.0.0
21
//! DATE: 2025-09-09, 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("dev"), DB CACHE: 1024
25

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

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

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

            
53
/// Weights for cumulus_pallet_xcmp_queue using the Substrate node and recommended hardware.
54
pub struct SubstrateWeight<T>(PhantomData<T>);
55
impl<T: frame_system::Config> cumulus_pallet_xcmp_queue::WeightInfo for SubstrateWeight<T> {
56
	/// Storage: `XcmpQueue::QueueConfig` (r:1 w:1)
57
	/// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
58
	fn set_config_with_u32() -> Weight {
59
		// Proof Size summary in bytes:
60
		//  Measured:  `109`
61
		//  Estimated: `1497`
62
		// Minimum execution time: 7_372_000 picoseconds.
63
		Weight::from_parts(7_626_000, 1497)
64
			.saturating_add(T::DbWeight::get().reads(1_u64))
65
			.saturating_add(T::DbWeight::get().writes(1_u64))
66
	}
67
	/// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
68
	/// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
69
	/// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
70
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
71
	/// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
72
	/// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
73
	/// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
74
	/// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
75
	/// Storage: `MessageQueue::Pages` (r:0 w:1)
76
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
77
	/// The range of component `n` is `[1, 65531]`.
78
6
	fn enqueue_n_bytes_xcmp_message(n: u32, ) -> Weight {
79
6
		// Proof Size summary in bytes:
80
6
		//  Measured:  `115`
81
6
		//  Estimated: `5487`
82
6
		// Minimum execution time: 17_707_000 picoseconds.
83
6
		Weight::from_parts(13_076_020, 5487)
84
6
			// Standard Error: 9
85
6
			.saturating_add(Weight::from_parts(954, 0).saturating_mul(n.into()))
86
6
			.saturating_add(T::DbWeight::get().reads(4_u64))
87
6
			.saturating_add(T::DbWeight::get().writes(3_u64))
88
6
	}
89
	/// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
90
	/// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
91
	/// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
92
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
93
	/// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
94
	/// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
95
	/// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
96
	/// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
97
	/// Storage: `MessageQueue::Pages` (r:0 w:1)
98
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
99
	fn enqueue_2_empty_xcmp_messages() -> Weight {
100
		// Proof Size summary in bytes:
101
		//  Measured:  `115`
102
		//  Estimated: `5487`
103
		// Minimum execution time: 29_607_000 picoseconds.
104
		Weight::from_parts(30_134_000, 5487)
105
			.saturating_add(T::DbWeight::get().reads(4_u64))
106
			.saturating_add(T::DbWeight::get().writes(3_u64))
107
	}
108
	/// Storage: `XcmpQueue::OutboundXcmpStatus` (r:1 w:1)
109
	/// Proof: `XcmpQueue::OutboundXcmpStatus` (`max_values`: Some(1), `max_size`: Some(1282), added: 1777, mode: `MaxEncodedLen`)
110
	fn suspend_channel() -> Weight {
111
		// Proof Size summary in bytes:
112
		//  Measured:  `109`
113
		//  Estimated: `2767`
114
		// Minimum execution time: 4_544_000 picoseconds.
115
		Weight::from_parts(4_827_000, 2767)
116
			.saturating_add(T::DbWeight::get().reads(1_u64))
117
			.saturating_add(T::DbWeight::get().writes(1_u64))
118
	}
119
	/// Storage: `XcmpQueue::OutboundXcmpStatus` (r:1 w:1)
120
	/// Proof: `XcmpQueue::OutboundXcmpStatus` (`max_values`: Some(1), `max_size`: Some(1282), added: 1777, mode: `MaxEncodedLen`)
121
	fn resume_channel() -> Weight {
122
		// Proof Size summary in bytes:
123
		//  Measured:  `144`
124
		//  Estimated: `2767`
125
		// Minimum execution time: 5_982_000 picoseconds.
126
		Weight::from_parts(6_224_000, 2767)
127
			.saturating_add(T::DbWeight::get().reads(1_u64))
128
			.saturating_add(T::DbWeight::get().writes(1_u64))
129
	}
130
6
	fn take_first_concatenated_xcm() -> Weight {
131
6
		// Proof Size summary in bytes:
132
6
		//  Measured:  `0`
133
6
		//  Estimated: `0`
134
6
		// Minimum execution time: 7_476_000 picoseconds.
135
6
		Weight::from_parts(7_600_000, 0)
136
6
	}
137
	/// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
138
	/// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
139
	/// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
140
	/// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
141
	/// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
142
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
143
	/// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
144
	/// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
145
	/// Storage: `XcmpQueue::QueueConfig` (r:1 w:0)
146
	/// Proof: `XcmpQueue::QueueConfig` (`max_values`: Some(1), `max_size`: Some(12), added: 507, mode: `MaxEncodedLen`)
147
	/// Storage: `XcmpQueue::InboundXcmpSuspended` (r:1 w:0)
148
	/// Proof: `XcmpQueue::InboundXcmpSuspended` (`max_values`: Some(1), `max_size`: Some(4002), added: 4497, mode: `MaxEncodedLen`)
149
	/// Storage: `MessageQueue::Pages` (r:0 w:1)
150
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
151
123
	fn on_idle_good_msg() -> Weight {
152
123
		// Proof Size summary in bytes:
153
123
		//  Measured:  `65744`
154
123
		//  Estimated: `69209`
155
123
		// Minimum execution time: 125_692_000 picoseconds.
156
123
		Weight::from_parts(126_820_000, 69209)
157
123
			.saturating_add(T::DbWeight::get().reads(6_u64))
158
123
			.saturating_add(T::DbWeight::get().writes(5_u64))
159
123
	}
160
	/// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
161
	/// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6b345d8e88afa015075c945637c07e8f20` (r:1 w:1)
162
	/// Storage: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
163
	/// Proof: UNKNOWN KEY `0x7b3237373ffdfeb1cab4222e3b520d6bedc49980ba3aa32b0a189290fd036649` (r:1 w:1)
164
123
	fn on_idle_large_msg() -> Weight {
165
123
		// Proof Size summary in bytes:
166
123
		//  Measured:  `65743`
167
123
		//  Estimated: `69208`
168
123
		// Minimum execution time: 62_562_000 picoseconds.
169
123
		Weight::from_parts(63_150_000, 69208)
170
123
			.saturating_add(T::DbWeight::get().reads(2_u64))
171
123
			.saturating_add(T::DbWeight::get().writes(2_u64))
172
123
	}
173
}