Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there anyone run it ok? #3

Open
renjc0816 opened this issue Sep 7, 2021 · 2 comments
Open

Is there anyone run it ok? #3

renjc0816 opened this issue Sep 7, 2021 · 2 comments

Comments

@renjc0816
Copy link

I tried the 'Getting Started' and failed in 'Initialize the submodules'.
Than i changed the '.gitmodules' and 'CMakeLists.txt' .
But the//Boost download URL BOOST_URL:STRING=https://dl.bintray.com/boostorg/release/1.66.0/source/boost_1_66_0.tar.bz2
in CMakeCache.txt is 403 forbiden.
So i changed it into https://boostorg.jfrog.io/ui/native/main/release/1.77.0/source/boost_1_77_0.tar.bz2 with corresponding hash.
It downloaded successfully but crashed here again :third-party/boost-cmake/CMakeLists.txt:11 (include) refer to CMakeList.txt
if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE Release) endif().
In fact all the CMakeList.txt in file i have tried to cmake and none okay.
so..how can i run the code?

@l-iberty
Copy link

you should change hot/third-party/boost-cmake/CMakeLists.txt, not that CMakeLists.txt you mentioned

set(BOOST_URL "https://boostorg.jfrog.io/artifactory/main/release/1.79.0/source/boost_1_79_0.tar.bz2" CACHE STRING "Boost download URL")
set(BOOST_URL_SHA256 "475d589d51a7f8b3ba2ba4eda022b170e562ca3b760ee922c146b6c65856ef39" CACHE STRING "Boost download URL SHA256 checksum")

change the two lines as you did

@gshanemiller
Copy link

gshanemiller commented Jun 5, 2022

I was able to after major surgery by removing everything from cmake except the single threaded trie code. I removed all the submodules. I installed boost with apt. I also had to disable a lot of C++ warnings; there are a lot if one turns on -Wall, -Wpendantic -Wextra.

After futzing around with all this, I was able to run 4,545,921 find/insertions on strings containing 569,785 unique values with 236ns/op insert, and 82ns/find on a Xeon E-2278G 3.4Ghz. Average keysize was 6.3 chars using this dictionary file: https://www.gutenberg.org/cache/epub/29765/pg29765.txt

In my case I know the length of the strings (no need for strlen). I probably can use SIMD to do a faster compare than strcmp. I also have not plugged in Microsoft's mimalloc library, which is supposed to outperform most of the alternatives (jemalloc etc.). I haven't done any of these optimizations.

My code is here: https://github.com/rodgarrison/kvbench

If I can get insert to run at < 100ns this trie code would run at the same order of 10 as hashing. Currently Facebooks F14 hash is the best if I know of. F14's does the same work with 31ns/op insert, and 27ns/op find.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants