mirror of
https://github.com/mimblewimble/grin.git
synced 2025-02-08 04:11:08 +03:00
Add debug logging on startup to provide size of our leaf_set (aka UTXO set) (#2788)
This commit is contained in:
parent
6352780d6a
commit
b9db129b33
2 changed files with 9 additions and 1 deletions
|
@ -47,6 +47,14 @@ impl LeafSet {
|
||||||
Bitmap::create()
|
Bitmap::create()
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if !bitmap.is_empty() {
|
||||||
|
debug!(
|
||||||
|
"bitmap {} pos ({} bytes)",
|
||||||
|
bitmap.cardinality(),
|
||||||
|
bitmap.get_serialized_size_in_bytes(),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
Ok(LeafSet {
|
Ok(LeafSet {
|
||||||
path: file_path.to_path_buf(),
|
path: file_path.to_path_buf(),
|
||||||
bitmap_bak: bitmap.clone(),
|
bitmap_bak: bitmap.clone(),
|
||||||
|
|
|
@ -83,7 +83,7 @@ impl PruneList {
|
||||||
prune_list.init_caches();
|
prune_list.init_caches();
|
||||||
|
|
||||||
if !prune_list.bitmap.is_empty() {
|
if !prune_list.bitmap.is_empty() {
|
||||||
debug!("prune_list: bitmap {} pos ({} bytes), pruned_cache {} pos ({} bytes), shift_cache {}, leaf_shift_cache {}",
|
debug!("bitmap {} pos ({} bytes), pruned_cache {} pos ({} bytes), shift_cache {}, leaf_shift_cache {}",
|
||||||
prune_list.bitmap.cardinality(),
|
prune_list.bitmap.cardinality(),
|
||||||
prune_list.bitmap.get_serialized_size_in_bytes(),
|
prune_list.bitmap.get_serialized_size_in_bytes(),
|
||||||
prune_list.pruned_cache.cardinality(),
|
prune_list.pruned_cache.cardinality(),
|
||||||
|
|
Loading…
Reference in a new issue