Introduce benchmark test for rotate_cpx_vector

This commit introduces google benchmark library and one benchmark for
rotate_cpx_vector.  Also extracted common tools used in testcases for
generation and allocation of byte aligned vectors in phy_test_tools.hpp
This commit is contained in:
Bartosz Podrygajlo
2024-08-14 07:43:07 +02:00
committed by Robert Schmidt
parent 46a1d2a621
commit 0883904891
6 changed files with 242 additions and 69 deletions

View File

@@ -2367,6 +2367,19 @@ if(ENABLE_TESTS)
add_library(GTest::gtest ALIAS gtest)
add_library(GTest::gtest_main ALIAS gtest_main)
endif()
find_package(benchmark)
if (NOT benchmark_FOUND)
message(STATUS "benchmark package not found, will download benchmark automatically. To prevent that install google benchmark on your system (libbenchmark-dev)")
include(FetchContent)
set(BENCHMARK_ENABLE_TESTING OFF)
FetchContent_Declare(
benchmark
GIT_REPOSITORY https://github.com/google/benchmark.git
GIT_TAG v1.9.0
)
FetchContent_MakeAvailable(benchmark)
endif()
endif()
add_subdirectory(common)