| 119 | } |
| 120 | |
| 121 | static void AddrManSelectByNetwork(benchmark::Bench& bench) |
| 122 | { |
| 123 | AddrMan addrman{EMPTY_NETGROUPMAN, /*deterministic=*/false, ADDRMAN_CONSISTENCY_CHECK_RATIO}; |
| 124 | |
| 125 | // add single I2P address to new table |
| 126 | CService i2p_service; |
| 127 | i2p_service.SetSpecial("udhdrtrcetjm5sxzskjyr5ztpeszydbh4dpl3pl4utgqqw2v4jna.b32.i2p"); |
| 128 | CAddress i2p_address(i2p_service, NODE_NONE); |
| 129 | i2p_address.nTime = Now<NodeSeconds>(); |
| 130 | const CNetAddr source{LookupHost("252.2.2.2", false).value()}; |
| 131 | addrman.Add({i2p_address}, source); |
| 132 | |
| 133 | FillAddrMan(addrman); |
| 134 | |
| 135 | bench.run([&] { |
| 136 | (void)addrman.Select(/*new_only=*/false, {NET_I2P}); |
| 137 | }); |
| 138 | } |
| 139 | |
| 140 | static void AddrManGetAddr(benchmark::Bench& bench) |
| 141 | { |
nothing calls this directly
no test coverage detected