2020-04-06 07:43:37 +08:00
|
|
|
include_directories( . linux )
|
2020-08-09 06:19:56 +08:00
|
|
|
link_libraries(simdjson-windows-headers test-data)
|
|
|
|
|
|
|
|
|
|
|
|
if (TARGET benchmark::benchmark)
|
|
|
|
add_executable(bench_sax bench_sax.cpp)
|
|
|
|
target_link_libraries(bench_sax simdjson-internal-flags simdjson-include-source benchmark::benchmark)
|
2020-08-21 01:52:44 +08:00
|
|
|
# Don't pass all the compiler options on ARM
|
|
|
|
CHECK_CXX_COMPILER_FLAG(-mavx2 HAVE_MAVX2_FLAG)
|
|
|
|
if (HAVE_MAVX2_FLAG)
|
|
|
|
target_compile_options(bench_sax PRIVATE -mavx2 -mbmi -mpclmul -mlzcnt)
|
2020-09-02 22:43:28 +08:00
|
|
|
target_compile_definitions(bench_sax PRIVATE SIMDJSON_IMPLEMENTATION=haswell)
|
2020-08-21 01:52:44 +08:00
|
|
|
# Some ARM compilers "support" -mavx2 but don't use it. This makes them not complain.
|
|
|
|
CHECK_CXX_COMPILER_FLAG(-Qunused-arguments HAVE_QUNUSED_ARGUMENTS_FLAG)
|
|
|
|
if (HAVE_QUNUSED_ARGUMENTS_FLAG)
|
|
|
|
target_compile_options(bench_sax PRIVATE -Qunused-arguments)
|
|
|
|
endif()
|
|
|
|
endif()
|
2020-08-09 06:19:56 +08:00
|
|
|
endif (TARGET benchmark::benchmark)
|
|
|
|
|
|
|
|
link_libraries(simdjson simdjson-flags)
|
2020-05-03 04:00:00 +08:00
|
|
|
add_executable(benchfeatures benchfeatures.cpp)
|
2020-04-06 23:24:54 +08:00
|
|
|
add_executable(get_corpus_benchmark get_corpus_benchmark.cpp)
|
2019-08-13 04:03:56 +08:00
|
|
|
add_executable(perfdiff perfdiff.cpp)
|
2020-04-07 08:57:24 +08:00
|
|
|
add_executable(parse parse.cpp)
|
|
|
|
add_executable(parse_stream parse_stream.cpp)
|
|
|
|
add_executable(statisticalmodel statisticalmodel.cpp)
|
|
|
|
|
|
|
|
add_executable(parse_noutf8validation parse.cpp)
|
|
|
|
target_compile_definitions(parse_noutf8validation PRIVATE SIMDJSON_SKIPUTF8VALIDATION)
|
|
|
|
add_executable(parse_nonumberparsing parse.cpp)
|
|
|
|
target_compile_definitions(parse_nonumberparsing PRIVATE SIMDJSON_SKIPNUMBERPARSING)
|
|
|
|
add_executable(parse_nostringparsing parse.cpp)
|
|
|
|
target_compile_definitions(parse_nostringparsing PRIVATE SIMDJSON_SKIPSTRINGPARSING)
|
2020-02-15 07:20:17 +08:00
|
|
|
|
2020-06-25 03:13:47 +08:00
|
|
|
if (TARGET competition-all)
|
2020-04-08 00:25:11 +08:00
|
|
|
add_executable(distinctuseridcompetition distinctuseridcompetition.cpp)
|
|
|
|
target_link_libraries(distinctuseridcompetition competition-core)
|
2020-10-04 16:00:09 +08:00
|
|
|
|
2020-04-08 00:25:11 +08:00
|
|
|
add_executable(minifiercompetition minifiercompetition.cpp)
|
|
|
|
target_link_libraries(minifiercompetition competition-core)
|
2020-10-04 16:00:09 +08:00
|
|
|
|
2020-04-08 00:25:11 +08:00
|
|
|
add_executable(parseandstatcompetition parseandstatcompetition.cpp)
|
|
|
|
target_link_libraries(parseandstatcompetition competition-core)
|
2020-10-04 16:00:09 +08:00
|
|
|
|
2020-04-08 00:25:11 +08:00
|
|
|
add_executable(parsingcompetition parsingcompetition.cpp)
|
|
|
|
target_link_libraries(parsingcompetition competition-core)
|
2020-10-04 16:00:09 +08:00
|
|
|
|
2020-04-08 00:25:11 +08:00
|
|
|
add_executable(allparsingcompetition parsingcompetition.cpp)
|
|
|
|
target_link_libraries(allparsingcompetition competition-all)
|
|
|
|
target_compile_definitions(allparsingcompetition PRIVATE ALLPARSER)
|
|
|
|
endif()
|
2020-04-17 04:49:17 +08:00
|
|
|
|
2020-08-09 06:19:56 +08:00
|
|
|
if (TARGET benchmark::benchmark)
|
|
|
|
link_libraries(benchmark::benchmark)
|
|
|
|
add_executable(bench_parse_call bench_parse_call.cpp)
|
|
|
|
add_executable(bench_dom_api bench_dom_api.cpp)
|
|
|
|
endif()
|
|
|
|
|
2020-04-28 02:20:05 +08:00
|
|
|
include(checkperf.cmake)
|