perf(trie): remove shrink_to_fit calls from SparseSubtrieBuffers::clear (#21630)

Co-authored-by: DaniPopes <57450786+DaniPopes@users.noreply.github.com>
This commit is contained in:
Georgios Konstantopoulos
2026-01-30 10:02:43 -08:00
committed by GitHub
parent f90b5c8a7f
commit 29072639d6

View File

@@ -3134,19 +3134,10 @@ impl SparseSubtrieBuffers {
/// Clears all buffers.
fn clear(&mut self) {
self.path_stack.clear();
self.path_stack.shrink_to_fit();
self.rlp_node_stack.clear();
self.rlp_node_stack.shrink_to_fit();
self.branch_child_buf.clear();
self.branch_child_buf.shrink_to_fit();
self.branch_value_stack_buf.clear();
self.branch_value_stack_buf.shrink_to_fit();
self.rlp_buf.clear();
self.rlp_buf.shrink_to_fit();
}
}