All Projects → martinus → map_benchmark

martinus / map_benchmark

Licence: MIT license
Comprehensive benchmarks of C++ maps

Programming Languages

C++
36643 projects - #6 most used programming language
ruby
36898 projects - #4 most used programming language
CMake
9771 projects
Jinja
831 projects
python
139335 projects - #7 most used programming language
Gnuplot
187 projects

Projects that are alternatives of or similar to map benchmark

gpumembench
A GPU benchmark suite for assessing on-chip GPU memory bandwidth
Stars: ✭ 62 (-53.03%)
Mutual labels:  benchmark
cpm
Continuous Perfomance Monitor (CPM) for C++ code
Stars: ✭ 39 (-70.45%)
Mutual labels:  benchmark
revl
Helps to benchmark code for Autodesk Maya.
Stars: ✭ 14 (-89.39%)
Mutual labels:  benchmark
gl-bench
⏱ WebGL performance monitor with CPU/GPU load.
Stars: ✭ 146 (+10.61%)
Mutual labels:  benchmark
hood
The plugin to manage benchmarks on your CI
Stars: ✭ 17 (-87.12%)
Mutual labels:  benchmark
node-vs-ruby-io
Node vs Ruby I/O benchmarks when resizing images with libvips.
Stars: ✭ 11 (-91.67%)
Mutual labels:  benchmark
hashcat-benchmark-comparison
Hashcat Benchmark Comparison
Stars: ✭ 22 (-83.33%)
Mutual labels:  benchmark
react-benchmark
A tool for benchmarking the render performance of React components
Stars: ✭ 99 (-25%)
Mutual labels:  benchmark
graphql-benchmarks
GraphQL benchmarks using the-benchmarker framework.
Stars: ✭ 54 (-59.09%)
Mutual labels:  benchmark
benchmarking-fft
choosing FFT library...
Stars: ✭ 74 (-43.94%)
Mutual labels:  benchmark
glDelegateBenchmark
quick and dirty benchmark for TFLite gles delegate on iOS
Stars: ✭ 13 (-90.15%)
Mutual labels:  benchmark
nowplaying-RS-Music-Reco-FM
#nowplaying-RS: Music Recommendation using Factorization Machines
Stars: ✭ 23 (-82.58%)
Mutual labels:  benchmark
typescript-orm-benchmark
⚖️ ORM benchmarking for Node.js applications written in TypeScript
Stars: ✭ 106 (-19.7%)
Mutual labels:  benchmark
LuaJIT-Benchmarks
LuaJIT Benchmark tests
Stars: ✭ 20 (-84.85%)
Mutual labels:  benchmark
sets
Benchmarks for set data structures: hash sets, dawg's, bloom filters, etc.
Stars: ✭ 20 (-84.85%)
Mutual labels:  benchmark
TensorTrade
This repository hosts all my code related to TensorTrade. It consists of the main program, its old versions, and some extras for more insights.
Stars: ✭ 16 (-87.88%)
Mutual labels:  benchmark
Face-Renovation
Official repository of the paper "HiFaceGAN: Face Renovation via Collaborative Suppression and Replenishment".
Stars: ✭ 245 (+85.61%)
Mutual labels:  benchmark
rpc-bench
RPC Benchmark of gRPC, Aeron and KryoNet
Stars: ✭ 59 (-55.3%)
Mutual labels:  benchmark
httpit
A rapid http(s) benchmark tool written in Go
Stars: ✭ 156 (+18.18%)
Mutual labels:  benchmark
caliper-benchmarks
Sample benchmark files for Hyperledger Caliper https://wiki.hyperledger.org/display/caliper
Stars: ✭ 69 (-47.73%)
Mutual labels:  benchmark

map_benchmark

Comprehensive benchmarks of C++ maps

Results

Please see here.

building

  1. Install dependencies for folly::F14, see https://github.com/facebook/folly/#ubuntu-1604-lts
  2. Install ninja and cmake
git clone --recurse-submodules https://github.com/martinus/map_benchmark.git
./map_benchmark/tools/build.sh

Sourcecode Layout

The implementation if the benchmark is open source, get it here: martinus/map_benchmark. It is split in several parts:

  1. external: all map implementations available through github are added as git submodules here.
  2. src/hashes: One directory for each hashing algorithm, each directory contains a Hash.h which basically contains a using instruction for the hash, e.g. like this:
template <class Key>
using Hash = robin_hood::hash<Key>;
  1. src/maps: One directory for each unordered map implementation, each directory contains a Map.h which basically contains a using instruction for the map. It includes Hash.h. E.g. like this:
#include "Hash.h"
template <class Key, class Val>
using Map = robin_hood::unordered_flat_map<Key, Val, Hash<Key>>;

Add a new Hashmap

  1. In external, add a submodule:
    git submodule add -b master https://github.com/rigtorp/HashMap.git rigtorp__HashMap
    
  2. Create a directory in src/map/ with a file Hash.h. See the others for example.

Maps I couldn't add

  • QHash: It's interface is too different to be easily includeable. e.g. iterator->first and iterator->second do not exist.
  • rigtorp::HashMap: Doesn't have a default constructor

Reliable Benchmarks

  1. Run lscpu --extended to find out if you have hyperthreadding. E.g. for me it shows
    $ lscpu --extended
    CPU NODE SOCKET CORE L1d:L1i:L2:L3 ONLINE MAXMHZ    MINMHZ
    0   0    0      0    0:0:0:0       yes    4600,0000 800,0000
    1   0    0      1    1:1:1:0       yes    4600,0000 800,0000
    2   0    0      2    2:2:2:0       yes    4600,0000 800,0000
    3   0    0      3    3:3:3:0       yes    4600,0000 800,0000
    4   0    0      4    4:4:4:0       yes    4600,0000 800,0000
    5   0    0      5    5:5:5:0       yes    4600,0000 800,0000
    6   0    0      0    0:0:0:0       yes    4600,0000 800,0000
    7   0    0      1    1:1:1:0       yes    4600,0000 800,0000
    8   0    0      2    2:2:2:0       yes    4600,0000 800,0000
    9   0    0      3    3:3:3:0       yes    4600,0000 800,0000
    10  0    0      4    4:4:4:0       yes    4600,0000 800,0000
    11  0    0      5    5:5:5:0       yes    4600,0000 800,0000
    
  2. Isolate a CPU with it's hyperthreading companion. I'm isolating CPU 5 and 11.
  3. Edit /etc/default/grub and change GRUB_CMDLINE_LINUX_DEFAULT so it looks like this:
    GRUB_CMDLINE_LINUX_DEFAULT="quiet splash isolcpus=5,11 rcu_nocbs=5,11"
    
  4. Run sudo update-grub
  5. reboot
  6. Edit bench.rb so the taskset -c ... prefix is correct.
  7. Install Python module perf, see https://perf.readthedocs.io/en/latest/
  8. Run sudo python3 -m perf system tune
  9. Start the benchmarks: ../tools/bench.rb |tee ../data/all_new.txt

Sources:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].