Warning, /sdk/heaptrack/tests/benchmarks/CMakeLists.txt is written in an unsupported language. File is not indexed.

0001 include_directories(
0002     ../..
0003     ${Boost_INCLUDE_DIRS}
0004 )
0005 
0006 include (CheckCXXSourceCompiles)
0007 check_cxx_source_compiles(
0008     "#include <malloc.h>
0009     int main() { return mallinfo2().uordblks > 0; }"
0010     HAVE_MALLOC_H)
0011 
0012 if (HAVE_MALLOC_H)
0013     add_executable(bench_pointermap bench_pointermap.cpp)
0014     set_target_properties(bench_pointermap PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${BIN_INSTALL_DIR}")
0015     target_link_libraries(bench_pointermap PRIVATE tsl::robin_map)
0016 
0017     add_executable(bench_pointerhash bench_pointerhash.cpp)
0018     set_target_properties(bench_pointerhash PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${BIN_INSTALL_DIR}")
0019     target_link_libraries(bench_pointerhash PRIVATE tsl::robin_map)
0020 
0021     add_executable(measure_malloc_overhead measure_malloc_overhead.cpp)
0022     set_target_properties(measure_malloc_overhead PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${BIN_INSTALL_DIR}")
0023 endif()
0024 
0025 add_executable(bench_linereader bench_linereader.cpp)
0026 set_target_properties(bench_linereader PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${BIN_INSTALL_DIR}")
0027 
0028 if (TARGET heaptrack_gui_private)
0029     add_executable(bench_parser bench_parser.cpp)
0030     set_target_properties(bench_parser PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${BIN_INSTALL_DIR}")
0031     target_link_libraries(bench_parser sharedprint heaptrack_gui_private)
0032 endif()
0033 
0034 if (TARGET Qt${QT_VERSION_MAJOR}::Core AND Boost_CONTAINER_FOUND)
0035     add_executable(bench_tree bench_tree.cpp)
0036     set_target_properties(bench_tree PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/${BIN_INSTALL_DIR}")
0037     target_include_directories(bench_tree PRIVATE ${Boost_INCLUDE_DIRS})
0038     target_link_libraries(bench_tree Qt${QT_VERSION_MAJOR}::Core
0039     ${Boost_CONTAINER_LIBRARY})
0040 endif()