Page MenuHomePhabricator

Call ReallocateCache() on each Flush()
ClosedPublic

Authored by PiRK on May 16 2024, 14:39.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC4b916c68bdc2: Call ReallocateCache() on each Flush()
Summary

This frees up all associated memory with the map, not only the nodes.
This is necessary in preparation for using the PoolAllocator for
CCoinsMap, which does not actually free any memory on clear().

This is a partial backport of core#25325
https://github.com/bitcoin/bitcoin/pull/25325/commits/5e4ac5abf54f8e6d6330df0c73119aa0cca4c103

Depends on D16176

Test Plan

ninja all check-all

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable