Skip to content

Commit

Permalink
Remove histograms
Browse files Browse the repository at this point in the history
Rumor has it these are very expensive to compute, so let's remove them
for now.
  • Loading branch information
rkuris committed Oct 10, 2024
1 parent 14d029c commit ec180a7
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
3 changes: 0 additions & 3 deletions firewood/src/merkle.rs
Original file line number Diff line number Diff line change
Expand Up @@ -416,9 +416,6 @@ impl<S: ReadableStorage> Merkle<NodeStore<MutableProposal, S>> {
/// Map `key` to `value` in the trie.
/// Each element of key is 2 nibbles.
pub fn insert(&mut self, key: &[u8], value: Box<[u8]>) -> Result<(), MerkleError> {
histogram!("firewood.insert.key.length").record(key.len() as f64);
histogram!("firewood.insert.data.length").record(value.len() as f64);

let key = Path::from_nibbles_iterator(NibblesIterator::new(key));

let root = self.nodestore.mut_root();
Expand Down
1 change: 0 additions & 1 deletion storage/src/nodestore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -492,7 +492,6 @@ impl<S: ReadableStorage> NodeStore<Arc<ImmutableProposal>, S> {
/// Also returns the index of the free list the node was allocated from.
pub fn allocate_node(&mut self, node: &Node) -> Result<(LinearAddress, AreaIndex), Error> {
let stored_area_size = Self::stored_len(node);
histogram!("firewood.node_size").record(stored_area_size as f64);

// Attempt to allocate from a free list.
// If we can't allocate from a free list, allocate past the existing
Expand Down

0 comments on commit ec180a7

Please sign in to comment.