Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pavel-odintsov/dcf6569f2ad9619e4d83aeae52311f1d to your computer and use it in GitHub Desktop.
Save pavel-odintsov/dcf6569f2ad9619e4d83aeae52311f1d to your computer and use it in GitHub Desktop.
Ryzen 7 5800X with number of buckets boost::unordered
Loaded 183978 IPs into memory
std::map big endian
Total lookup time is 31 seconds
Million of lookup ops per second: 5.85925
Total scan time is 3 seconds
Million of full scan ops per second: 40.3343
Accumulator value to guarantee no optimisation tricks from compiler: 183978000000
std::map little endian
Total lookup time is 30 seconds
Million of lookup ops per second: 6.09461
Total scan time is 3 seconds
Million of full scan ops per second: 43.8008
Accumulator value to guarantee no optimisation tricks from compiler: 183978000000
std::unordered_map big endian
Total lookup time is 3 seconds
Million of lookup ops per second: 82.9214
Total scan time is 2 seconds
Million of full scan ops per second: 65.9872
Bucket number: 172933
Accumulator value to guarantee no optimisation tricks from compiler: 183978000000
std::unordered_map little endian
Total lookup time is 2 seconds
Million of lookup ops per second: 92.2912
Total scan time is 1 seconds
Million of full scan ops per second: 73.7456
Bucket number: 172933
Accumulator value to guarantee no optimisation tricks from compiler: 183978000000
boost::unordered_map big endian
Total lookup time is 2 seconds
Million of lookup ops per second: 85.598
Total scan time is 1 seconds
Million of full scan ops per second: 146.771
Bucket number: 196613
Accumulator value to guarantee no optimisation tricks from compiler: 183978000000
boost::unordered_map little endian
Total lookup time is 3 seconds
Million of lookup ops per second: 79.1636
Total scan time is 1 seconds
Million of full scan ops per second: 158.002
Bucket number: 196613
Accumulator value to guarantee no optimisation tricks from compiler: 183978000000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment