### Is there an existing issue for this?

- [X] I have searched the existing issues

### Current behaviour

The `bitcoind -dbcache=100 -par=4 -disablewallet -reindex-chainstate` command fails with OOM. First reported in https://github.com/bitcoin/bitcoin/issues/28718#issuecomment-1807197107.

### Expected behaviour

RAM usage does not exceed 0.9 GB.

### Steps to reproduce

100% reproducibility with Guix compiled binaries.

### Relevant log output

```
2023-11-17T18:43:31Z [loadblk] UpdateTip: new best=000000000000000016d35e6ca77dea6f4e2caa387f245a712b1df5bbab3c559c height=314541 version=0x00000002 log2_work=80.091273 tx=44112815 date='2014-08-08T11:42:41Z' progress=0.049410 cache=105.6MiB(13710725txo)
```

### How did you obtain Bitcoin Core

Compiled from source

### What version of Bitcoin Core are you using?

master@5aa0c82ccd6ceb4a141686fc8658f679de75a787

### Operating system and version

Armbian 23.8.3 jammy, 1 GB swap-file

### Machine specifications

armv7l, 8 cores, 2 GB RAM
}
    PoolResourceTester::CheckAllDataAccountedFor(resource);
}
BOOST_AUTO_TEST_CASE(memusage_test)
{
    auto std_map = std::unordered_map<int, int>{};
    using Map = std::unordered_map<int,
                                   int,
                                   std::hash<int>,
                                   std::equal_to<int>,
                                   PoolAllocator<std::pair<const int, int>,
                                                 sizeof(std::pair<const int, int>) + sizeof(void*) * 4,
                                                 alignof(void*)>>;
    auto resource = Map::allocator_type::ResourceType(1024);
    PoolResourceTester::CheckAllDataAccountedFor(resource);
    {
        auto resource_map = Map{0, std::hash<int>{}, std::equal_to<int>{}, &resource};
        
        BOOST_TEST(memusage::DynamicUsage(std_map) != memusage::DynamicUsage(resource_map));
        for (size_t i = 0; i < 10000; ++i) {
            std_map[i];
            resource_map[i];
        }
        
        BOOST_TEST(memusage::DynamicUsage(resource_map) <= memusage::DynamicUsage(std_map) * 90 / 100);
    }
    PoolResourceTester::CheckAllDataAccountedFor(resource);
}
BOOST_AUTO_TEST_SUITE_END()