Request to do comparative benchmark for hash set implementation

13 views
Skip to first unread message

pawan

unread,
May 18, 2025, 9:10:21 PMMay 18
to hashtable-benchmarks

I have an "experimental" hash set implementation which I have uploaded to GitHub under 
exp-ds , is it possible to do a benchmark comparison on it ?

I have included the profiling code I used to compare insert, find and delete ops across the std library implementation, flat hash set and ex-ds.

- Pawan C.


Matthew Fowles Kulukundis

unread,
May 19, 2025, 10:09:44 AMMay 19
to pawan, hashtable-benchmarks
Pawan~

https://github.com/google/hashtable-benchmarks/blob/main/hashtable_benchmarks.cc#L961-L969 has the set of currently configured tables.  Given that these benchmarks work last used 7 years ago, I suspect it may take a few hours to dust them off and bring the toolchains up to more recent versions, but it should not be particularly bad.

That should be enough to let you use them for your own comparisons.  I have since left Google, so I don't know if there is any Google sponsor for this project, but if you submit a PR I am certain that I can scare up someone who can review and land it.

Matt

--
You received this message because you are subscribed to the Google Groups "hashtable-benchmarks" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hashtable-benchm...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/hashtable-benchmarks/c4ec9d00-03bf-4262-a861-b71f73f1a392n%40googlegroups.com.

pawan singh

unread,
May 19, 2025, 10:33:19 PMMay 19
to Matthew Fowles Kulukundis, hashtable-benchmarks
Thanks Matt,

I am not familiar with Bazel, so will give it a try, I got an older version bazel-6.3.0 but it fails to build at:
ERROR: Analysis of target '//:hashtable_benchmarks' failed; build aborted: no such package '@rules_cc//cc/compiler': BUILD file not found in directory 'cc/compiler' of external repository @rules_cc. Add a BUILD file to a directory to mark it as a package.
INFO: Elapsed time: 7.090s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (46 packages loaded, 629 targets configured)


I was getting an error on bazel_skylib, so after some Googling - added the below to get past that error 

    name = "bazel_skylib",
+    sha256 = "bc283cdfcd526a52c3201279cda4bc298652efa898b10b4db0837dc51652756f",
+    urls = [
+        "https://mirror.bazel.build/github.com/bazelbuild/bazel-skylib/releases/download/1.7.1/bazel-skylib-1.7.1.tar.gz",
+        "https://github.com/bazelbuild/bazel-skylib/releases/download/1.7.1/bazel-skylib-1.7.1.tar.gz",
+    ],
 )
 
+load("@bazel_skylib//:workspace.bzl", "bazel_skylib_workspace")
+
+bazel_skylib_workspace()


Any ideas ? 

pawan

unread,
May 20, 2025, 5:08:14 PMMay 20
to Matthew Fowles Kulukundis, hashtable-benchmarks
Just wanted to let you know, I tried the latest Bazel on OsX and it gets further but gives me a different error, so will try to figure that out. 
Build log - 
Starting local Bazel server (8.2.1-homebrew) and connecting to it...
WARNING: WORKSPACE support will be removed in Bazel 9 (late 2025), please migrate to Bzlmod, see https://bazel.build/external/migration.
DEBUG: Rule 'com_github_nelhage_rules_boost' indicated that a canonical reproducible form can be obtained by modifying arguments integrity = "sha256-U5jyv7hOP7uaWRNOEuou1EAX8f3AHEn6Wh5oOqz4jr0="
DEBUG: Repository com_github_nelhage_rules_boost instantiated at:
  /Users/pawan/Documents/code/github/hashtable-benchmarks/WORKSPACE:74:13: in <toplevel>
Repository rule http_archive defined at:
  /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/bazel_tools/tools/build_defs/repo/http.bzl:392:31: in <toplevel>
DEBUG: Rule 'skarupke' indicated that a canonical reproducible form can be obtained by modifying arguments integrity = "sha256-gUeLPpn35qNS9Sja8LKKAqFnA90CCum5GUHCFdobnjg="
DEBUG: Repository skarupke instantiated at:
  /Users/pawan/Documents/code/github/hashtable-benchmarks/WORKSPACE:67:13: in <toplevel>
Repository rule http_archive defined at:
  /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/bazel_tools/tools/build_defs/repo/http.bzl:392:31: in <toplevel>
DEBUG: Rule 'gbench' indicated that a canonical reproducible form can be obtained by modifying arguments integrity = "sha256-dbyBkY1Vw2ZaA1wlIDdYXnbsrCu7PlPwbMDJA6kA5n8="
DEBUG: Repository gbench instantiated at:
  /Users/pawan/Documents/code/github/hashtable-benchmarks/WORKSPACE:27:13: in <toplevel>
Repository rule http_archive defined at:
  /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/bazel_tools/tools/build_defs/repo/http.bzl:392:31: in <toplevel>
DEBUG: Rule 'google_sparsehash' indicated that a canonical reproducible form can be obtained by modifying arguments integrity = "sha256-SzUYtaS91Lkg2b5IQqQgpfaCuLsHPSk9EGsx/Guldl0="
DEBUG: Repository google_sparsehash instantiated at:
  /Users/pawan/Documents/code/github/hashtable-benchmarks/WORKSPACE:34:13: in <toplevel>
Repository rule http_archive defined at:
  /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/bazel_tools/tools/build_defs/repo/http.bzl:392:31: in <toplevel>
DEBUG: Rule 'absl' indicated that a canonical reproducible form can be obtained by modifying arguments integrity = "sha256-uLuPecpeLVedEx5yOoA3oB2F08oObs7AnNMnE07bnU0="
DEBUG: Repository absl instantiated at:
  /Users/pawan/Documents/code/github/hashtable-benchmarks/WORKSPACE:20:13: in <toplevel>
Repository rule http_archive defined at:
  /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/bazel_tools/tools/build_defs/repo/http.bzl:392:31: in <toplevel>
DEBUG: Rule 'facebook_folly' indicated that a canonical reproducible form can be obtained by modifying arguments integrity = "sha256-lSeICw6eahaNCKAnTBBycwFfHxU63x+Uhs6psjxYXUo="
DEBUG: Repository facebook_folly instantiated at:
  /Users/pawan/Documents/code/github/hashtable-benchmarks/WORKSPACE:59:13: in <toplevel>
Repository rule http_archive defined at:
  /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/bazel_tools/tools/build_defs/repo/http.bzl:392:31: in <toplevel>
DEBUG: Rule 'com_github_google_glog' indicated that a canonical reproducible form can be obtained by modifying arguments integrity = "sha256-BPcUQR5dEHX0jd1ejg3VHI2qrSzILiZzBLBD2k6OYVM="
DEBUG: Repository com_github_google_glog instantiated at:
  /Users/pawan/Documents/code/github/hashtable-benchmarks/WORKSPACE:46:13: in <toplevel>
Repository rule http_archive defined at:
  /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/bazel_tools/tools/build_defs/repo/http.bzl:392:31: in <toplevel>
ERROR: no such package '@@gflags//': The repository '@@gflags' could not be resolved: Repository '@@gflags' is not defined
ERROR: /private/var/tmp/_bazel_pawan/f80e19e3966aacb53af35e2f58beb37a/external/com_github_google_glog/BUILD.bazel:7:13: no such package '@@gflags//': The repository '@@gflags' could not be resolved: Repository '@@gflags' is not defined and referenced by '@@com_github_google_glog//:glog'
ERROR: Analysis of target '//:hashtable_benchmarks' failed; build aborted: Analysis failed
INFO: Elapsed time: 8.215s, Critical Path: 0.10s
INFO: 1 process: 1 internal.
ERROR: Build did NOT complete successfully
FAILED:
    Fetching repository @@boost; starting
    Fetching https://github.com/boostorg/boost/releases/download/boost-1.84.0/boost-1.84.0.tar.gz; 10.2 MiB (8.6%)
    Fetching repository @@com_github_google_double_conversion; starting
    Fetching repository @@bazel_tools+xcode_configure_extension+local_config_xcode; Fetching the default Xcode version
    Fetching https://github.com/google/double-conversion/archive/master.zip


Reply all
Reply to author
Forward
0 new messages