From 43139709aa4a3630241e1288a8d5bc124a2a1713 Mon Sep 17 00:00:00 2001 From: Evgeny Fomin Date: Thu, 29 Aug 2024 11:38:34 +0200 Subject: [PATCH] qfix --- merk/src/estimated_costs/worst_case_costs.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/merk/src/estimated_costs/worst_case_costs.rs b/merk/src/estimated_costs/worst_case_costs.rs index 537bb246..0f50c75a 100644 --- a/merk/src/estimated_costs/worst_case_costs.rs +++ b/merk/src/estimated_costs/worst_case_costs.rs @@ -210,7 +210,7 @@ pub fn add_worst_case_merk_propagate( // todo: verify these numbers cost.storage_cost.replaced_bytes += nodes_updated * MERK_BIGGEST_VALUE_SIZE; cost.storage_loaded_bytes += - (nodes_updated * (MERK_BIGGEST_VALUE_SIZE + MERK_BIGGEST_KEY_SIZE)) as u64; + nodes_updated as u64 * (MERK_BIGGEST_VALUE_SIZE + MERK_BIGGEST_KEY_SIZE) as u64; cost.seek_count += nodes_updated as u32; cost.hash_node_calls += nodes_updated * 2; Ok(())