#  Copyright (C) GridGain Systems. All Rights Reserved.
#  _________        _____ __________________        _____
#  __  ____/___________(_)______  /__  ____/______ ____(_)_______
#  _  / __  __  ___/__  / _  __  / _  / __  _  __ `/__  / __  __ \
#  / /_/ /  _  /    _  /  / /_/ /  / /_/ /  / /_/ / _  /  _  / / /
#  \____/   /_/     /_/   \_,__/   \____/   \__,_/  /_/   /_/ /_/

# Each bench binary covers one client API surface. Splitting into separate
# executables keeps reports focused and lets each suite be built / run in
# isolation. Shared helpers live in the sibling bench-common/ subdir.
function(add_client_bench TARGET SOURCE)
    add_executable(${TARGET} ${SOURCE})
    # bench-common provides main() with CLI default injection, so we do NOT link
    # benchmark::benchmark_main (that would clash with our main). benchmark::benchmark itself
    # arrives transitively through gridgain-bench-common's PUBLIC link.
    target_link_libraries(${TARGET} PRIVATE
        gridgain-bench-common
    )
endfunction()

add_client_bench(gridgain-record-view-benchmark   record_view_bench.cpp)
add_client_bench(gridgain-kv-view-benchmark       key_value_view_bench.cpp)
add_client_bench(gridgain-cursor-benchmark        cursor_bench.cpp)
