Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

Commit

Permalink
use measure_us, remove incorrect name (#30254)
Browse files Browse the repository at this point in the history
  • Loading branch information
apfitzge authored Feb 13, 2023
1 parent 51bace2 commit 2e32b7f
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions poh/src/poh_recorder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use {
genesis_utils::{create_genesis_config, GenesisConfigInfo},
leader_schedule_cache::LeaderScheduleCache,
},
solana_measure::measure,
solana_measure::{measure, measure_us},
solana_metrics::poh_timing_point::{send_poh_timing_point, PohTimingSender, SlotPohTimingInfo},
solana_runtime::bank::Bank,
solana_sdk::{
Expand Down Expand Up @@ -173,12 +173,11 @@ impl TransactionRecorder {
let mut starting_transaction_index = None;

if !transactions.is_empty() {
let (hash, hash_time) = measure!(hash_transactions(&transactions), "hash");
record_transactions_timings.hash_us = hash_time.as_us();
let (hash, hash_us) = measure_us!(hash_transactions(&transactions));
record_transactions_timings.hash_us = hash_us;

let (res, poh_record_time) =
measure!(self.record(bank_slot, hash, transactions), "hash");
record_transactions_timings.poh_record_us = poh_record_time.as_us();
let (res, poh_record_us) = measure_us!(self.record(bank_slot, hash, transactions));
record_transactions_timings.poh_record_us = poh_record_us;

match res {
Ok(starting_index) => {
Expand Down

0 comments on commit 2e32b7f

Please sign in to comment.