bitcoind – Varied caches are outlined within the Bitcoin supply code. What do these caches discuss with?

0
26


The supply code is as follows:

//! -dbcache default (MiB) 

static const int64_t nDefaultDbCache = 450;

//! -dbbatchsize default (bytes)

static const int64_t nDefaultDbBatchSize = 16 << 20;

//! max. -dbcache (MiB)

static const int64_t nMaxDbCache = sizeof(void*) > 4 ? 16384 : 1024;

//! min. -dbcache (MiB)

static const int64_t nMinDbCache = 4;

//! Max reminiscence allotted to dam tree DB particular cache, if no -txindex (MiB)

static const int64_t nMaxBlockDBCache = 2;

//! Max reminiscence allotted to dam tree DB particular cache, if -txindex (MiB)
// Not like for the UTXO database, for the txindex situation the leveldb cache make
// a significant distinction: https://github.com/bitcoin/bitcoin/pull/8273#issuecomment-229601991

static const int64_t nMaxTxIndexCache = 1024;

//! Max reminiscence allotted to all block filter index caches mixed in MiB.

static const int64_t max_filter_index_cache = 1024;

//! Max reminiscence allotted to coin DB particular cache (MiB)

static const int64_t nMaxCoinsDBCache = 8;

I’ve 5 questions.

  1. What do these caches symbolize?
  2. What’s the relationship between UTXO cache and these caches?
  3. What’s the relationship between levelDB’s personal cache and UTXO cache?
  4. What’s the present UTXO cache measurement?
  5. What does the memtable in levelDB correspond to within the Bitcoin system?



Supply hyperlink

Leave a reply