addrman: improve performance by using more suitable containers
Summary:
CAddrMan uses std::map internally even though it does not require that the map's elements are sorted. std::map's access time is O(log(map size)). std::unordered_map is more suitable as it has a O(1) access time.
Backport of core#18722.
Test Plan:
ninja all check-all
Build and run the unit tests with DEBUG_ADDRMAN defined.
Reviewers: #bitcoin_abc, PiRK
Reviewed By: #bitcoin_abc, PiRK
Differential Revision: https://reviews.bitcoinabc.org/D12252