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_message_queue
19
//!
20
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0
21
//! DATE: 2025-05-02, 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
// --execution=wasm
31
// --wasm-execution=compiled
32
// --pallet
33
// pallet_message_queue
34
// --extrinsic
35
// *
36
// --chain=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/simple_template_weights/pallet_message_queue.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 sp_std::marker::PhantomData;
53

            
54
/// Weights for pallet_message_queue using the Substrate node and recommended hardware.
55
pub struct SubstrateWeight<T>(PhantomData<T>);
56
impl<T: frame_system::Config> pallet_message_queue::WeightInfo for SubstrateWeight<T> {
57
	fn set_service_head() -> cumulus_primitives_core::Weight {
58
		Default::default()
59
	}
60
	/// Storage: `MessageQueue::ServiceHead` (r:1 w:0)
61
	/// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
62
	/// Storage: `MessageQueue::BookStateFor` (r:2 w:2)
63
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
64
	fn ready_ring_knit() -> Weight {
65
		// Proof Size summary in bytes:
66
		//  Measured:  `223`
67
		//  Estimated: `6044`
68
		// Minimum execution time: 18_052_000 picoseconds.
69
		Weight::from_parts(18_706_000, 6044)
70
			.saturating_add(T::DbWeight::get().reads(3_u64))
71
			.saturating_add(T::DbWeight::get().writes(2_u64))
72
	}
73
	/// Storage: `MessageQueue::BookStateFor` (r:2 w:2)
74
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
75
	/// Storage: `MessageQueue::ServiceHead` (r:1 w:1)
76
	/// Proof: `MessageQueue::ServiceHead` (`max_values`: Some(1), `max_size`: Some(5), added: 500, mode: `MaxEncodedLen`)
77
203
	fn ready_ring_unknit() -> Weight {
78
203
		// Proof Size summary in bytes:
79
203
		//  Measured:  `218`
80
203
		//  Estimated: `6044`
81
203
		// Minimum execution time: 16_272_000 picoseconds.
82
203
		Weight::from_parts(16_760_000, 6044)
83
203
			.saturating_add(T::DbWeight::get().reads(3_u64))
84
203
			.saturating_add(T::DbWeight::get().writes(3_u64))
85
203
	}
86
	/// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
87
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
88
	/// Storage: `MaintenanceMode::MaintenanceMode` (r:1 w:0)
89
	/// Proof: `MaintenanceMode::MaintenanceMode` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
90
203
	fn service_queue_base() -> Weight {
91
203
		// Proof Size summary in bytes:
92
203
		//  Measured:  `48`
93
203
		//  Estimated: `3517`
94
203
		// Minimum execution time: 9_641_000 picoseconds.
95
203
		Weight::from_parts(9_903_000, 3517)
96
203
			.saturating_add(T::DbWeight::get().reads(2_u64))
97
203
			.saturating_add(T::DbWeight::get().writes(1_u64))
98
203
	}
99
	/// Storage: `MessageQueue::Pages` (r:1 w:1)
100
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
101
192
	fn service_page_base_completion() -> Weight {
102
192
		// Proof Size summary in bytes:
103
192
		//  Measured:  `72`
104
192
		//  Estimated: `69050`
105
192
		// Minimum execution time: 9_437_000 picoseconds.
106
192
		Weight::from_parts(9_734_000, 69050)
107
192
			.saturating_add(T::DbWeight::get().reads(1_u64))
108
192
			.saturating_add(T::DbWeight::get().writes(1_u64))
109
192
	}
110
	/// Storage: `MessageQueue::Pages` (r:1 w:1)
111
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
112
192
	fn service_page_base_no_completion() -> Weight {
113
192
		// Proof Size summary in bytes:
114
192
		//  Measured:  `72`
115
192
		//  Estimated: `69050`
116
192
		// Minimum execution time: 9_565_000 picoseconds.
117
192
		Weight::from_parts(9_816_000, 69050)
118
192
			.saturating_add(T::DbWeight::get().reads(1_u64))
119
192
			.saturating_add(T::DbWeight::get().writes(1_u64))
120
192
	}
121
	/// Storage: `MessageQueue::BookStateFor` (r:0 w:1)
122
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
123
	/// Storage: `MessageQueue::Pages` (r:0 w:1)
124
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
125
192
	fn service_page_item() -> Weight {
126
192
		// Proof Size summary in bytes:
127
192
		//  Measured:  `0`
128
192
		//  Estimated: `0`
129
192
		// Minimum execution time: 162_169_000 picoseconds.
130
192
		Weight::from_parts(164_144_000, 0)
131
192
			.saturating_add(T::DbWeight::get().writes(2_u64))
132
192
	}
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: `MessageQueue::BookStateFor` (r:1 w:0)
136
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
137
362
	fn bump_service_head() -> Weight {
138
362
		// Proof Size summary in bytes:
139
362
		//  Measured:  `171`
140
362
		//  Estimated: `3517`
141
362
		// Minimum execution time: 11_011_000 picoseconds.
142
362
		Weight::from_parts(11_276_000, 3517)
143
362
			.saturating_add(T::DbWeight::get().reads(2_u64))
144
362
			.saturating_add(T::DbWeight::get().writes(1_u64))
145
362
	}
146
	/// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
147
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
148
	/// Storage: `MessageQueue::Pages` (r:1 w:1)
149
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
150
	fn reap_page() -> Weight {
151
		// Proof Size summary in bytes:
152
		//  Measured:  `65667`
153
		//  Estimated: `69050`
154
		// Minimum execution time: 61_809_000 picoseconds.
155
		Weight::from_parts(62_962_000, 69050)
156
			.saturating_add(T::DbWeight::get().reads(2_u64))
157
			.saturating_add(T::DbWeight::get().writes(2_u64))
158
	}
159
	/// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
160
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
161
	/// Storage: `MaintenanceMode::MaintenanceMode` (r:1 w:0)
162
	/// Proof: `MaintenanceMode::MaintenanceMode` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
163
	/// Storage: `MessageQueue::Pages` (r:1 w:1)
164
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
165
	fn execute_overweight_page_removed() -> Weight {
166
		// Proof Size summary in bytes:
167
		//  Measured:  `65709`
168
		//  Estimated: `69050`
169
		// Minimum execution time: 81_837_000 picoseconds.
170
		Weight::from_parts(84_476_000, 69050)
171
			.saturating_add(T::DbWeight::get().reads(3_u64))
172
			.saturating_add(T::DbWeight::get().writes(2_u64))
173
	}
174
	/// Storage: `MessageQueue::BookStateFor` (r:1 w:1)
175
	/// Proof: `MessageQueue::BookStateFor` (`max_values`: None, `max_size`: Some(52), added: 2527, mode: `MaxEncodedLen`)
176
	/// Storage: `MaintenanceMode::MaintenanceMode` (r:1 w:0)
177
	/// Proof: `MaintenanceMode::MaintenanceMode` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
178
	/// Storage: `MessageQueue::Pages` (r:1 w:1)
179
	/// Proof: `MessageQueue::Pages` (`max_values`: None, `max_size`: Some(65585), added: 68060, mode: `MaxEncodedLen`)
180
	fn execute_overweight_page_updated() -> Weight {
181
		// Proof Size summary in bytes:
182
		//  Measured:  `65709`
183
		//  Estimated: `69050`
184
		// Minimum execution time: 119_833_000 picoseconds.
185
		Weight::from_parts(121_113_000, 69050)
186
			.saturating_add(T::DbWeight::get().reads(3_u64))
187
			.saturating_add(T::DbWeight::get().writes(2_u64))
188
	}
189
}