Page MenuHomePhabricator

[backport#18754] bench: add CAddrMan benchmarks
ClosedPublic

Authored by majcosta on Jan 20 2021, 18:52.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC8b0b3a190975: [backport#18754] bench: add CAddrMan benchmarks
Summary

a9b957740e3490d87e5ce0b7f1b93ba43bb19764 bench: add CAddrMan benchmarks (Vasil Dimov)

Pull request description:

The added benchmarks exercise the public methods Add(), GetAddr(),
Select() and Good().

Backport of Core PR18754

Test Plan
ninja all
./src/bench/bitcoin-bench -filter=AddrMan.*

Diff Detail

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

Event Timeline

Failed tests logs:

====== Bitcoin ABC functional tests: p2p_leak.py ======

------- Stdout: -------
2021-01-20T18:55:55.636000Z TestFramework (INFO): Initializing test directory /work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20210120_185400/p2p_leak_212
2021-01-20T18:56:01.001000Z TestFramework (INFO): Check that the version message does not leak the local address of the node
2021-01-20T18:56:01.102000Z TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
  File "/work/test/functional/test_framework/test_framework.py", line 120, in main
    self.run_test()
  File "/work/test/functional/p2p_leak.py", line 189, in run_test
    assert_greater_than_or_equal(ver.nTime, time_begin)
  File "/work/test/functional/test_framework/util.py", line 70, in assert_greater_than_or_equal
    raise AssertionError("{} < {}".format(str(thing1), str(thing2)))
AssertionError: 1611168960 < 1611168961
2021-01-20T18:56:01.153000Z TestFramework (INFO): Stopping nodes
2021-01-20T18:56:01.404000Z TestFramework (WARNING): Not cleaning up dir /work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20210120_185400/p2p_leak_212
2021-01-20T18:56:01.404000Z TestFramework (ERROR): Test failed. Test logging available at /work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20210120_185400/p2p_leak_212/test_framework.log
2021-01-20T18:56:01.404000Z TestFramework (ERROR): Hint: Call /work/test/functional/combine_logs.py '/work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20210120_185400/p2p_leak_212' to consolidate all logs

Each failure log is accessible here:
Bitcoin ABC functional tests: p2p_leak.py

Fabien requested changes to this revision.Jan 21 2021, 08:55
Fabien added a subscriber: Fabien.

@bot build-bench

src/bench/addrman.cpp
13 ↗(On Diff #27155)

Layout

22 ↗(On Diff #27155)

Move the comment on it's own line

102 ↗(On Diff #27155)

Layout

This revision now requires changes to proceed.Jan 21 2021, 08:55
This revision is now accepted and ready to land.Jan 21 2021, 12:12