From be9974b70a8e860291f22c7bf05cfcd9efd0a22a Mon Sep 17 00:00:00 2001 From: bgallois <benjamin@gallois.cc> Date: Thu, 20 Jun 2024 20:11:08 +0200 Subject: [PATCH] separate weights --- node/src/chain_spec/g1.rs | 193 ++++++++- node/src/chain_spec/gen_genesis_data.rs | 7 +- node/src/chain_spec/gtest.rs | 50 ++- node/src/command.rs | 13 +- pallets/smith-members/src/benchmarking.rs | 11 +- runtime/common/src/constants.rs | 2 - runtime/common/src/fees.rs | 4 +- runtime/common/src/handlers.rs | 3 +- runtime/common/src/lib.rs | 1 - runtime/common/src/pallets_config.rs | 64 ++- runtime/g1/src/lib.rs | 8 + runtime/g1/src/parameters.rs | 9 + runtime/{common => g1}/src/weights.rs | 0 runtime/g1/src/weights/block_weights.rs | 64 +++ runtime/g1/src/weights/extrinsic_weights.rs | 64 +++ .../weights/frame_benchmarking_baseline.rs | 32 +- .../src/weights/frame_system.rs | 56 +-- .../src/weights/pallet_authority_members.rs | 48 +-- .../{common => g1}/src/weights/pallet_babe.rs | 0 .../src/weights/pallet_balances.rs | 42 +- .../g1/src/weights/pallet_certification.rs | 191 +++++++++ .../src/weights/pallet_collective.rs | 128 +++--- runtime/g1/src/weights/pallet_distance.rs | 252 +++++++++++ .../src/weights/pallet_duniter_account.rs | 8 +- .../src/weights/pallet_grandpa.rs | 0 runtime/g1/src/weights/pallet_identity.rs | 402 ++++++++++++++++++ runtime/g1/src/weights/pallet_im_online.rs | 74 ++++ .../src/weights/pallet_membership.rs | 30 +- .../src/weights/pallet_multisig.rs | 70 +-- .../src/weights/pallet_oneshot_account.rs | 16 +- .../src/weights/pallet_preimage.rs | 72 ++-- .../src/weights/pallet_provide_randomness.rs | 24 +- runtime/g1/src/weights/pallet_proxy.rs | 221 ++++++++++ .../src/weights/pallet_quota.rs | 0 .../src/weights/pallet_scheduler.rs | 100 ++--- .../src/weights/pallet_session.rs | 24 +- .../g1/src/weights/pallet_smith_members.rs | 139 ++++++ .../{common => g1}/src/weights/pallet_sudo.rs | 20 +- runtime/g1/src/weights/pallet_timestamp.rs | 74 ++++ .../src/weights/pallet_treasury.rs | 46 +- .../src/weights/pallet_universal_dividend.rs | 34 +- .../src/weights/pallet_upgrade_origin.rs | 8 +- .../src/weights/pallet_utility.rs | 36 +- runtime/g1/src/weights/paritydb_weights.rs | 94 ++++ runtime/gdev/src/lib.rs | 2 + runtime/gdev/src/weights.rs | 52 +++ .../src/weights/block_weights.rs | 22 +- .../src/weights/extrinsic_weights.rs | 22 +- .../weights/frame_benchmarking_baseline.rs | 105 +++++ runtime/gdev/src/weights/frame_system.rs | 171 ++++++++ .../src/weights/pallet_authority_members.rs | 156 +++++++ runtime/gdev/src/weights/pallet_babe.rs | 54 +++ runtime/gdev/src/weights/pallet_balances.rs | 142 +++++++ .../src/weights/pallet_certification.rs | 72 ++-- runtime/gdev/src/weights/pallet_collective.rs | 302 +++++++++++++ .../src/weights/pallet_distance.rs | 106 ++--- .../src/weights/pallet_duniter_account.rs | 62 +++ runtime/gdev/src/weights/pallet_grandpa.rs | 55 +++ .../src/weights/pallet_identity.rs | 184 ++++---- .../src/weights/pallet_im_online.rs | 14 +- runtime/gdev/src/weights/pallet_membership.rs | 102 +++++ runtime/gdev/src/weights/pallet_multisig.rs | 162 +++++++ .../src/weights/pallet_oneshot_account.rs | 94 ++++ runtime/gdev/src/weights/pallet_preimage.rs | 259 +++++++++++ .../src/weights/pallet_provide_randomness.rs | 132 ++++++ runtime/gdev/src/weights/pallet_proxy.rs | 219 ++++++++++ runtime/gdev/src/weights/pallet_quota.rs | 133 ++++++ runtime/gdev/src/weights/pallet_scheduler.rs | 287 +++++++++++++ runtime/gdev/src/weights/pallet_session.rs | 78 ++++ .../src/weights/pallet_smith_members.rs | 60 +-- runtime/gdev/src/weights/pallet_sudo.rs | 96 +++++ .../src/weights/pallet_timestamp.rs | 12 +- runtime/gdev/src/weights/pallet_treasury.rs | 185 ++++++++ .../src/weights/pallet_universal_dividend.rs | 118 +++++ .../gdev/src/weights/pallet_upgrade_origin.rs | 58 +++ runtime/gdev/src/weights/pallet_utility.rs | 99 +++++ .../src/weights/paritydb_weights.rs | 38 +- runtime/gtest/src/lib.rs | 2 + runtime/gtest/src/weights.rs | 52 +++ runtime/gtest/src/weights/block_weights.rs | 64 +++ .../gtest/src/weights/extrinsic_weights.rs | 64 +++ .../weights/frame_benchmarking_baseline.rs | 105 +++++ runtime/gtest/src/weights/frame_system.rs | 171 ++++++++ .../src/weights/pallet_authority_members.rs | 156 +++++++ runtime/gtest/src/weights/pallet_babe.rs | 54 +++ runtime/gtest/src/weights/pallet_balances.rs | 142 +++++++ .../gtest/src/weights/pallet_certification.rs | 191 +++++++++ .../gtest/src/weights/pallet_collective.rs | 302 +++++++++++++ runtime/gtest/src/weights/pallet_distance.rs | 252 +++++++++++ .../src/weights/pallet_duniter_account.rs | 62 +++ runtime/gtest/src/weights/pallet_grandpa.rs | 55 +++ runtime/gtest/src/weights/pallet_identity.rs | 402 ++++++++++++++++++ runtime/gtest/src/weights/pallet_im_online.rs | 74 ++++ .../gtest/src/weights/pallet_membership.rs | 102 +++++ runtime/gtest/src/weights/pallet_multisig.rs | 162 +++++++ .../src/weights/pallet_oneshot_account.rs | 94 ++++ runtime/gtest/src/weights/pallet_preimage.rs | 259 +++++++++++ .../src/weights/pallet_provide_randomness.rs | 132 ++++++ .../src/weights/pallet_proxy.rs | 100 ++--- runtime/gtest/src/weights/pallet_quota.rs | 133 ++++++ runtime/gtest/src/weights/pallet_scheduler.rs | 287 +++++++++++++ runtime/gtest/src/weights/pallet_session.rs | 78 ++++ .../gtest/src/weights/pallet_smith_members.rs | 139 ++++++ runtime/gtest/src/weights/pallet_sudo.rs | 96 +++++ runtime/gtest/src/weights/pallet_timestamp.rs | 74 ++++ runtime/gtest/src/weights/pallet_treasury.rs | 185 ++++++++ .../src/weights/pallet_universal_dividend.rs | 118 +++++ .../src/weights/pallet_upgrade_origin.rs | 58 +++ runtime/gtest/src/weights/pallet_utility.rs | 99 +++++ runtime/gtest/src/weights/paritydb_weights.rs | 94 ++++ scripts/run_all_benchmarks.sh | 12 +- 111 files changed, 9986 insertions(+), 771 deletions(-) rename runtime/{common => g1}/src/weights.rs (100%) create mode 100644 runtime/g1/src/weights/block_weights.rs create mode 100644 runtime/g1/src/weights/extrinsic_weights.rs rename runtime/{common => g1}/src/weights/frame_benchmarking_baseline.rs (81%) rename runtime/{common => g1}/src/weights/frame_system.rs (81%) rename runtime/{common => g1}/src/weights/pallet_authority_members.rs (88%) rename runtime/{common => g1}/src/weights/pallet_babe.rs (100%) rename runtime/{common => g1}/src/weights/pallet_balances.rs (83%) create mode 100644 runtime/g1/src/weights/pallet_certification.rs rename runtime/{common => g1}/src/weights/pallet_collective.rs (81%) create mode 100644 runtime/g1/src/weights/pallet_distance.rs rename runtime/{common => g1}/src/weights/pallet_duniter_account.rs (91%) rename runtime/{common => g1}/src/weights/pallet_grandpa.rs (100%) create mode 100644 runtime/g1/src/weights/pallet_identity.rs create mode 100644 runtime/g1/src/weights/pallet_im_online.rs rename runtime/{common => g1}/src/weights/pallet_membership.rs (85%) rename runtime/{common => g1}/src/weights/pallet_multisig.rs (77%) rename runtime/{common => g1}/src/weights/pallet_oneshot_account.rs (90%) rename runtime/{common => g1}/src/weights/pallet_preimage.rs (87%) rename runtime/{common => g1}/src/weights/pallet_provide_randomness.rs (92%) create mode 100644 runtime/g1/src/weights/pallet_proxy.rs rename runtime/{common => g1}/src/weights/pallet_quota.rs (100%) rename runtime/{common => g1}/src/weights/pallet_scheduler.rs (82%) rename runtime/{common => g1}/src/weights/pallet_session.rs (83%) create mode 100644 runtime/g1/src/weights/pallet_smith_members.rs rename runtime/{common => g1}/src/weights/pallet_sudo.rs (87%) create mode 100644 runtime/g1/src/weights/pallet_timestamp.rs rename runtime/{common => g1}/src/weights/pallet_treasury.rs (86%) rename runtime/{common => g1}/src/weights/pallet_universal_dividend.rs (86%) rename runtime/{common => g1}/src/weights/pallet_upgrade_origin.rs (90%) rename runtime/{common => g1}/src/weights/pallet_utility.rs (75%) create mode 100644 runtime/g1/src/weights/paritydb_weights.rs create mode 100644 runtime/gdev/src/weights.rs rename runtime/{common => gdev}/src/weights/block_weights.rs (82%) rename runtime/{common => gdev}/src/weights/extrinsic_weights.rs (79%) create mode 100644 runtime/gdev/src/weights/frame_benchmarking_baseline.rs create mode 100644 runtime/gdev/src/weights/frame_system.rs create mode 100644 runtime/gdev/src/weights/pallet_authority_members.rs create mode 100644 runtime/gdev/src/weights/pallet_babe.rs create mode 100644 runtime/gdev/src/weights/pallet_balances.rs rename runtime/{common => gdev}/src/weights/pallet_certification.rs (83%) create mode 100644 runtime/gdev/src/weights/pallet_collective.rs rename runtime/{common => gdev}/src/weights/pallet_distance.rs (81%) create mode 100644 runtime/gdev/src/weights/pallet_duniter_account.rs create mode 100644 runtime/gdev/src/weights/pallet_grandpa.rs rename runtime/{common => gdev}/src/weights/pallet_identity.rs (83%) rename runtime/{common => gdev}/src/weights/pallet_im_online.rs (90%) create mode 100644 runtime/gdev/src/weights/pallet_membership.rs create mode 100644 runtime/gdev/src/weights/pallet_multisig.rs create mode 100644 runtime/gdev/src/weights/pallet_oneshot_account.rs create mode 100644 runtime/gdev/src/weights/pallet_preimage.rs create mode 100644 runtime/gdev/src/weights/pallet_provide_randomness.rs create mode 100644 runtime/gdev/src/weights/pallet_proxy.rs create mode 100644 runtime/gdev/src/weights/pallet_quota.rs create mode 100644 runtime/gdev/src/weights/pallet_scheduler.rs create mode 100644 runtime/gdev/src/weights/pallet_session.rs rename runtime/{common => gdev}/src/weights/pallet_smith_members.rs (82%) create mode 100644 runtime/gdev/src/weights/pallet_sudo.rs rename runtime/{common => gdev}/src/weights/pallet_timestamp.rs (90%) create mode 100644 runtime/gdev/src/weights/pallet_treasury.rs create mode 100644 runtime/gdev/src/weights/pallet_universal_dividend.rs create mode 100644 runtime/gdev/src/weights/pallet_upgrade_origin.rs create mode 100644 runtime/gdev/src/weights/pallet_utility.rs rename runtime/{common => gdev}/src/weights/paritydb_weights.rs (79%) create mode 100644 runtime/gtest/src/weights.rs create mode 100644 runtime/gtest/src/weights/block_weights.rs create mode 100644 runtime/gtest/src/weights/extrinsic_weights.rs create mode 100644 runtime/gtest/src/weights/frame_benchmarking_baseline.rs create mode 100644 runtime/gtest/src/weights/frame_system.rs create mode 100644 runtime/gtest/src/weights/pallet_authority_members.rs create mode 100644 runtime/gtest/src/weights/pallet_babe.rs create mode 100644 runtime/gtest/src/weights/pallet_balances.rs create mode 100644 runtime/gtest/src/weights/pallet_certification.rs create mode 100644 runtime/gtest/src/weights/pallet_collective.rs create mode 100644 runtime/gtest/src/weights/pallet_distance.rs create mode 100644 runtime/gtest/src/weights/pallet_duniter_account.rs create mode 100644 runtime/gtest/src/weights/pallet_grandpa.rs create mode 100644 runtime/gtest/src/weights/pallet_identity.rs create mode 100644 runtime/gtest/src/weights/pallet_im_online.rs create mode 100644 runtime/gtest/src/weights/pallet_membership.rs create mode 100644 runtime/gtest/src/weights/pallet_multisig.rs create mode 100644 runtime/gtest/src/weights/pallet_oneshot_account.rs create mode 100644 runtime/gtest/src/weights/pallet_preimage.rs create mode 100644 runtime/gtest/src/weights/pallet_provide_randomness.rs rename runtime/{common => gtest}/src/weights/pallet_proxy.rs (77%) create mode 100644 runtime/gtest/src/weights/pallet_quota.rs create mode 100644 runtime/gtest/src/weights/pallet_scheduler.rs create mode 100644 runtime/gtest/src/weights/pallet_session.rs create mode 100644 runtime/gtest/src/weights/pallet_smith_members.rs create mode 100644 runtime/gtest/src/weights/pallet_sudo.rs create mode 100644 runtime/gtest/src/weights/pallet_timestamp.rs create mode 100644 runtime/gtest/src/weights/pallet_treasury.rs create mode 100644 runtime/gtest/src/weights/pallet_universal_dividend.rs create mode 100644 runtime/gtest/src/weights/pallet_upgrade_origin.rs create mode 100644 runtime/gtest/src/weights/pallet_utility.rs create mode 100644 runtime/gtest/src/weights/paritydb_weights.rs diff --git a/node/src/chain_spec/g1.rs b/node/src/chain_spec/g1.rs index 952f493e9..49ef60461 100644 --- a/node/src/chain_spec/g1.rs +++ b/node/src/chain_spec/g1.rs @@ -14,8 +14,195 @@ // You should have received a copy of the GNU Affero General Public License // along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. -pub type ChainSpec = sc_service::GenericChainSpec<g1_runtime::GenesisConfig>; +use super::*; +use crate::chain_spec::gen_genesis_data::{ + AuthorityKeys, CommonParameters, GenesisIdentity, SessionKeysProvider, +}; +use common_runtime::{constants::*, entities::IdtyData, GenesisIdty, IdtyStatus}; +use g1_runtime::{opaque::SessionKeys, parameters, RuntimeGenesisConfig, WASM_BINARY}; +use sc_service::ChainType; +use serde::Deserialize; +use sp_core::sr25519; +use std::{env, fs}; -pub fn development_chain_spec() -> Result<ChainSpec, String> { - todo!() +pub type ChainSpec = sc_service::GenericChainSpec<RuntimeGenesisConfig>; + +#[derive(Default, Clone, Deserialize)] +// No parameters for GTest (unlike GDev) +struct GenesisParameters {} + +const TOKEN_DECIMALS: usize = 2; +const TOKEN_SYMBOL: &str = "Ğ"; +static EXISTENTIAL_DEPOSIT: u64 = parameters::ExistentialDeposit::get(); + +struct G1SKP; +impl SessionKeysProvider<SessionKeys> for G1SKP { + fn session_keys(keys: &AuthorityKeys) -> SessionKeys { + let cloned = keys.clone(); + SessionKeys { + grandpa: cloned.1, + babe: cloned.2, + im_online: cloned.3, + authority_discovery: cloned.4, + } + } +} + +fn get_parameters(_parameters_from_file: &Option<GenesisParameters>) -> CommonParameters { + CommonParameters::default() +} + +/// generate local network chainspects +pub fn local_testnet_config( + initial_authorities_len: usize, + initial_smiths_len: usize, + initial_identities_len: usize, +) -> Result<ChainSpec, String> { + Ok(ChainSpec::builder( + &get_wasm_binary().ok_or_else(|| "Development wasm not available".to_string())?, + None, + ) + .with_name("Ğ1 Local Testnet") + .with_id("g1_local") + .with_chain_type(ChainType::Local) + .with_genesis_config_patch({ + let genesis_data = + gen_genesis_data::generate_genesis_data_for_local_chain::<_, _, SessionKeys, G1SKP>( + // Initial authorities len + initial_authorities_len, + // Initial smiths len, + initial_smiths_len, + // Initial identities len + initial_identities_len, + EXISTENTIAL_DEPOSIT, + None, + // Sudo account + get_account_id_from_seed::<sr25519::Public>("Alice"), + get_parameters, + ) + .expect("Genesis Data must be buildable"); + genesis_data_to_g1_genesis_conf(genesis_data) + }) + .with_properties( + serde_json::json!({ + "tokenDecimals": TOKEN_DECIMALS, + "tokenSymbol": TOKEN_SYMBOL, + }) + .as_object() + .expect("must be a map") + .clone(), + ) + .build()) +} + +/// custom genesis +fn genesis_data_to_g1_genesis_conf( + genesis_data: super::gen_genesis_data::GenesisData<GenesisParameters, SessionKeys>, +) -> serde_json::Value { + let super::gen_genesis_data::GenesisData { + accounts, + treasury_balance, + certs_by_receiver, + first_ud, + first_ud_reeval, + identities, + initial_authorities, + initial_monetary_mass, + memberships, + parameters: _, + common_parameters: _, + session_keys_map, + initial_smiths, + sudo_key, + technical_committee_members, + ud, + } = genesis_data; + + serde_json::json!({ + "account": { + "accounts": accounts, + "treasuryBalance": treasury_balance, + }, + "authorityMembers": { + "initialAuthorities": initial_authorities, + }, + "balances": { + "totalIssuance": initial_monetary_mass, + }, + "babe": { + "epochConfig": Some(BABE_GENESIS_EPOCH_CONFIG), + }, + "session": { + "keys": session_keys_map + .into_iter() + .map(|(account_id, session_keys)| (account_id.clone(), account_id, session_keys)) + .collect::<Vec<_>>(), + }, + "sudo": { "key": sudo_key }, + "technicalCommittee": { + "members": technical_committee_members, + }, + "quota": { + "identities": identities.iter().map(|i| i.idty_index).collect::<Vec<_>>(), + }, + "identity": { + "identities": identities + .into_iter() + .map( + |GenesisIdentity { + idty_index, + name, + owner_key, + status, + expires_on, + revokes_on, + }| GenesisIdty { + index: idty_index, + name: common_runtime::IdtyName::from(name.as_str()), + value: common_runtime::IdtyValue { + data: IdtyData::new(), + next_creatable_identity_on: 0, + old_owner_key: None, + owner_key, + next_scheduled: match status { + IdtyStatus::Unconfirmed | IdtyStatus::Unvalidated => { + panic!("Unconfirmed or Unvalidated identity in genesis") + } + IdtyStatus::Member => expires_on.expect("must have expires_on set"), + IdtyStatus::Revoked => 0, + IdtyStatus::NotMember => { + revokes_on.expect("must have revokes_on set") + } + }, + status, + }, + }, + ) + .collect::<Vec<GenesisIdty<g1_runtime::Runtime>>>(), + }, + "certification": { + "applyCertPeriodAtGenesis": false, + "certsByReceiver": certs_by_receiver, + }, + "membership": { "memberships": memberships }, + "smithMembers": { "initialSmiths": initial_smiths}, + "universalDividend": { + "firstReeval": first_ud_reeval, + "firstUd": first_ud, + "initialMonetaryMass": initial_monetary_mass, + "ud": ud, + }, + }) +} + +/// Get the WASM bytes either from filesytem (`WASM_FILE` env variable giving the path to the wasm blob) +/// or else get the one compiled from source code. +/// Goal: allow to provide the WASM built with srtool, which is reproductible. +fn get_wasm_binary() -> Option<Vec<u8>> { + let wasm_bytes_from_file = if let Ok(file_path) = env::var("WASM_FILE") { + Some(fs::read(file_path).unwrap_or_else(|e| panic!("Could not read wasm file: {}", e))) + } else { + None + }; + wasm_bytes_from_file.or_else(|| WASM_BINARY.map(|bytes| bytes.to_vec())) } diff --git a/node/src/chain_spec/gen_genesis_data.rs b/node/src/chain_spec/gen_genesis_data.rs index d87347c44..a633403b0 100644 --- a/node/src/chain_spec/gen_genesis_data.rs +++ b/node/src/chain_spec/gen_genesis_data.rs @@ -14,6 +14,9 @@ // You should have received a copy of the GNU Affero General Public License // along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. +#![allow(unused_imports)] +#![allow(dead_code)] + use crate::chain_spec::{get_account_id_from_seed, get_from_seed, AccountPublic}; use common_runtime::{ constants::{DAYS, MILLISECS_PER_BLOCK}, @@ -1619,7 +1622,6 @@ fn decorate_smiths_with_identity( .collect() } -#[cfg(feature = "gdev")] pub fn generate_genesis_data_for_local_chain<P, SK, SessionKeys: Encode, SKP>( initial_authorities_len: usize, initial_smiths_len: usize, @@ -1634,6 +1636,7 @@ where SK: Decode, SKP: SessionKeysProvider<SessionKeys>, { + // For benchmarking, the total length of identities should be at least MinReceivedCertToBeAbleToIssueCert + 1 assert!(initial_identities_len <= 6); assert!(initial_smiths_len <= initial_identities_len); assert!(initial_authorities_len <= initial_smiths_len); @@ -1778,7 +1781,6 @@ where Ok(genesis_data) } -#[cfg(feature = "gdev")] fn clique_wot( initial_identities_len: usize, ) -> ( @@ -1805,7 +1807,6 @@ fn clique_wot( (certs_by_issuer, count) } -#[cfg(feature = "gdev")] fn clique_smith_wot(initial_identities_len: usize) -> BTreeMap<IdtyIndex, (bool, Vec<IdtyIndex>)> { let mut certs_by_issuer = BTreeMap::new(); for i in 1..=initial_identities_len { diff --git a/node/src/chain_spec/gtest.rs b/node/src/chain_spec/gtest.rs index 3154b76cf..2a0ea46ca 100644 --- a/node/src/chain_spec/gtest.rs +++ b/node/src/chain_spec/gtest.rs @@ -18,8 +18,8 @@ use super::*; use crate::chain_spec::gen_genesis_data::{CommonParameters, GenesisIdentity, SessionKeysProvider}; use common_runtime::{constants::*, entities::IdtyData, GenesisIdty, IdtyStatus}; use gtest_runtime::{ - opaque::SessionKeys, pallet_universal_dividend, parameters, AccountId, ImOnlineId, Perbill, - Runtime, RuntimeGenesisConfig, WASM_BINARY, + opaque::SessionKeys, pallet_universal_dividend, parameters, ImOnlineId, Perbill, Runtime, + RuntimeGenesisConfig, WASM_BINARY, }; use jsonrpsee::core::JsonValue; use sc_consensus_grandpa::AuthorityId as GrandpaId; @@ -29,7 +29,7 @@ use sc_telemetry::TelemetryEndpoints; use serde::Deserialize; use sp_authority_discovery::AuthorityId as AuthorityDiscoveryId; use sp_consensus_babe::AuthorityId as BabeId; -use sp_core::Get; +use sp_core::{sr25519, Get}; use std::{env, fs}; pub type ChainSpec = sc_service::GenericChainSpec<RuntimeGenesisConfig>; @@ -43,6 +43,7 @@ pub type AuthorityKeys = ( const TOKEN_DECIMALS: usize = 2; const TOKEN_SYMBOL: &str = "ĞT"; +static EXISTENTIAL_DEPOSIT: u64 = parameters::ExistentialDeposit::get(); #[derive(Default, Clone, Deserialize)] // No parameters for GTest (unlike GDev) @@ -61,6 +62,49 @@ impl SessionKeysProvider<SessionKeys> for GTestSKP { } } +/// generate local network chainspects +pub fn local_testnet_config( + initial_authorities_len: usize, + initial_smiths_len: usize, + initial_identities_len: usize, +) -> Result<ChainSpec, String> { + Ok(ChainSpec::builder( + &get_wasm_binary().ok_or_else(|| "Development wasm not available".to_string())?, + None, + ) + .with_name("ĞTest Local Testnet") + .with_id("gtest_local") + .with_chain_type(ChainType::Local) + .with_genesis_config_patch({ + let genesis_data = + gen_genesis_data::generate_genesis_data_for_local_chain::<_, _, SessionKeys, GTestSKP>( + // Initial authorities len + initial_authorities_len, + // Initial smiths len, + initial_smiths_len, + // Initial identities len + initial_identities_len, + EXISTENTIAL_DEPOSIT, + None, + // Sudo account + get_account_id_from_seed::<sr25519::Public>("Alice"), + get_parameters, + ) + .expect("Genesis Data must be buildable"); + genesis_data_to_gtest_genesis_conf(genesis_data) + }) + .with_properties( + serde_json::json!({ + "tokenDecimals": TOKEN_DECIMALS, + "tokenSymbol": TOKEN_SYMBOL, + }) + .as_object() + .expect("must be a map") + .clone(), + ) + .build()) +} + fn get_parameters(_: &Option<GenesisParameters>) -> CommonParameters { CommonParameters { currency_name: TOKEN_SYMBOL.to_string(), diff --git a/node/src/command.rs b/node/src/command.rs index 9b0f335c3..be3e2b16f 100644 --- a/node/src/command.rs +++ b/node/src/command.rs @@ -84,8 +84,9 @@ impl SubstrateCli for Cli { fn load_spec(&self, id: &str) -> Result<Box<dyn sc_service::ChainSpec>, String> { Ok(match id { // Development chainspec with generated genesis and Alice as a validator + // For benchmarking, the total length of identities should be at least MinReceivedCertToBeAbleToIssueCert + 1 #[cfg(feature = "gdev")] - "dev" => Box::new(chain_spec::gdev::local_testnet_config(1, 3, 4)?), + "dev" => Box::new(chain_spec::gdev::local_testnet_config(1, 5, 6)?), // Local testnet with G1 data, Gdev configuration (parameters & Smiths), and Alice as a validator. // Optionally, load configuration from DUNITER_GENESIS_CONFIG file to override default Gdev configuration. @@ -120,6 +121,10 @@ impl SubstrateCli for Cli { &include_bytes!("../specs/gdev-raw.json")[..], )?), + // For benchmarking, the total length of identities should be at least MinReceivedCertToBeAbleToIssueCert + 1 + #[cfg(feature = "gtest")] + "dev" => Box::new(chain_spec::gtest::local_testnet_config(1, 5, 6)?), + // Generate development chainspecs with Alice as a validator. // Provide the DUNITER_GTEST_GENESIS environment variable to build genesis from JSON; otherwise, a local testnet with generated genesis will be used. #[cfg(feature = "gtest")] @@ -157,11 +162,9 @@ impl SubstrateCli for Cli { &include_bytes!("../specs/gtest-raw.json")[..], )?), + // For benchmarking, the total length of identities should be at least MinReceivedCertToBeAbleToIssueCert + 1 #[cfg(feature = "g1")] - "g1" => { - unimplemented!() - //Box::new(chain_spec::g1::ChainSpec::from_json_file(file_path)?) - } + "dev" => Box::new(chain_spec::g1::local_testnet_config(1, 5, 6)?), path => { let path = std::path::PathBuf::from(path); diff --git a/pallets/smith-members/src/benchmarking.rs b/pallets/smith-members/src/benchmarking.rs index 0381e177c..7db266901 100644 --- a/pallets/smith-members/src/benchmarking.rs +++ b/pallets/smith-members/src/benchmarking.rs @@ -39,7 +39,8 @@ mod benchmarks { let issuer: T::IdtyIndex = 1.into(); let caller: T::AccountId = T::IdtyAttr::owner_key(issuer).unwrap(); Pallet::<T>::on_smith_goes_online(1.into()); - let receiver: T::IdtyIndex = 4.into(); + // Should be the last identities from the local_testnet_config + let receiver: T::IdtyIndex = 6.into(); #[extrinsic_call] _(RawOrigin::Signed(caller), receiver); @@ -54,9 +55,10 @@ mod benchmarks { Pallet::<T>::on_smith_goes_online(1.into()); let caller_origin: <T as frame_system::Config>::RuntimeOrigin = RawOrigin::Signed(caller.clone()).into(); - let receiver: T::IdtyIndex = 4.into(); + // Should be the last identities from the local_testnet_config + let receiver: T::IdtyIndex = 6.into(); Pallet::<T>::invite_smith(caller_origin, receiver)?; - let issuer: T::IdtyIndex = 4.into(); + let issuer: T::IdtyIndex = 6.into(); let caller: T::AccountId = T::IdtyAttr::owner_key(issuer).unwrap(); #[extrinsic_call] @@ -78,7 +80,8 @@ mod benchmarks { Pallet::<T>::on_smith_goes_online(1.into()); let caller_origin: <T as frame_system::Config>::RuntimeOrigin = RawOrigin::Signed(caller.clone()).into(); - let receiver: T::IdtyIndex = 4.into(); + // Should be the last identities from the local_testnet_config + let receiver: T::IdtyIndex = 6.into(); Pallet::<T>::invite_smith(caller_origin, receiver)?; let issuer: T::IdtyIndex = receiver; let caller: T::AccountId = T::IdtyAttr::owner_key(issuer).unwrap(); diff --git a/runtime/common/src/constants.rs b/runtime/common/src/constants.rs index 77de93269..a9f31004c 100644 --- a/runtime/common/src/constants.rs +++ b/runtime/common/src/constants.rs @@ -17,8 +17,6 @@ use crate::{Balance, BlockNumber}; use sp_runtime::Perbill; -pub use crate::weights::paritydb_weights::constants::ParityDbWeight as DbWeight; - /// This determines the average expected block time that we are targeting. /// Blocks will be produced at a minimum duration defined by `SLOT_DURATION`. /// `SLOT_DURATION` is picked up by `pallet_timestamp` which is in turn picked diff --git a/runtime/common/src/fees.rs b/runtime/common/src/fees.rs index 50e40df1f..9d7a166bb 100644 --- a/runtime/common/src/fees.rs +++ b/runtime/common/src/fees.rs @@ -27,7 +27,6 @@ use sp_core::Get; use sp_runtime::{traits::Convert, Perquintill}; #[cfg(not(feature = "constant-fees"))] use { - crate::weights::extrinsic_weights::ExtrinsicBaseWeight, frame_support::pallet_prelude::DispatchClass, frame_support::weights::{ WeightToFeeCoefficient, WeightToFeeCoefficients, WeightToFeePolynomial, @@ -154,7 +153,8 @@ where } else { // The extrinsic base weight (smallest non-zero weight) is mapped to 5 cents let p: Self::Balance = 5u64.into(); - let q: Self::Balance = Self::Balance::from(ExtrinsicBaseWeight::get().ref_time()); + let q: Self::Balance = + Self::Balance::from(weights.get(DispatchClass::Normal).base_extrinsic.ref_time()); smallvec![WeightToFeeCoefficient { degree: 1, negative: false, diff --git a/runtime/common/src/handlers.rs b/runtime/common/src/handlers.rs index e8518fd1c..fa247d1c5 100644 --- a/runtime/common/src/handlers.rs +++ b/runtime/common/src/handlers.rs @@ -17,6 +17,7 @@ use super::{entities::*, AccountId, IdtyIndex}; use frame_support::{pallet_prelude::Weight, traits::UnfilteredDispatchable}; use pallet_smith_members::SmithRemovalReason; +use sp_core::Get; /// OnNewSession handler for the runtime calling all the implementation /// of OnNewSession @@ -108,7 +109,7 @@ impl< let mut weight = pallet_duniter_wot::Pallet::<Runtime>::on_removed(idty_index); let mut add_db_reads_writes = |reads, writes| { - weight += crate::constants::DbWeight::get().reads_writes(reads, writes); + weight += Runtime::DbWeight::get().reads_writes(reads, writes); }; // When membership is removed, call on_removed_member handler which auto claims UD. diff --git a/runtime/common/src/lib.rs b/runtime/common/src/lib.rs index 589b4f381..e4fac0aa6 100644 --- a/runtime/common/src/lib.rs +++ b/runtime/common/src/lib.rs @@ -23,7 +23,6 @@ pub mod fees; pub mod handlers; mod pallets_config; pub mod providers; -pub mod weights; pub use pallet_duniter_account::GenesisAccountData; pub use pallet_identity::{GenesisIdty, IdtyName, IdtyStatus, IdtyValue}; diff --git a/runtime/common/src/pallets_config.rs b/runtime/common/src/pallets_config.rs index 967139552..8f44df118 100644 --- a/runtime/common/src/pallets_config.rs +++ b/runtime/common/src/pallets_config.rs @@ -74,7 +74,7 @@ macro_rules! pallets_config { type SS58Prefix = SS58Prefix; type SingleBlockMigrations = (); /// Weight information for the extrinsics of this pallet. - type SystemWeightInfo = common_runtime::weights::frame_system::WeightInfo<Runtime>; + type SystemWeightInfo = weights::frame_system::WeightInfo<Runtime>; /// Version of the runtime. type Version = Version; } @@ -97,7 +97,7 @@ macro_rules! pallets_config { type RuntimeEvent = RuntimeEvent; type RuntimeOrigin = RuntimeOrigin; type ScheduleOrigin = EnsureRoot<AccountId>; - type WeightInfo = common_runtime::weights::pallet_scheduler::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_scheduler::WeightInfo<Runtime>; } // ACCOUNT // @@ -107,7 +107,7 @@ macro_rules! pallets_config { type InnerOnChargeTransaction = FungibleAdapter<Balances, HandleFees>; type Refund = Quota; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_duniter_account::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_duniter_account::WeightInfo<Runtime>; } // QUOTA // @@ -130,7 +130,7 @@ macro_rules! pallets_config { type RefundAccount = TreasuryAccountId; type ReloadRate = ReloadRate; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_quota::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_quota::WeightInfo<Runtime>; } // BLOCK CREATION // @@ -147,14 +147,14 @@ macro_rules! pallets_config { <Historical as KeyOwnerProofSystem<(KeyTypeId, pallet_babe::AuthorityId)>>::Proof; type MaxAuthorities = MaxAuthorities; type MaxNominators = MaxNominators; - type WeightInfo = common_runtime::weights::pallet_babe::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_babe::WeightInfo<Runtime>; } impl pallet_timestamp::Config for Runtime { type MinimumPeriod = MinimumPeriod; type Moment = u64; type OnTimestampSet = (Babe, UniversalDividend); - type WeightInfo = common_runtime::weights::pallet_timestamp::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_timestamp::WeightInfo<Runtime>; } // MONEY MANAGEMENT // @@ -172,7 +172,7 @@ macro_rules! pallets_config { type RuntimeEvent = RuntimeEvent; type RuntimeFreezeReason = (); type RuntimeHoldReason = RuntimeHoldReason; - type WeightInfo = common_runtime::weights::pallet_balances::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_balances::WeightInfo<Runtime>; } type CreditOf = frame_support::traits::tokens::fungible::Credit<AccountId, Balances>; @@ -194,21 +194,20 @@ macro_rules! pallets_config { pub MaxMultiplier: sp_runtime::FixedU128 = 10.into(); } impl pallet_transaction_payment::Config for Runtime { - type FeeMultiplierUpdate = - common_runtime::fees::FeeMultiplier<Self, Target, MaxMultiplier>; - type LengthToFee = common_runtime::fees::LengthToFeeImpl<Balance, Self, Target>; + type FeeMultiplierUpdate = fees::FeeMultiplier<Self, Target, MaxMultiplier>; + type LengthToFee = fees::LengthToFeeImpl<Balance, Self, Target>; // does a filter on the call type OnChargeTransaction = OneshotAccount; type OperationalFeeMultiplier = frame_support::traits::ConstU8<5>; type RuntimeEvent = RuntimeEvent; - type WeightToFee = common_runtime::fees::WeightToFeeImpl<Balance, Self, Target>; + type WeightToFee = fees::WeightToFeeImpl<Balance, Self, Target>; } impl pallet_oneshot_account::Config for Runtime { type Currency = Balances; // when call is not oneshot account, fall back to duniter-account implementation type InnerOnChargeTransaction = Account; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_oneshot_account::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_oneshot_account::WeightInfo<Runtime>; } // CONSENSUS // @@ -226,8 +225,7 @@ macro_rules! pallets_config { type OnOutgoingMember = SmithMembers; type RemoveMemberOrigin = EnsureRoot<Self::AccountId>; type RuntimeEvent = RuntimeEvent; - type WeightInfo = - common_runtime::weights::pallet_authority_members::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_authority_members::WeightInfo<Runtime>; } impl pallet_authorship::Config for Runtime { type EventHandler = ImOnline; @@ -245,7 +243,7 @@ macro_rules! pallets_config { type RuntimeEvent = RuntimeEvent; type UnsignedPriority = ImOnlineUnsignedPriority; type ValidatorSet = Historical; - type WeightInfo = common_runtime::weights::pallet_im_online::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_im_online::WeightInfo<Runtime>; } impl pallet_offences::Config for Runtime { type IdentificationTuple = pallet_session::historical::IdentificationTuple<Self>; @@ -262,7 +260,7 @@ macro_rules! pallets_config { type ShouldEndSession = Babe; type ValidatorId = AccountId; type ValidatorIdOf = sp_runtime::traits::ConvertInto; - type WeightInfo = common_runtime::weights::pallet_session::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_session::WeightInfo<Runtime>; } impl pallet_session::historical::Config for Runtime { type FullIdentification = ValidatorFullIdentification; @@ -280,7 +278,7 @@ macro_rules! pallets_config { type MaxNominators = frame_support::traits::ConstU32<64>; type MaxSetIdSessionEntries = MaxSetIdSessionEntries; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_grandpa::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_grandpa::WeightInfo<Runtime>; } parameter_types! { // BondingDuration::get() * SessionsPerEra::get(); @@ -303,7 +301,7 @@ macro_rules! pallets_config { 2, 3, >; - type WeightInfo = common_runtime::weights::pallet_upgrade_origin::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_upgrade_origin::WeightInfo<Runtime>; #[cfg(feature = "runtime-benchmarks")] type WorstCaseOrigin = WorstCaseOrigin; #[cfg(feature = "runtime-benchmarks")] @@ -321,7 +319,7 @@ macro_rules! pallets_config { type Currency = Balances; type ManagerOrigin = EnsureRoot<AccountId>; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_preimage::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_preimage::WeightInfo<Runtime>; } // UTILITIES // @@ -342,8 +340,7 @@ macro_rules! pallets_config { type RandomnessFromOneEpochAgo = pallet_babe::RandomnessFromOneEpochAgo<Self>; type RequestPrice = frame_support::traits::ConstU64<2_000>; type RuntimeEvent = RuntimeEvent; - type WeightInfo = - common_runtime::weights::pallet_provide_randomness::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_provide_randomness::WeightInfo<Runtime>; } parameter_types! { @@ -366,7 +363,7 @@ macro_rules! pallets_config { type ProxyType = ProxyType; type RuntimeCall = RuntimeCall; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_proxy::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_proxy::WeightInfo<Runtime>; } parameter_types! { @@ -380,14 +377,14 @@ macro_rules! pallets_config { type MaxSignatories = MaxSignatories; type RuntimeCall = RuntimeCall; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_multisig::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_multisig::WeightInfo<Runtime>; } impl pallet_utility::Config for Runtime { type PalletsOrigin = OriginCaller; type RuntimeCall = RuntimeCall; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_utility::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_utility::WeightInfo<Runtime>; } parameter_types! { @@ -424,7 +421,7 @@ macro_rules! pallets_config { type SpendFunds = TreasurySpendFunds<Self>; type SpendOrigin = frame_support::traits::NeverEnsureOrigin<Balance>; type SpendPeriod = SpendPeriod; - type WeightInfo = common_runtime::weights::pallet_treasury::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_treasury::WeightInfo<Runtime>; } // UNIVERSAL DIVIDEND // @@ -449,8 +446,7 @@ macro_rules! pallets_config { type UdCreationPeriod = UdCreationPeriod; type UdReevalPeriod = UdReevalPeriod; type UnitsPerUd = frame_support::traits::ConstU64<1_000>; - type WeightInfo = - common_runtime::weights::pallet_universal_dividend::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_universal_dividend::WeightInfo<Runtime>; } // WEB OF TRUST // @@ -483,13 +479,13 @@ macro_rules! pallets_config { type Signature = Signature; type Signer = <Signature as sp_runtime::traits::Verify>::Signer; type ValidationPeriod = ValidationPeriod; - type WeightInfo = common_runtime::weights::pallet_identity::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_identity::WeightInfo<Runtime>; } impl pallet_sudo::Config for Runtime { type RuntimeCall = RuntimeCall; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_sudo::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_sudo::WeightInfo<Runtime>; } impl pallet_membership::Config for Runtime { @@ -503,7 +499,7 @@ macro_rules! pallets_config { type OnNewMembership = OnNewMembershipHandler<Runtime>; type OnRemoveMembership = OnRemoveMembershipHandler<Runtime>; type RuntimeEvent = RuntimeEvent; - type WeightInfo = common_runtime::weights::pallet_membership::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_membership::WeightInfo<Runtime>; } impl pallet_certification::Config for Runtime { @@ -517,7 +513,7 @@ macro_rules! pallets_config { type OnRemovedCert = Wot; type RuntimeEvent = RuntimeEvent; type ValidityPeriod = ValidityPeriod; - type WeightInfo = common_runtime::weights::pallet_certification::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_certification::WeightInfo<Runtime>; } parameter_types! { pub const MinAccessibleReferees: Perbill = Perbill::from_percent(80); @@ -532,7 +528,7 @@ macro_rules! pallets_config { type OnValidDistanceStatus = Wot; type RuntimeEvent = RuntimeEvent; type RuntimeHoldReason = RuntimeHoldReason; - type WeightInfo = common_runtime::weights::pallet_distance::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_distance::WeightInfo<Runtime>; } // SMITH-MEMBERS @@ -547,7 +543,7 @@ macro_rules! pallets_config { type OnSmithDelete = OnSmithDeletedHandler<Runtime>; type RuntimeEvent = RuntimeEvent; type SmithInactivityMaxDuration = SmithInactivityMaxDuration; - type WeightInfo = common_runtime::weights::pallet_smith_members::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_smith_members::WeightInfo<Runtime>; } pub struct TechnicalCommitteeDefaultVote; @@ -578,7 +574,7 @@ macro_rules! pallets_config { type RuntimeEvent = RuntimeEvent; type RuntimeOrigin = RuntimeOrigin; type SetMembersOrigin = EnsureRoot<AccountId>; - type WeightInfo = common_runtime::weights::pallet_collective::WeightInfo<Runtime>; + type WeightInfo = weights::pallet_collective::WeightInfo<Runtime>; } }; } diff --git a/runtime/g1/src/lib.rs b/runtime/g1/src/lib.rs index 21378216a..865c524eb 100644 --- a/runtime/g1/src/lib.rs +++ b/runtime/g1/src/lib.rs @@ -27,6 +27,7 @@ include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); extern crate frame_benchmarking; pub mod parameters; +pub mod weights; pub use self::parameters::*; use common_runtime::IdtyNameValidatorImpl; @@ -67,6 +68,7 @@ use sp_std::prelude::*; #[cfg(feature = "std")] use sp_version::NativeVersion; use sp_version::RuntimeVersion; +pub use weights::paritydb_weights::constants::ParityDbWeight as DbWeight; // A few exports that help ease life for downstream crates. use frame_support::instances::Instance2; @@ -171,6 +173,7 @@ mod benches { pub struct BaseCallFilter; impl Contains<RuntimeCall> for BaseCallFilter { + #[cfg(not(feature = "runtime-benchmarks"))] fn contains(call: &RuntimeCall) -> bool { !matches!( call, @@ -179,6 +182,11 @@ impl Contains<RuntimeCall> for BaseCallFilter { ) | RuntimeCall::Session(_) ) } + + #[cfg(feature = "runtime-benchmarks")] + fn contains(call: &RuntimeCall) -> bool { + !matches!(call, RuntimeCall::Session(_)) + } } /// The type used to represent the kinds of proxying allowed. diff --git a/runtime/g1/src/parameters.rs b/runtime/g1/src/parameters.rs index 4be9a2361..ba67b5a11 100644 --- a/runtime/g1/src/parameters.rs +++ b/runtime/g1/src/parameters.rs @@ -67,6 +67,15 @@ parameter_types! { /*********/ // Balances +// Why? Pallet treasury benchmarks are broken because the spend +// value is hardcoded 100 in benchmark and the account is not provided enough funds +// to exist if ED > 100. +#[cfg(feature = "runtime-benchmarks")] +frame_support::parameter_types! { + pub const ExistentialDeposit: Balance = 100; + pub const MaxLocks: u32 = 50; +} +#[cfg(not(feature = "runtime-benchmarks"))] frame_support::parameter_types! { pub const ExistentialDeposit: Balance = 200; pub const MaxLocks: u32 = 50; diff --git a/runtime/common/src/weights.rs b/runtime/g1/src/weights.rs similarity index 100% rename from runtime/common/src/weights.rs rename to runtime/g1/src/weights.rs diff --git a/runtime/g1/src/weights/block_weights.rs b/runtime/g1/src/weights/block_weights.rs new file mode 100644 index 000000000..a14012c73 --- /dev/null +++ b/runtime/g1/src/weights/block_weights.rs @@ -0,0 +1,64 @@ + +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21 (Y/M/D) +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! +//! SHORT-NAME: `block`, LONG-NAME: `BlockExecution`, RUNTIME: `Ğ1 Local Testnet` +//! WARMUPS: `10`, REPEAT: `100` +//! WEIGHT-PATH: `./runtime/g1/src/weights/` +//! WEIGHT-METRIC: `Average`, WEIGHT-MUL: `1.0`, WEIGHT-ADD: `0` + +// Executed Command: +// target/release/duniter +// benchmark +// overhead +// --chain=dev +// --wasm-execution=compiled +// --weight-path=./runtime/g1/src/weights/ +// --warmup=10 +// --repeat=100 + +use sp_core::parameter_types; +use sp_weights::{constants::WEIGHT_REF_TIME_PER_NANOS, Weight}; + +parameter_types! { + /// Time to execute an empty block. + /// Calculated by multiplying the *Average* with `1.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 128_003, 199_587 + /// Average: 143_429 + /// Median: 137_761 + /// Std-Dev: 14472.21 + /// + /// Percentiles nanoseconds: + /// 99th: 186_505 + /// 95th: 173_773 + /// 75th: 144_817 + pub const BlockExecutionWeight: Weight = + Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(143_429), 0); +} + +#[cfg(test)] +mod test_weights { + use sp_weights::constants; + + /// Checks that the weight exists and is sane. + // NOTE: If this test fails but you are sure that the generated values are fine, + // you can delete it. + #[test] + fn sane() { + let w = super::BlockExecutionWeight::get(); + + // At least 100 µs. + assert!( + w.ref_time() >= 100u64 * constants::WEIGHT_REF_TIME_PER_MICROS, + "Weight should be at least 100 µs." + ); + // At most 50 ms. + assert!( + w.ref_time() <= 50u64 * constants::WEIGHT_REF_TIME_PER_MILLIS, + "Weight should be at most 50 ms." + ); + } +} diff --git a/runtime/g1/src/weights/extrinsic_weights.rs b/runtime/g1/src/weights/extrinsic_weights.rs new file mode 100644 index 000000000..4f1068568 --- /dev/null +++ b/runtime/g1/src/weights/extrinsic_weights.rs @@ -0,0 +1,64 @@ + +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21 (Y/M/D) +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! +//! SHORT-NAME: `extrinsic`, LONG-NAME: `ExtrinsicBase`, RUNTIME: `Ğ1 Local Testnet` +//! WARMUPS: `10`, REPEAT: `100` +//! WEIGHT-PATH: `./runtime/g1/src/weights/` +//! WEIGHT-METRIC: `Average`, WEIGHT-MUL: `1.0`, WEIGHT-ADD: `0` + +// Executed Command: +// target/release/duniter +// benchmark +// overhead +// --chain=dev +// --wasm-execution=compiled +// --weight-path=./runtime/g1/src/weights/ +// --warmup=10 +// --repeat=100 + +use sp_core::parameter_types; +use sp_weights::{constants::WEIGHT_REF_TIME_PER_NANOS, Weight}; + +parameter_types! { + /// Time to execute a NO-OP extrinsic, for example `System::remark`. + /// Calculated by multiplying the *Average* with `1.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 93_630, 101_268 + /// Average: 95_816 + /// Median: 95_345 + /// Std-Dev: 1631.84 + /// + /// Percentiles nanoseconds: + /// 99th: 100_968 + /// 95th: 98_869 + /// 75th: 96_525 + pub const ExtrinsicBaseWeight: Weight = + Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(95_816), 0); +} + +#[cfg(test)] +mod test_weights { + use sp_weights::constants; + + /// Checks that the weight exists and is sane. + // NOTE: If this test fails but you are sure that the generated values are fine, + // you can delete it. + #[test] + fn sane() { + let w = super::ExtrinsicBaseWeight::get(); + + // At least 10 µs. + assert!( + w.ref_time() >= 10u64 * constants::WEIGHT_REF_TIME_PER_MICROS, + "Weight should be at least 10 µs." + ); + // At most 1 ms. + assert!( + w.ref_time() <= constants::WEIGHT_REF_TIME_PER_MILLIS, + "Weight should be at most 1 ms." + ); + } +} diff --git a/runtime/common/src/weights/frame_benchmarking_baseline.rs b/runtime/g1/src/weights/frame_benchmarking_baseline.rs similarity index 81% rename from runtime/common/src/weights/frame_benchmarking_baseline.rs rename to runtime/g1/src/weights/frame_benchmarking_baseline.rs index a64d72edc..cc3b73d03 100644 --- a/runtime/common/src/weights/frame_benchmarking_baseline.rs +++ b/runtime/g1/src/weights/frame_benchmarking_baseline.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `frame_benchmarking::baseline` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -52,8 +52,8 @@ impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for Weigh // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 78_000 picoseconds. - Weight::from_parts(91_433, 0) + // Minimum execution time: 82_000 picoseconds. + Weight::from_parts(102_509, 0) .saturating_add(Weight::from_parts(0, 0)) } /// The range of component `i` is `[0, 1000000]`. @@ -61,8 +61,8 @@ impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for Weigh // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 79_000 picoseconds. - Weight::from_parts(91_582, 0) + // Minimum execution time: 82_000 picoseconds. + Weight::from_parts(107_304, 0) .saturating_add(Weight::from_parts(0, 0)) } /// The range of component `i` is `[0, 1000000]`. @@ -70,8 +70,8 @@ impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for Weigh // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 79_000 picoseconds. - Weight::from_parts(102_823, 0) + // Minimum execution time: 82_000 picoseconds. + Weight::from_parts(112_346, 0) .saturating_add(Weight::from_parts(0, 0)) } /// The range of component `i` is `[0, 1000000]`. @@ -79,16 +79,16 @@ impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for Weigh // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 78_000 picoseconds. - Weight::from_parts(93_569, 0) + // Minimum execution time: 80_000 picoseconds. + Weight::from_parts(110_824, 0) .saturating_add(Weight::from_parts(0, 0)) } fn hashing() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 19_590_146_000 picoseconds. - Weight::from_parts(19_655_687_000, 0) + // Minimum execution time: 20_604_088_000 picoseconds. + Weight::from_parts(20_659_172_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// The range of component `i` is `[0, 100]`. @@ -96,10 +96,10 @@ impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for Weigh // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 82_000 picoseconds. - Weight::from_parts(27_963_495, 0) + // Minimum execution time: 83_000 picoseconds. + Weight::from_parts(86_000, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 12_306 - .saturating_add(Weight::from_parts(31_412_930, 0).saturating_mul(i.into())) + // Standard Error: 78_903 + .saturating_add(Weight::from_parts(34_221_862, 0).saturating_mul(i.into())) } } diff --git a/runtime/common/src/weights/frame_system.rs b/runtime/g1/src/weights/frame_system.rs similarity index 81% rename from runtime/common/src/weights/frame_system.rs rename to runtime/g1/src/weights/frame_system.rs index 898c8d46d..7729f342e 100644 --- a/runtime/common/src/weights/frame_system.rs +++ b/runtime/g1/src/weights/frame_system.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `frame_system` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -52,22 +52,22 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 1_419_000 picoseconds. - Weight::from_parts(1_498_000, 0) + // Minimum execution time: 1_488_000 picoseconds. + Weight::from_parts(1_588_000, 0) .saturating_add(Weight::from_parts(0, 0)) // Standard Error: 0 - .saturating_add(Weight::from_parts(256, 0).saturating_mul(b.into())) + .saturating_add(Weight::from_parts(266, 0).saturating_mul(b.into())) } /// The range of component `b` is `[0, 3932160]`. fn remark_with_event(b: u32, ) -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_020_000 picoseconds. - Weight::from_parts(4_121_000, 0) + // Minimum execution time: 4_103_000 picoseconds. + Weight::from_parts(4_318_000, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 0 - .saturating_add(Weight::from_parts(1_075, 0).saturating_mul(b.into())) + // Standard Error: 1 + .saturating_add(Weight::from_parts(1_112, 0).saturating_mul(b.into())) } /// Storage: `System::Digest` (r:1 w:1) /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) @@ -77,8 +77,8 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `1485` - // Minimum execution time: 2_492_000 picoseconds. - Weight::from_parts(2_799_000, 0) + // Minimum execution time: 2_426_000 picoseconds. + Weight::from_parts(2_721_000, 0) .saturating_add(Weight::from_parts(0, 1485)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(2)) @@ -91,8 +91,8 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `1485` - // Minimum execution time: 63_133_954_000 picoseconds. - Weight::from_parts(63_864_391_000, 0) + // Minimum execution time: 66_944_212_000 picoseconds. + Weight::from_parts(68_513_557_000, 0) .saturating_add(Weight::from_parts(0, 1485)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(2)) @@ -104,11 +104,11 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 1_449_000 picoseconds. - Weight::from_parts(1_579_000, 0) + // Minimum execution time: 1_620_000 picoseconds. + Weight::from_parts(1_718_000, 0) .saturating_add(Weight::from_parts(0, 0)) // Standard Error: 559 - .saturating_add(Weight::from_parts(556_169, 0).saturating_mul(i.into())) + .saturating_add(Weight::from_parts(580_078, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) } /// Storage: `Skipped::Metadata` (r:0 w:0) @@ -118,11 +118,11 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 1_433_000 picoseconds. - Weight::from_parts(1_567_000, 0) + // Minimum execution time: 1_430_000 picoseconds. + Weight::from_parts(1_645_000, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 663 - .saturating_add(Weight::from_parts(431_131, 0).saturating_mul(i.into())) + // Standard Error: 688 + .saturating_add(Weight::from_parts(444_307, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) } /// Storage: `Skipped::Metadata` (r:0 w:0) @@ -132,11 +132,11 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `77 + p * (69 ±0)` // Estimated: `76 + p * (70 ±0)` - // Minimum execution time: 2_623_000 picoseconds. - Weight::from_parts(2_777_000, 0) + // Minimum execution time: 2_941_000 picoseconds. + Weight::from_parts(3_124_000, 0) .saturating_add(Weight::from_parts(0, 76)) - // Standard Error: 880 - .saturating_add(Weight::from_parts(884_981, 0).saturating_mul(p.into())) + // Standard Error: 1_003 + .saturating_add(Weight::from_parts(920_024, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) .saturating_add(Weight::from_parts(0, 70).saturating_mul(p.into())) @@ -147,8 +147,8 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 8_355_000 picoseconds. - Weight::from_parts(9_636_000, 0) + // Minimum execution time: 8_620_000 picoseconds. + Weight::from_parts(11_950_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -162,8 +162,8 @@ impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `22` // Estimated: `1518` - // Minimum execution time: 67_748_762_000 picoseconds. - Weight::from_parts(68_751_848_000, 0) + // Minimum execution time: 71_526_279_000 picoseconds. + Weight::from_parts(73_982_865_000, 0) .saturating_add(Weight::from_parts(0, 1518)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(3)) diff --git a/runtime/common/src/weights/pallet_authority_members.rs b/runtime/g1/src/weights/pallet_authority_members.rs similarity index 88% rename from runtime/common/src/weights/pallet_authority_members.rs rename to runtime/g1/src/weights/pallet_authority_members.rs index 55a182c4a..78f713dda 100644 --- a/runtime/common/src/weights/pallet_authority_members.rs +++ b/runtime/g1/src/weights/pallet_authority_members.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_authority_members` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -61,11 +61,11 @@ impl<T: frame_system::Config> pallet_authority_members::WeightInfo for WeightInf /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) fn go_offline() -> Weight { // Proof Size summary in bytes: - // Measured: `750` - // Estimated: `4215` - // Minimum execution time: 19_493_000 picoseconds. - Weight::from_parts(20_030_000, 0) - .saturating_add(Weight::from_parts(0, 4215)) + // Measured: `900` + // Estimated: `4365` + // Minimum execution time: 19_310_000 picoseconds. + Weight::from_parts(20_099_000, 0) + .saturating_add(Weight::from_parts(0, 4365)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -87,11 +87,11 @@ impl<T: frame_system::Config> pallet_authority_members::WeightInfo for WeightInf /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) fn go_online() -> Weight { // Proof Size summary in bytes: - // Measured: `1141` - // Estimated: `4606` - // Minimum execution time: 25_348_000 picoseconds. - Weight::from_parts(26_404_000, 0) - .saturating_add(Weight::from_parts(0, 4606)) + // Measured: `1356` + // Estimated: `4821` + // Minimum execution time: 25_731_000 picoseconds. + Weight::from_parts(28_353_000, 0) + .saturating_add(Weight::from_parts(0, 4821)) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -109,11 +109,11 @@ impl<T: frame_system::Config> pallet_authority_members::WeightInfo for WeightInf /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) fn set_session_keys() -> Weight { // Proof Size summary in bytes: - // Measured: `1511` - // Estimated: `12401` - // Minimum execution time: 32_606_000 picoseconds. - Weight::from_parts(34_374_000, 0) - .saturating_add(Weight::from_parts(0, 12401)) + // Measured: `1805` + // Estimated: `12695` + // Minimum execution time: 34_495_000 picoseconds. + Weight::from_parts(35_882_000, 0) + .saturating_add(Weight::from_parts(0, 12695)) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -133,11 +133,11 @@ impl<T: frame_system::Config> pallet_authority_members::WeightInfo for WeightInf /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) fn remove_member() -> Weight { // Proof Size summary in bytes: - // Measured: `716` - // Estimated: `4181` - // Minimum execution time: 31_528_000 picoseconds. - Weight::from_parts(32_724_000, 0) - .saturating_add(Weight::from_parts(0, 4181)) + // Measured: `847` + // Estimated: `4312` + // Minimum execution time: 33_828_000 picoseconds. + Weight::from_parts(35_954_000, 0) + .saturating_add(Weight::from_parts(0, 4312)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(10)) } @@ -147,8 +147,8 @@ impl<T: frame_system::Config> pallet_authority_members::WeightInfo for WeightInf // Proof Size summary in bytes: // Measured: `199` // Estimated: `1684` - // Minimum execution time: 6_678_000 picoseconds. - Weight::from_parts(7_152_000, 0) + // Minimum execution time: 7_218_000 picoseconds. + Weight::from_parts(7_666_000, 0) .saturating_add(Weight::from_parts(0, 1684)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) diff --git a/runtime/common/src/weights/pallet_babe.rs b/runtime/g1/src/weights/pallet_babe.rs similarity index 100% rename from runtime/common/src/weights/pallet_babe.rs rename to runtime/g1/src/weights/pallet_babe.rs diff --git a/runtime/common/src/weights/pallet_balances.rs b/runtime/g1/src/weights/pallet_balances.rs similarity index 83% rename from runtime/common/src/weights/pallet_balances.rs rename to runtime/g1/src/weights/pallet_balances.rs index 839334501..acb0de82e 100644 --- a/runtime/common/src/weights/pallet_balances.rs +++ b/runtime/g1/src/weights/pallet_balances.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_balances` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -53,8 +53,8 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `63` // Estimated: `6126` - // Minimum execution time: 41_565_000 picoseconds. - Weight::from_parts(42_593_000, 0) + // Minimum execution time: 47_283_000 picoseconds. + Weight::from_parts(48_312_000, 0) .saturating_add(Weight::from_parts(0, 6126)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) @@ -65,8 +65,8 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3558` - // Minimum execution time: 27_790_000 picoseconds. - Weight::from_parts(29_817_000, 0) + // Minimum execution time: 29_130_000 picoseconds. + Weight::from_parts(29_974_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -75,10 +75,10 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) fn force_set_balance_creating() -> Weight { // Proof Size summary in bytes: - // Measured: `100` + // Measured: `134` // Estimated: `3558` - // Minimum execution time: 9_821_000 picoseconds. - Weight::from_parts(10_305_000, 0) + // Minimum execution time: 9_725_000 picoseconds. + Weight::from_parts(10_310_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -87,10 +87,10 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) fn force_set_balance_killing() -> Weight { // Proof Size summary in bytes: - // Measured: `100` + // Measured: `134` // Estimated: `3558` - // Minimum execution time: 12_978_000 picoseconds. - Weight::from_parts(13_582_000, 0) + // Minimum execution time: 13_621_000 picoseconds. + Weight::from_parts(14_288_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -101,8 +101,8 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `126` // Estimated: `8694` - // Minimum execution time: 42_747_000 picoseconds. - Weight::from_parts(44_051_000, 0) + // Minimum execution time: 48_880_000 picoseconds. + Weight::from_parts(68_817_000, 0) .saturating_add(Weight::from_parts(0, 8694)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) @@ -113,8 +113,8 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `3558` - // Minimum execution time: 34_844_000 picoseconds. - Weight::from_parts(35_230_000, 0) + // Minimum execution time: 36_784_000 picoseconds. + Weight::from_parts(37_938_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -123,10 +123,10 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) fn force_unreserve() -> Weight { // Proof Size summary in bytes: - // Measured: `100` + // Measured: `134` // Estimated: `3558` - // Minimum execution time: 11_831_000 picoseconds. - Weight::from_parts(12_229_000, 0) + // Minimum execution time: 12_523_000 picoseconds. + Weight::from_parts(13_096_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -135,8 +135,8 @@ impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_144_000 picoseconds. - Weight::from_parts(4_464_000, 0) + // Minimum execution time: 4_328_000 picoseconds. + Weight::from_parts(4_704_000, 0) .saturating_add(Weight::from_parts(0, 0)) } } diff --git a/runtime/g1/src/weights/pallet_certification.rs b/runtime/g1/src/weights/pallet_certification.rs new file mode 100644 index 000000000..480f979f5 --- /dev/null +++ b/runtime/g1/src/weights/pallet_certification.rs @@ -0,0 +1,191 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_certification` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/g1/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_certification`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsRemovableOn` (r:1 w:1) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn add_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `996` + // Estimated: `6936` + // Minimum execution time: 32_668_000 picoseconds. + Weight::from_parts(34_295_000, 0) + .saturating_add(Weight::from_parts(0, 6936)) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1 w:1) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsRemovableOn` (r:1 w:1) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn renew_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `1019` + // Estimated: `6959` + // Minimum execution time: 29_969_000 picoseconds. + Weight::from_parts(31_722_000, 0) + .saturating_add(Weight::from_parts(0, 6959)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn del_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `2202` + // Estimated: `15567` + // Minimum execution time: 104_239_000 picoseconds. + Weight::from_parts(108_628_000, 0) + .saturating_add(Weight::from_parts(0, 15567)) + .saturating_add(T::DbWeight::get().reads(20)) + .saturating_add(T::DbWeight::get().writes(22)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1000 w:1000) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[2, 1000]`. + fn remove_all_certs_received_by(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `554 + i * (35 ±0)` + // Estimated: `4018 + i * (2511 ±0)` + // Minimum execution time: 22_929_000 picoseconds. + Weight::from_parts(23_507_000, 0) + .saturating_add(Weight::from_parts(0, 4018)) + // Standard Error: 22_172 + .saturating_add(Weight::from_parts(8_401_006, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2511).saturating_mul(i.into())) + } + /// Storage: `Certification::CertsRemovableOn` (r:1 w:0) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn on_initialize() -> Weight { + // Proof Size summary in bytes: + // Measured: `138` + // Estimated: `3603` + // Minimum execution time: 2_568_000 picoseconds. + Weight::from_parts(2_701_000, 0) + .saturating_add(Weight::from_parts(0, 3603)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_cert_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `275` + // Estimated: `3740` + // Minimum execution time: 3_610_000 picoseconds. + Weight::from_parts(4_070_000, 0) + .saturating_add(Weight::from_parts(0, 3740)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `711` + // Estimated: `6651` + // Minimum execution time: 20_144_000 picoseconds. + Weight::from_parts(20_800_000, 0) + .saturating_add(Weight::from_parts(0, 6651)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/common/src/weights/pallet_collective.rs b/runtime/g1/src/weights/pallet_collective.rs similarity index 81% rename from runtime/common/src/weights/pallet_collective.rs rename to runtime/g1/src/weights/pallet_collective.rs index bdb723e56..bd57093c2 100644 --- a/runtime/common/src/weights/pallet_collective.rs +++ b/runtime/g1/src/weights/pallet_collective.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_collective` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -62,13 +62,13 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0 + m * (672 ±0) + p * (3191 ±0)` // Estimated: `10019 + m * (416 ±4) + p * (4183 ±23)` - // Minimum execution time: 10_752_000 picoseconds. - Weight::from_parts(10_889_000, 0) + // Minimum execution time: 11_455_000 picoseconds. + Weight::from_parts(11_731_000, 0) .saturating_add(Weight::from_parts(0, 10019)) - // Standard Error: 9_186 - .saturating_add(Weight::from_parts(692_252, 0).saturating_mul(m.into())) - // Standard Error: 45_413 - .saturating_add(Weight::from_parts(6_020_530, 0).saturating_mul(p.into())) + // Standard Error: 10_081 + .saturating_add(Weight::from_parts(778_276, 0).saturating_mul(m.into())) + // Standard Error: 49_834 + .saturating_add(Weight::from_parts(6_454_743, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) .saturating_add(T::DbWeight::get().writes(2)) @@ -84,13 +84,13 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `32 + m * (32 ±0)` // Estimated: `1518 + m * (32 ±0)` - // Minimum execution time: 9_225_000 picoseconds. - Weight::from_parts(9_016_861, 0) + // Minimum execution time: 9_805_000 picoseconds. + Weight::from_parts(9_281_964, 0) .saturating_add(Weight::from_parts(0, 1518)) - // Standard Error: 28 - .saturating_add(Weight::from_parts(1_184, 0).saturating_mul(b.into())) - // Standard Error: 289 - .saturating_add(Weight::from_parts(10_540, 0).saturating_mul(m.into())) + // Standard Error: 82 + .saturating_add(Weight::from_parts(1_478, 0).saturating_mul(b.into())) + // Standard Error: 848 + .saturating_add(Weight::from_parts(11_095, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } @@ -104,13 +104,13 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `32 + m * (32 ±0)` // Estimated: `3498 + m * (32 ±0)` - // Minimum execution time: 10_827_000 picoseconds. - Weight::from_parts(10_744_142, 0) + // Minimum execution time: 11_821_000 picoseconds. + Weight::from_parts(11_344_434, 0) .saturating_add(Weight::from_parts(0, 3498)) - // Standard Error: 36 - .saturating_add(Weight::from_parts(1_257, 0).saturating_mul(b.into())) - // Standard Error: 378 - .saturating_add(Weight::from_parts(17_916, 0).saturating_mul(m.into())) + // Standard Error: 105 + .saturating_add(Weight::from_parts(1_615, 0).saturating_mul(b.into())) + // Standard Error: 1_091 + .saturating_add(Weight::from_parts(18_409, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) } @@ -131,15 +131,15 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `24 + m * (32 ±0) + p * (55 ±0)` // Estimated: `3461 + m * (32 ±0) + p * (54 ±0)` - // Minimum execution time: 16_098_000 picoseconds. - Weight::from_parts(15_641_556, 0) + // Minimum execution time: 16_893_000 picoseconds. + Weight::from_parts(16_224_150, 0) .saturating_add(Weight::from_parts(0, 3461)) - // Standard Error: 60 - .saturating_add(Weight::from_parts(2_167, 0).saturating_mul(b.into())) - // Standard Error: 633 - .saturating_add(Weight::from_parts(14_798, 0).saturating_mul(m.into())) - // Standard Error: 3_162 - .saturating_add(Weight::from_parts(240_622, 0).saturating_mul(p.into())) + // Standard Error: 144 + .saturating_add(Weight::from_parts(2_745, 0).saturating_mul(b.into())) + // Standard Error: 1_512 + .saturating_add(Weight::from_parts(14_651, 0).saturating_mul(m.into())) + // Standard Error: 7_557 + .saturating_add(Weight::from_parts(272_881, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(4)) .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) @@ -154,11 +154,11 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `573 + m * (64 ±0)` // Estimated: `4037 + m * (64 ±0)` - // Minimum execution time: 14_164_000 picoseconds. - Weight::from_parts(15_244_842, 0) + // Minimum execution time: 15_152_000 picoseconds. + Weight::from_parts(16_030_484, 0) .saturating_add(Weight::from_parts(0, 4037)) - // Standard Error: 599 - .saturating_add(Weight::from_parts(32_813, 0).saturating_mul(m.into())) + // Standard Error: 571 + .saturating_add(Weight::from_parts(35_795, 0).saturating_mul(m.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) @@ -177,13 +177,13 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `117 + m * (64 ±0) + p * (55 ±0)` // Estimated: `3591 + m * (64 ±0) + p * (55 ±0)` - // Minimum execution time: 18_522_000 picoseconds. - Weight::from_parts(17_152_627, 0) + // Minimum execution time: 19_051_000 picoseconds. + Weight::from_parts(17_785_655, 0) .saturating_add(Weight::from_parts(0, 3591)) - // Standard Error: 516 - .saturating_add(Weight::from_parts(29_607, 0).saturating_mul(m.into())) - // Standard Error: 2_549 - .saturating_add(Weight::from_parts(211_764, 0).saturating_mul(p.into())) + // Standard Error: 666 + .saturating_add(Weight::from_parts(33_222, 0).saturating_mul(m.into())) + // Standard Error: 3_293 + .saturating_add(Weight::from_parts(239_176, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) @@ -204,15 +204,15 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `62 + b * (1 ±0) + m * (64 ±0) + p * (78 ±0)` // Estimated: `3619 + b * (1 ±0) + m * (63 ±0) + p * (74 ±0)` - // Minimum execution time: 26_712_000 picoseconds. - Weight::from_parts(25_076_930, 0) + // Minimum execution time: 27_513_000 picoseconds. + Weight::from_parts(26_090_194, 0) .saturating_add(Weight::from_parts(0, 3619)) - // Standard Error: 82 - .saturating_add(Weight::from_parts(1_994, 0).saturating_mul(b.into())) - // Standard Error: 873 - .saturating_add(Weight::from_parts(18_412, 0).saturating_mul(m.into())) - // Standard Error: 4_310 - .saturating_add(Weight::from_parts(313_327, 0).saturating_mul(p.into())) + // Standard Error: 97 + .saturating_add(Weight::from_parts(2_350, 0).saturating_mul(b.into())) + // Standard Error: 1_031 + .saturating_add(Weight::from_parts(20_452, 0).saturating_mul(m.into())) + // Standard Error: 5_088 + .saturating_add(Weight::from_parts(354_605, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) @@ -235,13 +235,13 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `137 + m * (64 ±0) + p * (55 ±0)` // Estimated: `3611 + m * (64 ±0) + p * (55 ±0)` - // Minimum execution time: 20_754_000 picoseconds. - Weight::from_parts(18_867_635, 0) + // Minimum execution time: 20_467_000 picoseconds. + Weight::from_parts(19_801_085, 0) .saturating_add(Weight::from_parts(0, 3611)) - // Standard Error: 545 - .saturating_add(Weight::from_parts(34_251, 0).saturating_mul(m.into())) - // Standard Error: 2_693 - .saturating_add(Weight::from_parts(232_282, 0).saturating_mul(p.into())) + // Standard Error: 788 + .saturating_add(Weight::from_parts(36_887, 0).saturating_mul(m.into())) + // Standard Error: 3_894 + .saturating_add(Weight::from_parts(255_052, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) @@ -264,15 +264,15 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `82 + b * (1 ±0) + m * (64 ±0) + p * (78 ±0)` // Estimated: `3639 + b * (1 ±0) + m * (63 ±0) + p * (74 ±0)` - // Minimum execution time: 27_752_000 picoseconds. - Weight::from_parts(26_500_438, 0) + // Minimum execution time: 29_432_000 picoseconds. + Weight::from_parts(27_967_998, 0) .saturating_add(Weight::from_parts(0, 3639)) - // Standard Error: 85 - .saturating_add(Weight::from_parts(2_063, 0).saturating_mul(b.into())) - // Standard Error: 903 - .saturating_add(Weight::from_parts(17_377, 0).saturating_mul(m.into())) - // Standard Error: 4_454 - .saturating_add(Weight::from_parts(327_819, 0).saturating_mul(p.into())) + // Standard Error: 117 + .saturating_add(Weight::from_parts(1_840, 0).saturating_mul(b.into())) + // Standard Error: 1_242 + .saturating_add(Weight::from_parts(19_800, 0).saturating_mul(m.into())) + // Standard Error: 6_127 + .saturating_add(Weight::from_parts(366_556, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) @@ -290,11 +290,11 @@ impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `189 + p * (32 ±0)` // Estimated: `1674 + p * (32 ±0)` - // Minimum execution time: 9_042_000 picoseconds. - Weight::from_parts(10_091_880, 0) + // Minimum execution time: 9_219_000 picoseconds. + Weight::from_parts(10_411_761, 0) .saturating_add(Weight::from_parts(0, 1674)) - // Standard Error: 1_853 - .saturating_add(Weight::from_parts(159_967, 0).saturating_mul(p.into())) + // Standard Error: 2_273 + .saturating_add(Weight::from_parts(192_309, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(3)) .saturating_add(Weight::from_parts(0, 32).saturating_mul(p.into())) diff --git a/runtime/g1/src/weights/pallet_distance.rs b/runtime/g1/src/weights/pallet_distance.rs new file mode 100644 index 000000000..b3e212bf0 --- /dev/null +++ b/runtime/g1/src/weights/pallet_distance.rs @@ -0,0 +1,252 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_distance` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/g1/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_distance`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1 w:0) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + fn request_distance_evaluation() -> Weight { + // Proof Size summary in bytes: + // Measured: `1107` + // Estimated: `4572` + // Minimum execution time: 52_342_000 picoseconds. + Weight::from_parts(53_914_000, 0) + .saturating_add(Weight::from_parts(0, 4572)) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1 w:0) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + fn request_distance_evaluation_for() -> Weight { + // Proof Size summary in bytes: + // Measured: `1136` + // Estimated: `7076` + // Minimum execution time: 54_176_000 picoseconds. + Weight::from_parts(56_512_000, 0) + .saturating_add(Weight::from_parts(0, 7076)) + .saturating_add(T::DbWeight::get().reads(10)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Distance::DidUpdate` (r:1 w:1) + /// Proof: `Distance::DidUpdate` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Authorship::Author` (r:1 w:1) + /// Proof: `Authorship::Author` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `System::Digest` (r:1 w:0) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::Validators` (r:1 w:0) + /// Proof: `Session::Validators` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool0` (r:1 w:1) + /// Proof: `Distance::EvaluationPool0` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[1, 1300]`. + fn update_evaluation(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `401 + i * (10 ±0)` + // Estimated: `1886 + i * (10 ±0)` + // Minimum execution time: 13_562_000 picoseconds. + Weight::from_parts(9_554_749, 0) + .saturating_add(Weight::from_parts(0, 1886)) + // Standard Error: 2_096 + .saturating_add(Weight::from_parts(129_096, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 10).saturating_mul(i.into())) + } + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool0` (r:1 w:1) + /// Proof: `Distance::EvaluationPool0` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[1, 1300]`. + fn force_update_evaluation(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `139 + i * (10 ±0)` + // Estimated: `1624 + i * (10 ±0)` + // Minimum execution time: 5_430_000 picoseconds. + Weight::from_parts(6_430_669, 0) + .saturating_add(Weight::from_parts(0, 1624)) + // Standard Error: 328 + .saturating_add(Weight::from_parts(107_495, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(Weight::from_parts(0, 10).saturating_mul(i.into())) + } + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::MembershipsExpireOn` (r:2 w:2) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn force_valid_distance_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `539` + // Estimated: `6479` + // Minimum execution time: 23_801_000 picoseconds. + Weight::from_parts(24_622_000, 0) + .saturating_add(Weight::from_parts(0, 6479)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } + fn on_initialize_overhead() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 91_000 picoseconds. + Weight::from_parts(121_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `System::ParentHash` (r:1 w:0) + /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::MembershipsExpireOn` (r:2 w:2) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationBlock` (r:0 w:1) + /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn do_evaluation_success() -> Weight { + // Proof Size summary in bytes: + // Measured: `951` + // Estimated: `6891` + // Minimum execution time: 54_127_000 picoseconds. + Weight::from_parts(58_505_000, 0) + .saturating_add(Weight::from_parts(0, 6891)) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(8)) + } + /// Storage: `System::ParentHash` (r:1 w:0) + /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationBlock` (r:0 w:1) + /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn do_evaluation_failure() -> Weight { + // Proof Size summary in bytes: + // Measured: `412` + // Estimated: `3877` + // Minimum execution time: 38_090_000 picoseconds. + Weight::from_parts(41_629_000, 0) + .saturating_add(Weight::from_parts(0, 3877)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::ParentHash` (r:1 w:0) + /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:0) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationBlock` (r:0 w:1) + /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn do_evaluation_overhead() -> Weight { + // Proof Size summary in bytes: + // Measured: `109` + // Estimated: `1594` + // Minimum execution time: 3_673_000 picoseconds. + Weight::from_parts(4_334_000, 0) + .saturating_add(Weight::from_parts(0, 1594)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Distance::DidUpdate` (r:1 w:1) + /// Proof: `Distance::DidUpdate` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn on_finalize() -> Weight { + // Proof Size summary in bytes: + // Measured: `133` + // Estimated: `1618` + // Minimum execution time: 2_500_000 picoseconds. + Weight::from_parts(2_719_000, 0) + .saturating_add(Weight::from_parts(0, 1618)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/common/src/weights/pallet_duniter_account.rs b/runtime/g1/src/weights/pallet_duniter_account.rs similarity index 91% rename from runtime/common/src/weights/pallet_duniter_account.rs rename to runtime/g1/src/weights/pallet_duniter_account.rs index d43be46c9..a7ad7e47a 100644 --- a/runtime/common/src/weights/pallet_duniter_account.rs +++ b/runtime/g1/src/weights/pallet_duniter_account.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_duniter_account` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -53,8 +53,8 @@ impl<T: frame_system::Config> pallet_duniter_account::WeightInfo for WeightInfo< // Proof Size summary in bytes: // Measured: `0` // Estimated: `3558` - // Minimum execution time: 2_950_000 picoseconds. - Weight::from_parts(3_302_000, 0) + // Minimum execution time: 3_276_000 picoseconds. + Weight::from_parts(3_498_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) diff --git a/runtime/common/src/weights/pallet_grandpa.rs b/runtime/g1/src/weights/pallet_grandpa.rs similarity index 100% rename from runtime/common/src/weights/pallet_grandpa.rs rename to runtime/g1/src/weights/pallet_grandpa.rs diff --git a/runtime/g1/src/weights/pallet_identity.rs b/runtime/g1/src/weights/pallet_identity.rs new file mode 100644 index 000000000..655eb36d8 --- /dev/null +++ b/runtime/g1/src/weights/pallet_identity.rs @@ -0,0 +1,402 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_identity` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/g1/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_identity`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:2 w:1) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:2) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Identity::NextIdtyIndex` (r:1 w:1) + /// Proof: `Identity::NextIdtyIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::CounterForIdentities` (r:1 w:1) + /// Proof: `Identity::CounterForIdentities` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Certification::CertsRemovableOn` (r:1 w:1) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn create_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `1042` + // Estimated: `6982` + // Minimum execution time: 57_159_000 picoseconds. + Weight::from_parts(58_944_000, 0) + .saturating_add(Weight::from_parts(0, 6982)) + .saturating_add(T::DbWeight::get().reads(12)) + .saturating_add(T::DbWeight::get().writes(12)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentitiesNames` (r:1 w:1) + /// Proof: `Identity::IdentitiesNames` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn confirm_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `784` + // Estimated: `6724` + // Minimum execution time: 27_974_000 picoseconds. + Weight::from_parts(29_240_000, 0) + .saturating_add(Weight::from_parts(0, 6724)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Identity::IdentityIndexOf` (r:2 w:2) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn change_owner_key() -> Weight { + // Proof Size summary in bytes: + // Measured: `793` + // Estimated: `6733` + // Minimum execution time: 73_700_000 picoseconds. + Weight::from_parts(76_284_000, 0) + .saturating_add(Weight::from_parts(0, 6733)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn revoke_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `697` + // Estimated: `6637` + // Minimum execution time: 63_941_000 picoseconds. + Weight::from_parts(65_986_000, 0) + .saturating_add(Weight::from_parts(0, 6637)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `Identity::IdentitiesNames` (r:0 w:999) + /// Proof: `Identity::IdentitiesNames` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[2, 1000]`. + fn prune_item_identities_names(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_658_000 picoseconds. + Weight::from_parts(3_837_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 1_600 + .saturating_add(Weight::from_parts(1_231_001, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn fix_sufficients() -> Weight { + // Proof Size summary in bytes: + // Measured: `104` + // Estimated: `3558` + // Minimum execution time: 6_189_000 picoseconds. + Weight::from_parts(6_702_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn link_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `440` + // Estimated: `3905` + // Minimum execution time: 50_644_000 picoseconds. + Weight::from_parts(52_917_000, 0) + .saturating_add(Weight::from_parts(0, 3905)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn on_initialize() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 82_000 picoseconds. + Weight::from_parts(95_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_revoke_identity_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `327` + // Estimated: `3792` + // Minimum execution time: 3_717_000 picoseconds. + Weight::from_parts(3_937_000, 0) + .saturating_add(Weight::from_parts(0, 3792)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_revoke_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `1873` + // Estimated: `15238` + // Minimum execution time: 89_637_000 picoseconds. + Weight::from_parts(92_550_000, 0) + .saturating_add(Weight::from_parts(0, 15238)) + .saturating_add(T::DbWeight::get().reads(18)) + .saturating_add(T::DbWeight::get().writes(21)) + } + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_identity_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `327` + // Estimated: `3792` + // Minimum execution time: 3_683_000 picoseconds. + Weight::from_parts(3_930_000, 0) + .saturating_add(Weight::from_parts(0, 3792)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::CounterForIdentities` (r:1 w:1) + /// Proof: `Identity::CounterForIdentities` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:6 w:6) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityIndexOf` (r:0 w:1) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `2322` + // Estimated: `18162` + // Minimum execution time: 135_200_000 picoseconds. + Weight::from_parts(140_643_000, 0) + .saturating_add(Weight::from_parts(0, 18162)) + .saturating_add(T::DbWeight::get().reads(24)) + .saturating_add(T::DbWeight::get().writes(30)) + } + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:6 w:6) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_identity_handler() -> Weight { + // Proof Size summary in bytes: + // Measured: `2315` + // Estimated: `18155` + // Minimum execution time: 129_327_000 picoseconds. + Weight::from_parts(135_434_000, 0) + .saturating_add(Weight::from_parts(0, 18155)) + .saturating_add(T::DbWeight::get().reads(25)) + .saturating_add(T::DbWeight::get().writes(28)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn membership_removed() -> Weight { + // Proof Size summary in bytes: + // Measured: `407` + // Estimated: `6347` + // Minimum execution time: 13_919_000 picoseconds. + Weight::from_parts(14_590_000, 0) + .saturating_add(Weight::from_parts(0, 6347)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:0) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn prune_identities_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `108` + // Estimated: `3573` + // Minimum execution time: 2_086_000 picoseconds. + Weight::from_parts(2_226_000, 0) + .saturating_add(Weight::from_parts(0, 3573)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn prune_identities_none() -> Weight { + // Proof Size summary in bytes: + // Measured: `325` + // Estimated: `3790` + // Minimum execution time: 5_490_000 picoseconds. + Weight::from_parts(5_800_000, 0) + .saturating_add(Weight::from_parts(0, 3790)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::CounterForIdentities` (r:1 w:1) + /// Proof: `Identity::CounterForIdentities` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:0) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityIndexOf` (r:0 w:1) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn prune_identities_err() -> Weight { + // Proof Size summary in bytes: + // Measured: `914` + // Estimated: `4379` + // Minimum execution time: 29_917_000 picoseconds. + Weight::from_parts(30_935_000, 0) + .saturating_add(Weight::from_parts(0, 4379)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(7)) + } +} diff --git a/runtime/g1/src/weights/pallet_im_online.rs b/runtime/g1/src/weights/pallet_im_online.rs new file mode 100644 index 000000000..b4c75e3a8 --- /dev/null +++ b/runtime/g1/src/weights/pallet_im_online.rs @@ -0,0 +1,74 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_im_online` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/g1/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_im_online`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_im_online::WeightInfo for WeightInfo<T> { + /// Storage: `Session::Validators` (r:1 w:0) + /// Proof: `Session::Validators` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::CurrentIndex` (r:1 w:0) + /// Proof: `Session::CurrentIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ImOnline::Keys` (r:1 w:0) + /// Proof: `ImOnline::Keys` (`max_values`: Some(1), `max_size`: Some(32002), added: 32497, mode: `MaxEncodedLen`) + /// Storage: `ImOnline::ReceivedHeartbeats` (r:1 w:1) + /// Proof: `ImOnline::ReceivedHeartbeats` (`max_values`: None, `max_size`: Some(25), added: 2500, mode: `MaxEncodedLen`) + /// Storage: `ImOnline::AuthoredBlocks` (r:1 w:0) + /// Proof: `ImOnline::AuthoredBlocks` (`max_values`: None, `max_size`: Some(56), added: 2531, mode: `MaxEncodedLen`) + /// The range of component `k` is `[1, 1000]`. + fn validate_unsigned_and_then_heartbeat(k: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `525 + k * (32 ±0)` + // Estimated: `33487 + k * (1761 ±0)` + // Minimum execution time: 51_978_000 picoseconds. + Weight::from_parts(90_294_507, 0) + .saturating_add(Weight::from_parts(0, 33487)) + // Standard Error: 1_035 + .saturating_add(Weight::from_parts(27_347, 0).saturating_mul(k.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(Weight::from_parts(0, 1761).saturating_mul(k.into())) + } +} diff --git a/runtime/common/src/weights/pallet_membership.rs b/runtime/g1/src/weights/pallet_membership.rs similarity index 85% rename from runtime/common/src/weights/pallet_membership.rs rename to runtime/g1/src/weights/pallet_membership.rs index e73cd744d..59462e72f 100644 --- a/runtime/common/src/weights/pallet_membership.rs +++ b/runtime/g1/src/weights/pallet_membership.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_membership` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -51,8 +51,8 @@ impl<T: frame_system::Config> pallet_membership::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 81_000 picoseconds. - Weight::from_parts(102_000, 0) + // Minimum execution time: 86_000 picoseconds. + Weight::from_parts(110_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// Storage: `Membership::MembershipsExpireOn` (r:2 w:2) @@ -63,11 +63,11 @@ impl<T: frame_system::Config> pallet_membership::WeightInfo for WeightInfo<T> { /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) /// Storage: `Identity::Identities` (r:3 w:3) /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:1) /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) - /// Storage: `SmithMembers::Smiths` (r:3 w:3) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `AuthorityMembers::Members` (r:3 w:3) /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -86,17 +86,17 @@ impl<T: frame_system::Config> pallet_membership::WeightInfo for WeightInfo<T> { /// The range of component `i` is `[0, 3]`. fn expire_memberships(i: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `138 + i * (804 ±0)` - // Estimated: `9744 + i * (2687 ±0)` - // Minimum execution time: 4_020_000 picoseconds. - Weight::from_parts(10_625_923, 0) - .saturating_add(Weight::from_parts(0, 9744)) - // Standard Error: 438_932 - .saturating_add(Weight::from_parts(59_569_449, 0).saturating_mul(i.into())) + // Measured: `139 + i * (964 ±0)` + // Estimated: `15002 + i * (2695 ±1)` + // Minimum execution time: 3_893_000 picoseconds. + Weight::from_parts(10_673_982, 0) + .saturating_add(Weight::from_parts(0, 15002)) + // Standard Error: 452_271 + .saturating_add(Weight::from_parts(69_545_566, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(3)) - .saturating_add(T::DbWeight::get().reads((10_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().reads((11_u64).saturating_mul(i.into()))) .saturating_add(T::DbWeight::get().writes(3)) .saturating_add(T::DbWeight::get().writes((14_u64).saturating_mul(i.into()))) - .saturating_add(Weight::from_parts(0, 2687).saturating_mul(i.into())) + .saturating_add(Weight::from_parts(0, 2695).saturating_mul(i.into())) } } diff --git a/runtime/common/src/weights/pallet_multisig.rs b/runtime/g1/src/weights/pallet_multisig.rs similarity index 77% rename from runtime/common/src/weights/pallet_multisig.rs rename to runtime/g1/src/weights/pallet_multisig.rs index 3a02f9907..4d24f20db 100644 --- a/runtime/common/src/weights/pallet_multisig.rs +++ b/runtime/g1/src/weights/pallet_multisig.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_multisig` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -52,11 +52,11 @@ impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_700_000 picoseconds. - Weight::from_parts(5_031_868, 0) + // Minimum execution time: 4_905_000 picoseconds. + Weight::from_parts(5_259_870, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 1 - .saturating_add(Weight::from_parts(336, 0).saturating_mul(z.into())) + // Standard Error: 2 + .saturating_add(Weight::from_parts(343, 0).saturating_mul(z.into())) } /// Storage: `Multisig::Multisigs` (r:1 w:1) /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) @@ -66,13 +66,13 @@ impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `125 + s * (5 ±0)` // Estimated: `3922` - // Minimum execution time: 22_870_000 picoseconds. - Weight::from_parts(22_165_477, 0) + // Minimum execution time: 24_291_000 picoseconds. + Weight::from_parts(22_243_031, 0) .saturating_add(Weight::from_parts(0, 3922)) - // Standard Error: 5_814 - .saturating_add(Weight::from_parts(182_402, 0).saturating_mul(s.into())) - // Standard Error: 5 - .saturating_add(Weight::from_parts(1_093, 0).saturating_mul(z.into())) + // Standard Error: 22_683 + .saturating_add(Weight::from_parts(319_381, 0).saturating_mul(s.into())) + // Standard Error: 19 + .saturating_add(Weight::from_parts(1_182, 0).saturating_mul(z.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -84,12 +84,12 @@ impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `240` // Estimated: `3922` - // Minimum execution time: 13_557_000 picoseconds. - Weight::from_parts(12_644_271, 0) + // Minimum execution time: 13_929_000 picoseconds. + Weight::from_parts(14_103_962, 0) .saturating_add(Weight::from_parts(0, 3922)) - // Standard Error: 4_239 - .saturating_add(Weight::from_parts(139_896, 0).saturating_mul(s.into())) - // Standard Error: 3 + // Standard Error: 5_337 + .saturating_add(Weight::from_parts(85_464, 0).saturating_mul(s.into())) + // Standard Error: 4 .saturating_add(Weight::from_parts(1_080, 0).saturating_mul(z.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -104,13 +104,13 @@ impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `259 + s * (37 ±0)` // Estimated: `3922` - // Minimum execution time: 25_742_000 picoseconds. - Weight::from_parts(25_260_018, 0) + // Minimum execution time: 27_493_000 picoseconds. + Weight::from_parts(26_581_790, 0) .saturating_add(Weight::from_parts(0, 3922)) - // Standard Error: 5_601 - .saturating_add(Weight::from_parts(190_696, 0).saturating_mul(s.into())) - // Standard Error: 4 - .saturating_add(Weight::from_parts(1_084, 0).saturating_mul(z.into())) + // Standard Error: 6_933 + .saturating_add(Weight::from_parts(209_068, 0).saturating_mul(s.into())) + // Standard Error: 5 + .saturating_add(Weight::from_parts(1_130, 0).saturating_mul(z.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -121,11 +121,11 @@ impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `130 + s * (5 ±0)` // Estimated: `3922` - // Minimum execution time: 20_342_000 picoseconds. - Weight::from_parts(22_035_094, 0) + // Minimum execution time: 21_028_000 picoseconds. + Weight::from_parts(22_918_964, 0) .saturating_add(Weight::from_parts(0, 3922)) - // Standard Error: 5_918 - .saturating_add(Weight::from_parts(100_249, 0).saturating_mul(s.into())) + // Standard Error: 7_405 + .saturating_add(Weight::from_parts(160_606, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -136,11 +136,11 @@ impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `240` // Estimated: `3922` - // Minimum execution time: 11_121_000 picoseconds. - Weight::from_parts(12_140_243, 0) + // Minimum execution time: 11_875_000 picoseconds. + Weight::from_parts(12_720_752, 0) .saturating_add(Weight::from_parts(0, 3922)) - // Standard Error: 3_270 - .saturating_add(Weight::from_parts(129_148, 0).saturating_mul(s.into())) + // Standard Error: 4_314 + .saturating_add(Weight::from_parts(142_496, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -151,11 +151,11 @@ impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `328 + s * (5 ±0)` // Estimated: `3922` - // Minimum execution time: 21_577_000 picoseconds. - Weight::from_parts(22_824_830, 0) + // Minimum execution time: 22_333_000 picoseconds. + Weight::from_parts(23_955_624, 0) .saturating_add(Weight::from_parts(0, 3922)) - // Standard Error: 5_043 - .saturating_add(Weight::from_parts(157_777, 0).saturating_mul(s.into())) + // Standard Error: 6_347 + .saturating_add(Weight::from_parts(177_303, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } diff --git a/runtime/common/src/weights/pallet_oneshot_account.rs b/runtime/g1/src/weights/pallet_oneshot_account.rs similarity index 90% rename from runtime/common/src/weights/pallet_oneshot_account.rs rename to runtime/g1/src/weights/pallet_oneshot_account.rs index 351111163..ee19a1197 100644 --- a/runtime/common/src/weights/pallet_oneshot_account.rs +++ b/runtime/g1/src/weights/pallet_oneshot_account.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_oneshot_account` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -53,8 +53,8 @@ impl<T: frame_system::Config> pallet_oneshot_account::WeightInfo for WeightInfo< // Proof Size summary in bytes: // Measured: `42` // Estimated: `3507` - // Minimum execution time: 14_969_000 picoseconds. - Weight::from_parts(15_431_000, 0) + // Minimum execution time: 19_796_000 picoseconds. + Weight::from_parts(21_414_000, 0) .saturating_add(Weight::from_parts(0, 3507)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -69,8 +69,8 @@ impl<T: frame_system::Config> pallet_oneshot_account::WeightInfo for WeightInfo< // Proof Size summary in bytes: // Measured: `241` // Estimated: `3706` - // Minimum execution time: 21_074_000 picoseconds. - Weight::from_parts(21_985_000, 0) + // Minimum execution time: 27_329_000 picoseconds. + Weight::from_parts(28_104_000, 0) .saturating_add(Weight::from_parts(0, 3706)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(2)) @@ -85,8 +85,8 @@ impl<T: frame_system::Config> pallet_oneshot_account::WeightInfo for WeightInfo< // Proof Size summary in bytes: // Measured: `301` // Estimated: `6126` - // Minimum execution time: 29_007_000 picoseconds. - Weight::from_parts(30_502_000, 0) + // Minimum execution time: 39_994_000 picoseconds. + Weight::from_parts(42_840_000, 0) .saturating_add(Weight::from_parts(0, 6126)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) diff --git a/runtime/common/src/weights/pallet_preimage.rs b/runtime/g1/src/weights/pallet_preimage.rs similarity index 87% rename from runtime/common/src/weights/pallet_preimage.rs rename to runtime/g1/src/weights/pallet_preimage.rs index 3b548577f..77782a0af 100644 --- a/runtime/common/src/weights/pallet_preimage.rs +++ b/runtime/g1/src/weights/pallet_preimage.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_preimage` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -58,11 +58,11 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `42` // Estimated: `3548` - // Minimum execution time: 10_457_000 picoseconds. - Weight::from_parts(11_037_000, 0) + // Minimum execution time: 11_008_000 picoseconds. + Weight::from_parts(11_408_000, 0) .saturating_add(Weight::from_parts(0, 3548)) - // Standard Error: 1 - .saturating_add(Weight::from_parts(1_322, 0).saturating_mul(s.into())) + // Standard Error: 2 + .saturating_add(Weight::from_parts(1_407, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -77,11 +77,11 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `106` // Estimated: `3548` - // Minimum execution time: 12_718_000 picoseconds. - Weight::from_parts(13_125_000, 0) + // Minimum execution time: 13_031_000 picoseconds. + Weight::from_parts(13_374_000, 0) .saturating_add(Weight::from_parts(0, 3548)) - // Standard Error: 1 - .saturating_add(Weight::from_parts(1_317, 0).saturating_mul(s.into())) + // Standard Error: 3 + .saturating_add(Weight::from_parts(1_420, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -96,11 +96,11 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `106` // Estimated: `3548` - // Minimum execution time: 11_424_000 picoseconds. - Weight::from_parts(11_595_000, 0) + // Minimum execution time: 11_900_000 picoseconds. + Weight::from_parts(12_300_000, 0) .saturating_add(Weight::from_parts(0, 3548)) - // Standard Error: 1 - .saturating_add(Weight::from_parts(1_402, 0).saturating_mul(s.into())) + // Standard Error: 2 + .saturating_add(Weight::from_parts(1_510, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -114,8 +114,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `172` // Estimated: `3548` - // Minimum execution time: 21_436_000 picoseconds. - Weight::from_parts(23_457_000, 0) + // Minimum execution time: 25_482_000 picoseconds. + Weight::from_parts(28_824_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) @@ -130,8 +130,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `144` // Estimated: `3548` - // Minimum execution time: 22_815_000 picoseconds. - Weight::from_parts(25_024_000, 0) + // Minimum execution time: 24_411_000 picoseconds. + Weight::from_parts(28_027_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) @@ -144,8 +144,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `172` // Estimated: `3548` - // Minimum execution time: 20_222_000 picoseconds. - Weight::from_parts(22_476_000, 0) + // Minimum execution time: 22_034_000 picoseconds. + Weight::from_parts(23_648_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -158,8 +158,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `144` // Estimated: `3548` - // Minimum execution time: 12_916_000 picoseconds. - Weight::from_parts(14_899_000, 0) + // Minimum execution time: 13_772_000 picoseconds. + Weight::from_parts(18_780_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -172,8 +172,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `42` // Estimated: `3548` - // Minimum execution time: 9_655_000 picoseconds. - Weight::from_parts(10_358_000, 0) + // Minimum execution time: 11_427_000 picoseconds. + Weight::from_parts(14_282_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -186,8 +186,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `106` // Estimated: `3548` - // Minimum execution time: 6_793_000 picoseconds. - Weight::from_parts(7_733_000, 0) + // Minimum execution time: 7_629_000 picoseconds. + Weight::from_parts(9_068_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -202,8 +202,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `144` // Estimated: `3548` - // Minimum execution time: 20_945_000 picoseconds. - Weight::from_parts(22_280_000, 0) + // Minimum execution time: 22_200_000 picoseconds. + Weight::from_parts(26_854_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) @@ -216,8 +216,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `106` // Estimated: `3548` - // Minimum execution time: 6_661_000 picoseconds. - Weight::from_parts(7_650_000, 0) + // Minimum execution time: 7_152_000 picoseconds. + Weight::from_parts(8_912_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -230,8 +230,8 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `106` // Estimated: `3548` - // Minimum execution time: 6_583_000 picoseconds. - Weight::from_parts(7_274_000, 0) + // Minimum execution time: 7_553_000 picoseconds. + Weight::from_parts(9_237_000, 0) .saturating_add(Weight::from_parts(0, 3548)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -247,11 +247,11 @@ impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0 + n * (179 ±0)` // Estimated: `990 + n * (2568 ±0)` - // Minimum execution time: 16_145_000 picoseconds. - Weight::from_parts(16_720_000, 0) + // Minimum execution time: 16_759_000 picoseconds. + Weight::from_parts(17_317_000, 0) .saturating_add(Weight::from_parts(0, 990)) - // Standard Error: 17_095 - .saturating_add(Weight::from_parts(13_483_623, 0).saturating_mul(n.into())) + // Standard Error: 26_668 + .saturating_add(Weight::from_parts(14_468_206, 0).saturating_mul(n.into())) .saturating_add(T::DbWeight::get().reads((2_u64).saturating_mul(n.into()))) .saturating_add(T::DbWeight::get().writes((3_u64).saturating_mul(n.into()))) .saturating_add(Weight::from_parts(0, 2568).saturating_mul(n.into())) diff --git a/runtime/common/src/weights/pallet_provide_randomness.rs b/runtime/g1/src/weights/pallet_provide_randomness.rs similarity index 92% rename from runtime/common/src/weights/pallet_provide_randomness.rs rename to runtime/g1/src/weights/pallet_provide_randomness.rs index 70522dc8c..bb9f08c17 100644 --- a/runtime/common/src/weights/pallet_provide_randomness.rs +++ b/runtime/g1/src/weights/pallet_provide_randomness.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_provide_randomness` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -65,8 +65,8 @@ impl<T: frame_system::Config> pallet_provide_randomness::WeightInfo for WeightIn // Proof Size summary in bytes: // Measured: `298` // Estimated: `3763` - // Minimum execution time: 31_329_000 picoseconds. - Weight::from_parts(32_906_000, 0) + // Minimum execution time: 40_216_000 picoseconds. + Weight::from_parts(41_444_000, 0) .saturating_add(Weight::from_parts(0, 3763)) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(5)) @@ -86,11 +86,11 @@ impl<T: frame_system::Config> pallet_provide_randomness::WeightInfo for WeightIn // Proof Size summary in bytes: // Measured: `341 + i * (59 ±0)` // Estimated: `1827 + i * (2535 ±0)` - // Minimum execution time: 14_478_000 picoseconds. - Weight::from_parts(13_079_242, 0) + // Minimum execution time: 15_548_000 picoseconds. + Weight::from_parts(15_098_900, 0) .saturating_add(Weight::from_parts(0, 1827)) - // Standard Error: 3_642 - .saturating_add(Weight::from_parts(4_859_336, 0).saturating_mul(i.into())) + // Standard Error: 4_879 + .saturating_add(Weight::from_parts(4_980_390, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) .saturating_add(T::DbWeight::get().writes(3)) @@ -118,11 +118,11 @@ impl<T: frame_system::Config> pallet_provide_randomness::WeightInfo for WeightIn // Proof Size summary in bytes: // Measured: `351 + i * (59 ±0)` // Estimated: `3817 + i * (2535 ±0)` - // Minimum execution time: 16_054_000 picoseconds. - Weight::from_parts(14_770_472, 0) + // Minimum execution time: 16_544_000 picoseconds. + Weight::from_parts(14_137_562, 0) .saturating_add(Weight::from_parts(0, 3817)) - // Standard Error: 4_259 - .saturating_add(Weight::from_parts(5_131_103, 0).saturating_mul(i.into())) + // Standard Error: 5_845 + .saturating_add(Weight::from_parts(5_368_289, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) .saturating_add(T::DbWeight::get().writes(3)) diff --git a/runtime/g1/src/weights/pallet_proxy.rs b/runtime/g1/src/weights/pallet_proxy.rs new file mode 100644 index 000000000..f05c14cf9 --- /dev/null +++ b/runtime/g1/src/weights/pallet_proxy.rs @@ -0,0 +1,221 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_proxy` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/g1/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_proxy`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { + /// Storage: `Proxy::Proxies` (r:1 w:0) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn proxy(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 11_448_000 picoseconds. + Weight::from_parts(12_510_240, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 1_389 + .saturating_add(Weight::from_parts(29_999, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:0) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn proxy_announced(a: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `399 + a * (68 ±0) + p * (37 ±0)` + // Estimated: `5690` + // Minimum execution time: 28_067_000 picoseconds. + Weight::from_parts(27_820_834, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 2_054 + .saturating_add(Weight::from_parts(166_105, 0).saturating_mul(a.into())) + // Standard Error: 2_122 + .saturating_add(Weight::from_parts(49_724, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn remove_announcement(a: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `322 + a * (68 ±0)` + // Estimated: `5690` + // Minimum execution time: 18_890_000 picoseconds. + Weight::from_parts(19_804_593, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 1_605 + .saturating_add(Weight::from_parts(136_751, 0).saturating_mul(a.into())) + // Standard Error: 1_659 + .saturating_add(Weight::from_parts(5_598, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn reject_announcement(a: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `322 + a * (68 ±0)` + // Estimated: `5690` + // Minimum execution time: 18_762_000 picoseconds. + Weight::from_parts(19_060_260, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 2_274 + .saturating_add(Weight::from_parts(157_951, 0).saturating_mul(a.into())) + // Standard Error: 2_349 + .saturating_add(Weight::from_parts(16_694, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Proxies` (r:1 w:0) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn announce(a: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `331 + a * (68 ±0) + p * (37 ±0)` + // Estimated: `5690` + // Minimum execution time: 25_291_000 picoseconds. + Weight::from_parts(25_192_634, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 2_007 + .saturating_add(Weight::from_parts(144_625, 0).saturating_mul(a.into())) + // Standard Error: 2_074 + .saturating_add(Weight::from_parts(43_235, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn add_proxy(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 17_554_000 picoseconds. + Weight::from_parts(18_598_066, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 1_424 + .saturating_add(Weight::from_parts(48_257, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn remove_proxy(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 17_845_000 picoseconds. + Weight::from_parts(19_286_212, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 2_036 + .saturating_add(Weight::from_parts(30_533, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn remove_proxies(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 16_828_000 picoseconds. + Weight::from_parts(18_013_971, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 9_417 + .saturating_add(Weight::from_parts(68_134, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn create_pure(_p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `177` + // Estimated: `4698` + // Minimum execution time: 18_561_000 picoseconds. + Weight::from_parts(20_461_631, 0) + .saturating_add(Weight::from_parts(0, 4698)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[0, 30]`. + fn kill_pure(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `194 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 17_435_000 picoseconds. + Weight::from_parts(18_836_380, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 1_597 + .saturating_add(Weight::from_parts(24_718, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/common/src/weights/pallet_quota.rs b/runtime/g1/src/weights/pallet_quota.rs similarity index 100% rename from runtime/common/src/weights/pallet_quota.rs rename to runtime/g1/src/weights/pallet_quota.rs diff --git a/runtime/common/src/weights/pallet_scheduler.rs b/runtime/g1/src/weights/pallet_scheduler.rs similarity index 82% rename from runtime/common/src/weights/pallet_scheduler.rs rename to runtime/g1/src/weights/pallet_scheduler.rs index 59e5bbdcb..142adc3d4 100644 --- a/runtime/common/src/weights/pallet_scheduler.rs +++ b/runtime/g1/src/weights/pallet_scheduler.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_scheduler` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -53,8 +53,8 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `30` // Estimated: `1489` - // Minimum execution time: 2_247_000 picoseconds. - Weight::from_parts(2_368_000, 0) + // Minimum execution time: 2_250_000 picoseconds. + Weight::from_parts(2_406_000, 0) .saturating_add(Weight::from_parts(0, 1489)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -66,11 +66,11 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `77 + s * (177 ±0)` // Estimated: `13928` - // Minimum execution time: 2_623_000 picoseconds. - Weight::from_parts(5_323_281, 0) + // Minimum execution time: 2_640_000 picoseconds. + Weight::from_parts(5_477_847, 0) .saturating_add(Weight::from_parts(0, 13928)) - // Standard Error: 1_521 - .saturating_add(Weight::from_parts(261_061, 0).saturating_mul(s.into())) + // Standard Error: 1_527 + .saturating_add(Weight::from_parts(318_609, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -78,8 +78,8 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_057_000 picoseconds. - Weight::from_parts(2_231_000, 0) + // Minimum execution time: 2_257_000 picoseconds. + Weight::from_parts(2_461_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// Storage: `Preimage::PreimageFor` (r:1 w:1) @@ -93,11 +93,11 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `179 + s * (1 ±0)` // Estimated: `3644 + s * (1 ±0)` - // Minimum execution time: 13_676_000 picoseconds. - Weight::from_parts(13_904_000, 0) + // Minimum execution time: 14_666_000 picoseconds. + Weight::from_parts(15_128_000, 0) .saturating_add(Weight::from_parts(0, 3644)) - // Standard Error: 2 - .saturating_add(Weight::from_parts(864, 0).saturating_mul(s.into())) + // Standard Error: 4 + .saturating_add(Weight::from_parts(952, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(2)) .saturating_add(Weight::from_parts(0, 1).saturating_mul(s.into())) @@ -108,8 +108,8 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_190_000 picoseconds. - Weight::from_parts(3_399_000, 0) + // Minimum execution time: 3_540_000 picoseconds. + Weight::from_parts(3_696_000, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -117,24 +117,24 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_037_000 picoseconds. - Weight::from_parts(2_185_000, 0) + // Minimum execution time: 2_210_000 picoseconds. + Weight::from_parts(2_450_000, 0) .saturating_add(Weight::from_parts(0, 0)) } fn execute_dispatch_signed() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 1_451_000 picoseconds. - Weight::from_parts(1_527_000, 0) + // Minimum execution time: 1_580_000 picoseconds. + Weight::from_parts(1_713_000, 0) .saturating_add(Weight::from_parts(0, 0)) } fn execute_dispatch_unsigned() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 1_380_000 picoseconds. - Weight::from_parts(1_528_000, 0) + // Minimum execution time: 1_510_000 picoseconds. + Weight::from_parts(1_622_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// Storage: `Scheduler::Agenda` (r:1 w:1) @@ -144,11 +144,11 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `77 + s * (177 ±0)` // Estimated: `13928` - // Minimum execution time: 7_345_000 picoseconds. - Weight::from_parts(10_149_347, 0) + // Minimum execution time: 7_270_000 picoseconds. + Weight::from_parts(10_459_858, 0) .saturating_add(Weight::from_parts(0, 13928)) - // Standard Error: 1_470 - .saturating_add(Weight::from_parts(271_802, 0).saturating_mul(s.into())) + // Standard Error: 1_717 + .saturating_add(Weight::from_parts(317_296, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -163,11 +163,11 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `77 + s * (177 ±0)` // Estimated: `13928` - // Minimum execution time: 11_065_000 picoseconds. - Weight::from_parts(12_201_393, 0) + // Minimum execution time: 12_317_000 picoseconds. + Weight::from_parts(12_424_622, 0) .saturating_add(Weight::from_parts(0, 13928)) - // Standard Error: 1_220 - .saturating_add(Weight::from_parts(421_428, 0).saturating_mul(s.into())) + // Standard Error: 1_699 + .saturating_add(Weight::from_parts(512_785, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -180,11 +180,11 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `254 + s * (185 ±0)` // Estimated: `13928` - // Minimum execution time: 9_738_000 picoseconds. - Weight::from_parts(13_973_802, 0) + // Minimum execution time: 10_259_000 picoseconds. + Weight::from_parts(14_741_699, 0) .saturating_add(Weight::from_parts(0, 13928)) - // Standard Error: 3_249 - .saturating_add(Weight::from_parts(309_352, 0).saturating_mul(s.into())) + // Standard Error: 4_845 + .saturating_add(Weight::from_parts(361_292, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -199,11 +199,11 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `280 + s * (185 ±0)` // Estimated: `13928` - // Minimum execution time: 13_718_000 picoseconds. - Weight::from_parts(15_856_702, 0) + // Minimum execution time: 14_134_000 picoseconds. + Weight::from_parts(17_187_706, 0) .saturating_add(Weight::from_parts(0, 13928)) - // Standard Error: 2_313 - .saturating_add(Weight::from_parts(428_752, 0).saturating_mul(s.into())) + // Standard Error: 10_474 + .saturating_add(Weight::from_parts(500_931, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -216,11 +216,11 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `117` // Estimated: `13928` - // Minimum execution time: 6_953_000 picoseconds. - Weight::from_parts(7_530_478, 0) + // Minimum execution time: 7_036_000 picoseconds. + Weight::from_parts(8_028_535, 0) .saturating_add(Weight::from_parts(0, 13928)) - // Standard Error: 563 - .saturating_add(Weight::from_parts(20_586, 0).saturating_mul(s.into())) + // Standard Error: 1_057 + .saturating_add(Weight::from_parts(22_882, 0).saturating_mul(s.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -232,8 +232,8 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `8927` // Estimated: `13928` - // Minimum execution time: 18_248_000 picoseconds. - Weight::from_parts(18_882_000, 0) + // Minimum execution time: 20_972_000 picoseconds. + Weight::from_parts(21_963_000, 0) .saturating_add(Weight::from_parts(0, 13928)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -248,8 +248,8 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `9605` // Estimated: `13928` - // Minimum execution time: 23_731_000 picoseconds. - Weight::from_parts(24_949_000, 0) + // Minimum execution time: 25_955_000 picoseconds. + Weight::from_parts(27_095_000, 0) .saturating_add(Weight::from_parts(0, 13928)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -262,8 +262,8 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `8939` // Estimated: `13928` - // Minimum execution time: 18_270_000 picoseconds. - Weight::from_parts(18_997_000, 0) + // Minimum execution time: 19_940_000 picoseconds. + Weight::from_parts(20_696_000, 0) .saturating_add(Weight::from_parts(0, 13928)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -278,8 +278,8 @@ impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `9617` // Estimated: `13928` - // Minimum execution time: 23_185_000 picoseconds. - Weight::from_parts(23_971_000, 0) + // Minimum execution time: 25_698_000 picoseconds. + Weight::from_parts(26_496_000, 0) .saturating_add(Weight::from_parts(0, 13928)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) diff --git a/runtime/common/src/weights/pallet_session.rs b/runtime/g1/src/weights/pallet_session.rs similarity index 83% rename from runtime/common/src/weights/pallet_session.rs rename to runtime/g1/src/weights/pallet_session.rs index 5bbff4c24..84229096f 100644 --- a/runtime/common/src/weights/pallet_session.rs +++ b/runtime/g1/src/weights/pallet_session.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_session` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -53,11 +53,11 @@ impl<T: frame_system::Config> pallet_session::WeightInfo for WeightInfo<T> { /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) fn set_keys() -> Weight { // Proof Size summary in bytes: - // Measured: `723` - // Estimated: `11613` - // Minimum execution time: 22_533_000 picoseconds. - Weight::from_parts(23_536_000, 0) - .saturating_add(Weight::from_parts(0, 11613)) + // Measured: `810` + // Estimated: `11700` + // Minimum execution time: 23_192_000 picoseconds. + Weight::from_parts(25_270_000, 0) + .saturating_add(Weight::from_parts(0, 11700)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -67,11 +67,11 @@ impl<T: frame_system::Config> pallet_session::WeightInfo for WeightInfo<T> { /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) fn purge_keys() -> Weight { // Proof Size summary in bytes: - // Measured: `412` - // Estimated: `3877` - // Minimum execution time: 13_783_000 picoseconds. - Weight::from_parts(14_376_000, 0) - .saturating_add(Weight::from_parts(0, 3877)) + // Measured: `477` + // Estimated: `3942` + // Minimum execution time: 14_237_000 picoseconds. + Weight::from_parts(14_927_000, 0) + .saturating_add(Weight::from_parts(0, 3942)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(5)) } diff --git a/runtime/g1/src/weights/pallet_smith_members.rs b/runtime/g1/src/weights/pallet_smith_members.rs new file mode 100644 index 000000000..9a0e0a48d --- /dev/null +++ b/runtime/g1/src/weights/pallet_smith_members.rs @@ -0,0 +1,139 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_smith_members` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/g1/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_smith_members`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_smith_members::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:2 w:1) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::CurrentSession` (r:1 w:0) + /// Proof: `SmithMembers::CurrentSession` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::ExpiresOn` (r:1 w:1) + /// Proof: `SmithMembers::ExpiresOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn invite_smith() -> Weight { + // Proof Size summary in bytes: + // Measured: `801` + // Estimated: `6741` + // Minimum execution time: 25_020_000 picoseconds. + Weight::from_parts(25_887_000, 0) + .saturating_add(Weight::from_parts(0, 6741)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:1) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn accept_invitation() -> Weight { + // Proof Size summary in bytes: + // Measured: `566` + // Estimated: `4031` + // Minimum execution time: 14_245_000 picoseconds. + Weight::from_parts(14_993_000, 0) + .saturating_add(Weight::from_parts(0, 4031)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:2 w:2) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::CurrentSession` (r:1 w:0) + /// Proof: `SmithMembers::CurrentSession` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::ExpiresOn` (r:1 w:1) + /// Proof: `SmithMembers::ExpiresOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn certify_smith() -> Weight { + // Proof Size summary in bytes: + // Measured: `611` + // Estimated: `6551` + // Minimum execution time: 22_113_000 picoseconds. + Weight::from_parts(23_004_000, 0) + .saturating_add(Weight::from_parts(0, 6551)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn on_removed_wot_member() -> Weight { + // Proof Size summary in bytes: + // Measured: `1204` + // Estimated: `14569` + // Minimum execution time: 58_187_000 picoseconds. + Weight::from_parts(61_728_000, 0) + .saturating_add(Weight::from_parts(0, 14569)) + .saturating_add(T::DbWeight::get().reads(11)) + .saturating_add(T::DbWeight::get().writes(15)) + } + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn on_removed_wot_member_empty() -> Weight { + // Proof Size summary in bytes: + // Measured: `253` + // Estimated: `3718` + // Minimum execution time: 2_935_000 picoseconds. + Weight::from_parts(3_179_000, 0) + .saturating_add(Weight::from_parts(0, 3718)) + .saturating_add(T::DbWeight::get().reads(1)) + } +} diff --git a/runtime/common/src/weights/pallet_sudo.rs b/runtime/g1/src/weights/pallet_sudo.rs similarity index 87% rename from runtime/common/src/weights/pallet_sudo.rs rename to runtime/g1/src/weights/pallet_sudo.rs index c51df6c48..ff7d501a4 100644 --- a/runtime/common/src/weights/pallet_sudo.rs +++ b/runtime/g1/src/weights/pallet_sudo.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_sudo` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -53,8 +53,8 @@ impl<T: frame_system::Config> pallet_sudo::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `165` // Estimated: `1517` - // Minimum execution time: 6_589_000 picoseconds. - Weight::from_parts(6_985_000, 0) + // Minimum execution time: 6_911_000 picoseconds. + Weight::from_parts(7_327_000, 0) .saturating_add(Weight::from_parts(0, 1517)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -65,8 +65,8 @@ impl<T: frame_system::Config> pallet_sudo::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `165` // Estimated: `1517` - // Minimum execution time: 6_878_000 picoseconds. - Weight::from_parts(7_358_000, 0) + // Minimum execution time: 7_320_000 picoseconds. + Weight::from_parts(7_861_000, 0) .saturating_add(Weight::from_parts(0, 1517)) .saturating_add(T::DbWeight::get().reads(1)) } @@ -76,8 +76,8 @@ impl<T: frame_system::Config> pallet_sudo::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `165` // Estimated: `1517` - // Minimum execution time: 6_934_000 picoseconds. - Weight::from_parts(7_434_000, 0) + // Minimum execution time: 7_250_000 picoseconds. + Weight::from_parts(7_747_000, 0) .saturating_add(Weight::from_parts(0, 1517)) .saturating_add(T::DbWeight::get().reads(1)) } @@ -87,8 +87,8 @@ impl<T: frame_system::Config> pallet_sudo::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `165` // Estimated: `1517` - // Minimum execution time: 6_001_000 picoseconds. - Weight::from_parts(6_397_000, 0) + // Minimum execution time: 6_141_000 picoseconds. + Weight::from_parts(6_562_000, 0) .saturating_add(Weight::from_parts(0, 1517)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) diff --git a/runtime/g1/src/weights/pallet_timestamp.rs b/runtime/g1/src/weights/pallet_timestamp.rs new file mode 100644 index 000000000..c57f38991 --- /dev/null +++ b/runtime/g1/src/weights/pallet_timestamp.rs @@ -0,0 +1,74 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_timestamp` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/g1/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_timestamp`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_timestamp::WeightInfo for WeightInfo<T> { + /// Storage: `Timestamp::Now` (r:1 w:1) + /// Proof: `Timestamp::Now` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `Babe::CurrentSlot` (r:1 w:0) + /// Proof: `Babe::CurrentSlot` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `UniversalDividend::NextUd` (r:1 w:1) + /// Proof: `UniversalDividend::NextUd` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + fn set() -> Weight { + // Proof Size summary in bytes: + // Measured: `268` + // Estimated: `1493` + // Minimum execution time: 9_301_000 picoseconds. + Weight::from_parts(13_457_000, 0) + .saturating_add(Weight::from_parts(0, 1493)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + fn on_finalize() -> Weight { + // Proof Size summary in bytes: + // Measured: `57` + // Estimated: `0` + // Minimum execution time: 2_591_000 picoseconds. + Weight::from_parts(2_764_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } +} diff --git a/runtime/common/src/weights/pallet_treasury.rs b/runtime/g1/src/weights/pallet_treasury.rs similarity index 86% rename from runtime/common/src/weights/pallet_treasury.rs rename to runtime/g1/src/weights/pallet_treasury.rs index 5bfd1059f..09324d926 100644 --- a/runtime/common/src/weights/pallet_treasury.rs +++ b/runtime/g1/src/weights/pallet_treasury.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_treasury` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -63,8 +63,8 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `67` // Estimated: `1489` - // Minimum execution time: 16_895_000 picoseconds. - Weight::from_parts(17_676_000, 0) + // Minimum execution time: 16_698_000 picoseconds. + Weight::from_parts(17_539_000, 0) .saturating_add(Weight::from_parts(0, 1489)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(2)) @@ -77,8 +77,8 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `272` // Estimated: `6126` - // Minimum execution time: 27_835_000 picoseconds. - Weight::from_parts(28_815_000, 0) + // Minimum execution time: 27_671_000 picoseconds. + Weight::from_parts(28_330_000, 0) .saturating_add(Weight::from_parts(0, 6126)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) @@ -92,11 +92,11 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `433 + p * (8 ±0)` // Estimated: `3557` - // Minimum execution time: 6_110_000 picoseconds. - Weight::from_parts(9_332_735, 0) + // Minimum execution time: 5_969_000 picoseconds. + Weight::from_parts(9_883_491, 0) .saturating_add(Weight::from_parts(0, 3557)) - // Standard Error: 1_142 - .saturating_add(Weight::from_parts(49_768, 0).saturating_mul(p.into())) + // Standard Error: 1_311 + .saturating_add(Weight::from_parts(49_267, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -106,8 +106,8 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `90` // Estimated: `1887` - // Minimum execution time: 4_290_000 picoseconds. - Weight::from_parts(4_657_000, 0) + // Minimum execution time: 4_413_000 picoseconds. + Weight::from_parts(4_673_000, 0) .saturating_add(Weight::from_parts(0, 1887)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -123,13 +123,13 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { /// The range of component `p` is `[0, 99]`. fn on_initialize_proposals(p: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `0 + p * (195 ±0)` + // Measured: `24 + p * (196 ±0)` // Estimated: `3558 + p * (5136 ±0)` - // Minimum execution time: 11_965_000 picoseconds. - Weight::from_parts(24_309_981, 0) + // Minimum execution time: 12_862_000 picoseconds. + Weight::from_parts(15_920_154, 0) .saturating_add(Weight::from_parts(0, 3558)) - // Standard Error: 14_472 - .saturating_add(Weight::from_parts(23_310_107, 0).saturating_mul(p.into())) + // Standard Error: 50_173 + .saturating_add(Weight::from_parts(24_811_424, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().reads((3_u64).saturating_mul(p.into()))) .saturating_add(T::DbWeight::get().writes(3)) @@ -152,8 +152,8 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `179` // Estimated: `6126` - // Minimum execution time: 39_319_000 picoseconds. - Weight::from_parts(40_632_000, 0) + // Minimum execution time: 39_523_000 picoseconds. + Weight::from_parts(41_042_000, 0) .saturating_add(Weight::from_parts(0, 6126)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) @@ -164,8 +164,8 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `116` // Estimated: `3526` - // Minimum execution time: 8_711_000 picoseconds. - Weight::from_parts(9_202_000, 0) + // Minimum execution time: 8_828_000 picoseconds. + Weight::from_parts(9_194_000, 0) .saturating_add(Weight::from_parts(0, 3526)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -176,8 +176,8 @@ impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `116` // Estimated: `3526` - // Minimum execution time: 7_887_000 picoseconds. - Weight::from_parts(8_349_000, 0) + // Minimum execution time: 7_593_000 picoseconds. + Weight::from_parts(8_178_000, 0) .saturating_add(Weight::from_parts(0, 3526)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) diff --git a/runtime/common/src/weights/pallet_universal_dividend.rs b/runtime/g1/src/weights/pallet_universal_dividend.rs similarity index 86% rename from runtime/common/src/weights/pallet_universal_dividend.rs rename to runtime/g1/src/weights/pallet_universal_dividend.rs index 778f298d2..ac1a8eb6b 100644 --- a/runtime/common/src/weights/pallet_universal_dividend.rs +++ b/runtime/g1/src/weights/pallet_universal_dividend.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_universal_dividend` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -60,13 +60,13 @@ impl<T: frame_system::Config> pallet_universal_dividend::WeightInfo for WeightIn /// The range of component `i` is `[1, 160]`. fn claim_uds(i: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `643` - // Estimated: `4108` - // Minimum execution time: 24_610_000 picoseconds. - Weight::from_parts(26_539_017, 0) - .saturating_add(Weight::from_parts(0, 4108)) - // Standard Error: 382 - .saturating_add(Weight::from_parts(234, 0).saturating_mul(i.into())) + // Measured: `676` + // Estimated: `4141` + // Minimum execution time: 29_494_000 picoseconds. + Weight::from_parts(31_713_448, 0) + .saturating_add(Weight::from_parts(0, 4141)) + // Standard Error: 1_246 + .saturating_add(Weight::from_parts(1_971, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -78,8 +78,8 @@ impl<T: frame_system::Config> pallet_universal_dividend::WeightInfo for WeightIn // Proof Size summary in bytes: // Measured: `156` // Estimated: `6126` - // Minimum execution time: 45_470_000 picoseconds. - Weight::from_parts(46_660_000, 0) + // Minimum execution time: 51_596_000 picoseconds. + Weight::from_parts(52_757_000, 0) .saturating_add(Weight::from_parts(0, 6126)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(2)) @@ -92,8 +92,8 @@ impl<T: frame_system::Config> pallet_universal_dividend::WeightInfo for WeightIn // Proof Size summary in bytes: // Measured: `93` // Estimated: `3558` - // Minimum execution time: 30_105_000 picoseconds. - Weight::from_parts(31_315_000, 0) + // Minimum execution time: 31_777_000 picoseconds. + Weight::from_parts(32_527_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -109,11 +109,11 @@ impl<T: frame_system::Config> pallet_universal_dividend::WeightInfo for WeightIn // Proof Size summary in bytes: // Measured: `181` // Estimated: `3558` - // Minimum execution time: 12_722_000 picoseconds. - Weight::from_parts(14_020_745, 0) + // Minimum execution time: 17_140_000 picoseconds. + Weight::from_parts(18_224_900, 0) .saturating_add(Weight::from_parts(0, 3558)) - // Standard Error: 216 - .saturating_add(Weight::from_parts(1_349, 0).saturating_mul(i.into())) + // Standard Error: 530 + .saturating_add(Weight::from_parts(2_330, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(1)) } diff --git a/runtime/common/src/weights/pallet_upgrade_origin.rs b/runtime/g1/src/weights/pallet_upgrade_origin.rs similarity index 90% rename from runtime/common/src/weights/pallet_upgrade_origin.rs rename to runtime/g1/src/weights/pallet_upgrade_origin.rs index 09e11404c..f76827762 100644 --- a/runtime/common/src/weights/pallet_upgrade_origin.rs +++ b/runtime/g1/src/weights/pallet_upgrade_origin.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_upgrade_origin` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -51,8 +51,8 @@ impl<T: frame_system::Config> pallet_upgrade_origin::WeightInfo for WeightInfo<T // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_208_000 picoseconds. - Weight::from_parts(4_574_000, 0) + // Minimum execution time: 4_586_000 picoseconds. + Weight::from_parts(4_902_000, 0) .saturating_add(Weight::from_parts(0, 0)) } } diff --git a/runtime/common/src/weights/pallet_utility.rs b/runtime/g1/src/weights/pallet_utility.rs similarity index 75% rename from runtime/common/src/weights/pallet_utility.rs rename to runtime/g1/src/weights/pallet_utility.rs index 3e4b97c81..27a567b27 100644 --- a/runtime/common/src/weights/pallet_utility.rs +++ b/runtime/g1/src/weights/pallet_utility.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_utility` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/g1/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -52,18 +52,18 @@ impl<T: frame_system::Config> pallet_utility::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_225_000 picoseconds. - Weight::from_parts(6_768_835, 0) + // Minimum execution time: 3_470_000 picoseconds. + Weight::from_parts(18_585_545, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 2_935 - .saturating_add(Weight::from_parts(2_000_415, 0).saturating_mul(c.into())) + // Standard Error: 5_190 + .saturating_add(Weight::from_parts(2_137_740, 0).saturating_mul(c.into())) } fn as_derivative() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 2_752_000 picoseconds. - Weight::from_parts(2_997_000, 0) + // Minimum execution time: 3_074_000 picoseconds. + Weight::from_parts(3_246_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// The range of component `c` is `[0, 1000]`. @@ -71,18 +71,18 @@ impl<T: frame_system::Config> pallet_utility::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_150_000 picoseconds. - Weight::from_parts(6_300_063, 0) + // Minimum execution time: 3_460_000 picoseconds. + Weight::from_parts(4_102_015, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 1_366 - .saturating_add(Weight::from_parts(2_184_259, 0).saturating_mul(c.into())) + // Standard Error: 6_684 + .saturating_add(Weight::from_parts(2_329_214, 0).saturating_mul(c.into())) } fn dispatch_as() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_387_000 picoseconds. - Weight::from_parts(4_735_000, 0) + // Minimum execution time: 4_600_000 picoseconds. + Weight::from_parts(5_054_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// The range of component `c` is `[0, 1000]`. @@ -90,10 +90,10 @@ impl<T: frame_system::Config> pallet_utility::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_227_000 picoseconds. - Weight::from_parts(8_110_481, 0) + // Minimum execution time: 3_528_000 picoseconds. + Weight::from_parts(13_930_642, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 1_389 - .saturating_add(Weight::from_parts(2_001_592, 0).saturating_mul(c.into())) + // Standard Error: 2_091 + .saturating_add(Weight::from_parts(2_193_678, 0).saturating_mul(c.into())) } } diff --git a/runtime/g1/src/weights/paritydb_weights.rs b/runtime/g1/src/weights/paritydb_weights.rs new file mode 100644 index 000000000..b6ea2dae5 --- /dev/null +++ b/runtime/g1/src/weights/paritydb_weights.rs @@ -0,0 +1,94 @@ + +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21 (Y/M/D) +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! +//! DATABASE: `ParityDb`, RUNTIME: `Ğ1 Local Testnet` +//! BLOCK-NUM: `BlockId::Number(0)` +//! SKIP-WRITE: `false`, SKIP-READ: `false`, WARMUPS: `1` +//! STATE-VERSION: `V1`, STATE-CACHE-SIZE: `` +//! WEIGHT-PATH: `./runtime/g1/src/weights/` +//! METRIC: `Average`, WEIGHT-MUL: `2.0`, WEIGHT-ADD: `0` + +// Executed Command: +// target/release/duniter +// benchmark +// storage +// --chain=dev +// --mul=2 +// --weight-path=./runtime/g1/src/weights/ +// --state-version=1 + +/// Storage DB weights for the `Ğ1 Local Testnet` runtime and `ParityDb`. +pub mod constants { + use frame_support::weights::constants; + use sp_core::parameter_types; + use sp_weights::RuntimeDbWeight; + + parameter_types! { + /// `ParityDB` can be enabled with a feature flag, but is still experimental. These weights + /// are available for brave runtime engineers who may want to try this out as default. + pub const ParityDbWeight: RuntimeDbWeight = RuntimeDbWeight { + /// Time to read one storage item. + /// Calculated by multiplying the *Average* of all values with `2.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 837, 1_153_996 + /// Average: 9_224 + /// Median: 1_801 + /// Std-Dev: 91659.68 + /// + /// Percentiles nanoseconds: + /// 99th: 11_191 + /// 95th: 3_156 + /// 75th: 2_083 + read: 18_448 * constants::WEIGHT_REF_TIME_PER_NANOS, + + /// Time to write one storage item. + /// Calculated by multiplying the *Average* of all values with `2.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 3_895, 7_498_039 + /// Average: 61_102 + /// Median: 12_538 + /// Std-Dev: 595462.2 + /// + /// Percentiles nanoseconds: + /// 99th: 51_618 + /// 95th: 24_955 + /// 75th: 16_182 + write: 122_204 * constants::WEIGHT_REF_TIME_PER_NANOS, + }; + } + + #[cfg(test)] + mod test_db_weights { + use super::constants::ParityDbWeight as W; + use sp_weights::constants; + + /// Checks that all weights exist and have sane values. + // NOTE: If this test fails but you are sure that the generated values are fine, + // you can delete it. + #[test] + fn bound() { + // At least 1 µs. + assert!( + W::get().reads(1).ref_time() >= constants::WEIGHT_REF_TIME_PER_MICROS, + "Read weight should be at least 1 µs." + ); + assert!( + W::get().writes(1).ref_time() >= constants::WEIGHT_REF_TIME_PER_MICROS, + "Write weight should be at least 1 µs." + ); + // At most 1 ms. + assert!( + W::get().reads(1).ref_time() <= constants::WEIGHT_REF_TIME_PER_MILLIS, + "Read weight should be at most 1 ms." + ); + assert!( + W::get().writes(1).ref_time() <= constants::WEIGHT_REF_TIME_PER_MILLIS, + "Write weight should be at most 1 ms." + ); + } + } +} diff --git a/runtime/gdev/src/lib.rs b/runtime/gdev/src/lib.rs index e7bd13e0b..bfd9a714a 100644 --- a/runtime/gdev/src/lib.rs +++ b/runtime/gdev/src/lib.rs @@ -27,6 +27,7 @@ include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); extern crate frame_benchmarking; pub mod parameters; +pub mod weights; pub use self::parameters::*; use common_runtime::IdtyNameValidatorImpl; @@ -67,6 +68,7 @@ use sp_std::prelude::*; #[cfg(feature = "std")] use sp_version::NativeVersion; use sp_version::RuntimeVersion; +pub use weights::paritydb_weights::constants::ParityDbWeight as DbWeight; // A few exports that help ease life for downstream crates. use frame_support::instances::Instance2; diff --git a/runtime/gdev/src/weights.rs b/runtime/gdev/src/weights.rs new file mode 100644 index 000000000..1bf51bdbb --- /dev/null +++ b/runtime/gdev/src/weights.rs @@ -0,0 +1,52 @@ +// Copyright 2021 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(clippy::unnecessary_cast)] +#![allow(unused_doc_comments)] + +pub mod block_weights; +pub mod extrinsic_weights; +pub mod frame_system; +pub mod pallet_babe; +pub mod pallet_balances; +pub mod pallet_collective; +pub mod pallet_distance; +pub mod pallet_grandpa; +pub mod pallet_im_online; +pub mod pallet_multisig; +pub mod pallet_proxy; +pub mod pallet_session; +pub mod pallet_scheduler; +pub mod pallet_timestamp; +pub mod pallet_treasury; +pub mod pallet_universal_dividend; +pub mod pallet_upgrade_origin; +pub mod pallet_provide_randomness; +pub mod pallet_identity; +pub mod pallet_preimage; +pub mod pallet_utility; +pub mod pallet_duniter_account; +pub mod pallet_quota; +pub mod pallet_oneshot_account; +pub mod pallet_certification; +pub mod pallet_membership; +pub mod pallet_smith_members; +pub mod pallet_sudo; +pub mod pallet_authority_members; +pub mod paritydb_weights; diff --git a/runtime/common/src/weights/block_weights.rs b/runtime/gdev/src/weights/block_weights.rs similarity index 82% rename from runtime/common/src/weights/block_weights.rs rename to runtime/gdev/src/weights/block_weights.rs index a1d29d9a5..86717b540 100644 --- a/runtime/common/src/weights/block_weights.rs +++ b/runtime/gdev/src/weights/block_weights.rs @@ -1,11 +1,11 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13 (Y/M/D) +//! DATE: 2024-06-21 (Y/M/D) //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! //! SHORT-NAME: `block`, LONG-NAME: `BlockExecution`, RUNTIME: `Ğdev Local Testnet` //! WARMUPS: `10`, REPEAT: `100` -//! WEIGHT-PATH: `./runtime/common/src/weights/` +//! WEIGHT-PATH: `./runtime/gdev/src/weights/` //! WEIGHT-METRIC: `Average`, WEIGHT-MUL: `1.0`, WEIGHT-ADD: `0` // Executed Command: @@ -14,7 +14,7 @@ // overhead // --chain=dev // --wasm-execution=compiled -// --weight-path=./runtime/common/src/weights/ +// --weight-path=./runtime/gdev/src/weights/ // --warmup=10 // --repeat=100 @@ -26,17 +26,17 @@ parameter_types! { /// Calculated by multiplying the *Average* with `1.0` and adding `0`. /// /// Stats nanoseconds: - /// Min, Max: 124_012, 323_353 - /// Average: 133_143 - /// Median: 128_528 - /// Std-Dev: 20423.87 + /// Min, Max: 127_220, 170_087 + /// Average: 136_588 + /// Median: 135_555 + /// Std-Dev: 5899.47 /// /// Percentiles nanoseconds: - /// 99th: 174_283 - /// 95th: 146_055 - /// 75th: 132_728 + /// 99th: 158_776 + /// 95th: 145_516 + /// 75th: 137_489 pub const BlockExecutionWeight: Weight = - Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(133_143), 0); + Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(136_588), 0); } #[cfg(test)] diff --git a/runtime/common/src/weights/extrinsic_weights.rs b/runtime/gdev/src/weights/extrinsic_weights.rs similarity index 79% rename from runtime/common/src/weights/extrinsic_weights.rs rename to runtime/gdev/src/weights/extrinsic_weights.rs index 252aa7bcc..5ec0de75a 100644 --- a/runtime/common/src/weights/extrinsic_weights.rs +++ b/runtime/gdev/src/weights/extrinsic_weights.rs @@ -1,11 +1,11 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13 (Y/M/D) +//! DATE: 2024-06-21 (Y/M/D) //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! //! SHORT-NAME: `extrinsic`, LONG-NAME: `ExtrinsicBase`, RUNTIME: `Ğdev Local Testnet` //! WARMUPS: `10`, REPEAT: `100` -//! WEIGHT-PATH: `./runtime/common/src/weights/` +//! WEIGHT-PATH: `./runtime/gdev/src/weights/` //! WEIGHT-METRIC: `Average`, WEIGHT-MUL: `1.0`, WEIGHT-ADD: `0` // Executed Command: @@ -14,7 +14,7 @@ // overhead // --chain=dev // --wasm-execution=compiled -// --weight-path=./runtime/common/src/weights/ +// --weight-path=./runtime/gdev/src/weights/ // --warmup=10 // --repeat=100 @@ -26,17 +26,17 @@ parameter_types! { /// Calculated by multiplying the *Average* with `1.0` and adding `0`. /// /// Stats nanoseconds: - /// Min, Max: 70_730, 71_335 - /// Average: 70_896 - /// Median: 70_881 - /// Std-Dev: 92.55 + /// Min, Max: 92_467, 101_179 + /// Average: 95_431 + /// Median: 95_127 + /// Std-Dev: 2019.77 /// /// Percentiles nanoseconds: - /// 99th: 71_139 - /// 95th: 71_044 - /// 75th: 70_948 + /// 99th: 100_737 + /// 95th: 99_095 + /// 75th: 96_867 pub const ExtrinsicBaseWeight: Weight = - Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(70_896), 0); + Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(95_431), 0); } #[cfg(test)] diff --git a/runtime/gdev/src/weights/frame_benchmarking_baseline.rs b/runtime/gdev/src/weights/frame_benchmarking_baseline.rs new file mode 100644 index 000000000..beb095a0c --- /dev/null +++ b/runtime/gdev/src/weights/frame_benchmarking_baseline.rs @@ -0,0 +1,105 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `frame_benchmarking::baseline` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `frame_benchmarking::baseline`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for WeightInfo<T> { + /// The range of component `i` is `[0, 1000000]`. + fn addition(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 81_000 picoseconds. + Weight::from_parts(91_789, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 1000000]`. + fn subtraction(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 82_000 picoseconds. + Weight::from_parts(115_142, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 1000000]`. + fn multiplication(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 81_000 picoseconds. + Weight::from_parts(97_794, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 1000000]`. + fn division(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 80_000 picoseconds. + Weight::from_parts(97_609, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + fn hashing() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 20_926_729_000 picoseconds. + Weight::from_parts(21_099_085_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 100]`. + fn sr25519_verification(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 88_000 picoseconds. + Weight::from_parts(37_412_038, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 134_767 + .saturating_add(Weight::from_parts(37_321_454, 0).saturating_mul(i.into())) + } +} diff --git a/runtime/gdev/src/weights/frame_system.rs b/runtime/gdev/src/weights/frame_system.rs new file mode 100644 index 000000000..add5dac32 --- /dev/null +++ b/runtime/gdev/src/weights/frame_system.rs @@ -0,0 +1,171 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `frame_system` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `frame_system`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { + /// The range of component `b` is `[0, 3932160]`. + fn remark(b: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_573_000 picoseconds. + Weight::from_parts(10_669_791, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 1 + .saturating_add(Weight::from_parts(267, 0).saturating_mul(b.into())) + } + /// The range of component `b` is `[0, 3932160]`. + fn remark_with_event(b: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_362_000 picoseconds. + Weight::from_parts(4_469_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 1 + .saturating_add(Weight::from_parts(1_094, 0).saturating_mul(b.into())) + } + /// Storage: `System::Digest` (r:1 w:1) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: UNKNOWN KEY `0x3a686561707061676573` (r:0 w:1) + /// Proof: UNKNOWN KEY `0x3a686561707061676573` (r:0 w:1) + fn set_heap_pages() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `1485` + // Minimum execution time: 2_463_000 picoseconds. + Weight::from_parts(2_691_000, 0) + .saturating_add(Weight::from_parts(0, 1485)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `System::Digest` (r:1 w:1) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + /// Proof: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + fn set_code() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `1485` + // Minimum execution time: 64_757_694_000 picoseconds. + Weight::from_parts(67_279_038_000, 0) + .saturating_add(Weight::from_parts(0, 1485)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Skipped::Metadata` (r:0 w:0) + /// Proof: `Skipped::Metadata` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[0, 1000]`. + fn set_storage(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_574_000 picoseconds. + Weight::from_parts(1_637_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 712 + .saturating_add(Weight::from_parts(564_024, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + } + /// Storage: `Skipped::Metadata` (r:0 w:0) + /// Proof: `Skipped::Metadata` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[0, 1000]`. + fn kill_storage(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_541_000 picoseconds. + Weight::from_parts(1_680_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 971 + .saturating_add(Weight::from_parts(445_963, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + } + /// Storage: `Skipped::Metadata` (r:0 w:0) + /// Proof: `Skipped::Metadata` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `p` is `[0, 1000]`. + fn kill_prefix(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + p * (69 ±0)` + // Estimated: `76 + p * (70 ±0)` + // Minimum execution time: 3_007_000 picoseconds. + Weight::from_parts(3_105_000, 0) + .saturating_add(Weight::from_parts(0, 76)) + // Standard Error: 2_208 + .saturating_add(Weight::from_parts(921_382, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) + .saturating_add(Weight::from_parts(0, 70).saturating_mul(p.into())) + } + /// Storage: `System::AuthorizedUpgrade` (r:0 w:1) + /// Proof: `System::AuthorizedUpgrade` (`max_values`: Some(1), `max_size`: Some(33), added: 528, mode: `MaxEncodedLen`) + fn authorize_upgrade() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 10_100_000 picoseconds. + Weight::from_parts(15_806_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::AuthorizedUpgrade` (r:1 w:1) + /// Proof: `System::AuthorizedUpgrade` (`max_values`: Some(1), `max_size`: Some(33), added: 528, mode: `MaxEncodedLen`) + /// Storage: `System::Digest` (r:1 w:1) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + /// Proof: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + fn apply_authorized_upgrade() -> Weight { + // Proof Size summary in bytes: + // Measured: `22` + // Estimated: `1518` + // Minimum execution time: 68_994_269_000 picoseconds. + Weight::from_parts(71_919_128_000, 0) + .saturating_add(Weight::from_parts(0, 1518)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gdev/src/weights/pallet_authority_members.rs b/runtime/gdev/src/weights/pallet_authority_members.rs new file mode 100644 index 000000000..8fc4beb49 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_authority_members.rs @@ -0,0 +1,156 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_authority_members` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_authority_members`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_authority_members::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:0) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn go_offline() -> Weight { + // Proof Size summary in bytes: + // Measured: `933` + // Estimated: `4398` + // Minimum execution time: 19_481_000 picoseconds. + Weight::from_parts(20_278_000, 0) + .saturating_add(Weight::from_parts(0, 4398)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Blacklist` (r:1 w:0) + /// Proof: `AuthorityMembers::Blacklist` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:0) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:0) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn go_online() -> Weight { + // Proof Size summary in bytes: + // Measured: `1390` + // Estimated: `4855` + // Minimum execution time: 25_822_000 picoseconds. + Weight::from_parts(27_588_000, 0) + .saturating_add(Weight::from_parts(0, 4855)) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:0) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::KeyOwner` (r:4 w:0) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:0 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn set_session_keys() -> Weight { + // Proof Size summary in bytes: + // Measured: `1839` + // Estimated: `12729` + // Minimum execution time: 34_670_000 picoseconds. + Weight::from_parts(36_119_000, 0) + .saturating_add(Weight::from_parts(0, 12729)) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn remove_member() -> Weight { + // Proof Size summary in bytes: + // Measured: `848` + // Estimated: `4313` + // Minimum execution time: 33_082_000 picoseconds. + Weight::from_parts(35_238_000, 0) + .saturating_add(Weight::from_parts(0, 4313)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(10)) + } + /// Storage: `AuthorityMembers::Blacklist` (r:1 w:1) + /// Proof: `AuthorityMembers::Blacklist` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn remove_member_from_blacklist() -> Weight { + // Proof Size summary in bytes: + // Measured: `199` + // Estimated: `1684` + // Minimum execution time: 7_161_000 picoseconds. + Weight::from_parts(7_998_000, 0) + .saturating_add(Weight::from_parts(0, 1684)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gdev/src/weights/pallet_babe.rs b/runtime/gdev/src/weights/pallet_babe.rs new file mode 100644 index 000000000..caa37df09 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_babe.rs @@ -0,0 +1,54 @@ +// Copyright 2021 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Manual weights for the GRANDPA Pallet in duniter runtimes +//! This file was not auto-generated. + +use frame_support::{ + traits::Get, + weights::{ + constants::{WEIGHT_REF_TIME_PER_MICROS, WEIGHT_REF_TIME_PER_NANOS}, + Weight, + }, +}; +use sp_std::marker::PhantomData; + +/// Weight functions for `pallet_babe`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_babe::WeightInfo for WeightInfo<T> { + fn plan_config_change() -> Weight { + T::DbWeight::get().writes(1) + } + + fn report_equivocation(validator_count: u32, _p: u32) -> Weight { + // we take the validator set count from the membership proof to + // calculate the weight but we set a floor of 100 validators. + let validator_count = validator_count.max(100) as u64; + + // checking membership proof + (Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 35) + .saturating_add( + (Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS, 0) * 175) + .saturating_mul(validator_count), + ) + .saturating_add(T::DbWeight::get().reads(5)) + // check equivocation proof + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 110) + // report offence + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 110) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gdev/src/weights/pallet_balances.rs b/runtime/gdev/src/weights/pallet_balances.rs new file mode 100644 index 000000000..9088d77ee --- /dev/null +++ b/runtime/gdev/src/weights/pallet_balances.rs @@ -0,0 +1,142 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_balances` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_balances`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_allow_death() -> Weight { + // Proof Size summary in bytes: + // Measured: `63` + // Estimated: `6126` + // Minimum execution time: 50_143_000 picoseconds. + Weight::from_parts(51_313_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_keep_alive() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3558` + // Minimum execution time: 30_573_000 picoseconds. + Weight::from_parts(31_994_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_set_balance_creating() -> Weight { + // Proof Size summary in bytes: + // Measured: `134` + // Estimated: `3558` + // Minimum execution time: 10_074_000 picoseconds. + Weight::from_parts(10_588_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_set_balance_killing() -> Weight { + // Proof Size summary in bytes: + // Measured: `134` + // Estimated: `3558` + // Minimum execution time: 13_847_000 picoseconds. + Weight::from_parts(14_914_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:3 w:3) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_transfer() -> Weight { + // Proof Size summary in bytes: + // Measured: `126` + // Estimated: `8694` + // Minimum execution time: 50_579_000 picoseconds. + Weight::from_parts(51_601_000, 0) + .saturating_add(Weight::from_parts(0, 8694)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_all() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3558` + // Minimum execution time: 38_352_000 picoseconds. + Weight::from_parts(39_084_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_unreserve() -> Weight { + // Proof Size summary in bytes: + // Measured: `134` + // Estimated: `3558` + // Minimum execution time: 13_345_000 picoseconds. + Weight::from_parts(14_298_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn force_adjust_total_issuance() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_393_000 picoseconds. + Weight::from_parts(4_677_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } +} diff --git a/runtime/common/src/weights/pallet_certification.rs b/runtime/gdev/src/weights/pallet_certification.rs similarity index 83% rename from runtime/common/src/weights/pallet_certification.rs rename to runtime/gdev/src/weights/pallet_certification.rs index 580c622e9..18a9b81f5 100644 --- a/runtime/common/src/weights/pallet_certification.rs +++ b/runtime/gdev/src/weights/pallet_certification.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_certification` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/gdev/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -61,11 +61,11 @@ impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) fn add_cert() -> Weight { // Proof Size summary in bytes: - // Measured: `956` - // Estimated: `6896` - // Minimum execution time: 30_971_000 picoseconds. - Weight::from_parts(32_188_000, 0) - .saturating_add(Weight::from_parts(0, 6896)) + // Measured: `1107` + // Estimated: `7047` + // Minimum execution time: 32_125_000 picoseconds. + Weight::from_parts(33_477_000, 0) + .saturating_add(Weight::from_parts(0, 7047)) .saturating_add(T::DbWeight::get().reads(8)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -83,11 +83,11 @@ impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) fn renew_cert() -> Weight { // Proof Size summary in bytes: - // Measured: `980` - // Estimated: `6920` - // Minimum execution time: 29_235_000 picoseconds. - Weight::from_parts(30_293_000, 0) - .saturating_add(Weight::from_parts(0, 6920)) + // Measured: `1130` + // Estimated: `7070` + // Minimum execution time: 31_149_000 picoseconds. + Weight::from_parts(32_863_000, 0) + .saturating_add(Weight::from_parts(0, 7070)) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -99,11 +99,11 @@ impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> /// Proof: `Parameters::ParametersStorage` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) fn del_cert() -> Weight { // Proof Size summary in bytes: - // Measured: `444` - // Estimated: `6384` - // Minimum execution time: 15_655_000 picoseconds. - Weight::from_parts(16_665_000, 0) - .saturating_add(Weight::from_parts(0, 6384)) + // Measured: `528` + // Estimated: `6468` + // Minimum execution time: 17_019_000 picoseconds. + Weight::from_parts(17_719_000, 0) + .saturating_add(Weight::from_parts(0, 6468)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -118,13 +118,13 @@ impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> /// The range of component `i` is `[2, 1000]`. fn remove_all_certs_received_by(i: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `546 + i * (35 ±0)` - // Estimated: `4017 + i * (2511 ±0)` - // Minimum execution time: 24_107_000 picoseconds. - Weight::from_parts(24_630_000, 0) - .saturating_add(Weight::from_parts(0, 4017)) - // Standard Error: 22_328 - .saturating_add(Weight::from_parts(8_359_989, 0).saturating_mul(i.into())) + // Measured: `665 + i * (35 ±0)` + // Estimated: `4129 + i * (2511 ±0)` + // Minimum execution time: 25_722_000 picoseconds. + Weight::from_parts(26_587_000, 0) + .saturating_add(Weight::from_parts(0, 4129)) + // Standard Error: 27_721 + .saturating_add(Weight::from_parts(9_183_060, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) .saturating_add(T::DbWeight::get().writes(1)) @@ -137,8 +137,8 @@ impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> // Proof Size summary in bytes: // Measured: `139` // Estimated: `3604` - // Minimum execution time: 2_464_000 picoseconds. - Weight::from_parts(2_697_000, 0) + // Minimum execution time: 2_488_000 picoseconds. + Weight::from_parts(2_730_000, 0) .saturating_add(Weight::from_parts(0, 3604)) .saturating_add(T::DbWeight::get().reads(1)) } @@ -146,11 +146,11 @@ impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) fn do_remove_cert_noop() -> Weight { // Proof Size summary in bytes: - // Measured: `237` - // Estimated: `3702` - // Minimum execution time: 3_424_000 picoseconds. - Weight::from_parts(3_805_000, 0) - .saturating_add(Weight::from_parts(0, 3702)) + // Measured: `276` + // Estimated: `3741` + // Minimum execution time: 3_548_000 picoseconds. + Weight::from_parts(3_668_000, 0) + .saturating_add(Weight::from_parts(0, 3741)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -164,11 +164,11 @@ impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) fn do_remove_cert() -> Weight { // Proof Size summary in bytes: - // Measured: `660` - // Estimated: `6600` - // Minimum execution time: 19_445_000 picoseconds. - Weight::from_parts(20_341_000, 0) - .saturating_add(Weight::from_parts(0, 6600)) + // Measured: `822` + // Estimated: `6762` + // Minimum execution time: 22_206_000 picoseconds. + Weight::from_parts(23_016_000, 0) + .saturating_add(Weight::from_parts(0, 6762)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } diff --git a/runtime/gdev/src/weights/pallet_collective.rs b/runtime/gdev/src/weights/pallet_collective.rs new file mode 100644 index 000000000..3acfc0333 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_collective.rs @@ -0,0 +1,302 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_collective` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_collective`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { + /// Storage: `TechnicalCommittee::Members` (r:1 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:20 w:20) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[0, 100]`. + /// The range of component `n` is `[0, 100]`. + /// The range of component `p` is `[0, 20]`. + fn set_members(m: u32, _n: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0 + m * (672 ±0) + p * (3191 ±0)` + // Estimated: `10019 + m * (416 ±4) + p * (4183 ±23)` + // Minimum execution time: 11_435_000 picoseconds. + Weight::from_parts(11_954_000, 0) + .saturating_add(Weight::from_parts(0, 10019)) + // Standard Error: 9_720 + .saturating_add(Weight::from_parts(715_272, 0).saturating_mul(m.into())) + // Standard Error: 48_052 + .saturating_add(Weight::from_parts(6_303_885, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) + .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) + .saturating_add(Weight::from_parts(0, 416).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 4183).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[1, 100]`. + fn execute(b: u32, m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `32 + m * (32 ±0)` + // Estimated: `1518 + m * (32 ±0)` + // Minimum execution time: 10_063_000 picoseconds. + Weight::from_parts(9_531_468, 0) + .saturating_add(Weight::from_parts(0, 1518)) + // Standard Error: 89 + .saturating_add(Weight::from_parts(1_269, 0).saturating_mul(b.into())) + // Standard Error: 925 + .saturating_add(Weight::from_parts(14_714, 0).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:0) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[1, 100]`. + fn propose_execute(b: u32, m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `32 + m * (32 ±0)` + // Estimated: `3498 + m * (32 ±0)` + // Minimum execution time: 11_902_000 picoseconds. + Weight::from_parts(11_249_336, 0) + .saturating_add(Weight::from_parts(0, 3498)) + // Standard Error: 132 + .saturating_add(Weight::from_parts(1_866, 0).saturating_mul(b.into())) + // Standard Error: 1_363 + .saturating_add(Weight::from_parts(18_107, 0).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalCount` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[2, 100]`. + /// The range of component `p` is `[1, 20]`. + fn propose_proposed(b: u32, m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `24 + m * (32 ±0) + p * (55 ±0)` + // Estimated: `3461 + m * (32 ±0) + p * (54 ±0)` + // Minimum execution time: 17_015_000 picoseconds. + Weight::from_parts(16_315_149, 0) + .saturating_add(Weight::from_parts(0, 3461)) + // Standard Error: 91 + .saturating_add(Weight::from_parts(2_317, 0).saturating_mul(b.into())) + // Standard Error: 954 + .saturating_add(Weight::from_parts(16_299, 0).saturating_mul(m.into())) + // Standard Error: 4_771 + .saturating_add(Weight::from_parts(271_892, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(4)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 54).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[5, 100]`. + fn vote(m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `573 + m * (64 ±0)` + // Estimated: `4037 + m * (64 ±0)` + // Minimum execution time: 15_140_000 picoseconds. + Weight::from_parts(15_967_323, 0) + .saturating_add(Weight::from_parts(0, 4037)) + // Standard Error: 591 + .saturating_add(Weight::from_parts(39_787, 0).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_early_disapproved(m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `117 + m * (64 ±0) + p * (55 ±0)` + // Estimated: `3591 + m * (64 ±0) + p * (55 ±0)` + // Minimum execution time: 19_766_000 picoseconds. + Weight::from_parts(18_588_256, 0) + .saturating_add(Weight::from_parts(0, 3591)) + // Standard Error: 2_162 + .saturating_add(Weight::from_parts(37_082, 0).saturating_mul(m.into())) + // Standard Error: 10_680 + .saturating_add(Weight::from_parts(221_997, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 55).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_early_approved(b: u32, m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `62 + b * (1 ±0) + m * (64 ±0) + p * (78 ±0)` + // Estimated: `3619 + b * (1 ±0) + m * (63 ±0) + p * (74 ±0)` + // Minimum execution time: 27_239_000 picoseconds. + Weight::from_parts(26_634_766, 0) + .saturating_add(Weight::from_parts(0, 3619)) + // Standard Error: 85 + .saturating_add(Weight::from_parts(2_323, 0).saturating_mul(b.into())) + // Standard Error: 899 + .saturating_add(Weight::from_parts(18_347, 0).saturating_mul(m.into())) + // Standard Error: 4_438 + .saturating_add(Weight::from_parts(351_492, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) + .saturating_add(Weight::from_parts(0, 63).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 74).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_disapproved(m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `137 + m * (64 ±0) + p * (55 ±0)` + // Estimated: `3611 + m * (64 ±0) + p * (55 ±0)` + // Minimum execution time: 21_806_000 picoseconds. + Weight::from_parts(20_516_127, 0) + .saturating_add(Weight::from_parts(0, 3611)) + // Standard Error: 1_286 + .saturating_add(Weight::from_parts(29_711, 0).saturating_mul(m.into())) + // Standard Error: 6_352 + .saturating_add(Weight::from_parts(266_183, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 55).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_approved(b: u32, m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `82 + b * (1 ±0) + m * (64 ±0) + p * (78 ±0)` + // Estimated: `3639 + b * (1 ±0) + m * (63 ±0) + p * (74 ±0)` + // Minimum execution time: 29_299_000 picoseconds. + Weight::from_parts(29_950_046, 0) + .saturating_add(Weight::from_parts(0, 3639)) + // Standard Error: 205 + .saturating_add(Weight::from_parts(756, 0).saturating_mul(b.into())) + // Standard Error: 2_168 + .saturating_add(Weight::from_parts(11_325, 0).saturating_mul(m.into())) + // Standard Error: 10_698 + .saturating_add(Weight::from_parts(356_496, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) + .saturating_add(Weight::from_parts(0, 63).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 74).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `p` is `[1, 20]`. + fn disapprove_proposal(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `189 + p * (32 ±0)` + // Estimated: `1674 + p * (32 ±0)` + // Minimum execution time: 9_568_000 picoseconds. + Weight::from_parts(10_412_791, 0) + .saturating_add(Weight::from_parts(0, 1674)) + // Standard Error: 2_544 + .saturating_add(Weight::from_parts(191_027, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(p.into())) + } +} diff --git a/runtime/common/src/weights/pallet_distance.rs b/runtime/gdev/src/weights/pallet_distance.rs similarity index 81% rename from runtime/common/src/weights/pallet_distance.rs rename to runtime/gdev/src/weights/pallet_distance.rs index 698e6ce40..03832edbb 100644 --- a/runtime/common/src/weights/pallet_distance.rs +++ b/runtime/gdev/src/weights/pallet_distance.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_distance` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/gdev/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -65,15 +65,17 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) /// Storage: `System::Account` (r:1 w:1) /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) fn request_distance_evaluation() -> Weight { // Proof Size summary in bytes: - // Measured: `1119` - // Estimated: `4584` - // Minimum execution time: 40_210_000 picoseconds. - Weight::from_parts(42_313_000, 0) - .saturating_add(Weight::from_parts(0, 4584)) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(3)) + // Measured: `1251` + // Estimated: `4716` + // Minimum execution time: 57_561_000 picoseconds. + Weight::from_parts(60_205_000, 0) + .saturating_add(Weight::from_parts(0, 4716)) + .saturating_add(T::DbWeight::get().reads(10)) + .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -93,15 +95,17 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) /// Storage: `System::Account` (r:1 w:1) /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) fn request_distance_evaluation_for() -> Weight { // Proof Size summary in bytes: - // Measured: `1148` - // Estimated: `7088` - // Minimum execution time: 43_404_000 picoseconds. - Weight::from_parts(44_672_000, 0) - .saturating_add(Weight::from_parts(0, 7088)) - .saturating_add(T::DbWeight::get().reads(10)) - .saturating_add(T::DbWeight::get().writes(3)) + // Measured: `1280` + // Estimated: `7220` + // Minimum execution time: 60_563_000 picoseconds. + Weight::from_parts(62_555_000, 0) + .saturating_add(Weight::from_parts(0, 7220)) + .saturating_add(T::DbWeight::get().reads(11)) + .saturating_add(T::DbWeight::get().writes(4)) } /// Storage: `Distance::DidUpdate` (r:1 w:1) /// Proof: `Distance::DidUpdate` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) @@ -120,11 +124,11 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `402 + i * (10 ±0)` // Estimated: `1887 + i * (10 ±0)` - // Minimum execution time: 12_374_000 picoseconds. - Weight::from_parts(15_184_116, 0) + // Minimum execution time: 12_665_000 picoseconds. + Weight::from_parts(15_026_666, 0) .saturating_add(Weight::from_parts(0, 1887)) - // Standard Error: 109 - .saturating_add(Weight::from_parts(99_165, 0).saturating_mul(i.into())) + // Standard Error: 101 + .saturating_add(Weight::from_parts(109_497, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) .saturating_add(Weight::from_parts(0, 10).saturating_mul(i.into())) @@ -138,11 +142,11 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `139 + i * (10 ±0)` // Estimated: `1624 + i * (10 ±0)` - // Minimum execution time: 5_098_000 picoseconds. - Weight::from_parts(6_634_188, 0) + // Minimum execution time: 5_313_000 picoseconds. + Weight::from_parts(7_139_413, 0) .saturating_add(Weight::from_parts(0, 1624)) - // Standard Error: 72 - .saturating_add(Weight::from_parts(99_785, 0).saturating_mul(i.into())) + // Standard Error: 336 + .saturating_add(Weight::from_parts(109_963, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) .saturating_add(Weight::from_parts(0, 10).saturating_mul(i.into())) @@ -157,11 +161,11 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { /// Proof: `Parameters::ParametersStorage` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) fn force_valid_distance_status() -> Weight { // Proof Size summary in bytes: - // Measured: `609` - // Estimated: `6549` - // Minimum execution time: 24_084_000 picoseconds. - Weight::from_parts(25_424_000, 0) - .saturating_add(Weight::from_parts(0, 6549)) + // Measured: `683` + // Estimated: `6623` + // Minimum execution time: 25_655_000 picoseconds. + Weight::from_parts(27_167_000, 0) + .saturating_add(Weight::from_parts(0, 6623)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -169,8 +173,8 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 82_000 picoseconds. - Weight::from_parts(104_000, 0) + // Minimum execution time: 81_000 picoseconds. + Weight::from_parts(97_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// Storage: `System::ParentHash` (r:1 w:0) @@ -181,6 +185,8 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `System::Account` (r:1 w:1) /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) /// Storage: `Identity::Identities` (r:1 w:0) /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `Membership::Membership` (r:1 w:1) @@ -193,13 +199,13 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) fn do_evaluation_success() -> Weight { // Proof Size summary in bytes: - // Measured: `973` - // Estimated: `6913` - // Minimum execution time: 41_435_000 picoseconds. - Weight::from_parts(43_480_000, 0) - .saturating_add(Weight::from_parts(0, 6913)) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(7)) + // Measured: `1095` + // Estimated: `7035` + // Minimum execution time: 55_847_000 picoseconds. + Weight::from_parts(57_892_000, 0) + .saturating_add(Weight::from_parts(0, 7035)) + .saturating_add(T::DbWeight::get().reads(10)) + .saturating_add(T::DbWeight::get().writes(8)) } /// Storage: `System::ParentHash` (r:1 w:0) /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) @@ -207,19 +213,21 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) /// Storage: `System::Account` (r:1 w:1) /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) /// Storage: `Distance::EvaluationBlock` (r:0 w:1) /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) fn do_evaluation_failure() -> Weight { // Proof Size summary in bytes: - // Measured: `364` - // Estimated: `3829` - // Minimum execution time: 21_085_000 picoseconds. - Weight::from_parts(22_071_000, 0) - .saturating_add(Weight::from_parts(0, 3829)) - .saturating_add(T::DbWeight::get().reads(4)) - .saturating_add(T::DbWeight::get().writes(4)) + // Measured: `412` + // Estimated: `3877` + // Minimum execution time: 26_165_000 picoseconds. + Weight::from_parts(27_257_000, 0) + .saturating_add(Weight::from_parts(0, 3877)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) } /// Storage: `System::ParentHash` (r:1 w:0) /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) @@ -231,8 +239,8 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `109` // Estimated: `1594` - // Minimum execution time: 2_403_000 picoseconds. - Weight::from_parts(2_646_000, 0) + // Minimum execution time: 2_418_000 picoseconds. + Weight::from_parts(2_617_000, 0) .saturating_add(Weight::from_parts(0, 1594)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) @@ -243,8 +251,8 @@ impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `133` // Estimated: `1618` - // Minimum execution time: 2_423_000 picoseconds. - Weight::from_parts(2_611_000, 0) + // Minimum execution time: 2_443_000 picoseconds. + Weight::from_parts(2_613_000, 0) .saturating_add(Weight::from_parts(0, 1618)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) diff --git a/runtime/gdev/src/weights/pallet_duniter_account.rs b/runtime/gdev/src/weights/pallet_duniter_account.rs new file mode 100644 index 000000000..13af319f7 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_duniter_account.rs @@ -0,0 +1,62 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_duniter_account` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_duniter_account`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_duniter_account::WeightInfo for WeightInfo<T> { + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn unlink_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3558` + // Minimum execution time: 3_338_000 picoseconds. + Weight::from_parts(3_597_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gdev/src/weights/pallet_grandpa.rs b/runtime/gdev/src/weights/pallet_grandpa.rs new file mode 100644 index 000000000..3c6528f7f --- /dev/null +++ b/runtime/gdev/src/weights/pallet_grandpa.rs @@ -0,0 +1,55 @@ +// Copyright 2021 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Manual weights for the GRANDPA Pallet in duniter runtimes +//! This file was not auto-generated. + +use frame_support::{ + traits::Get, + weights::{ + constants::{WEIGHT_REF_TIME_PER_MICROS, WEIGHT_REF_TIME_PER_NANOS}, + Weight, + }, +}; +use sp_std::marker::PhantomData; + +/// Weight functions for `pallet_grandpa`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_grandpa::WeightInfo for WeightInfo<T> { + fn report_equivocation(validator_count: u32, _p: u32) -> Weight { + // we take the validator set count from the membership proof to + // calculate the weight but we set a floor of 100 validators. + let validator_count = validator_count.max(100) as u64; + + // checking membership proof + (Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 35) + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS, 0) * 175) + .saturating_mul(validator_count) + .saturating_add(T::DbWeight::get().reads(5)) + // check equivocation proof + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 95) + // report offence + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 110) + .saturating_add(T::DbWeight::get().writes(3)) + // fetching set id -> session index mappings + .saturating_add(T::DbWeight::get().reads(2)) + } + + fn note_stalled() -> Weight { + (Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 3) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/common/src/weights/pallet_identity.rs b/runtime/gdev/src/weights/pallet_identity.rs similarity index 83% rename from runtime/common/src/weights/pallet_identity.rs rename to runtime/gdev/src/weights/pallet_identity.rs index 5b0f3d032..b9d57da85 100644 --- a/runtime/common/src/weights/pallet_identity.rs +++ b/runtime/gdev/src/weights/pallet_identity.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_identity` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-16, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -29,12 +29,12 @@ // --chain=dev // --steps=50 // --repeat=20 -// --pallet=pallet-identity +// --pallet=* // --extrinsic=* // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/gdev/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -71,11 +71,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) fn create_identity() -> Weight { // Proof Size summary in bytes: - // Measured: `1070` - // Estimated: `7010` - // Minimum execution time: 64_979_000 picoseconds. - Weight::from_parts(66_407_000, 0) - .saturating_add(Weight::from_parts(0, 7010)) + // Measured: `1210` + // Estimated: `7150` + // Minimum execution time: 68_786_000 picoseconds. + Weight::from_parts(71_671_000, 0) + .saturating_add(Weight::from_parts(0, 7150)) .saturating_add(T::DbWeight::get().reads(13)) .saturating_add(T::DbWeight::get().writes(12)) } @@ -89,11 +89,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) fn confirm_identity() -> Weight { // Proof Size summary in bytes: - // Measured: `698` - // Estimated: `6638` - // Minimum execution time: 28_030_000 picoseconds. - Weight::from_parts(29_442_000, 0) - .saturating_add(Weight::from_parts(0, 6638)) + // Measured: `822` + // Estimated: `6762` + // Minimum execution time: 29_039_000 picoseconds. + Weight::from_parts(30_405_000, 0) + .saturating_add(Weight::from_parts(0, 6762)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(4)) } @@ -107,11 +107,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) fn change_owner_key() -> Weight { // Proof Size summary in bytes: - // Measured: `723` - // Estimated: `6663` - // Minimum execution time: 73_717_000 picoseconds. - Weight::from_parts(75_195_000, 0) - .saturating_add(Weight::from_parts(0, 6663)) + // Measured: `793` + // Estimated: `6733` + // Minimum execution time: 74_132_000 picoseconds. + Weight::from_parts(77_401_000, 0) + .saturating_add(Weight::from_parts(0, 6733)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -127,11 +127,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) fn revoke_identity() -> Weight { // Proof Size summary in bytes: - // Measured: `664` - // Estimated: `6604` - // Minimum execution time: 64_566_000 picoseconds. - Weight::from_parts(65_978_000, 0) - .saturating_add(Weight::from_parts(0, 6604)) + // Measured: `731` + // Estimated: `6671` + // Minimum execution time: 68_027_000 picoseconds. + Weight::from_parts(71_497_000, 0) + .saturating_add(Weight::from_parts(0, 6671)) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(5)) } @@ -142,11 +142,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_611_000 picoseconds. - Weight::from_parts(3_788_000, 0) + // Minimum execution time: 3_905_000 picoseconds. + Weight::from_parts(4_081_000, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 1_076 - .saturating_add(Weight::from_parts(1_174_325, 0).saturating_mul(i.into())) + // Standard Error: 1_859 + .saturating_add(Weight::from_parts(1_261_179, 0).saturating_mul(i.into())) .saturating_add(T::DbWeight::get().writes(1)) .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) } @@ -156,8 +156,8 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `104` // Estimated: `3558` - // Minimum execution time: 6_271_000 picoseconds. - Weight::from_parts(6_529_000, 0) + // Minimum execution time: 6_347_000 picoseconds. + Weight::from_parts(6_771_000, 0) .saturating_add(Weight::from_parts(0, 3558)) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) @@ -170,11 +170,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) fn link_account() -> Weight { // Proof Size summary in bytes: - // Measured: `403` - // Estimated: `3868` - // Minimum execution time: 50_535_000 picoseconds. - Weight::from_parts(51_906_000, 0) - .saturating_add(Weight::from_parts(0, 3868)) + // Measured: `436` + // Estimated: `3901` + // Minimum execution time: 51_898_000 picoseconds. + Weight::from_parts(53_782_000, 0) + .saturating_add(Weight::from_parts(0, 3901)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -182,19 +182,19 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 83_000 picoseconds. - Weight::from_parts(107_000, 0) + // Minimum execution time: 84_000 picoseconds. + Weight::from_parts(99_000, 0) .saturating_add(Weight::from_parts(0, 0)) } /// Storage: `Identity::Identities` (r:1 w:0) /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) fn do_revoke_identity_noop() -> Weight { // Proof Size summary in bytes: - // Measured: `302` - // Estimated: `3767` - // Minimum execution time: 3_424_000 picoseconds. - Weight::from_parts(3_629_000, 0) - .saturating_add(Weight::from_parts(0, 3767)) + // Measured: `360` + // Estimated: `3825` + // Minimum execution time: 3_660_000 picoseconds. + Weight::from_parts(3_844_000, 0) + .saturating_add(Weight::from_parts(0, 3825)) .saturating_add(T::DbWeight::get().reads(1)) } /// Storage: `Identity::Identities` (r:1 w:1) @@ -209,7 +209,7 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) - /// Storage: `SmithMembers::Smiths` (r:3 w:3) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `AuthorityMembers::Members` (r:1 w:1) /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -229,23 +229,23 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) fn do_revoke_identity() -> Weight { // Proof Size summary in bytes: - // Measured: `1555` - // Estimated: `9970` - // Minimum execution time: 81_169_000 picoseconds. - Weight::from_parts(83_252_000, 0) - .saturating_add(Weight::from_parts(0, 9970)) - .saturating_add(T::DbWeight::get().reads(16)) - .saturating_add(T::DbWeight::get().writes(20)) + // Measured: `1931` + // Estimated: `15296` + // Minimum execution time: 96_875_000 picoseconds. + Weight::from_parts(102_455_000, 0) + .saturating_add(Weight::from_parts(0, 15296)) + .saturating_add(T::DbWeight::get().reads(18)) + .saturating_add(T::DbWeight::get().writes(22)) } /// Storage: `Identity::Identities` (r:1 w:0) /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) fn do_remove_identity_noop() -> Weight { // Proof Size summary in bytes: - // Measured: `302` - // Estimated: `3767` - // Minimum execution time: 3_406_000 picoseconds. - Weight::from_parts(3_698_000, 0) - .saturating_add(Weight::from_parts(0, 3767)) + // Measured: `360` + // Estimated: `3825` + // Minimum execution time: 3_647_000 picoseconds. + Weight::from_parts(3_798_000, 0) + .saturating_add(Weight::from_parts(0, 3825)) .saturating_add(T::DbWeight::get().reads(1)) } /// Storage: `Identity::Identities` (r:1 w:1) @@ -260,7 +260,7 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// Storage: `SmithMembers::Smiths` (r:3 w:3) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `AuthorityMembers::Members` (r:1 w:1) /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -274,7 +274,7 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `Certification::CertsByReceiver` (r:1 w:1) /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// Storage: `Certification::StorageIdtyCertMeta` (r:4 w:4) + /// Storage: `Certification::StorageIdtyCertMeta` (r:6 w:6) /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `Parameters::ParametersStorage` (r:1 w:0) /// Proof: `Parameters::ParametersStorage` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) @@ -286,13 +286,13 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) fn do_remove_identity() -> Weight { // Proof Size summary in bytes: - // Measured: `1990` - // Estimated: `12880` - // Minimum execution time: 110_128_000 picoseconds. - Weight::from_parts(113_248_000, 0) - .saturating_add(Weight::from_parts(0, 12880)) - .saturating_add(T::DbWeight::get().reads(21)) - .saturating_add(T::DbWeight::get().writes(26)) + // Measured: `2466` + // Estimated: `18306` + // Minimum execution time: 138_760_000 picoseconds. + Weight::from_parts(143_611_000, 0) + .saturating_add(Weight::from_parts(0, 18306)) + .saturating_add(T::DbWeight::get().reads(25)) + .saturating_add(T::DbWeight::get().writes(30)) } /// Storage: `Membership::Membership` (r:1 w:1) /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -306,7 +306,7 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) - /// Storage: `SmithMembers::Smiths` (r:3 w:3) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `AuthorityMembers::Members` (r:1 w:1) /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -322,7 +322,7 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) /// Storage: `Certification::CertsByReceiver` (r:1 w:1) /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) - /// Storage: `Certification::StorageIdtyCertMeta` (r:4 w:4) + /// Storage: `Certification::StorageIdtyCertMeta` (r:6 w:6) /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `Parameters::ParametersStorage` (r:1 w:0) /// Proof: `Parameters::ParametersStorage` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) @@ -332,13 +332,13 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) fn do_remove_identity_handler() -> Weight { // Proof Size summary in bytes: - // Measured: `1999` - // Estimated: `12889` - // Minimum execution time: 106_877_000 picoseconds. - Weight::from_parts(111_899_000, 0) - .saturating_add(Weight::from_parts(0, 12889)) - .saturating_add(T::DbWeight::get().reads(22)) - .saturating_add(T::DbWeight::get().writes(25)) + // Measured: `2483` + // Estimated: `18323` + // Minimum execution time: 136_707_000 picoseconds. + Weight::from_parts(143_456_000, 0) + .saturating_add(Weight::from_parts(0, 18323)) + .saturating_add(T::DbWeight::get().reads(26)) + .saturating_add(T::DbWeight::get().writes(29)) } /// Storage: `Identity::Identities` (r:1 w:1) /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -346,11 +346,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) fn membership_removed() -> Weight { // Proof Size summary in bytes: - // Measured: `407` - // Estimated: `6347` - // Minimum execution time: 14_063_000 picoseconds. - Weight::from_parts(14_485_000, 0) - .saturating_add(Weight::from_parts(0, 6347)) + // Measured: `441` + // Estimated: `6381` + // Minimum execution time: 14_724_000 picoseconds. + Weight::from_parts(16_749_000, 0) + .saturating_add(Weight::from_parts(0, 6381)) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(3)) } @@ -358,11 +358,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) fn prune_identities_noop() -> Weight { // Proof Size summary in bytes: - // Measured: `157` - // Estimated: `3622` - // Minimum execution time: 2_535_000 picoseconds. - Weight::from_parts(2_722_000, 0) - .saturating_add(Weight::from_parts(0, 3622)) + // Measured: `165` + // Estimated: `3630` + // Minimum execution time: 2_588_000 picoseconds. + Weight::from_parts(2_932_000, 0) + .saturating_add(Weight::from_parts(0, 3630)) .saturating_add(T::DbWeight::get().reads(1)) } /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:1) @@ -371,11 +371,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) fn prune_identities_none() -> Weight { // Proof Size summary in bytes: - // Measured: `327` - // Estimated: `3792` - // Minimum execution time: 5_830_000 picoseconds. - Weight::from_parts(6_226_000, 0) - .saturating_add(Weight::from_parts(0, 3792)) + // Measured: `362` + // Estimated: `3827` + // Minimum execution time: 5_764_000 picoseconds. + Weight::from_parts(6_068_000, 0) + .saturating_add(Weight::from_parts(0, 3827)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -397,11 +397,11 @@ impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) fn prune_identities_err() -> Weight { // Proof Size summary in bytes: - // Measured: `851` - // Estimated: `4316` - // Minimum execution time: 29_919_000 picoseconds. - Weight::from_parts(30_964_000, 0) - .saturating_add(Weight::from_parts(0, 4316)) + // Measured: `952` + // Estimated: `4417` + // Minimum execution time: 31_529_000 picoseconds. + Weight::from_parts(33_766_000, 0) + .saturating_add(Weight::from_parts(0, 4417)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(7)) } diff --git a/runtime/common/src/weights/pallet_im_online.rs b/runtime/gdev/src/weights/pallet_im_online.rs similarity index 90% rename from runtime/common/src/weights/pallet_im_online.rs rename to runtime/gdev/src/weights/pallet_im_online.rs index ce863fb2a..db3d88b83 100644 --- a/runtime/common/src/weights/pallet_im_online.rs +++ b/runtime/gdev/src/weights/pallet_im_online.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_im_online` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/gdev/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -62,13 +62,13 @@ impl<T: frame_system::Config> pallet_im_online::WeightInfo for WeightInfo<T> { /// The range of component `k` is `[1, 1000]`. fn validate_unsigned_and_then_heartbeat(k: u32, ) -> Weight { // Proof Size summary in bytes: - // Measured: `603 + k * (32 ±0)` + // Measured: `636 + k * (32 ±0)` // Estimated: `33487 + k * (1761 ±0)` - // Minimum execution time: 51_245_000 picoseconds. - Weight::from_parts(65_147_264, 0) + // Minimum execution time: 53_013_000 picoseconds. + Weight::from_parts(94_659_725, 0) .saturating_add(Weight::from_parts(0, 33487)) - // Standard Error: 668 - .saturating_add(Weight::from_parts(42_079, 0).saturating_mul(k.into())) + // Standard Error: 1_107 + .saturating_add(Weight::from_parts(26_812, 0).saturating_mul(k.into())) .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(1)) .saturating_add(Weight::from_parts(0, 1761).saturating_mul(k.into())) diff --git a/runtime/gdev/src/weights/pallet_membership.rs b/runtime/gdev/src/weights/pallet_membership.rs new file mode 100644 index 000000000..d42ec5f21 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_membership.rs @@ -0,0 +1,102 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_membership` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_membership`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_membership::WeightInfo for WeightInfo<T> { + fn on_initialize() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 82_000 picoseconds. + Weight::from_parts(93_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Membership::MembershipsExpireOn` (r:2 w:2) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:3 w:3) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Identity::Identities` (r:3 w:3) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:3 w:3) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:3 w:3) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:3 w:3) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:12) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[0, 3]`. + fn expire_memberships(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `139 + i * (993 ±0)` + // Estimated: `15060 + i * (2695 ±1)` + // Minimum execution time: 3_980_000 picoseconds. + Weight::from_parts(11_421_011, 0) + .saturating_add(Weight::from_parts(0, 15060)) + // Standard Error: 514_143 + .saturating_add(Weight::from_parts(73_178_089, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().reads((11_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((15_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2695).saturating_mul(i.into())) + } +} diff --git a/runtime/gdev/src/weights/pallet_multisig.rs b/runtime/gdev/src/weights/pallet_multisig.rs new file mode 100644 index 000000000..ae4eeb742 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_multisig.rs @@ -0,0 +1,162 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_multisig` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_multisig`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { + /// The range of component `z` is `[0, 10000]`. + fn as_multi_threshold_1(z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_784_000 picoseconds. + Weight::from_parts(5_478_578, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 5 + .saturating_add(Weight::from_parts(336, 0).saturating_mul(z.into())) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + /// The range of component `z` is `[0, 10000]`. + fn as_multi_create(s: u32, z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `125 + s * (5 ±0)` + // Estimated: `3922` + // Minimum execution time: 23_842_000 picoseconds. + Weight::from_parts(23_833_702, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 9_896 + .saturating_add(Weight::from_parts(114_314, 0).saturating_mul(s.into())) + // Standard Error: 8 + .saturating_add(Weight::from_parts(1_111, 0).saturating_mul(z.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[3, 10]`. + /// The range of component `z` is `[0, 10000]`. + fn as_multi_approve(s: u32, z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `240` + // Estimated: `3922` + // Minimum execution time: 13_662_000 picoseconds. + Weight::from_parts(13_992_378, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 7_944 + .saturating_add(Weight::from_parts(48_542, 0).saturating_mul(s.into())) + // Standard Error: 5 + .saturating_add(Weight::from_parts(1_096, 0).saturating_mul(z.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + /// The range of component `z` is `[0, 10000]`. + fn as_multi_complete(s: u32, z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `259 + s * (37 ±0)` + // Estimated: `3922` + // Minimum execution time: 26_174_000 picoseconds. + Weight::from_parts(26_448_294, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 11_430 + .saturating_add(Weight::from_parts(205_620, 0).saturating_mul(s.into())) + // Standard Error: 9 + .saturating_add(Weight::from_parts(1_102, 0).saturating_mul(z.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + fn approve_as_multi_create(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `130 + s * (5 ±0)` + // Estimated: `3922` + // Minimum execution time: 20_899_000 picoseconds. + Weight::from_parts(22_552_183, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 9_369 + .saturating_add(Weight::from_parts(285_263, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + fn approve_as_multi_approve(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `240` + // Estimated: `3922` + // Minimum execution time: 12_031_000 picoseconds. + Weight::from_parts(12_790_608, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 4_220 + .saturating_add(Weight::from_parts(139_188, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + fn cancel_as_multi(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `328 + s * (5 ±0)` + // Estimated: `3922` + // Minimum execution time: 23_347_000 picoseconds. + Weight::from_parts(24_436_321, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 6_585 + .saturating_add(Weight::from_parts(190_469, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gdev/src/weights/pallet_oneshot_account.rs b/runtime/gdev/src/weights/pallet_oneshot_account.rs new file mode 100644 index 000000000..8f665c0d3 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_oneshot_account.rs @@ -0,0 +1,94 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_oneshot_account` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_oneshot_account`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_oneshot_account::WeightInfo for WeightInfo<T> { + /// Storage: `OneshotAccount::OneshotAccounts` (r:1 w:1) + /// Proof: `OneshotAccount::OneshotAccounts` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn create_oneshot_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `42` + // Estimated: `3507` + // Minimum execution time: 19_744_000 picoseconds. + Weight::from_parts(20_725_000, 0) + .saturating_add(Weight::from_parts(0, 3507)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `OneshotAccount::OneshotAccounts` (r:1 w:1) + /// Proof: `OneshotAccount::OneshotAccounts` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn consume_oneshot_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `241` + // Estimated: `3706` + // Minimum execution time: 27_698_000 picoseconds. + Weight::from_parts(28_682_000, 0) + .saturating_add(Weight::from_parts(0, 3706)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `OneshotAccount::OneshotAccounts` (r:1 w:1) + /// Proof: `OneshotAccount::OneshotAccounts` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn consume_oneshot_account_with_remaining() -> Weight { + // Proof Size summary in bytes: + // Measured: `301` + // Estimated: `6126` + // Minimum execution time: 40_850_000 picoseconds. + Weight::from_parts(42_634_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gdev/src/weights/pallet_preimage.rs b/runtime/gdev/src/weights/pallet_preimage.rs new file mode 100644 index 000000000..f210ed089 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_preimage.rs @@ -0,0 +1,259 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_preimage` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_preimage`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 4194304]`. + fn note_preimage(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `42` + // Estimated: `3548` + // Minimum execution time: 11_214_000 picoseconds. + Weight::from_parts(11_549_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + // Standard Error: 5 + .saturating_add(Weight::from_parts(1_466, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 4194304]`. + fn note_requested_preimage(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 12_952_000 picoseconds. + Weight::from_parts(13_622_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + // Standard Error: 3 + .saturating_add(Weight::from_parts(1_405, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 4194304]`. + fn note_no_deposit_preimage(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 11_359_000 picoseconds. + Weight::from_parts(11_683_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + // Standard Error: 2 + .saturating_add(Weight::from_parts(1_478, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + fn unnote_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `172` + // Estimated: `3548` + // Minimum execution time: 27_286_000 picoseconds. + Weight::from_parts(31_206_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + fn unnote_no_deposit_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `144` + // Estimated: `3548` + // Minimum execution time: 25_257_000 picoseconds. + Weight::from_parts(27_860_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `172` + // Estimated: `3548` + // Minimum execution time: 22_414_000 picoseconds. + Weight::from_parts(30_207_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_no_deposit_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `144` + // Estimated: `3548` + // Minimum execution time: 13_918_000 picoseconds. + Weight::from_parts(16_274_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_unnoted_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `42` + // Estimated: `3548` + // Minimum execution time: 10_070_000 picoseconds. + Weight::from_parts(12_023_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_requested_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 6_702_000 picoseconds. + Weight::from_parts(7_871_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + fn unrequest_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `144` + // Estimated: `3548` + // Minimum execution time: 20_409_000 picoseconds. + Weight::from_parts(23_712_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn unrequest_unnoted_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 7_200_000 picoseconds. + Weight::from_parts(8_434_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn unrequest_multi_referenced_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 7_187_000 picoseconds. + Weight::from_parts(8_936_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1023 w:1023) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1023 w:1023) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:0 w:1023) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// The range of component `n` is `[1, 1024]`. + fn ensure_updated(n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0 + n * (179 ±0)` + // Estimated: `990 + n * (2568 ±0)` + // Minimum execution time: 16_587_000 picoseconds. + Weight::from_parts(16_890_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 42_346 + .saturating_add(Weight::from_parts(15_307_835, 0).saturating_mul(n.into())) + .saturating_add(T::DbWeight::get().reads((2_u64).saturating_mul(n.into()))) + .saturating_add(T::DbWeight::get().writes((3_u64).saturating_mul(n.into()))) + .saturating_add(Weight::from_parts(0, 2568).saturating_mul(n.into())) + } +} diff --git a/runtime/gdev/src/weights/pallet_provide_randomness.rs b/runtime/gdev/src/weights/pallet_provide_randomness.rs new file mode 100644 index 000000000..4376353c1 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_provide_randomness.rs @@ -0,0 +1,132 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_provide_randomness` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_provide_randomness`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_provide_randomness::WeightInfo for WeightInfo<T> { + /// Storage: `ProvideRandomness::CounterForRequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::CounterForRequestsIds` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestIdProvider` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestIdProvider` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::RequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsIds` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Babe::EpochIndex` (r:1 w:0) + /// Proof: `Babe::EpochIndex` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::NexEpochHookIn` (r:1 w:0) + /// Proof: `ProvideRandomness::NexEpochHookIn` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::RequestsReadyAtEpoch` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsReadyAtEpoch` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn request() -> Weight { + // Proof Size summary in bytes: + // Measured: `298` + // Estimated: `3763` + // Minimum execution time: 41_268_000 picoseconds. + Weight::from_parts(42_201_000, 0) + .saturating_add(Weight::from_parts(0, 3763)) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `ProvideRandomness::RequestsReadyAtNextBlock` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsReadyAtNextBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Babe::AuthorVrfRandomness` (r:1 w:0) + /// Proof: `Babe::AuthorVrfRandomness` (`max_values`: Some(1), `max_size`: Some(33), added: 528, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestsIds` (r:100 w:100) + /// Proof: `ProvideRandomness::RequestsIds` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::CounterForRequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::CounterForRequestsIds` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::NexEpochHookIn` (r:1 w:1) + /// Proof: `ProvideRandomness::NexEpochHookIn` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[1, 100]`. + fn on_initialize(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `341 + i * (59 ±0)` + // Estimated: `1827 + i * (2535 ±0)` + // Minimum execution time: 15_293_000 picoseconds. + Weight::from_parts(14_978_074, 0) + .saturating_add(Weight::from_parts(0, 1827)) + // Standard Error: 12_716 + .saturating_add(Weight::from_parts(5_200_150, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2535).saturating_mul(i.into())) + } + /// Storage: `ProvideRandomness::RequestsReadyAtNextBlock` (r:1 w:0) + /// Proof: `ProvideRandomness::RequestsReadyAtNextBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::NexEpochHookIn` (r:1 w:1) + /// Proof: `ProvideRandomness::NexEpochHookIn` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Babe::EpochIndex` (r:1 w:0) + /// Proof: `Babe::EpochIndex` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestsReadyAtEpoch` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsReadyAtEpoch` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Babe::NextRandomness` (r:1 w:0) + /// Proof: `Babe::NextRandomness` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Babe::EpochStart` (r:1 w:0) + /// Proof: `Babe::EpochStart` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestsIds` (r:100 w:100) + /// Proof: `ProvideRandomness::RequestsIds` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::CounterForRequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::CounterForRequestsIds` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 100]`. + fn on_initialize_epoch(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `351 + i * (59 ±0)` + // Estimated: `3817 + i * (2535 ±0)` + // Minimum execution time: 16_732_000 picoseconds. + Weight::from_parts(14_558_724, 0) + .saturating_add(Weight::from_parts(0, 3817)) + // Standard Error: 6_675 + .saturating_add(Weight::from_parts(5_500_120, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2535).saturating_mul(i.into())) + } +} diff --git a/runtime/gdev/src/weights/pallet_proxy.rs b/runtime/gdev/src/weights/pallet_proxy.rs new file mode 100644 index 000000000..0d31e0197 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_proxy.rs @@ -0,0 +1,219 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_proxy` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_proxy`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { + /// Storage: `Proxy::Proxies` (r:1 w:0) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn proxy(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 11_524_000 picoseconds. + Weight::from_parts(12_709_203, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 7_401 + .saturating_add(Weight::from_parts(43_792, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:0) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn proxy_announced(a: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `399 + a * (68 ±0) + p * (37 ±0)` + // Estimated: `5690` + // Minimum execution time: 27_208_000 picoseconds. + Weight::from_parts(29_185_186, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 3_557 + .saturating_add(Weight::from_parts(124_513, 0).saturating_mul(a.into())) + // Standard Error: 3_675 + .saturating_add(Weight::from_parts(37_800, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn remove_announcement(a: u32, _p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `322 + a * (68 ±0)` + // Estimated: `5690` + // Minimum execution time: 18_025_000 picoseconds. + Weight::from_parts(19_377_354, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 3_019 + .saturating_add(Weight::from_parts(156_538, 0).saturating_mul(a.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn reject_announcement(a: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `322 + a * (68 ±0)` + // Estimated: `5690` + // Minimum execution time: 17_751_000 picoseconds. + Weight::from_parts(19_090_708, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 2_083 + .saturating_add(Weight::from_parts(126_665, 0).saturating_mul(a.into())) + // Standard Error: 2_153 + .saturating_add(Weight::from_parts(19_945, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Proxies` (r:1 w:0) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// Storage: `Proxy::Announcements` (r:1 w:1) + /// Proof: `Proxy::Announcements` (`max_values`: None, `max_size`: Some(2225), added: 4700, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `a` is `[0, 31]`. + /// The range of component `p` is `[1, 31]`. + fn announce(a: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `331 + a * (68 ±0) + p * (37 ±0)` + // Estimated: `5690` + // Minimum execution time: 24_852_000 picoseconds. + Weight::from_parts(25_924_348, 0) + .saturating_add(Weight::from_parts(0, 5690)) + // Standard Error: 2_624 + .saturating_add(Weight::from_parts(138_483, 0).saturating_mul(a.into())) + // Standard Error: 2_711 + .saturating_add(Weight::from_parts(17_584, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn add_proxy(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 17_136_000 picoseconds. + Weight::from_parts(18_606_744, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 2_704 + .saturating_add(Weight::from_parts(46_640, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn remove_proxy(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 16_919_000 picoseconds. + Weight::from_parts(19_169_491, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 3_560 + .saturating_add(Weight::from_parts(51_942, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn remove_proxies(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `157 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 16_265_000 picoseconds. + Weight::from_parts(17_945_592, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 3_043 + .saturating_add(Weight::from_parts(49_119, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[1, 31]`. + fn create_pure(_p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `177` + // Estimated: `4698` + // Minimum execution time: 18_222_000 picoseconds. + Weight::from_parts(20_172_622, 0) + .saturating_add(Weight::from_parts(0, 4698)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Proxy::Proxies` (r:1 w:1) + /// Proof: `Proxy::Proxies` (`max_values`: None, `max_size`: Some(1233), added: 3708, mode: `MaxEncodedLen`) + /// The range of component `p` is `[0, 30]`. + fn kill_pure(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `194 + p * (37 ±0)` + // Estimated: `4698` + // Minimum execution time: 17_293_000 picoseconds. + Weight::from_parts(18_597_116, 0) + .saturating_add(Weight::from_parts(0, 4698)) + // Standard Error: 2_838 + .saturating_add(Weight::from_parts(52_690, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gdev/src/weights/pallet_quota.rs b/runtime/gdev/src/weights/pallet_quota.rs new file mode 100644 index 000000000..f56f12659 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_quota.rs @@ -0,0 +1,133 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_quota` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_quota`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_quota::WeightInfo for WeightInfo<T> { + /// Storage: `Quota::RefundQueue` (r:1 w:1) + /// Proof: `Quota::RefundQueue` (`max_values`: Some(1), `max_size`: Some(11266), added: 11761, mode: `MaxEncodedLen`) + fn queue_refund() -> Weight { + // Proof Size summary in bytes: + // Measured: `11288` + // Estimated: `12751` + // Minimum execution time: 7_398_000 picoseconds. + Weight::from_parts(7_684_000, 0) + .saturating_add(Weight::from_parts(0, 12751)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn spend_quota() -> Weight { + // Proof Size summary in bytes: + // Measured: `172` + // Estimated: `3489` + // Minimum execution time: 4_882_000 picoseconds. + Weight::from_parts(5_063_000, 0) + .saturating_add(Weight::from_parts(0, 3489)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn try_refund() -> Weight { + // Proof Size summary in bytes: + // Measured: `235` + // Estimated: `6126` + // Minimum execution time: 22_908_000 picoseconds. + Weight::from_parts(23_904_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn do_refund() -> Weight { + // Proof Size summary in bytes: + // Measured: `235` + // Estimated: `6126` + // Minimum execution time: 22_559_000 picoseconds. + Weight::from_parts(23_862_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Quota::RefundQueue` (r:1 w:1) + /// Proof: `Quota::RefundQueue` (`max_values`: Some(1), `max_size`: Some(11266), added: 11761, mode: `MaxEncodedLen`) + fn on_process_refund_queue() -> Weight { + // Proof Size summary in bytes: + // Measured: `43` + // Estimated: `12751` + // Minimum execution time: 2_089_000 picoseconds. + Weight::from_parts(2_790_000, 0) + .saturating_add(Weight::from_parts(0, 12751)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Quota::RefundQueue` (r:1 w:1) + /// Proof: `Quota::RefundQueue` (`max_values`: Some(1), `max_size`: Some(11266), added: 11761, mode: `MaxEncodedLen`) + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 256]`. + fn on_process_refund_queue_elements(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `260 + i * (44 ±0)` + // Estimated: `12751` + // Minimum execution time: 25_180_000 picoseconds. + Weight::from_parts(41_079_807, 0) + .saturating_add(Weight::from_parts(0, 12751)) + // Standard Error: 2_263 + .saturating_add(Weight::from_parts(1_281_591, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gdev/src/weights/pallet_scheduler.rs b/runtime/gdev/src/weights/pallet_scheduler.rs new file mode 100644 index 000000000..8734686d2 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_scheduler.rs @@ -0,0 +1,287 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_scheduler` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_scheduler`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { + /// Storage: `Scheduler::IncompleteSince` (r:1 w:1) + /// Proof: `Scheduler::IncompleteSince` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + fn service_agendas_base() -> Weight { + // Proof Size summary in bytes: + // Measured: `30` + // Estimated: `1489` + // Minimum execution time: 2_154_000 picoseconds. + Weight::from_parts(2_266_000, 0) + .saturating_add(Weight::from_parts(0, 1489)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 50]`. + fn service_agenda_base(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + s * (177 ±0)` + // Estimated: `13928` + // Minimum execution time: 2_722_000 picoseconds. + Weight::from_parts(5_087_987, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 1_631 + .saturating_add(Weight::from_parts(322_988, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn service_task_base() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_320_000 picoseconds. + Weight::from_parts(2_433_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Preimage::PreimageFor` (r:1 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `Measured`) + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// The range of component `s` is `[128, 4194304]`. + fn service_task_fetched(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `179 + s * (1 ±0)` + // Estimated: `3644 + s * (1 ±0)` + // Minimum execution time: 14_707_000 picoseconds. + Weight::from_parts(14_955_000, 0) + .saturating_add(Weight::from_parts(0, 3644)) + // Standard Error: 3 + .saturating_add(Weight::from_parts(919, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(Weight::from_parts(0, 1).saturating_mul(s.into())) + } + /// Storage: `Scheduler::Lookup` (r:0 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + fn service_task_named() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_614_000 picoseconds. + Weight::from_parts(3_890_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn service_task_periodic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_237_000 picoseconds. + Weight::from_parts(2_460_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + fn execute_dispatch_signed() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_477_000 picoseconds. + Weight::from_parts(1_594_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + fn execute_dispatch_unsigned() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_463_000 picoseconds. + Weight::from_parts(1_602_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 49]`. + fn schedule(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + s * (177 ±0)` + // Estimated: `13928` + // Minimum execution time: 7_295_000 picoseconds. + Weight::from_parts(10_033_530, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 2_003 + .saturating_add(Weight::from_parts(327_823, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Lookup` (r:0 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// The range of component `s` is `[1, 50]`. + fn cancel(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + s * (177 ±0)` + // Estimated: `13928` + // Minimum execution time: 11_990_000 picoseconds. + Weight::from_parts(12_341_263, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 2_216 + .saturating_add(Weight::from_parts(512_563, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 49]`. + fn schedule_named(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `254 + s * (185 ±0)` + // Estimated: `13928` + // Minimum execution time: 10_530_000 picoseconds. + Weight::from_parts(16_112_062, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 9_080 + .saturating_add(Weight::from_parts(316_461, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + /// The range of component `s` is `[1, 50]`. + fn cancel_named(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `280 + s * (185 ±0)` + // Estimated: `13928` + // Minimum execution time: 13_498_000 picoseconds. + Weight::from_parts(15_519_133, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 2_928 + .saturating_add(Weight::from_parts(540_747, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + /// The range of component `s` is `[1, 50]`. + fn schedule_retry(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `117` + // Estimated: `13928` + // Minimum execution time: 7_058_000 picoseconds. + Weight::from_parts(7_825_322, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 696 + .saturating_add(Weight::from_parts(27_002, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn set_retry() -> Weight { + // Proof Size summary in bytes: + // Measured: `8927` + // Estimated: `13928` + // Minimum execution time: 21_627_000 picoseconds. + Weight::from_parts(22_813_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:0) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn set_retry_named() -> Weight { + // Proof Size summary in bytes: + // Measured: `9605` + // Estimated: `13928` + // Minimum execution time: 27_432_000 picoseconds. + Weight::from_parts(28_396_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn cancel_retry() -> Weight { + // Proof Size summary in bytes: + // Measured: `8939` + // Estimated: `13928` + // Minimum execution time: 21_225_000 picoseconds. + Weight::from_parts(21_880_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:0) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn cancel_retry_named() -> Weight { + // Proof Size summary in bytes: + // Measured: `9617` + // Estimated: `13928` + // Minimum execution time: 25_466_000 picoseconds. + Weight::from_parts(27_062_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gdev/src/weights/pallet_session.rs b/runtime/gdev/src/weights/pallet_session.rs new file mode 100644 index 000000000..1a71741a7 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_session.rs @@ -0,0 +1,78 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_session` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_session`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_session::WeightInfo for WeightInfo<T> { + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::KeyOwner` (r:4 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn set_keys() -> Weight { + // Proof Size summary in bytes: + // Measured: `811` + // Estimated: `11701` + // Minimum execution time: 24_216_000 picoseconds. + Weight::from_parts(25_442_000, 0) + .saturating_add(Weight::from_parts(0, 11701)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn purge_keys() -> Weight { + // Proof Size summary in bytes: + // Measured: `478` + // Estimated: `3943` + // Minimum execution time: 14_589_000 picoseconds. + Weight::from_parts(15_413_000, 0) + .saturating_add(Weight::from_parts(0, 3943)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(5)) + } +} diff --git a/runtime/common/src/weights/pallet_smith_members.rs b/runtime/gdev/src/weights/pallet_smith_members.rs similarity index 82% rename from runtime/common/src/weights/pallet_smith_members.rs rename to runtime/gdev/src/weights/pallet_smith_members.rs index 8f2a1a7dc..3e8ba42ef 100644 --- a/runtime/common/src/weights/pallet_smith_members.rs +++ b/runtime/gdev/src/weights/pallet_smith_members.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_smith_members` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/gdev/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -61,11 +61,11 @@ impl<T: frame_system::Config> pallet_smith_members::WeightInfo for WeightInfo<T> /// Proof: `SmithMembers::ExpiresOn` (`max_values`: None, `max_size`: None, mode: `Measured`) fn invite_smith() -> Weight { // Proof Size summary in bytes: - // Measured: `765` - // Estimated: `6705` - // Minimum execution time: 24_537_000 picoseconds. - Weight::from_parts(25_692_000, 0) - .saturating_add(Weight::from_parts(0, 6705)) + // Measured: `945` + // Estimated: `6885` + // Minimum execution time: 27_498_000 picoseconds. + Weight::from_parts(28_218_000, 0) + .saturating_add(Weight::from_parts(0, 6885)) .saturating_add(T::DbWeight::get().reads(7)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -75,11 +75,11 @@ impl<T: frame_system::Config> pallet_smith_members::WeightInfo for WeightInfo<T> /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) fn accept_invitation() -> Weight { // Proof Size summary in bytes: - // Measured: `496` - // Estimated: `3961` - // Minimum execution time: 13_084_000 picoseconds. - Weight::from_parts(13_653_000, 0) - .saturating_add(Weight::from_parts(0, 3961)) + // Measured: `599` + // Estimated: `4064` + // Minimum execution time: 13_652_000 picoseconds. + Weight::from_parts(14_409_000, 0) + .saturating_add(Weight::from_parts(0, 4064)) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -95,15 +95,15 @@ impl<T: frame_system::Config> pallet_smith_members::WeightInfo for WeightInfo<T> /// Proof: `SmithMembers::ExpiresOn` (`max_values`: None, `max_size`: None, mode: `Measured`) fn certify_smith() -> Weight { // Proof Size summary in bytes: - // Measured: `626` - // Estimated: `6566` - // Minimum execution time: 23_286_000 picoseconds. - Weight::from_parts(24_203_000, 0) - .saturating_add(Weight::from_parts(0, 6566)) + // Measured: `755` + // Estimated: `6695` + // Minimum execution time: 25_736_000 picoseconds. + Weight::from_parts(26_782_000, 0) + .saturating_add(Weight::from_parts(0, 6695)) .saturating_add(T::DbWeight::get().reads(6)) .saturating_add(T::DbWeight::get().writes(3)) } - /// Storage: `SmithMembers::Smiths` (r:3 w:3) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) /// Storage: `AuthorityMembers::Members` (r:1 w:1) /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) @@ -121,23 +121,23 @@ impl<T: frame_system::Config> pallet_smith_members::WeightInfo for WeightInfo<T> /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) fn on_removed_wot_member() -> Weight { // Proof Size summary in bytes: - // Measured: `911` - // Estimated: `9326` - // Minimum execution time: 46_868_000 picoseconds. - Weight::from_parts(48_648_000, 0) - .saturating_add(Weight::from_parts(0, 9326)) - .saturating_add(T::DbWeight::get().reads(9)) - .saturating_add(T::DbWeight::get().writes(13)) + // Measured: `1205` + // Estimated: `14570` + // Minimum execution time: 58_535_000 picoseconds. + Weight::from_parts(60_852_000, 0) + .saturating_add(Weight::from_parts(0, 14570)) + .saturating_add(T::DbWeight::get().reads(11)) + .saturating_add(T::DbWeight::get().writes(15)) } /// Storage: `SmithMembers::Smiths` (r:1 w:0) /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) fn on_removed_wot_member_empty() -> Weight { // Proof Size summary in bytes: - // Measured: `187` - // Estimated: `3652` - // Minimum execution time: 2_780_000 picoseconds. - Weight::from_parts(2_992_000, 0) - .saturating_add(Weight::from_parts(0, 3652)) + // Measured: `253` + // Estimated: `3718` + // Minimum execution time: 2_855_000 picoseconds. + Weight::from_parts(3_130_000, 0) + .saturating_add(Weight::from_parts(0, 3718)) .saturating_add(T::DbWeight::get().reads(1)) } } diff --git a/runtime/gdev/src/weights/pallet_sudo.rs b/runtime/gdev/src/weights/pallet_sudo.rs new file mode 100644 index 000000000..bd41502fe --- /dev/null +++ b/runtime/gdev/src/weights/pallet_sudo.rs @@ -0,0 +1,96 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_sudo` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_sudo`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_sudo::WeightInfo for WeightInfo<T> { + /// Storage: `Sudo::Key` (r:1 w:1) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn set_key() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 6_629_000 picoseconds. + Weight::from_parts(7_041_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Sudo::Key` (r:1 w:0) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn sudo() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 7_361_000 picoseconds. + Weight::from_parts(7_700_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Sudo::Key` (r:1 w:0) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn sudo_as() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 7_059_000 picoseconds. + Weight::from_parts(7_604_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Sudo::Key` (r:1 w:1) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn remove_key() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 6_101_000 picoseconds. + Weight::from_parts(7_405_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/common/src/weights/pallet_timestamp.rs b/runtime/gdev/src/weights/pallet_timestamp.rs similarity index 90% rename from runtime/common/src/weights/pallet_timestamp.rs rename to runtime/gdev/src/weights/pallet_timestamp.rs index df562e804..83fff7518 100644 --- a/runtime/common/src/weights/pallet_timestamp.rs +++ b/runtime/gdev/src/weights/pallet_timestamp.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_timestamp` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/gdev/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -59,8 +59,8 @@ impl<T: frame_system::Config> pallet_timestamp::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `379` // Estimated: `1864` - // Minimum execution time: 10_293_000 picoseconds. - Weight::from_parts(11_107_000, 0) + // Minimum execution time: 10_756_000 picoseconds. + Weight::from_parts(11_365_000, 0) .saturating_add(Weight::from_parts(0, 1864)) .saturating_add(T::DbWeight::get().reads(4)) .saturating_add(T::DbWeight::get().writes(2)) @@ -69,8 +69,8 @@ impl<T: frame_system::Config> pallet_timestamp::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `57` // Estimated: `0` - // Minimum execution time: 2_400_000 picoseconds. - Weight::from_parts(2_539_000, 0) + // Minimum execution time: 2_455_000 picoseconds. + Weight::from_parts(2_619_000, 0) .saturating_add(Weight::from_parts(0, 0)) } } diff --git a/runtime/gdev/src/weights/pallet_treasury.rs b/runtime/gdev/src/weights/pallet_treasury.rs new file mode 100644 index 000000000..c6268edd1 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_treasury.rs @@ -0,0 +1,185 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_treasury` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_treasury`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { + fn spend_local() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 0_000 picoseconds. + Weight::from_parts(0, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Treasury::ProposalCount` (r:1 w:1) + /// Proof: `Treasury::ProposalCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Proposals` (r:0 w:1) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + fn propose_spend() -> Weight { + // Proof Size summary in bytes: + // Measured: `67` + // Estimated: `1489` + // Minimum execution time: 16_849_000 picoseconds. + Weight::from_parts(17_913_000, 0) + .saturating_add(Weight::from_parts(0, 1489)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Treasury::Proposals` (r:1 w:1) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn reject_proposal() -> Weight { + // Proof Size summary in bytes: + // Measured: `272` + // Estimated: `6126` + // Minimum execution time: 28_376_000 picoseconds. + Weight::from_parts(28_874_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Treasury::Proposals` (r:1 w:0) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Approvals` (r:1 w:1) + /// Proof: `Treasury::Approvals` (`max_values`: Some(1), `max_size`: Some(402), added: 897, mode: `MaxEncodedLen`) + /// The range of component `p` is `[0, 99]`. + fn approve_proposal(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `433 + p * (8 ±0)` + // Estimated: `3557` + // Minimum execution time: 6_009_000 picoseconds. + Weight::from_parts(10_044_708, 0) + .saturating_add(Weight::from_parts(0, 3557)) + // Standard Error: 2_984 + .saturating_add(Weight::from_parts(53_007, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Treasury::Approvals` (r:1 w:1) + /// Proof: `Treasury::Approvals` (`max_values`: Some(1), `max_size`: Some(402), added: 897, mode: `MaxEncodedLen`) + fn remove_approval() -> Weight { + // Proof Size summary in bytes: + // Measured: `90` + // Estimated: `1887` + // Minimum execution time: 4_334_000 picoseconds. + Weight::from_parts(4_655_000, 0) + .saturating_add(Weight::from_parts(0, 1887)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:199 w:199) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Deactivated` (r:1 w:1) + /// Proof: `Treasury::Deactivated` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Approvals` (r:1 w:1) + /// Proof: `Treasury::Approvals` (`max_values`: Some(1), `max_size`: Some(402), added: 897, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Proposals` (r:99 w:99) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + /// The range of component `p` is `[0, 99]`. + fn on_initialize_proposals(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `24 + p * (196 ±0)` + // Estimated: `3558 + p * (5136 ±0)` + // Minimum execution time: 11_800_000 picoseconds. + Weight::from_parts(75_599_705, 0) + .saturating_add(Weight::from_parts(0, 3558)) + // Standard Error: 104_779 + .saturating_add(Weight::from_parts(25_030_979, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().reads((3_u64).saturating_mul(p.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((3_u64).saturating_mul(p.into()))) + .saturating_add(Weight::from_parts(0, 5136).saturating_mul(p.into())) + } + fn spend() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 0_000 picoseconds. + Weight::from_parts(0, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Treasury::Spends` (r:1 w:1) + /// Proof: `Treasury::Spends` (`max_values`: None, `max_size`: Some(61), added: 2536, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn payout() -> Weight { + // Proof Size summary in bytes: + // Measured: `179` + // Estimated: `6126` + // Minimum execution time: 40_548_000 picoseconds. + Weight::from_parts(41_351_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Treasury::Spends` (r:1 w:1) + /// Proof: `Treasury::Spends` (`max_values`: None, `max_size`: Some(61), added: 2536, mode: `MaxEncodedLen`) + fn check_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `116` + // Estimated: `3526` + // Minimum execution time: 8_609_000 picoseconds. + Weight::from_parts(9_020_000, 0) + .saturating_add(Weight::from_parts(0, 3526)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Treasury::Spends` (r:1 w:1) + /// Proof: `Treasury::Spends` (`max_values`: None, `max_size`: Some(61), added: 2536, mode: `MaxEncodedLen`) + fn void_spend() -> Weight { + // Proof Size summary in bytes: + // Measured: `116` + // Estimated: `3526` + // Minimum execution time: 7_562_000 picoseconds. + Weight::from_parts(7_952_000, 0) + .saturating_add(Weight::from_parts(0, 3526)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gdev/src/weights/pallet_universal_dividend.rs b/runtime/gdev/src/weights/pallet_universal_dividend.rs new file mode 100644 index 000000000..201659809 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_universal_dividend.rs @@ -0,0 +1,118 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_universal_dividend` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_universal_dividend`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_universal_dividend::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `UniversalDividend::PastReevals` (r:1 w:0) + /// Proof: `UniversalDividend::PastReevals` (`max_values`: Some(1), `max_size`: Some(1602), added: 2097, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 160]`. + fn claim_uds(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `709` + // Estimated: `4174` + // Minimum execution time: 29_671_000 picoseconds. + Weight::from_parts(31_728_203, 0) + .saturating_add(Weight::from_parts(0, 4174)) + // Standard Error: 547 + .saturating_add(Weight::from_parts(3_509, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `UniversalDividend::CurrentUd` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUd` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_ud() -> Weight { + // Proof Size summary in bytes: + // Measured: `156` + // Estimated: `6126` + // Minimum execution time: 52_946_000 picoseconds. + Weight::from_parts(54_540_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `UniversalDividend::CurrentUd` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUd` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_ud_keep_alive() -> Weight { + // Proof Size summary in bytes: + // Measured: `93` + // Estimated: `3558` + // Minimum execution time: 32_583_000 picoseconds. + Weight::from_parts(33_824_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `UniversalDividend::PastReevals` (r:1 w:0) + /// Proof: `UniversalDividend::PastReevals` (`max_values`: Some(1), `max_size`: Some(1602), added: 2097, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 160]`. + fn on_removed_member(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `181` + // Estimated: `3558` + // Minimum execution time: 17_276_000 picoseconds. + Weight::from_parts(18_756_758, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gdev/src/weights/pallet_upgrade_origin.rs b/runtime/gdev/src/weights/pallet_upgrade_origin.rs new file mode 100644 index 000000000..583d19c54 --- /dev/null +++ b/runtime/gdev/src/weights/pallet_upgrade_origin.rs @@ -0,0 +1,58 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_upgrade_origin` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_upgrade_origin`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_upgrade_origin::WeightInfo for WeightInfo<T> { + fn dispatch_as_root() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_779_000 picoseconds. + Weight::from_parts(5_013_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } +} diff --git a/runtime/gdev/src/weights/pallet_utility.rs b/runtime/gdev/src/weights/pallet_utility.rs new file mode 100644 index 000000000..dd1fcee6b --- /dev/null +++ b/runtime/gdev/src/weights/pallet_utility.rs @@ -0,0 +1,99 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_utility` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gdev/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_utility`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_utility::WeightInfo for WeightInfo<T> { + /// The range of component `c` is `[0, 1000]`. + fn batch(c: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_394_000 picoseconds. + Weight::from_parts(3_775_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 11_495 + .saturating_add(Weight::from_parts(2_170_944, 0).saturating_mul(c.into())) + } + fn as_derivative() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_828_000 picoseconds. + Weight::from_parts(3_111_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `c` is `[0, 1000]`. + fn batch_all(c: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_776_000 picoseconds. + Weight::from_parts(3_860_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 25_284 + .saturating_add(Weight::from_parts(2_582_062, 0).saturating_mul(c.into())) + } + fn dispatch_as() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_561_000 picoseconds. + Weight::from_parts(5_028_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `c` is `[0, 1000]`. + fn force_batch(c: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_552_000 picoseconds. + Weight::from_parts(15_414_514, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 20_608 + .saturating_add(Weight::from_parts(2_203_524, 0).saturating_mul(c.into())) + } +} diff --git a/runtime/common/src/weights/paritydb_weights.rs b/runtime/gdev/src/weights/paritydb_weights.rs similarity index 79% rename from runtime/common/src/weights/paritydb_weights.rs rename to runtime/gdev/src/weights/paritydb_weights.rs index 972f0dca3..1968d2d40 100644 --- a/runtime/common/src/weights/paritydb_weights.rs +++ b/runtime/gdev/src/weights/paritydb_weights.rs @@ -1,13 +1,13 @@ //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13 (Y/M/D) +//! DATE: 2024-06-21 (Y/M/D) //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! //! DATABASE: `ParityDb`, RUNTIME: `Ğdev Local Testnet` //! BLOCK-NUM: `BlockId::Number(0)` //! SKIP-WRITE: `false`, SKIP-READ: `false`, WARMUPS: `1` //! STATE-VERSION: `V1`, STATE-CACHE-SIZE: `` -//! WEIGHT-PATH: `./runtime/common/src/weights/` +//! WEIGHT-PATH: `./runtime/gdev/src/weights/` //! METRIC: `Average`, WEIGHT-MUL: `2.0`, WEIGHT-ADD: `0` // Executed Command: @@ -16,7 +16,7 @@ // storage // --chain=dev // --mul=2 -// --weight-path=./runtime/common/src/weights/ +// --weight-path=./runtime/gdev/src/weights/ // --state-version=1 /// Storage DB weights for the `Ğdev Local Testnet` runtime and `ParityDb`. @@ -33,31 +33,31 @@ pub mod constants { /// Calculated by multiplying the *Average* of all values with `2.0` and adding `0`. /// /// Stats nanoseconds: - /// Min, Max: 794, 1_098_997 - /// Average: 9_893 - /// Median: 1_232 - /// Std-Dev: 95894.03 + /// Min, Max: 799, 1_016_931 + /// Average: 7_978 + /// Median: 1_388 + /// Std-Dev: 80020.79 /// /// Percentiles nanoseconds: - /// 99th: 9_401 - /// 95th: 2_655 - /// 75th: 1_565 - read: 19_786 * constants::WEIGHT_REF_TIME_PER_NANOS, + /// 99th: 11_180 + /// 95th: 2_941 + /// 75th: 1_891 + read: 15_956 * constants::WEIGHT_REF_TIME_PER_NANOS, /// Time to write one storage item. /// Calculated by multiplying the *Average* of all values with `2.0` and adding `0`. /// /// Stats nanoseconds: - /// Min, Max: 3_685, 6_605_999 - /// Average: 59_740 - /// Median: 8_551 - /// Std-Dev: 576372.47 + /// Min, Max: 3_838, 7_114_419 + /// Average: 54_186 + /// Median: 9_826 + /// Std-Dev: 559921.2 /// /// Percentiles nanoseconds: - /// 99th: 18_887 - /// 95th: 13_172 - /// 75th: 11_273 - write: 119_480 * constants::WEIGHT_REF_TIME_PER_NANOS, + /// 99th: 22_807 + /// 95th: 13_848 + /// 75th: 12_109 + write: 108_372 * constants::WEIGHT_REF_TIME_PER_NANOS, }; } diff --git a/runtime/gtest/src/lib.rs b/runtime/gtest/src/lib.rs index 0a19c2e4b..356b288ac 100644 --- a/runtime/gtest/src/lib.rs +++ b/runtime/gtest/src/lib.rs @@ -27,6 +27,7 @@ include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs")); extern crate frame_benchmarking; pub mod parameters; +pub mod weights; pub use self::parameters::*; use common_runtime::IdtyNameValidatorImpl; @@ -66,6 +67,7 @@ use sp_std::prelude::*; #[cfg(feature = "std")] use sp_version::NativeVersion; use sp_version::RuntimeVersion; +pub use weights::paritydb_weights::constants::ParityDbWeight as DbWeight; // A few exports that help ease life for downstream crates. use frame_support::instances::Instance2; diff --git a/runtime/gtest/src/weights.rs b/runtime/gtest/src/weights.rs new file mode 100644 index 000000000..1bf51bdbb --- /dev/null +++ b/runtime/gtest/src/weights.rs @@ -0,0 +1,52 @@ +// Copyright 2021 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(clippy::unnecessary_cast)] +#![allow(unused_doc_comments)] + +pub mod block_weights; +pub mod extrinsic_weights; +pub mod frame_system; +pub mod pallet_babe; +pub mod pallet_balances; +pub mod pallet_collective; +pub mod pallet_distance; +pub mod pallet_grandpa; +pub mod pallet_im_online; +pub mod pallet_multisig; +pub mod pallet_proxy; +pub mod pallet_session; +pub mod pallet_scheduler; +pub mod pallet_timestamp; +pub mod pallet_treasury; +pub mod pallet_universal_dividend; +pub mod pallet_upgrade_origin; +pub mod pallet_provide_randomness; +pub mod pallet_identity; +pub mod pallet_preimage; +pub mod pallet_utility; +pub mod pallet_duniter_account; +pub mod pallet_quota; +pub mod pallet_oneshot_account; +pub mod pallet_certification; +pub mod pallet_membership; +pub mod pallet_smith_members; +pub mod pallet_sudo; +pub mod pallet_authority_members; +pub mod paritydb_weights; diff --git a/runtime/gtest/src/weights/block_weights.rs b/runtime/gtest/src/weights/block_weights.rs new file mode 100644 index 000000000..15a553912 --- /dev/null +++ b/runtime/gtest/src/weights/block_weights.rs @@ -0,0 +1,64 @@ + +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21 (Y/M/D) +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! +//! SHORT-NAME: `block`, LONG-NAME: `BlockExecution`, RUNTIME: `ĞTest Local Testnet` +//! WARMUPS: `10`, REPEAT: `100` +//! WEIGHT-PATH: `./runtime/gtest/src/weights/` +//! WEIGHT-METRIC: `Average`, WEIGHT-MUL: `1.0`, WEIGHT-ADD: `0` + +// Executed Command: +// target/release/duniter +// benchmark +// overhead +// --chain=dev +// --wasm-execution=compiled +// --weight-path=./runtime/gtest/src/weights/ +// --warmup=10 +// --repeat=100 + +use sp_core::parameter_types; +use sp_weights::{constants::WEIGHT_REF_TIME_PER_NANOS, Weight}; + +parameter_types! { + /// Time to execute an empty block. + /// Calculated by multiplying the *Average* with `1.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 128_084, 165_150 + /// Average: 137_255 + /// Median: 135_968 + /// Std-Dev: 6290.75 + /// + /// Percentiles nanoseconds: + /// 99th: 163_670 + /// 95th: 149_330 + /// 75th: 137_810 + pub const BlockExecutionWeight: Weight = + Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(137_255), 0); +} + +#[cfg(test)] +mod test_weights { + use sp_weights::constants; + + /// Checks that the weight exists and is sane. + // NOTE: If this test fails but you are sure that the generated values are fine, + // you can delete it. + #[test] + fn sane() { + let w = super::BlockExecutionWeight::get(); + + // At least 100 µs. + assert!( + w.ref_time() >= 100u64 * constants::WEIGHT_REF_TIME_PER_MICROS, + "Weight should be at least 100 µs." + ); + // At most 50 ms. + assert!( + w.ref_time() <= 50u64 * constants::WEIGHT_REF_TIME_PER_MILLIS, + "Weight should be at most 50 ms." + ); + } +} diff --git a/runtime/gtest/src/weights/extrinsic_weights.rs b/runtime/gtest/src/weights/extrinsic_weights.rs new file mode 100644 index 000000000..5328d64d4 --- /dev/null +++ b/runtime/gtest/src/weights/extrinsic_weights.rs @@ -0,0 +1,64 @@ + +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21 (Y/M/D) +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! +//! SHORT-NAME: `extrinsic`, LONG-NAME: `ExtrinsicBase`, RUNTIME: `ĞTest Local Testnet` +//! WARMUPS: `10`, REPEAT: `100` +//! WEIGHT-PATH: `./runtime/gtest/src/weights/` +//! WEIGHT-METRIC: `Average`, WEIGHT-MUL: `1.0`, WEIGHT-ADD: `0` + +// Executed Command: +// target/release/duniter +// benchmark +// overhead +// --chain=dev +// --wasm-execution=compiled +// --weight-path=./runtime/gtest/src/weights/ +// --warmup=10 +// --repeat=100 + +use sp_core::parameter_types; +use sp_weights::{constants::WEIGHT_REF_TIME_PER_NANOS, Weight}; + +parameter_types! { + /// Time to execute a NO-OP extrinsic, for example `System::remark`. + /// Calculated by multiplying the *Average* with `1.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 91_833, 100_887 + /// Average: 93_961 + /// Median: 93_414 + /// Std-Dev: 1767.34 + /// + /// Percentiles nanoseconds: + /// 99th: 99_757 + /// 95th: 97_829 + /// 75th: 94_487 + pub const ExtrinsicBaseWeight: Weight = + Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS.saturating_mul(93_961), 0); +} + +#[cfg(test)] +mod test_weights { + use sp_weights::constants; + + /// Checks that the weight exists and is sane. + // NOTE: If this test fails but you are sure that the generated values are fine, + // you can delete it. + #[test] + fn sane() { + let w = super::ExtrinsicBaseWeight::get(); + + // At least 10 µs. + assert!( + w.ref_time() >= 10u64 * constants::WEIGHT_REF_TIME_PER_MICROS, + "Weight should be at least 10 µs." + ); + // At most 1 ms. + assert!( + w.ref_time() <= constants::WEIGHT_REF_TIME_PER_MILLIS, + "Weight should be at most 1 ms." + ); + } +} diff --git a/runtime/gtest/src/weights/frame_benchmarking_baseline.rs b/runtime/gtest/src/weights/frame_benchmarking_baseline.rs new file mode 100644 index 000000000..d24022c72 --- /dev/null +++ b/runtime/gtest/src/weights/frame_benchmarking_baseline.rs @@ -0,0 +1,105 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `frame_benchmarking::baseline` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `frame_benchmarking::baseline`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> frame_benchmarking::baseline::WeightInfo for WeightInfo<T> { + /// The range of component `i` is `[0, 1000000]`. + fn addition(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 80_000 picoseconds. + Weight::from_parts(102_931, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 1000000]`. + fn subtraction(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 81_000 picoseconds. + Weight::from_parts(105_621, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 1000000]`. + fn multiplication(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 83_000 picoseconds. + Weight::from_parts(107_233, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 1000000]`. + fn division(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 80_000 picoseconds. + Weight::from_parts(106_675, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + fn hashing() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 22_167_867_000 picoseconds. + Weight::from_parts(22_418_255_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `i` is `[0, 100]`. + fn sr25519_verification(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 86_000 picoseconds. + Weight::from_parts(18_020_613, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 134_055 + .saturating_add(Weight::from_parts(36_547_361, 0).saturating_mul(i.into())) + } +} diff --git a/runtime/gtest/src/weights/frame_system.rs b/runtime/gtest/src/weights/frame_system.rs new file mode 100644 index 000000000..2580f9ea2 --- /dev/null +++ b/runtime/gtest/src/weights/frame_system.rs @@ -0,0 +1,171 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `frame_system` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `frame_system`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> frame_system::WeightInfo for WeightInfo<T> { + /// The range of component `b` is `[0, 3932160]`. + fn remark(b: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_489_000 picoseconds. + Weight::from_parts(1_562_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 0 + .saturating_add(Weight::from_parts(273, 0).saturating_mul(b.into())) + } + /// The range of component `b` is `[0, 3932160]`. + fn remark_with_event(b: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_279_000 picoseconds. + Weight::from_parts(4_499_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 1 + .saturating_add(Weight::from_parts(1_107, 0).saturating_mul(b.into())) + } + /// Storage: `System::Digest` (r:1 w:1) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: UNKNOWN KEY `0x3a686561707061676573` (r:0 w:1) + /// Proof: UNKNOWN KEY `0x3a686561707061676573` (r:0 w:1) + fn set_heap_pages() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `1485` + // Minimum execution time: 2_487_000 picoseconds. + Weight::from_parts(2_849_000, 0) + .saturating_add(Weight::from_parts(0, 1485)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `System::Digest` (r:1 w:1) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + /// Proof: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + fn set_code() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `1485` + // Minimum execution time: 66_301_550_000 picoseconds. + Weight::from_parts(67_251_386_000, 0) + .saturating_add(Weight::from_parts(0, 1485)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Skipped::Metadata` (r:0 w:0) + /// Proof: `Skipped::Metadata` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[0, 1000]`. + fn set_storage(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_504_000 picoseconds. + Weight::from_parts(1_674_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 598 + .saturating_add(Weight::from_parts(573_238, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + } + /// Storage: `Skipped::Metadata` (r:0 w:0) + /// Proof: `Skipped::Metadata` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[0, 1000]`. + fn kill_storage(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_505_000 picoseconds. + Weight::from_parts(1_586_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 658 + .saturating_add(Weight::from_parts(448_595, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + } + /// Storage: `Skipped::Metadata` (r:0 w:0) + /// Proof: `Skipped::Metadata` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `p` is `[0, 1000]`. + fn kill_prefix(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + p * (69 ±0)` + // Estimated: `76 + p * (70 ±0)` + // Minimum execution time: 2_924_000 picoseconds. + Weight::from_parts(3_085_000, 0) + .saturating_add(Weight::from_parts(0, 76)) + // Standard Error: 919 + .saturating_add(Weight::from_parts(918_163, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) + .saturating_add(Weight::from_parts(0, 70).saturating_mul(p.into())) + } + /// Storage: `System::AuthorizedUpgrade` (r:0 w:1) + /// Proof: `System::AuthorizedUpgrade` (`max_values`: Some(1), `max_size`: Some(33), added: 528, mode: `MaxEncodedLen`) + fn authorize_upgrade() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 8_308_000 picoseconds. + Weight::from_parts(11_151_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::AuthorizedUpgrade` (r:1 w:1) + /// Proof: `System::AuthorizedUpgrade` (`max_values`: Some(1), `max_size`: Some(33), added: 528, mode: `MaxEncodedLen`) + /// Storage: `System::Digest` (r:1 w:1) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + /// Proof: UNKNOWN KEY `0x3a636f6465` (r:0 w:1) + fn apply_authorized_upgrade() -> Weight { + // Proof Size summary in bytes: + // Measured: `22` + // Estimated: `1518` + // Minimum execution time: 70_799_774_000 picoseconds. + Weight::from_parts(72_338_014_000, 0) + .saturating_add(Weight::from_parts(0, 1518)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gtest/src/weights/pallet_authority_members.rs b/runtime/gtest/src/weights/pallet_authority_members.rs new file mode 100644 index 000000000..535032602 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_authority_members.rs @@ -0,0 +1,156 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_authority_members` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_authority_members`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_authority_members::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:0) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn go_offline() -> Weight { + // Proof Size summary in bytes: + // Measured: `933` + // Estimated: `4398` + // Minimum execution time: 19_721_000 picoseconds. + Weight::from_parts(20_304_000, 0) + .saturating_add(Weight::from_parts(0, 4398)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Blacklist` (r:1 w:0) + /// Proof: `AuthorityMembers::Blacklist` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:0) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:0) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:0) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn go_online() -> Weight { + // Proof Size summary in bytes: + // Measured: `1389` + // Estimated: `4854` + // Minimum execution time: 25_990_000 picoseconds. + Weight::from_parts(27_050_000, 0) + .saturating_add(Weight::from_parts(0, 4854)) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:0) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::KeyOwner` (r:4 w:0) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:0 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn set_session_keys() -> Weight { + // Proof Size summary in bytes: + // Measured: `1838` + // Estimated: `12728` + // Minimum execution time: 34_494_000 picoseconds. + Weight::from_parts(36_657_000, 0) + .saturating_add(Weight::from_parts(0, 12728)) + .saturating_add(T::DbWeight::get().reads(8)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn remove_member() -> Weight { + // Proof Size summary in bytes: + // Measured: `847` + // Estimated: `4312` + // Minimum execution time: 33_836_000 picoseconds. + Weight::from_parts(35_203_000, 0) + .saturating_add(Weight::from_parts(0, 4312)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(10)) + } + /// Storage: `AuthorityMembers::Blacklist` (r:1 w:1) + /// Proof: `AuthorityMembers::Blacklist` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn remove_member_from_blacklist() -> Weight { + // Proof Size summary in bytes: + // Measured: `199` + // Estimated: `1684` + // Minimum execution time: 7_082_000 picoseconds. + Weight::from_parts(7_536_000, 0) + .saturating_add(Weight::from_parts(0, 1684)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_babe.rs b/runtime/gtest/src/weights/pallet_babe.rs new file mode 100644 index 000000000..caa37df09 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_babe.rs @@ -0,0 +1,54 @@ +// Copyright 2021 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Manual weights for the GRANDPA Pallet in duniter runtimes +//! This file was not auto-generated. + +use frame_support::{ + traits::Get, + weights::{ + constants::{WEIGHT_REF_TIME_PER_MICROS, WEIGHT_REF_TIME_PER_NANOS}, + Weight, + }, +}; +use sp_std::marker::PhantomData; + +/// Weight functions for `pallet_babe`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_babe::WeightInfo for WeightInfo<T> { + fn plan_config_change() -> Weight { + T::DbWeight::get().writes(1) + } + + fn report_equivocation(validator_count: u32, _p: u32) -> Weight { + // we take the validator set count from the membership proof to + // calculate the weight but we set a floor of 100 validators. + let validator_count = validator_count.max(100) as u64; + + // checking membership proof + (Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 35) + .saturating_add( + (Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS, 0) * 175) + .saturating_mul(validator_count), + ) + .saturating_add(T::DbWeight::get().reads(5)) + // check equivocation proof + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 110) + // report offence + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 110) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gtest/src/weights/pallet_balances.rs b/runtime/gtest/src/weights/pallet_balances.rs new file mode 100644 index 000000000..bbb351b22 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_balances.rs @@ -0,0 +1,142 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_balances` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_balances`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_balances::WeightInfo for WeightInfo<T> { + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_allow_death() -> Weight { + // Proof Size summary in bytes: + // Measured: `63` + // Estimated: `6126` + // Minimum execution time: 49_147_000 picoseconds. + Weight::from_parts(50_032_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_keep_alive() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3558` + // Minimum execution time: 30_048_000 picoseconds. + Weight::from_parts(31_020_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_set_balance_creating() -> Weight { + // Proof Size summary in bytes: + // Measured: `134` + // Estimated: `3558` + // Minimum execution time: 9_760_000 picoseconds. + Weight::from_parts(10_610_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_set_balance_killing() -> Weight { + // Proof Size summary in bytes: + // Measured: `134` + // Estimated: `3558` + // Minimum execution time: 14_190_000 picoseconds. + Weight::from_parts(14_765_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:3 w:3) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_transfer() -> Weight { + // Proof Size summary in bytes: + // Measured: `126` + // Estimated: `8694` + // Minimum execution time: 50_544_000 picoseconds. + Weight::from_parts(52_315_000, 0) + .saturating_add(Weight::from_parts(0, 8694)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_all() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3558` + // Minimum execution time: 37_937_000 picoseconds. + Weight::from_parts(38_824_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn force_unreserve() -> Weight { + // Proof Size summary in bytes: + // Measured: `134` + // Estimated: `3558` + // Minimum execution time: 12_707_000 picoseconds. + Weight::from_parts(13_261_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn force_adjust_total_issuance() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_280_000 picoseconds. + Weight::from_parts(4_722_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } +} diff --git a/runtime/gtest/src/weights/pallet_certification.rs b/runtime/gtest/src/weights/pallet_certification.rs new file mode 100644 index 000000000..dc37183cf --- /dev/null +++ b/runtime/gtest/src/weights/pallet_certification.rs @@ -0,0 +1,191 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_certification` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_certification`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_certification::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsRemovableOn` (r:1 w:1) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn add_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `996` + // Estimated: `6936` + // Minimum execution time: 34_093_000 picoseconds. + Weight::from_parts(34_925_000, 0) + .saturating_add(Weight::from_parts(0, 6936)) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1 w:1) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsRemovableOn` (r:1 w:1) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn renew_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `1019` + // Estimated: `6959` + // Minimum execution time: 30_778_000 picoseconds. + Weight::from_parts(31_841_000, 0) + .saturating_add(Weight::from_parts(0, 6959)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn del_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `2259` + // Estimated: `15624` + // Minimum execution time: 105_452_000 picoseconds. + Weight::from_parts(110_814_000, 0) + .saturating_add(Weight::from_parts(0, 15624)) + .saturating_add(T::DbWeight::get().reads(20)) + .saturating_add(T::DbWeight::get().writes(23)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1000 w:1000) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[2, 1000]`. + fn remove_all_certs_received_by(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `554 + i * (35 ±0)` + // Estimated: `4018 + i * (2511 ±0)` + // Minimum execution time: 22_654_000 picoseconds. + Weight::from_parts(23_630_000, 0) + .saturating_add(Weight::from_parts(0, 4018)) + // Standard Error: 26_249 + .saturating_add(Weight::from_parts(8_724_228, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2511).saturating_mul(i.into())) + } + /// Storage: `Certification::CertsRemovableOn` (r:1 w:0) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn on_initialize() -> Weight { + // Proof Size summary in bytes: + // Measured: `138` + // Estimated: `3603` + // Minimum execution time: 2_604_000 picoseconds. + Weight::from_parts(2_830_000, 0) + .saturating_add(Weight::from_parts(0, 3603)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_cert_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `275` + // Estimated: `3740` + // Minimum execution time: 3_623_000 picoseconds. + Weight::from_parts(3_837_000, 0) + .saturating_add(Weight::from_parts(0, 3740)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_cert() -> Weight { + // Proof Size summary in bytes: + // Measured: `711` + // Estimated: `6651` + // Minimum execution time: 19_370_000 picoseconds. + Weight::from_parts(20_860_000, 0) + .saturating_add(Weight::from_parts(0, 6651)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gtest/src/weights/pallet_collective.rs b/runtime/gtest/src/weights/pallet_collective.rs new file mode 100644 index 000000000..74b5184e4 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_collective.rs @@ -0,0 +1,302 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_collective` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_collective`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_collective::WeightInfo for WeightInfo<T> { + /// Storage: `TechnicalCommittee::Members` (r:1 w:1) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:0) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:20 w:20) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Prime` (r:0 w:1) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[0, 100]`. + /// The range of component `n` is `[0, 100]`. + /// The range of component `p` is `[0, 20]`. + fn set_members(m: u32, _n: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0 + m * (672 ±0) + p * (3191 ±0)` + // Estimated: `10019 + m * (416 ±4) + p * (4183 ±23)` + // Minimum execution time: 11_698_000 picoseconds. + Weight::from_parts(11_860_000, 0) + .saturating_add(Weight::from_parts(0, 10019)) + // Standard Error: 9_352 + .saturating_add(Weight::from_parts(701_006, 0).saturating_mul(m.into())) + // Standard Error: 46_230 + .saturating_add(Weight::from_parts(6_187_701, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(p.into()))) + .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(p.into()))) + .saturating_add(Weight::from_parts(0, 416).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 4183).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[1, 100]`. + fn execute(b: u32, m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `32 + m * (32 ±0)` + // Estimated: `1518 + m * (32 ±0)` + // Minimum execution time: 9_813_000 picoseconds. + Weight::from_parts(9_659_301, 0) + .saturating_add(Weight::from_parts(0, 1518)) + // Standard Error: 148 + .saturating_add(Weight::from_parts(1_416, 0).saturating_mul(b.into())) + // Standard Error: 1_531 + .saturating_add(Weight::from_parts(12_443, 0).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:0) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[1, 100]`. + fn propose_execute(b: u32, m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `32 + m * (32 ±0)` + // Estimated: `3498 + m * (32 ±0)` + // Minimum execution time: 11_695_000 picoseconds. + Weight::from_parts(11_202_995, 0) + .saturating_add(Weight::from_parts(0, 3498)) + // Standard Error: 191 + .saturating_add(Weight::from_parts(1_914, 0).saturating_mul(b.into())) + // Standard Error: 1_973 + .saturating_add(Weight::from_parts(20_367, 0).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalCount` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalCount` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[2, 100]`. + /// The range of component `p` is `[1, 20]`. + fn propose_proposed(b: u32, m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `24 + m * (32 ±0) + p * (55 ±0)` + // Estimated: `3461 + m * (32 ±0) + p * (54 ±0)` + // Minimum execution time: 16_830_000 picoseconds. + Weight::from_parts(15_964_970, 0) + .saturating_add(Weight::from_parts(0, 3461)) + // Standard Error: 117 + .saturating_add(Weight::from_parts(2_547, 0).saturating_mul(b.into())) + // Standard Error: 1_229 + .saturating_add(Weight::from_parts(17_423, 0).saturating_mul(m.into())) + // Standard Error: 6_142 + .saturating_add(Weight::from_parts(256_168, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(4)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 54).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[5, 100]`. + fn vote(m: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `573 + m * (64 ±0)` + // Estimated: `4037 + m * (64 ±0)` + // Minimum execution time: 14_713_000 picoseconds. + Weight::from_parts(16_226_095, 0) + .saturating_add(Weight::from_parts(0, 4037)) + // Standard Error: 1_695 + .saturating_add(Weight::from_parts(32_697, 0).saturating_mul(m.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_early_disapproved(m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `117 + m * (64 ±0) + p * (55 ±0)` + // Estimated: `3591 + m * (64 ±0) + p * (55 ±0)` + // Minimum execution time: 19_603_000 picoseconds. + Weight::from_parts(15_929_072, 0) + .saturating_add(Weight::from_parts(0, 3591)) + // Standard Error: 2_936 + .saturating_add(Weight::from_parts(57_993, 0).saturating_mul(m.into())) + // Standard Error: 14_499 + .saturating_add(Weight::from_parts(284_316, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 55).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_early_approved(b: u32, m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `62 + b * (1 ±0) + m * (64 ±0) + p * (78 ±0)` + // Estimated: `3619 + b * (1 ±0) + m * (63 ±0) + p * (74 ±0)` + // Minimum execution time: 28_135_000 picoseconds. + Weight::from_parts(27_787_764, 0) + .saturating_add(Weight::from_parts(0, 3619)) + // Standard Error: 193 + .saturating_add(Weight::from_parts(2_341, 0).saturating_mul(b.into())) + // Standard Error: 2_047 + .saturating_add(Weight::from_parts(7_123, 0).saturating_mul(m.into())) + // Standard Error: 10_100 + .saturating_add(Weight::from_parts(340_508, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) + .saturating_add(Weight::from_parts(0, 63).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 74).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_disapproved(m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `137 + m * (64 ±0) + p * (55 ±0)` + // Estimated: `3611 + m * (64 ±0) + p * (55 ±0)` + // Minimum execution time: 21_501_000 picoseconds. + Weight::from_parts(19_516_330, 0) + .saturating_add(Weight::from_parts(0, 3611)) + // Standard Error: 1_611 + .saturating_add(Weight::from_parts(36_726, 0).saturating_mul(m.into())) + // Standard Error: 7_958 + .saturating_add(Weight::from_parts(281_108, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 64).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 55).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Voting` (r:1 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Members` (r:1 w:0) + /// Proof: `TechnicalCommittee::Members` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Prime` (r:1 w:0) + /// Proof: `TechnicalCommittee::Prime` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:1 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `b` is `[2, 1024]`. + /// The range of component `m` is `[4, 100]`. + /// The range of component `p` is `[1, 20]`. + fn close_approved(b: u32, m: u32, p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `82 + b * (1 ±0) + m * (64 ±0) + p * (78 ±0)` + // Estimated: `3639 + b * (1 ±0) + m * (63 ±0) + p * (74 ±0)` + // Minimum execution time: 29_042_000 picoseconds. + Weight::from_parts(27_246_680, 0) + .saturating_add(Weight::from_parts(0, 3639)) + // Standard Error: 161 + .saturating_add(Weight::from_parts(2_036, 0).saturating_mul(b.into())) + // Standard Error: 1_710 + .saturating_add(Weight::from_parts(24_217, 0).saturating_mul(m.into())) + // Standard Error: 8_436 + .saturating_add(Weight::from_parts(392_472, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 1).saturating_mul(b.into())) + .saturating_add(Weight::from_parts(0, 63).saturating_mul(m.into())) + .saturating_add(Weight::from_parts(0, 74).saturating_mul(p.into())) + } + /// Storage: `TechnicalCommittee::Proposals` (r:1 w:1) + /// Proof: `TechnicalCommittee::Proposals` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::Voting` (r:0 w:1) + /// Proof: `TechnicalCommittee::Voting` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `TechnicalCommittee::ProposalOf` (r:0 w:1) + /// Proof: `TechnicalCommittee::ProposalOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `p` is `[1, 20]`. + fn disapprove_proposal(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `189 + p * (32 ±0)` + // Estimated: `1674 + p * (32 ±0)` + // Minimum execution time: 9_836_000 picoseconds. + Weight::from_parts(10_522_146, 0) + .saturating_add(Weight::from_parts(0, 1674)) + // Standard Error: 1_861 + .saturating_add(Weight::from_parts(169_308, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 32).saturating_mul(p.into())) + } +} diff --git a/runtime/gtest/src/weights/pallet_distance.rs b/runtime/gtest/src/weights/pallet_distance.rs new file mode 100644 index 000000000..216ea5ac9 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_distance.rs @@ -0,0 +1,252 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_distance` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_distance`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_distance::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1 w:0) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + fn request_distance_evaluation() -> Weight { + // Proof Size summary in bytes: + // Measured: `1140` + // Estimated: `4605` + // Minimum execution time: 53_150_000 picoseconds. + Weight::from_parts(55_308_000, 0) + .saturating_add(Weight::from_parts(0, 4605)) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:1 w:0) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + fn request_distance_evaluation_for() -> Weight { + // Proof Size summary in bytes: + // Measured: `1169` + // Estimated: `7109` + // Minimum execution time: 55_332_000 picoseconds. + Weight::from_parts(57_807_000, 0) + .saturating_add(Weight::from_parts(0, 7109)) + .saturating_add(T::DbWeight::get().reads(10)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Distance::DidUpdate` (r:1 w:1) + /// Proof: `Distance::DidUpdate` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Authorship::Author` (r:1 w:1) + /// Proof: `Authorship::Author` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `System::Digest` (r:1 w:0) + /// Proof: `System::Digest` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::Validators` (r:1 w:0) + /// Proof: `Session::Validators` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool0` (r:1 w:1) + /// Proof: `Distance::EvaluationPool0` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[1, 1300]`. + fn update_evaluation(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `401 + i * (10 ±0)` + // Estimated: `1886 + i * (10 ±0)` + // Minimum execution time: 12_670_000 picoseconds. + Weight::from_parts(15_290_377, 0) + .saturating_add(Weight::from_parts(0, 1886)) + // Standard Error: 151 + .saturating_add(Weight::from_parts(113_107, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(Weight::from_parts(0, 10).saturating_mul(i.into())) + } + /// Storage: `Distance::CurrentPoolIndex` (r:1 w:0) + /// Proof: `Distance::CurrentPoolIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationPool0` (r:1 w:1) + /// Proof: `Distance::EvaluationPool0` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[1, 1300]`. + fn force_update_evaluation(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `139 + i * (10 ±0)` + // Estimated: `1624 + i * (10 ±0)` + // Minimum execution time: 5_483_000 picoseconds. + Weight::from_parts(8_547_236, 0) + .saturating_add(Weight::from_parts(0, 1624)) + // Standard Error: 251 + .saturating_add(Weight::from_parts(111_895, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(Weight::from_parts(0, 10).saturating_mul(i.into())) + } + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::MembershipsExpireOn` (r:2 w:2) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn force_valid_distance_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `572` + // Estimated: `6512` + // Minimum execution time: 24_095_000 picoseconds. + Weight::from_parts(24_966_000, 0) + .saturating_add(Weight::from_parts(0, 6512)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } + fn on_initialize_overhead() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 90_000 picoseconds. + Weight::from_parts(116_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `System::ParentHash` (r:1 w:0) + /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::MembershipsExpireOn` (r:2 w:2) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationBlock` (r:0 w:1) + /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn do_evaluation_success() -> Weight { + // Proof Size summary in bytes: + // Measured: `984` + // Estimated: `6924` + // Minimum execution time: 54_377_000 picoseconds. + Weight::from_parts(55_913_000, 0) + .saturating_add(Weight::from_parts(0, 6924)) + .saturating_add(T::DbWeight::get().reads(9)) + .saturating_add(T::DbWeight::get().writes(8)) + } + /// Storage: `System::ParentHash` (r:1 w:0) + /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:1) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::PendingEvaluationRequest` (r:1 w:1) + /// Proof: `Distance::PendingEvaluationRequest` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Balances::Holds` (r:1 w:1) + /// Proof: `Balances::Holds` (`max_values`: None, `max_size`: Some(69), added: 2544, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationBlock` (r:0 w:1) + /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn do_evaluation_failure() -> Weight { + // Proof Size summary in bytes: + // Measured: `412` + // Estimated: `3877` + // Minimum execution time: 25_479_000 picoseconds. + Weight::from_parts(27_033_000, 0) + .saturating_add(Weight::from_parts(0, 3877)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `System::ParentHash` (r:1 w:0) + /// Proof: `System::ParentHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Distance::EvaluationPool2` (r:1 w:0) + /// Proof: `Distance::EvaluationPool2` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Distance::EvaluationBlock` (r:0 w:1) + /// Proof: `Distance::EvaluationBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn do_evaluation_overhead() -> Weight { + // Proof Size summary in bytes: + // Measured: `109` + // Estimated: `1594` + // Minimum execution time: 2_542_000 picoseconds. + Weight::from_parts(2_822_000, 0) + .saturating_add(Weight::from_parts(0, 1594)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Distance::DidUpdate` (r:1 w:1) + /// Proof: `Distance::DidUpdate` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + fn on_finalize() -> Weight { + // Proof Size summary in bytes: + // Measured: `133` + // Estimated: `1618` + // Minimum execution time: 2_601_000 picoseconds. + Weight::from_parts(3_499_000, 0) + .saturating_add(Weight::from_parts(0, 1618)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_duniter_account.rs b/runtime/gtest/src/weights/pallet_duniter_account.rs new file mode 100644 index 000000000..3d572525c --- /dev/null +++ b/runtime/gtest/src/weights/pallet_duniter_account.rs @@ -0,0 +1,62 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_duniter_account` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_duniter_account`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_duniter_account::WeightInfo for WeightInfo<T> { + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn unlink_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `3558` + // Minimum execution time: 3_236_000 picoseconds. + Weight::from_parts(3_593_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_grandpa.rs b/runtime/gtest/src/weights/pallet_grandpa.rs new file mode 100644 index 000000000..3c6528f7f --- /dev/null +++ b/runtime/gtest/src/weights/pallet_grandpa.rs @@ -0,0 +1,55 @@ +// Copyright 2021 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Manual weights for the GRANDPA Pallet in duniter runtimes +//! This file was not auto-generated. + +use frame_support::{ + traits::Get, + weights::{ + constants::{WEIGHT_REF_TIME_PER_MICROS, WEIGHT_REF_TIME_PER_NANOS}, + Weight, + }, +}; +use sp_std::marker::PhantomData; + +/// Weight functions for `pallet_grandpa`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_grandpa::WeightInfo for WeightInfo<T> { + fn report_equivocation(validator_count: u32, _p: u32) -> Weight { + // we take the validator set count from the membership proof to + // calculate the weight but we set a floor of 100 validators. + let validator_count = validator_count.max(100) as u64; + + // checking membership proof + (Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 35) + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_NANOS, 0) * 175) + .saturating_mul(validator_count) + .saturating_add(T::DbWeight::get().reads(5)) + // check equivocation proof + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 95) + // report offence + .saturating_add(Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 110) + .saturating_add(T::DbWeight::get().writes(3)) + // fetching set id -> session index mappings + .saturating_add(T::DbWeight::get().reads(2)) + } + + fn note_stalled() -> Weight { + (Weight::from_parts(WEIGHT_REF_TIME_PER_MICROS, 0) * 3) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_identity.rs b/runtime/gtest/src/weights/pallet_identity.rs new file mode 100644 index 000000000..7d1d94d01 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_identity.rs @@ -0,0 +1,402 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_identity` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_identity`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_identity::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:2 w:1) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:2 w:2) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:2 w:2) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Identity::NextIdtyIndex` (r:1 w:1) + /// Proof: `Identity::NextIdtyIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::CounterForIdentities` (r:1 w:1) + /// Proof: `Identity::CounterForIdentities` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Certification::CertsRemovableOn` (r:1 w:1) + /// Proof: `Certification::CertsRemovableOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn create_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `1099` + // Estimated: `7039` + // Minimum execution time: 60_861_000 picoseconds. + Weight::from_parts(62_726_000, 0) + .saturating_add(Weight::from_parts(0, 7039)) + .saturating_add(T::DbWeight::get().reads(12)) + .saturating_add(T::DbWeight::get().writes(12)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentitiesNames` (r:1 w:1) + /// Proof: `Identity::IdentitiesNames` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn confirm_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `822` + // Estimated: `6762` + // Minimum execution time: 29_173_000 picoseconds. + Weight::from_parts(31_199_000, 0) + .saturating_add(Weight::from_parts(0, 6762)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(4)) + } + /// Storage: `Identity::IdentityIndexOf` (r:2 w:2) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn change_owner_key() -> Weight { + // Proof Size summary in bytes: + // Measured: `813` + // Estimated: `6753` + // Minimum execution time: 77_195_000 picoseconds. + Weight::from_parts(79_790_000, 0) + .saturating_add(Weight::from_parts(0, 6753)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn revoke_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `731` + // Estimated: `6671` + // Minimum execution time: 66_142_000 picoseconds. + Weight::from_parts(70_531_000, 0) + .saturating_add(Weight::from_parts(0, 6671)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `Identity::IdentitiesNames` (r:0 w:999) + /// Proof: `Identity::IdentitiesNames` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[2, 1000]`. + fn prune_item_identities_names(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_570_000 picoseconds. + Weight::from_parts(3_699_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 1_236 + .saturating_add(Weight::from_parts(1_254_192, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + } + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn fix_sufficients() -> Weight { + // Proof Size summary in bytes: + // Measured: `104` + // Estimated: `3558` + // Minimum execution time: 6_510_000 picoseconds. + Weight::from_parts(6_954_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn link_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `436` + // Estimated: `3901` + // Minimum execution time: 52_215_000 picoseconds. + Weight::from_parts(55_484_000, 0) + .saturating_add(Weight::from_parts(0, 3901)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn on_initialize() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 87_000 picoseconds. + Weight::from_parts(122_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_revoke_identity_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `360` + // Estimated: `3825` + // Minimum execution time: 3_719_000 picoseconds. + Weight::from_parts(4_008_000, 0) + .saturating_add(Weight::from_parts(0, 3825)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_revoke_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `1930` + // Estimated: `15295` + // Minimum execution time: 95_684_000 picoseconds. + Weight::from_parts(99_735_000, 0) + .saturating_add(Weight::from_parts(0, 15295)) + .saturating_add(T::DbWeight::get().reads(18)) + .saturating_add(T::DbWeight::get().writes(22)) + } + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_identity_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `360` + // Estimated: `3825` + // Minimum execution time: 3_744_000 picoseconds. + Weight::from_parts(3_968_000, 0) + .saturating_add(Weight::from_parts(0, 3825)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::CounterForIdentities` (r:1 w:1) + /// Proof: `Identity::CounterForIdentities` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:6 w:6) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityIndexOf` (r:0 w:1) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_identity() -> Weight { + // Proof Size summary in bytes: + // Measured: `2355` + // Estimated: `18195` + // Minimum execution time: 136_407_000 picoseconds. + Weight::from_parts(142_177_000, 0) + .saturating_add(Weight::from_parts(0, 18195)) + .saturating_add(T::DbWeight::get().reads(24)) + .saturating_add(T::DbWeight::get().writes(30)) + } + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Membership::MembershipsExpireOn` (r:1 w:1) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:1) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::StorageIdtyCertMeta` (r:6 w:6) + /// Proof: `Certification::StorageIdtyCertMeta` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn do_remove_identity_handler() -> Weight { + // Proof Size summary in bytes: + // Measured: `2372` + // Estimated: `18212` + // Minimum execution time: 132_481_000 picoseconds. + Weight::from_parts(138_612_000, 0) + .saturating_add(Weight::from_parts(0, 18212)) + .saturating_add(T::DbWeight::get().reads(25)) + .saturating_add(T::DbWeight::get().writes(29)) + } + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn membership_removed() -> Weight { + // Proof Size summary in bytes: + // Measured: `441` + // Estimated: `6381` + // Minimum execution time: 14_154_000 picoseconds. + Weight::from_parts(15_034_000, 0) + .saturating_add(Weight::from_parts(0, 6381)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:0) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn prune_identities_noop() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `3630` + // Minimum execution time: 2_696_000 picoseconds. + Weight::from_parts(2_921_000, 0) + .saturating_add(Weight::from_parts(0, 3630)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:0) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn prune_identities_none() -> Weight { + // Proof Size summary in bytes: + // Measured: `363` + // Estimated: `3828` + // Minimum execution time: 6_105_000 picoseconds. + Weight::from_parts(6_374_000, 0) + .saturating_add(Weight::from_parts(0, 3828)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityChangeSchedule` (r:1 w:1) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::CounterForIdentities` (r:1 w:1) + /// Proof: `Identity::CounterForIdentities` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Membership::Membership` (r:1 w:1) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Certification::CertsByReceiver` (r:1 w:0) + /// Proof: `Certification::CertsByReceiver` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityIndexOf` (r:0 w:1) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Quota::IdtyQuota` (r:0 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn prune_identities_err() -> Weight { + // Proof Size summary in bytes: + // Measured: `952` + // Estimated: `4417` + // Minimum execution time: 30_961_000 picoseconds. + Weight::from_parts(32_352_000, 0) + .saturating_add(Weight::from_parts(0, 4417)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(7)) + } +} diff --git a/runtime/gtest/src/weights/pallet_im_online.rs b/runtime/gtest/src/weights/pallet_im_online.rs new file mode 100644 index 000000000..ad89b41d3 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_im_online.rs @@ -0,0 +1,74 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_im_online` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_im_online`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_im_online::WeightInfo for WeightInfo<T> { + /// Storage: `Session::Validators` (r:1 w:0) + /// Proof: `Session::Validators` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::CurrentIndex` (r:1 w:0) + /// Proof: `Session::CurrentIndex` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ImOnline::Keys` (r:1 w:0) + /// Proof: `ImOnline::Keys` (`max_values`: Some(1), `max_size`: Some(32002), added: 32497, mode: `MaxEncodedLen`) + /// Storage: `ImOnline::ReceivedHeartbeats` (r:1 w:1) + /// Proof: `ImOnline::ReceivedHeartbeats` (`max_values`: None, `max_size`: Some(25), added: 2500, mode: `MaxEncodedLen`) + /// Storage: `ImOnline::AuthoredBlocks` (r:1 w:0) + /// Proof: `ImOnline::AuthoredBlocks` (`max_values`: None, `max_size`: Some(56), added: 2531, mode: `MaxEncodedLen`) + /// The range of component `k` is `[1, 1000]`. + fn validate_unsigned_and_then_heartbeat(k: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `525 + k * (32 ±0)` + // Estimated: `33487 + k * (1761 ±0)` + // Minimum execution time: 51_688_000 picoseconds. + Weight::from_parts(90_762_814, 0) + .saturating_add(Weight::from_parts(0, 33487)) + // Standard Error: 986 + .saturating_add(Weight::from_parts(27_568, 0).saturating_mul(k.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(1)) + .saturating_add(Weight::from_parts(0, 1761).saturating_mul(k.into())) + } +} diff --git a/runtime/gtest/src/weights/pallet_membership.rs b/runtime/gtest/src/weights/pallet_membership.rs new file mode 100644 index 000000000..7cd6e5b6f --- /dev/null +++ b/runtime/gtest/src/weights/pallet_membership.rs @@ -0,0 +1,102 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_membership` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_membership`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_membership::WeightInfo for WeightInfo<T> { + fn on_initialize() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 87_000 picoseconds. + Weight::from_parts(95_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Membership::MembershipsExpireOn` (r:2 w:2) + /// Proof: `Membership::MembershipsExpireOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:3 w:3) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::CounterForMembership` (r:1 w:1) + /// Proof: `Membership::CounterForMembership` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Identity::Identities` (r:3 w:3) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::IdentityChangeSchedule` (r:2 w:2) + /// Proof: `Identity::IdentityChangeSchedule` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:3 w:3) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:3 w:3) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:3 w:3) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:12) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[0, 3]`. + fn expire_memberships(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `139 + i * (992 ±0)` + // Estimated: `15059 + i * (2695 ±1)` + // Minimum execution time: 3_985_000 picoseconds. + Weight::from_parts(11_249_590, 0) + .saturating_add(Weight::from_parts(0, 15059)) + // Standard Error: 493_613 + .saturating_add(Weight::from_parts(72_285_534, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().reads((11_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((15_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2695).saturating_mul(i.into())) + } +} diff --git a/runtime/gtest/src/weights/pallet_multisig.rs b/runtime/gtest/src/weights/pallet_multisig.rs new file mode 100644 index 000000000..10d6b0f37 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_multisig.rs @@ -0,0 +1,162 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_multisig` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_multisig`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_multisig::WeightInfo for WeightInfo<T> { + /// The range of component `z` is `[0, 10000]`. + fn as_multi_threshold_1(z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_777_000 picoseconds. + Weight::from_parts(6_091_524, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 16 + .saturating_add(Weight::from_parts(239, 0).saturating_mul(z.into())) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + /// The range of component `z` is `[0, 10000]`. + fn as_multi_create(s: u32, z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `125 + s * (5 ±0)` + // Estimated: `3922` + // Minimum execution time: 23_682_000 picoseconds. + Weight::from_parts(23_930_274, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 15_734 + .saturating_add(Weight::from_parts(172_281, 0).saturating_mul(s.into())) + // Standard Error: 13 + .saturating_add(Weight::from_parts(1_103, 0).saturating_mul(z.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[3, 10]`. + /// The range of component `z` is `[0, 10000]`. + fn as_multi_approve(s: u32, z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `240` + // Estimated: `3922` + // Minimum execution time: 14_270_000 picoseconds. + Weight::from_parts(13_658_101, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 8_400 + .saturating_add(Weight::from_parts(133_468, 0).saturating_mul(s.into())) + // Standard Error: 6 + .saturating_add(Weight::from_parts(1_100, 0).saturating_mul(z.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + /// The range of component `z` is `[0, 10000]`. + fn as_multi_complete(s: u32, z: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `259 + s * (37 ±0)` + // Estimated: `3922` + // Minimum execution time: 27_338_000 picoseconds. + Weight::from_parts(26_677_216, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 7_682 + .saturating_add(Weight::from_parts(200_575, 0).saturating_mul(s.into())) + // Standard Error: 6 + .saturating_add(Weight::from_parts(1_128, 0).saturating_mul(z.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + fn approve_as_multi_create(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `130 + s * (5 ±0)` + // Estimated: `3922` + // Minimum execution time: 21_969_000 picoseconds. + Weight::from_parts(23_235_711, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 14_128 + .saturating_add(Weight::from_parts(175_776, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + fn approve_as_multi_approve(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `240` + // Estimated: `3922` + // Minimum execution time: 11_815_000 picoseconds. + Weight::from_parts(12_700_464, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 4_275 + .saturating_add(Weight::from_parts(143_781, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Multisig::Multisigs` (r:1 w:1) + /// Proof: `Multisig::Multisigs` (`max_values`: None, `max_size`: Some(457), added: 2932, mode: `MaxEncodedLen`) + /// The range of component `s` is `[2, 10]`. + fn cancel_as_multi(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `328 + s * (5 ±0)` + // Estimated: `3922` + // Minimum execution time: 22_727_000 picoseconds. + Weight::from_parts(23_838_362, 0) + .saturating_add(Weight::from_parts(0, 3922)) + // Standard Error: 6_477 + .saturating_add(Weight::from_parts(208_955, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_oneshot_account.rs b/runtime/gtest/src/weights/pallet_oneshot_account.rs new file mode 100644 index 000000000..324277a25 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_oneshot_account.rs @@ -0,0 +1,94 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_oneshot_account` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_oneshot_account`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_oneshot_account::WeightInfo for WeightInfo<T> { + /// Storage: `OneshotAccount::OneshotAccounts` (r:1 w:1) + /// Proof: `OneshotAccount::OneshotAccounts` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn create_oneshot_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `42` + // Estimated: `3507` + // Minimum execution time: 19_894_000 picoseconds. + Weight::from_parts(20_785_000, 0) + .saturating_add(Weight::from_parts(0, 3507)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `OneshotAccount::OneshotAccounts` (r:1 w:1) + /// Proof: `OneshotAccount::OneshotAccounts` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn consume_oneshot_account() -> Weight { + // Proof Size summary in bytes: + // Measured: `241` + // Estimated: `3706` + // Minimum execution time: 27_632_000 picoseconds. + Weight::from_parts(28_625_000, 0) + .saturating_add(Weight::from_parts(0, 3706)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `OneshotAccount::OneshotAccounts` (r:1 w:1) + /// Proof: `OneshotAccount::OneshotAccounts` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::BlockHash` (r:1 w:0) + /// Proof: `System::BlockHash` (`max_values`: None, `max_size`: Some(44), added: 2519, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn consume_oneshot_account_with_remaining() -> Weight { + // Proof Size summary in bytes: + // Measured: `301` + // Estimated: `6126` + // Minimum execution time: 40_675_000 picoseconds. + Weight::from_parts(42_044_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gtest/src/weights/pallet_preimage.rs b/runtime/gtest/src/weights/pallet_preimage.rs new file mode 100644 index 000000000..e30c48275 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_preimage.rs @@ -0,0 +1,259 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_preimage` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_preimage`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_preimage::WeightInfo for WeightInfo<T> { + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 4194304]`. + fn note_preimage(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `42` + // Estimated: `3548` + // Minimum execution time: 11_130_000 picoseconds. + Weight::from_parts(11_508_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + // Standard Error: 2 + .saturating_add(Weight::from_parts(1_408, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 4194304]`. + fn note_requested_preimage(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 12_751_000 picoseconds. + Weight::from_parts(13_118_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + // Standard Error: 2 + .saturating_add(Weight::from_parts(1_409, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 4194304]`. + fn note_no_deposit_preimage(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 12_065_000 picoseconds. + Weight::from_parts(12_325_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + // Standard Error: 2 + .saturating_add(Weight::from_parts(1_485, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + fn unnote_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `172` + // Estimated: `3548` + // Minimum execution time: 22_878_000 picoseconds. + Weight::from_parts(26_363_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + fn unnote_no_deposit_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `144` + // Estimated: `3548` + // Minimum execution time: 22_641_000 picoseconds. + Weight::from_parts(26_990_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `172` + // Estimated: `3548` + // Minimum execution time: 22_898_000 picoseconds. + Weight::from_parts(25_005_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_no_deposit_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `144` + // Estimated: `3548` + // Minimum execution time: 13_919_000 picoseconds. + Weight::from_parts(16_815_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_unnoted_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `42` + // Estimated: `3548` + // Minimum execution time: 9_917_000 picoseconds. + Weight::from_parts(14_864_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn request_requested_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 7_562_000 picoseconds. + Weight::from_parts(8_382_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// Storage: `Preimage::PreimageFor` (r:0 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `MaxEncodedLen`) + fn unrequest_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `144` + // Estimated: `3548` + // Minimum execution time: 22_684_000 picoseconds. + Weight::from_parts(27_082_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn unrequest_unnoted_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 7_358_000 picoseconds. + Weight::from_parts(9_386_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + fn unrequest_multi_referenced_preimage() -> Weight { + // Proof Size summary in bytes: + // Measured: `106` + // Estimated: `3548` + // Minimum execution time: 7_266_000 picoseconds. + Weight::from_parts(8_348_000, 0) + .saturating_add(Weight::from_parts(0, 3548)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Preimage::StatusFor` (r:1023 w:1023) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1023 w:1023) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:0 w:1023) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// The range of component `n` is `[1, 1024]`. + fn ensure_updated(n: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0 + n * (179 ±0)` + // Estimated: `990 + n * (2568 ±0)` + // Minimum execution time: 16_611_000 picoseconds. + Weight::from_parts(17_174_000, 0) + .saturating_add(Weight::from_parts(0, 990)) + // Standard Error: 24_530 + .saturating_add(Weight::from_parts(14_208_953, 0).saturating_mul(n.into())) + .saturating_add(T::DbWeight::get().reads((2_u64).saturating_mul(n.into()))) + .saturating_add(T::DbWeight::get().writes((3_u64).saturating_mul(n.into()))) + .saturating_add(Weight::from_parts(0, 2568).saturating_mul(n.into())) + } +} diff --git a/runtime/gtest/src/weights/pallet_provide_randomness.rs b/runtime/gtest/src/weights/pallet_provide_randomness.rs new file mode 100644 index 000000000..2a371a78a --- /dev/null +++ b/runtime/gtest/src/weights/pallet_provide_randomness.rs @@ -0,0 +1,132 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_provide_randomness` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_provide_randomness`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_provide_randomness::WeightInfo for WeightInfo<T> { + /// Storage: `ProvideRandomness::CounterForRequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::CounterForRequestsIds` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestIdProvider` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestIdProvider` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::RequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsIds` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Babe::EpochIndex` (r:1 w:0) + /// Proof: `Babe::EpochIndex` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::NexEpochHookIn` (r:1 w:0) + /// Proof: `ProvideRandomness::NexEpochHookIn` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::RequestsReadyAtEpoch` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsReadyAtEpoch` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn request() -> Weight { + // Proof Size summary in bytes: + // Measured: `298` + // Estimated: `3763` + // Minimum execution time: 40_502_000 picoseconds. + Weight::from_parts(41_498_000, 0) + .saturating_add(Weight::from_parts(0, 3763)) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `ProvideRandomness::RequestsReadyAtNextBlock` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsReadyAtNextBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Babe::AuthorVrfRandomness` (r:1 w:0) + /// Proof: `Babe::AuthorVrfRandomness` (`max_values`: Some(1), `max_size`: Some(33), added: 528, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestsIds` (r:100 w:100) + /// Proof: `ProvideRandomness::RequestsIds` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::CounterForRequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::CounterForRequestsIds` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::NexEpochHookIn` (r:1 w:1) + /// Proof: `ProvideRandomness::NexEpochHookIn` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// The range of component `i` is `[1, 100]`. + fn on_initialize(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `341 + i * (59 ±0)` + // Estimated: `1827 + i * (2535 ±0)` + // Minimum execution time: 15_605_000 picoseconds. + Weight::from_parts(13_004_515, 0) + .saturating_add(Weight::from_parts(0, 1827)) + // Standard Error: 8_795 + .saturating_add(Weight::from_parts(5_156_386, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2535).saturating_mul(i.into())) + } + /// Storage: `ProvideRandomness::RequestsReadyAtNextBlock` (r:1 w:0) + /// Proof: `ProvideRandomness::RequestsReadyAtNextBlock` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::NexEpochHookIn` (r:1 w:1) + /// Proof: `ProvideRandomness::NexEpochHookIn` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Babe::EpochIndex` (r:1 w:0) + /// Proof: `Babe::EpochIndex` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestsReadyAtEpoch` (r:1 w:1) + /// Proof: `ProvideRandomness::RequestsReadyAtEpoch` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Babe::NextRandomness` (r:1 w:0) + /// Proof: `Babe::NextRandomness` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + /// Storage: `Babe::EpochStart` (r:1 w:0) + /// Proof: `Babe::EpochStart` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `ProvideRandomness::RequestsIds` (r:100 w:100) + /// Proof: `ProvideRandomness::RequestsIds` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `ProvideRandomness::CounterForRequestsIds` (r:1 w:1) + /// Proof: `ProvideRandomness::CounterForRequestsIds` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 100]`. + fn on_initialize_epoch(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `351 + i * (59 ±0)` + // Estimated: `3817 + i * (2535 ±0)` + // Minimum execution time: 16_849_000 picoseconds. + Weight::from_parts(15_139_250, 0) + .saturating_add(Weight::from_parts(0, 3817)) + // Standard Error: 4_697 + .saturating_add(Weight::from_parts(5_454_975, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(7)) + .saturating_add(T::DbWeight::get().reads((1_u64).saturating_mul(i.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((1_u64).saturating_mul(i.into()))) + .saturating_add(Weight::from_parts(0, 2535).saturating_mul(i.into())) + } +} diff --git a/runtime/common/src/weights/pallet_proxy.rs b/runtime/gtest/src/weights/pallet_proxy.rs similarity index 77% rename from runtime/common/src/weights/pallet_proxy.rs rename to runtime/gtest/src/weights/pallet_proxy.rs index 315bf051c..771289807 100644 --- a/runtime/common/src/weights/pallet_proxy.rs +++ b/runtime/gtest/src/weights/pallet_proxy.rs @@ -17,7 +17,7 @@ //! Autogenerated weights for `pallet_proxy` //! //! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` //! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 @@ -34,7 +34,7 @@ // --wasm-execution=compiled // --heap-pages=4096 // --header=./file_header.txt -// --output=./runtime/common/src/weights/ +// --output=./runtime/gtest/src/weights/ #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] @@ -54,11 +54,11 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `157 + p * (37 ±0)` // Estimated: `4698` - // Minimum execution time: 10_587_000 picoseconds. - Weight::from_parts(11_927_836, 0) + // Minimum execution time: 11_439_000 picoseconds. + Weight::from_parts(12_364_382, 0) .saturating_add(Weight::from_parts(0, 4698)) - // Standard Error: 1_371 - .saturating_add(Weight::from_parts(22_824, 0).saturating_mul(p.into())) + // Standard Error: 1_541 + .saturating_add(Weight::from_parts(31_026, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(1)) } /// Storage: `Proxy::Proxies` (r:1 w:0) @@ -73,13 +73,13 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `399 + a * (68 ±0) + p * (37 ±0)` // Estimated: `5690` - // Minimum execution time: 26_005_000 picoseconds. - Weight::from_parts(26_650_052, 0) + // Minimum execution time: 27_570_000 picoseconds. + Weight::from_parts(28_014_978, 0) .saturating_add(Weight::from_parts(0, 5690)) - // Standard Error: 1_871 - .saturating_add(Weight::from_parts(128_419, 0).saturating_mul(a.into())) - // Standard Error: 1_933 - .saturating_add(Weight::from_parts(32_266, 0).saturating_mul(p.into())) + // Standard Error: 2_107 + .saturating_add(Weight::from_parts(139_831, 0).saturating_mul(a.into())) + // Standard Error: 2_177 + .saturating_add(Weight::from_parts(41_237, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -93,13 +93,13 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `322 + a * (68 ±0)` // Estimated: `5690` - // Minimum execution time: 17_219_000 picoseconds. - Weight::from_parts(18_205_164, 0) + // Minimum execution time: 18_452_000 picoseconds. + Weight::from_parts(18_356_429, 0) .saturating_add(Weight::from_parts(0, 5690)) - // Standard Error: 1_493 - .saturating_add(Weight::from_parts(122_565, 0).saturating_mul(a.into())) - // Standard Error: 1_543 - .saturating_add(Weight::from_parts(8_216, 0).saturating_mul(p.into())) + // Standard Error: 4_361 + .saturating_add(Weight::from_parts(158_127, 0).saturating_mul(a.into())) + // Standard Error: 4_506 + .saturating_add(Weight::from_parts(33_982, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -113,13 +113,13 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `322 + a * (68 ±0)` // Estimated: `5690` - // Minimum execution time: 17_268_000 picoseconds. - Weight::from_parts(18_015_864, 0) + // Minimum execution time: 18_164_000 picoseconds. + Weight::from_parts(19_395_937, 0) .saturating_add(Weight::from_parts(0, 5690)) - // Standard Error: 1_421 - .saturating_add(Weight::from_parts(120_331, 0).saturating_mul(a.into())) - // Standard Error: 1_468 - .saturating_add(Weight::from_parts(8_881, 0).saturating_mul(p.into())) + // Standard Error: 2_001 + .saturating_add(Weight::from_parts(129_069, 0).saturating_mul(a.into())) + // Standard Error: 2_067 + .saturating_add(Weight::from_parts(3_963, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -135,13 +135,13 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `331 + a * (68 ±0) + p * (37 ±0)` // Estimated: `5690` - // Minimum execution time: 23_803_000 picoseconds. - Weight::from_parts(23_771_521, 0) + // Minimum execution time: 24_668_000 picoseconds. + Weight::from_parts(25_536_050, 0) .saturating_add(Weight::from_parts(0, 5690)) - // Standard Error: 1_323 - .saturating_add(Weight::from_parts(125_762, 0).saturating_mul(a.into())) - // Standard Error: 1_367 - .saturating_add(Weight::from_parts(35_700, 0).saturating_mul(p.into())) + // Standard Error: 2_415 + .saturating_add(Weight::from_parts(126_782, 0).saturating_mul(a.into())) + // Standard Error: 2_495 + .saturating_add(Weight::from_parts(27_965, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(3)) .saturating_add(T::DbWeight::get().writes(2)) } @@ -152,11 +152,11 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `157 + p * (37 ±0)` // Estimated: `4698` - // Minimum execution time: 16_406_000 picoseconds. - Weight::from_parts(17_515_617, 0) + // Minimum execution time: 17_292_000 picoseconds. + Weight::from_parts(18_481_010, 0) .saturating_add(Weight::from_parts(0, 4698)) - // Standard Error: 1_411 - .saturating_add(Weight::from_parts(38_705, 0).saturating_mul(p.into())) + // Standard Error: 1_995 + .saturating_add(Weight::from_parts(40_322, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -167,11 +167,11 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `157 + p * (37 ±0)` // Estimated: `4698` - // Minimum execution time: 16_194_000 picoseconds. - Weight::from_parts(17_532_724, 0) + // Minimum execution time: 17_318_000 picoseconds. + Weight::from_parts(18_627_132, 0) .saturating_add(Weight::from_parts(0, 4698)) - // Standard Error: 2_309 - .saturating_add(Weight::from_parts(51_908, 0).saturating_mul(p.into())) + // Standard Error: 2_229 + .saturating_add(Weight::from_parts(39_031, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -182,11 +182,11 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `157 + p * (37 ±0)` // Estimated: `4698` - // Minimum execution time: 16_020_000 picoseconds. - Weight::from_parts(17_245_545, 0) + // Minimum execution time: 16_966_000 picoseconds. + Weight::from_parts(17_951_653, 0) .saturating_add(Weight::from_parts(0, 4698)) - // Standard Error: 1_555 - .saturating_add(Weight::from_parts(16_291, 0).saturating_mul(p.into())) + // Standard Error: 1_469 + .saturating_add(Weight::from_parts(36_028, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -197,11 +197,11 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `177` // Estimated: `4698` - // Minimum execution time: 17_534_000 picoseconds. - Weight::from_parts(18_700_319, 0) + // Minimum execution time: 17_988_000 picoseconds. + Weight::from_parts(19_720_009, 0) .saturating_add(Weight::from_parts(0, 4698)) - // Standard Error: 1_342 - .saturating_add(Weight::from_parts(10_675, 0).saturating_mul(p.into())) + // Standard Error: 1_483 + .saturating_add(Weight::from_parts(9_055, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } @@ -212,11 +212,11 @@ impl<T: frame_system::Config> pallet_proxy::WeightInfo for WeightInfo<T> { // Proof Size summary in bytes: // Measured: `194 + p * (37 ±0)` // Estimated: `4698` - // Minimum execution time: 16_577_000 picoseconds. - Weight::from_parts(17_708_748, 0) + // Minimum execution time: 17_308_000 picoseconds. + Weight::from_parts(18_478_122, 0) .saturating_add(Weight::from_parts(0, 4698)) - // Standard Error: 1_458 - .saturating_add(Weight::from_parts(25_279, 0).saturating_mul(p.into())) + // Standard Error: 1_673 + .saturating_add(Weight::from_parts(34_333, 0).saturating_mul(p.into())) .saturating_add(T::DbWeight::get().reads(1)) .saturating_add(T::DbWeight::get().writes(1)) } diff --git a/runtime/gtest/src/weights/pallet_quota.rs b/runtime/gtest/src/weights/pallet_quota.rs new file mode 100644 index 000000000..a19434338 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_quota.rs @@ -0,0 +1,133 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_quota` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-05-13, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/common/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_quota`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_quota::WeightInfo for WeightInfo<T> { + /// Storage: `Quota::RefundQueue` (r:1 w:1) + /// Proof: `Quota::RefundQueue` (`max_values`: Some(1), `max_size`: Some(11266), added: 11761, mode: `MaxEncodedLen`) + fn queue_refund() -> Weight { + // Proof Size summary in bytes: + // Measured: `11288` + // Estimated: `12751` + // Minimum execution time: 7_146_000 picoseconds. + Weight::from_parts(7_473_000, 0) + .saturating_add(Weight::from_parts(0, 12751)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + fn spend_quota() -> Weight { + // Proof Size summary in bytes: + // Measured: `139` + // Estimated: `3489` + // Minimum execution time: 4_469_000 picoseconds. + Weight::from_parts(4_731_000, 0) + .saturating_add(Weight::from_parts(0, 3489)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn try_refund() -> Weight { + // Proof Size summary in bytes: + // Measured: `202` + // Estimated: `6126` + // Minimum execution time: 21_893_000 picoseconds. + Weight::from_parts(22_789_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn do_refund() -> Weight { + // Proof Size summary in bytes: + // Measured: `202` + // Estimated: `6126` + // Minimum execution time: 21_581_000 picoseconds. + Weight::from_parts(22_465_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Quota::RefundQueue` (r:1 w:1) + /// Proof: `Quota::RefundQueue` (`max_values`: Some(1), `max_size`: Some(11266), added: 11761, mode: `MaxEncodedLen`) + fn on_process_refund_queue() -> Weight { + // Proof Size summary in bytes: + // Measured: `43` + // Estimated: `12751` + // Minimum execution time: 1_759_000 picoseconds. + Weight::from_parts(1_953_000, 0) + .saturating_add(Weight::from_parts(0, 12751)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Quota::RefundQueue` (r:1 w:1) + /// Proof: `Quota::RefundQueue` (`max_values`: Some(1), `max_size`: Some(11266), added: 11761, mode: `MaxEncodedLen`) + /// Storage: `Quota::IdtyQuota` (r:1 w:1) + /// Proof: `Quota::IdtyQuota` (`max_values`: None, `max_size`: Some(24), added: 2499, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 256]`. + fn on_process_refund_queue_elements(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `227 + i * (44 ±0)` + // Estimated: `12751` + // Minimum execution time: 25_323_000 picoseconds. + Weight::from_parts(39_142_016, 0) + .saturating_add(Weight::from_parts(0, 12751)) + // Standard Error: 2_270 + .saturating_add(Weight::from_parts(1_181_628, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(4)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} diff --git a/runtime/gtest/src/weights/pallet_scheduler.rs b/runtime/gtest/src/weights/pallet_scheduler.rs new file mode 100644 index 000000000..8a7d95f8d --- /dev/null +++ b/runtime/gtest/src/weights/pallet_scheduler.rs @@ -0,0 +1,287 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_scheduler` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_scheduler`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_scheduler::WeightInfo for WeightInfo<T> { + /// Storage: `Scheduler::IncompleteSince` (r:1 w:1) + /// Proof: `Scheduler::IncompleteSince` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + fn service_agendas_base() -> Weight { + // Proof Size summary in bytes: + // Measured: `30` + // Estimated: `1489` + // Minimum execution time: 2_262_000 picoseconds. + Weight::from_parts(2_408_000, 0) + .saturating_add(Weight::from_parts(0, 1489)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 50]`. + fn service_agenda_base(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + s * (177 ±0)` + // Estimated: `13928` + // Minimum execution time: 2_670_000 picoseconds. + Weight::from_parts(5_460_652, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 2_380 + .saturating_add(Weight::from_parts(311_727, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn service_task_base() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_342_000 picoseconds. + Weight::from_parts(2_535_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Preimage::PreimageFor` (r:1 w:1) + /// Proof: `Preimage::PreimageFor` (`max_values`: None, `max_size`: Some(4194344), added: 4196819, mode: `Measured`) + /// Storage: `Preimage::StatusFor` (r:1 w:0) + /// Proof: `Preimage::StatusFor` (`max_values`: None, `max_size`: Some(83), added: 2558, mode: `MaxEncodedLen`) + /// Storage: `Preimage::RequestStatusFor` (r:1 w:1) + /// Proof: `Preimage::RequestStatusFor` (`max_values`: None, `max_size`: Some(75), added: 2550, mode: `MaxEncodedLen`) + /// The range of component `s` is `[128, 4194304]`. + fn service_task_fetched(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `179 + s * (1 ±0)` + // Estimated: `3644 + s * (1 ±0)` + // Minimum execution time: 14_520_000 picoseconds. + Weight::from_parts(14_925_000, 0) + .saturating_add(Weight::from_parts(0, 3644)) + // Standard Error: 3 + .saturating_add(Weight::from_parts(936, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + .saturating_add(Weight::from_parts(0, 1).saturating_mul(s.into())) + } + /// Storage: `Scheduler::Lookup` (r:0 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + fn service_task_named() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_666_000 picoseconds. + Weight::from_parts(3_888_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } + fn service_task_periodic() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_282_000 picoseconds. + Weight::from_parts(2_432_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + fn execute_dispatch_signed() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_440_000 picoseconds. + Weight::from_parts(1_589_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + fn execute_dispatch_unsigned() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 1_456_000 picoseconds. + Weight::from_parts(1_584_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 49]`. + fn schedule(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + s * (177 ±0)` + // Estimated: `13928` + // Minimum execution time: 7_843_000 picoseconds. + Weight::from_parts(10_177_792, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 1_789 + .saturating_add(Weight::from_parts(339_708, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Lookup` (r:0 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// The range of component `s` is `[1, 50]`. + fn cancel(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `77 + s * (177 ±0)` + // Estimated: `13928` + // Minimum execution time: 12_433_000 picoseconds. + Weight::from_parts(12_625_840, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 2_224 + .saturating_add(Weight::from_parts(534_055, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 49]`. + fn schedule_named(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `254 + s * (185 ±0)` + // Estimated: `13928` + // Minimum execution time: 10_890_000 picoseconds. + Weight::from_parts(14_933_110, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 8_625 + .saturating_add(Weight::from_parts(355_163, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:1) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + /// The range of component `s` is `[1, 50]`. + fn cancel_named(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `280 + s * (185 ±0)` + // Estimated: `13928` + // Minimum execution time: 14_506_000 picoseconds. + Weight::from_parts(15_932_307, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 2_213 + .saturating_add(Weight::from_parts(545_865, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:1) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + /// The range of component `s` is `[1, 50]`. + fn schedule_retry(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `117` + // Estimated: `13928` + // Minimum execution time: 7_179_000 picoseconds. + Weight::from_parts(8_017_503, 0) + .saturating_add(Weight::from_parts(0, 13928)) + // Standard Error: 982 + .saturating_add(Weight::from_parts(25_502, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn set_retry() -> Weight { + // Proof Size summary in bytes: + // Measured: `8927` + // Estimated: `13928` + // Minimum execution time: 20_956_000 picoseconds. + Weight::from_parts(21_960_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:0) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn set_retry_named() -> Weight { + // Proof Size summary in bytes: + // Measured: `9605` + // Estimated: `13928` + // Minimum execution time: 26_029_000 picoseconds. + Weight::from_parts(27_194_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn cancel_retry() -> Weight { + // Proof Size summary in bytes: + // Measured: `8939` + // Estimated: `13928` + // Minimum execution time: 19_621_000 picoseconds. + Weight::from_parts(21_141_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Scheduler::Lookup` (r:1 w:0) + /// Proof: `Scheduler::Lookup` (`max_values`: None, `max_size`: Some(48), added: 2523, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Agenda` (r:1 w:0) + /// Proof: `Scheduler::Agenda` (`max_values`: None, `max_size`: Some(10463), added: 12938, mode: `MaxEncodedLen`) + /// Storage: `Scheduler::Retries` (r:0 w:1) + /// Proof: `Scheduler::Retries` (`max_values`: None, `max_size`: Some(30), added: 2505, mode: `MaxEncodedLen`) + fn cancel_retry_named() -> Weight { + // Proof Size summary in bytes: + // Measured: `9617` + // Estimated: `13928` + // Minimum execution time: 25_939_000 picoseconds. + Weight::from_parts(27_621_000, 0) + .saturating_add(Weight::from_parts(0, 13928)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_session.rs b/runtime/gtest/src/weights/pallet_session.rs new file mode 100644 index 000000000..5975ff3ee --- /dev/null +++ b/runtime/gtest/src/weights/pallet_session.rs @@ -0,0 +1,78 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_session` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_session`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_session::WeightInfo for WeightInfo<T> { + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::KeyOwner` (r:4 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn set_keys() -> Weight { + // Proof Size summary in bytes: + // Measured: `810` + // Estimated: `11700` + // Minimum execution time: 24_559_000 picoseconds. + Weight::from_parts(25_631_000, 0) + .saturating_add(Weight::from_parts(0, 11700)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(5)) + } + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn purge_keys() -> Weight { + // Proof Size summary in bytes: + // Measured: `477` + // Estimated: `3942` + // Minimum execution time: 14_661_000 picoseconds. + Weight::from_parts(15_038_000, 0) + .saturating_add(Weight::from_parts(0, 3942)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(5)) + } +} diff --git a/runtime/gtest/src/weights/pallet_smith_members.rs b/runtime/gtest/src/weights/pallet_smith_members.rs new file mode 100644 index 000000000..4d25c54d9 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_smith_members.rs @@ -0,0 +1,139 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_smith_members` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_smith_members`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_smith_members::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:2 w:1) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Membership::Membership` (r:1 w:0) + /// Proof: `Membership::Membership` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::CurrentSession` (r:1 w:0) + /// Proof: `SmithMembers::CurrentSession` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::ExpiresOn` (r:1 w:1) + /// Proof: `SmithMembers::ExpiresOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn invite_smith() -> Weight { + // Proof Size summary in bytes: + // Measured: `834` + // Estimated: `6774` + // Minimum execution time: 25_370_000 picoseconds. + Weight::from_parts(26_642_000, 0) + .saturating_add(Weight::from_parts(0, 6774)) + .saturating_add(T::DbWeight::get().reads(6)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:1 w:1) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn accept_invitation() -> Weight { + // Proof Size summary in bytes: + // Measured: `599` + // Estimated: `4064` + // Minimum execution time: 14_514_000 picoseconds. + Weight::from_parts(15_323_000, 0) + .saturating_add(Weight::from_parts(0, 4064)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::Smiths` (r:2 w:2) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::CurrentSession` (r:1 w:0) + /// Proof: `SmithMembers::CurrentSession` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `SmithMembers::ExpiresOn` (r:1 w:1) + /// Proof: `SmithMembers::ExpiresOn` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn certify_smith() -> Weight { + // Proof Size summary in bytes: + // Measured: `644` + // Estimated: `6584` + // Minimum execution time: 22_406_000 picoseconds. + Weight::from_parts(23_388_000, 0) + .saturating_add(Weight::from_parts(0, 6584)) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `SmithMembers::Smiths` (r:5 w:5) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::Members` (r:1 w:1) + /// Proof: `AuthorityMembers::Members` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OnlineAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OnlineAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::OutgoingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::OutgoingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `AuthorityMembers::IncomingAuthorities` (r:1 w:1) + /// Proof: `AuthorityMembers::IncomingAuthorities` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Session::NextKeys` (r:1 w:1) + /// Proof: `Session::NextKeys` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Session::KeyOwner` (r:0 w:4) + /// Proof: `Session::KeyOwner` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn on_removed_wot_member() -> Weight { + // Proof Size summary in bytes: + // Measured: `1204` + // Estimated: `14569` + // Minimum execution time: 59_347_000 picoseconds. + Weight::from_parts(62_051_000, 0) + .saturating_add(Weight::from_parts(0, 14569)) + .saturating_add(T::DbWeight::get().reads(11)) + .saturating_add(T::DbWeight::get().writes(15)) + } + /// Storage: `SmithMembers::Smiths` (r:1 w:0) + /// Proof: `SmithMembers::Smiths` (`max_values`: None, `max_size`: None, mode: `Measured`) + fn on_removed_wot_member_empty() -> Weight { + // Proof Size summary in bytes: + // Measured: `253` + // Estimated: `3718` + // Minimum execution time: 2_930_000 picoseconds. + Weight::from_parts(3_146_000, 0) + .saturating_add(Weight::from_parts(0, 3718)) + .saturating_add(T::DbWeight::get().reads(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_sudo.rs b/runtime/gtest/src/weights/pallet_sudo.rs new file mode 100644 index 000000000..18666def7 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_sudo.rs @@ -0,0 +1,96 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_sudo` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_sudo`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_sudo::WeightInfo for WeightInfo<T> { + /// Storage: `Sudo::Key` (r:1 w:1) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn set_key() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 6_873_000 picoseconds. + Weight::from_parts(7_409_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Sudo::Key` (r:1 w:0) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn sudo() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 7_352_000 picoseconds. + Weight::from_parts(7_654_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Sudo::Key` (r:1 w:0) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn sudo_as() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 7_363_000 picoseconds. + Weight::from_parts(7_755_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + } + /// Storage: `Sudo::Key` (r:1 w:1) + /// Proof: `Sudo::Key` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) + fn remove_key() -> Weight { + // Proof Size summary in bytes: + // Measured: `165` + // Estimated: `1517` + // Minimum execution time: 6_204_000 picoseconds. + Weight::from_parts(6_704_000, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_timestamp.rs b/runtime/gtest/src/weights/pallet_timestamp.rs new file mode 100644 index 000000000..38ad91ba5 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_timestamp.rs @@ -0,0 +1,74 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_timestamp` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_timestamp`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_timestamp::WeightInfo for WeightInfo<T> { + /// Storage: `Timestamp::Now` (r:1 w:1) + /// Proof: `Timestamp::Now` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `Babe::CurrentSlot` (r:1 w:0) + /// Proof: `Babe::CurrentSlot` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `UniversalDividend::NextUd` (r:1 w:1) + /// Proof: `UniversalDividend::NextUd` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + fn set() -> Weight { + // Proof Size summary in bytes: + // Measured: `268` + // Estimated: `1493` + // Minimum execution time: 8_068_000 picoseconds. + Weight::from_parts(8_530_000, 0) + .saturating_add(Weight::from_parts(0, 1493)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + fn on_finalize() -> Weight { + // Proof Size summary in bytes: + // Measured: `57` + // Estimated: `0` + // Minimum execution time: 2_526_000 picoseconds. + Weight::from_parts(2_680_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } +} diff --git a/runtime/gtest/src/weights/pallet_treasury.rs b/runtime/gtest/src/weights/pallet_treasury.rs new file mode 100644 index 000000000..7e9f101a2 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_treasury.rs @@ -0,0 +1,185 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_treasury` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_treasury`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_treasury::WeightInfo for WeightInfo<T> { + fn spend_local() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 0_000 picoseconds. + Weight::from_parts(0, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Treasury::ProposalCount` (r:1 w:1) + /// Proof: `Treasury::ProposalCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Proposals` (r:0 w:1) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + fn propose_spend() -> Weight { + // Proof Size summary in bytes: + // Measured: `67` + // Estimated: `1489` + // Minimum execution time: 17_205_000 picoseconds. + Weight::from_parts(18_353_000, 0) + .saturating_add(Weight::from_parts(0, 1489)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `Treasury::Proposals` (r:1 w:1) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn reject_proposal() -> Weight { + // Proof Size summary in bytes: + // Measured: `272` + // Estimated: `6126` + // Minimum execution time: 27_997_000 picoseconds. + Weight::from_parts(28_786_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Treasury::Proposals` (r:1 w:0) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Approvals` (r:1 w:1) + /// Proof: `Treasury::Approvals` (`max_values`: Some(1), `max_size`: Some(402), added: 897, mode: `MaxEncodedLen`) + /// The range of component `p` is `[0, 99]`. + fn approve_proposal(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `433 + p * (8 ±0)` + // Estimated: `3557` + // Minimum execution time: 6_284_000 picoseconds. + Weight::from_parts(9_676_437, 0) + .saturating_add(Weight::from_parts(0, 3557)) + // Standard Error: 1_254 + .saturating_add(Weight::from_parts(51_325, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Treasury::Approvals` (r:1 w:1) + /// Proof: `Treasury::Approvals` (`max_values`: Some(1), `max_size`: Some(402), added: 897, mode: `MaxEncodedLen`) + fn remove_approval() -> Weight { + // Proof Size summary in bytes: + // Measured: `90` + // Estimated: `1887` + // Minimum execution time: 4_287_000 picoseconds. + Weight::from_parts(4_565_000, 0) + .saturating_add(Weight::from_parts(0, 1887)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `System::Account` (r:199 w:199) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Deactivated` (r:1 w:1) + /// Proof: `Treasury::Deactivated` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Approvals` (r:1 w:1) + /// Proof: `Treasury::Approvals` (`max_values`: Some(1), `max_size`: Some(402), added: 897, mode: `MaxEncodedLen`) + /// Storage: `Treasury::Proposals` (r:99 w:99) + /// Proof: `Treasury::Proposals` (`max_values`: None, `max_size`: Some(92), added: 2567, mode: `MaxEncodedLen`) + /// The range of component `p` is `[0, 99]`. + fn on_initialize_proposals(p: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `24 + p * (196 ±0)` + // Estimated: `3558 + p * (5136 ±0)` + // Minimum execution time: 12_909_000 picoseconds. + Weight::from_parts(18_002_580, 0) + .saturating_add(Weight::from_parts(0, 3558)) + // Standard Error: 35_095 + .saturating_add(Weight::from_parts(25_115_785, 0).saturating_mul(p.into())) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().reads((3_u64).saturating_mul(p.into()))) + .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes((3_u64).saturating_mul(p.into()))) + .saturating_add(Weight::from_parts(0, 5136).saturating_mul(p.into())) + } + fn spend() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 0_000 picoseconds. + Weight::from_parts(0, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// Storage: `Treasury::Spends` (r:1 w:1) + /// Proof: `Treasury::Spends` (`max_values`: None, `max_size`: Some(61), added: 2536, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn payout() -> Weight { + // Proof Size summary in bytes: + // Measured: `179` + // Estimated: `6126` + // Minimum execution time: 40_131_000 picoseconds. + Weight::from_parts(41_275_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(3)) + } + /// Storage: `Treasury::Spends` (r:1 w:1) + /// Proof: `Treasury::Spends` (`max_values`: None, `max_size`: Some(61), added: 2536, mode: `MaxEncodedLen`) + fn check_status() -> Weight { + // Proof Size summary in bytes: + // Measured: `116` + // Estimated: `3526` + // Minimum execution time: 8_626_000 picoseconds. + Weight::from_parts(8_880_000, 0) + .saturating_add(Weight::from_parts(0, 3526)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `Treasury::Spends` (r:1 w:1) + /// Proof: `Treasury::Spends` (`max_values`: None, `max_size`: Some(61), added: 2536, mode: `MaxEncodedLen`) + fn void_spend() -> Weight { + // Proof Size summary in bytes: + // Measured: `116` + // Estimated: `3526` + // Minimum execution time: 7_904_000 picoseconds. + Weight::from_parts(8_281_000, 0) + .saturating_add(Weight::from_parts(0, 3526)) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_universal_dividend.rs b/runtime/gtest/src/weights/pallet_universal_dividend.rs new file mode 100644 index 000000000..08e4bc992 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_universal_dividend.rs @@ -0,0 +1,118 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_universal_dividend` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_universal_dividend`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_universal_dividend::WeightInfo for WeightInfo<T> { + /// Storage: `Identity::IdentityIndexOf` (r:1 w:0) + /// Proof: `Identity::IdentityIndexOf` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `Identity::Identities` (r:1 w:1) + /// Proof: `Identity::Identities` (`max_values`: None, `max_size`: None, mode: `Measured`) + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `UniversalDividend::PastReevals` (r:1 w:0) + /// Proof: `UniversalDividend::PastReevals` (`max_values`: Some(1), `max_size`: Some(1602), added: 2097, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 160]`. + fn claim_uds(i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `709` + // Estimated: `4174` + // Minimum execution time: 29_185_000 picoseconds. + Weight::from_parts(31_512_714, 0) + .saturating_add(Weight::from_parts(0, 4174)) + // Standard Error: 2_550 + .saturating_add(Weight::from_parts(12_086, 0).saturating_mul(i.into())) + .saturating_add(T::DbWeight::get().reads(5)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `UniversalDividend::CurrentUd` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUd` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:2 w:2) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_ud() -> Weight { + // Proof Size summary in bytes: + // Measured: `156` + // Estimated: `6126` + // Minimum execution time: 51_925_000 picoseconds. + Weight::from_parts(53_414_000, 0) + .saturating_add(Weight::from_parts(0, 6126)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `UniversalDividend::CurrentUd` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUd` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + fn transfer_ud_keep_alive() -> Weight { + // Proof Size summary in bytes: + // Measured: `93` + // Estimated: `3558` + // Minimum execution time: 32_939_000 picoseconds. + Weight::from_parts(33_638_000, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(2)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `UniversalDividend::CurrentUdIndex` (r:1 w:0) + /// Proof: `UniversalDividend::CurrentUdIndex` (`max_values`: Some(1), `max_size`: Some(2), added: 497, mode: `MaxEncodedLen`) + /// Storage: `UniversalDividend::PastReevals` (r:1 w:0) + /// Proof: `UniversalDividend::PastReevals` (`max_values`: Some(1), `max_size`: Some(1602), added: 2097, mode: `MaxEncodedLen`) + /// Storage: `System::Account` (r:1 w:1) + /// Proof: `System::Account` (`max_values`: None, `max_size`: Some(93), added: 2568, mode: `MaxEncodedLen`) + /// The range of component `i` is `[1, 160]`. + fn on_removed_member(_i: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `181` + // Estimated: `3558` + // Minimum execution time: 17_374_000 picoseconds. + Weight::from_parts(18_846_781, 0) + .saturating_add(Weight::from_parts(0, 3558)) + .saturating_add(T::DbWeight::get().reads(3)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} diff --git a/runtime/gtest/src/weights/pallet_upgrade_origin.rs b/runtime/gtest/src/weights/pallet_upgrade_origin.rs new file mode 100644 index 000000000..4052e15d6 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_upgrade_origin.rs @@ -0,0 +1,58 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_upgrade_origin` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_upgrade_origin`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_upgrade_origin::WeightInfo for WeightInfo<T> { + fn dispatch_as_root() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_653_000 picoseconds. + Weight::from_parts(4_921_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } +} diff --git a/runtime/gtest/src/weights/pallet_utility.rs b/runtime/gtest/src/weights/pallet_utility.rs new file mode 100644 index 000000000..fd86342f0 --- /dev/null +++ b/runtime/gtest/src/weights/pallet_utility.rs @@ -0,0 +1,99 @@ +// Copyright 2021-2022 Axiom-Team +// +// This file is part of Duniter-v2S. +// +// Duniter-v2S is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, version 3 of the License. +// +// Duniter-v2S is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with Duniter-v2S. If not, see <https://www.gnu.org/licenses/>. + +//! Autogenerated weights for `pallet_utility` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// target/release/duniter +// benchmark +// pallet +// --chain=dev +// --steps=50 +// --repeat=20 +// --pallet=* +// --extrinsic=* +// --wasm-execution=compiled +// --heap-pages=4096 +// --header=./file_header.txt +// --output=./runtime/gtest/src/weights/ + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_utility`. +pub struct WeightInfo<T>(PhantomData<T>); +impl<T: frame_system::Config> pallet_utility::WeightInfo for WeightInfo<T> { + /// The range of component `c` is `[0, 1000]`. + fn batch(c: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_461_000 picoseconds. + Weight::from_parts(3_396_636, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 2_464 + .saturating_add(Weight::from_parts(2_162_182, 0).saturating_mul(c.into())) + } + fn as_derivative() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_887_000 picoseconds. + Weight::from_parts(3_186_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `c` is `[0, 1000]`. + fn batch_all(c: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_610_000 picoseconds. + Weight::from_parts(11_037_900, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 4_023 + .saturating_add(Weight::from_parts(2_312_516, 0).saturating_mul(c.into())) + } + fn dispatch_as() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_689_000 picoseconds. + Weight::from_parts(5_079_000, 0) + .saturating_add(Weight::from_parts(0, 0)) + } + /// The range of component `c` is `[0, 1000]`. + fn force_batch(c: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_291_000 picoseconds. + Weight::from_parts(4_871_822, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 8_989 + .saturating_add(Weight::from_parts(2_159_572, 0).saturating_mul(c.into())) + } +} diff --git a/runtime/gtest/src/weights/paritydb_weights.rs b/runtime/gtest/src/weights/paritydb_weights.rs new file mode 100644 index 000000000..63069fd9d --- /dev/null +++ b/runtime/gtest/src/weights/paritydb_weights.rs @@ -0,0 +1,94 @@ + +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-21 (Y/M/D) +//! HOSTNAME: `bgallois-ms7d43`, CPU: `12th Gen Intel(R) Core(TM) i3-12100F` +//! +//! DATABASE: `ParityDb`, RUNTIME: `ĞTest Local Testnet` +//! BLOCK-NUM: `BlockId::Number(0)` +//! SKIP-WRITE: `false`, SKIP-READ: `false`, WARMUPS: `1` +//! STATE-VERSION: `V1`, STATE-CACHE-SIZE: `` +//! WEIGHT-PATH: `./runtime/gtest/src/weights/` +//! METRIC: `Average`, WEIGHT-MUL: `2.0`, WEIGHT-ADD: `0` + +// Executed Command: +// target/release/duniter +// benchmark +// storage +// --chain=dev +// --mul=2 +// --weight-path=./runtime/gtest/src/weights/ +// --state-version=1 + +/// Storage DB weights for the `ĞTest Local Testnet` runtime and `ParityDb`. +pub mod constants { + use frame_support::weights::constants; + use sp_core::parameter_types; + use sp_weights::RuntimeDbWeight; + + parameter_types! { + /// `ParityDB` can be enabled with a feature flag, but is still experimental. These weights + /// are available for brave runtime engineers who may want to try this out as default. + pub const ParityDbWeight: RuntimeDbWeight = RuntimeDbWeight { + /// Time to read one storage item. + /// Calculated by multiplying the *Average* of all values with `2.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 907, 2_186_594 + /// Average: 15_846 + /// Median: 1_673 + /// Std-Dev: 173254.69 + /// + /// Percentiles nanoseconds: + /// 99th: 19_704 + /// 95th: 3_556 + /// 75th: 2_202 + read: 31_692 * constants::WEIGHT_REF_TIME_PER_NANOS, + + /// Time to write one storage item. + /// Calculated by multiplying the *Average* of all values with `2.0` and adding `0`. + /// + /// Stats nanoseconds: + /// Min, Max: 4_014, 7_075_138 + /// Average: 55_795 + /// Median: 11_187 + /// Std-Dev: 560218.89 + /// + /// Percentiles nanoseconds: + /// 99th: 31_849 + /// 95th: 19_073 + /// 75th: 12_958 + write: 111_590 * constants::WEIGHT_REF_TIME_PER_NANOS, + }; + } + + #[cfg(test)] + mod test_db_weights { + use super::constants::ParityDbWeight as W; + use sp_weights::constants; + + /// Checks that all weights exist and have sane values. + // NOTE: If this test fails but you are sure that the generated values are fine, + // you can delete it. + #[test] + fn bound() { + // At least 1 µs. + assert!( + W::get().reads(1).ref_time() >= constants::WEIGHT_REF_TIME_PER_MICROS, + "Read weight should be at least 1 µs." + ); + assert!( + W::get().writes(1).ref_time() >= constants::WEIGHT_REF_TIME_PER_MICROS, + "Write weight should be at least 1 µs." + ); + // At most 1 ms. + assert!( + W::get().reads(1).ref_time() <= constants::WEIGHT_REF_TIME_PER_MILLIS, + "Read weight should be at most 1 ms." + ); + assert!( + W::get().writes(1).ref_time() <= constants::WEIGHT_REF_TIME_PER_MILLIS, + "Write weight should be at most 1 ms." + ); + } + } +} diff --git a/scripts/run_all_benchmarks.sh b/scripts/run_all_benchmarks.sh index 01ec0fe5d..7b86566a6 100755 --- a/scripts/run_all_benchmarks.sh +++ b/scripts/run_all_benchmarks.sh @@ -1,5 +1,7 @@ -cargo build --release --features runtime-benchmarks -target/release/duniter benchmark storage --chain=dev --mul=2 --weight-path=./runtime/common/src/weights/ --state-version=1 -target/release/duniter benchmark overhead --chain=dev --wasm-execution=compiled --weight-path=./runtime/common/src/weights/ --warmup=10 --repeat=100 -target/release/duniter benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet="*" --extrinsic="*" --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/common/src/weights/ - +for chain in g1 gtest gdev +do + cargo build --release --no-default-features --features runtime-benchmarks,$chain + target/release/duniter benchmark storage --chain=dev --mul=2 --weight-path=./runtime/$chain/src/weights/ --state-version=1 + target/release/duniter benchmark overhead --chain=dev --wasm-execution=compiled --weight-path=./runtime/$chain/src/weights/ --warmup=10 --repeat=100 + target/release/duniter benchmark pallet --chain=dev --steps=50 --repeat=20 --pallet="*" --extrinsic="*" --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/$chain/src/weights/ +done -- GitLab