Skip to content

Commit bdc9339

Browse files
authored
Merge pull request #49 from bkille/improve-shift
Improve shift and benchmarking
2 parents 70eb1d4 + 007d772 commit bdc9339

37 files changed

+1840
-426
lines changed

.gitmodules

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[submodule "benchmark/ext/BitArray"]
2+
path = benchmark/ext/BitArray
3+
url = https://github.com/noporpoise/BitArray.git
4+
[submodule "benchmark/ext/itsy_bitsy"]
5+
path = benchmark/ext/itsy_bitsy
6+
url = https://github.com/ThePhD/itsy_bitsy.git
7+
[submodule "benchmark/ext/dynamic_bitset"]
8+
path = benchmark/ext/dynamic_bitset
9+
url = https://github.com/pinam45/dynamic_bitset.git

CMakeLists.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
cmake_minimum_required(VERSION 3.14)
33

44
# set the project name
5-
project(Bit-Vector VERSION 0.1.1)
5+
project(Bit-Vector VERSION 0.3.0)
66

77
# set output directory of builds
88
#set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
@@ -46,6 +46,7 @@ option(BITLIB_HWY "Build with google highway SIMD extensions" OFF)
4646
option(BITLIB_BENCHMARK "Build bitlib benchmarks" OFF)
4747
option(BITLIB_EXAMPLE "Build bitlib examples" OFF)
4848
option(BITLIB_TEST "Build bitlib tests" OFF)
49+
option(BITLIB_PROFILE "Buid simple example for profiling" OFF)
4950
option(BITLIB_COVERAGE "Compute test coverage" OFF)
5051

5152
if (BITLIB_HWY)
@@ -64,3 +65,7 @@ if(BITLIB_TEST)
6465
add_subdirectory(test)
6566
endif()
6667

68+
if(BITLIB_PROFILE)
69+
add_subdirectory(profile)
70+
endif()
71+

README.md

Lines changed: 109 additions & 75 deletions
Large diffs are not rendered by default.

benchmark/CMakeLists.txt

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,15 @@ set(CMAKE_BUILD_TYPE Release)
1212
file(GLOB BENCH_SOURCES "src/*.cc")
1313
add_executable(bitlib-bench ${BENCH_SOURCES})
1414

15+
add_subdirectory(ext/dynamic_bitset)
16+
1517
# specify benchmark-specific libraries
16-
include_directories(${googlebench_SOURCE_DIR}/benchmark/include src/utils)
17-
target_link_libraries(bitlib-bench PRIVATE benchmark::benchmark -pthread)
18+
include_directories(
19+
${googlebench_SOURCE_DIR}/benchmark/include
20+
src/utils
21+
ext/BitArray
22+
ext/itsy_bitsy/include)
23+
target_link_libraries(bitlib-bench PRIVATE benchmark::benchmark -pthread ${CMAKE_CURRENT_LIST_DIR}/ext/BitArray/libbitarr.a sul::dynamic_bitset)
1824

1925
target_compile_options(bitlib-bench PUBLIC -O3 -DNDEBUG -march=native -Wpedantic)
2026
install(TARGETS bitlib-bench DESTINATION .)

0 commit comments

Comments
 (0)