From 41e543164b5d425aa71f5475040f48e8113d2743 Mon Sep 17 00:00:00 2001 From: Kirill Fomichev Date: Mon, 25 Nov 2024 19:49:54 +0200 Subject: [PATCH] solana-program-runtime: remove solana-metrics for wasm --- Cargo.lock | 1 - program-runtime/Cargo.toml | 2 +- program-runtime/src/lib.rs | 4 ++-- program-runtime/src/loaded_programs.rs | 16 ++++++++-------- 4 files changed, 11 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 69e7c92db8..8d91eaf06d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7535,7 +7535,6 @@ dependencies = [ "solana-log-collector", "solana-logger", "solana-measure", - "solana-metrics", "solana-sdk", "solana-timings", "solana-type-overrides", diff --git a/program-runtime/Cargo.toml b/program-runtime/Cargo.toml index 4e764de35b..8601f2cd59 100644 --- a/program-runtime/Cargo.toml +++ b/program-runtime/Cargo.toml @@ -31,7 +31,7 @@ solana-frozen-abi-macro = { workspace = true, optional = true, features = [ ] } solana-log-collector = { workspace = true } solana-measure = { workspace = true } -solana-metrics = { workspace = true } +# solana-metrics = { workspace = true } solana-sdk = { workspace = true } solana-timings = { workspace = true } solana-type-overrides = { workspace = true } diff --git a/program-runtime/src/lib.rs b/program-runtime/src/lib.rs index 3a690d1d08..41eb4fe65c 100644 --- a/program-runtime/src/lib.rs +++ b/program-runtime/src/lib.rs @@ -2,8 +2,8 @@ #![deny(clippy::arithmetic_side_effects)] #![deny(clippy::indexing_slicing)] -#[macro_use] -extern crate solana_metrics; +// #[macro_use] +// extern crate solana_metrics; pub use solana_rbpf; pub mod invoke_context; diff --git a/program-runtime/src/loaded_programs.rs b/program-runtime/src/loaded_programs.rs index f8a0f2534b..1ec2b018a7 100644 --- a/program-runtime/src/loaded_programs.rs +++ b/program-runtime/src/loaded_programs.rs @@ -296,14 +296,14 @@ impl LoadProgramMetrics { saturating_add_assign!(timings.create_executor_load_elf_us, self.load_elf_us); saturating_add_assign!(timings.create_executor_verify_code_us, self.verify_code_us); saturating_add_assign!(timings.create_executor_jit_compile_us, self.jit_compile_us); - datapoint_trace!( - "create_executor_trace", - ("program_id", self.program_id, String), - ("register_syscalls_us", self.register_syscalls_us, i64), - ("load_elf_us", self.load_elf_us, i64), - ("verify_code_us", self.verify_code_us, i64), - ("jit_compile_us", self.jit_compile_us, i64), - ); + // datapoint_trace!( + // "create_executor_trace", + // ("program_id", self.program_id, String), + // ("register_syscalls_us", self.register_syscalls_us, i64), + // ("load_elf_us", self.load_elf_us, i64), + // ("verify_code_us", self.verify_code_us, i64), + // ("jit_compile_us", self.jit_compile_us, i64), + // ); } }