Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
walletdb/bdb: attempt to set initial memory map size when opening
In this commit, we start to set the initial memory map size when opening the database. This helps with bulk insertions or migrations of the database, as if we set this to a larger value, then bbolt needs to remap less often. Remapping can be memory intensive as it needs to copy over the entire existing database. For 32-bit systems, we take care to clamp this value to ensure we don't exceed the largest addressable memory on such systems.
- Loading branch information