aboutsummaryrefslogtreecommitdiff
path: root/src/node/caches.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/node/caches.h')
-rw-r--r--src/node/caches.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/node/caches.h b/src/node/caches.h
new file mode 100644
index 0000000000..67388b91fd
--- /dev/null
+++ b/src/node/caches.h
@@ -0,0 +1,24 @@
+// Copyright (c) 2021 The Bitcoin Core developers
+// Distributed under the MIT software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef BITCOIN_NODE_CACHES_H
+#define BITCOIN_NODE_CACHES_H
+
+#include <cstddef>
+#include <cstdint>
+
+class ArgsManager;
+
+namespace node {
+struct CacheSizes {
+ int64_t block_tree_db;
+ int64_t coins_db;
+ int64_t coins;
+ int64_t tx_index;
+ int64_t filter_index;
+};
+CacheSizes CalculateCacheSizes(const ArgsManager& args, size_t n_indexes = 0);
+} // namespace node
+
+#endif // BITCOIN_NODE_CACHES_H