proxygen
|
#include <folly/Benchmark.h>
#include <folly/experimental/flat_combining/test/FlatCombiningTestHelpers.h>
#include <folly/portability/GTest.h>
#include <glog/logging.h>
Go to the source code of this file.
Functions | |
DEFINE_bool (direct, false,"run direct measurement") | |
DEFINE_int32 (reps, 10,"number of reps") | |
DEFINE_int32 (ops, 100000,"number of operations per rep") | |
DEFINE_int32 (lines, 5,"number of cache lines accessed per operation") | |
DEFINE_int32 (numRecs, 8,"number of records") | |
DEFINE_int32 (work, 1000,"amount of unrelated work per operation") | |
BENCHMARK (no_combining_base, iters) | |
BENCHMARK_RELATIVE (no_combining_dup, iters) | |
BENCHMARK_DRAW_LINE () | |
BENCHMARK_RELATIVE (combining_dedicated_notc_sync, iters) | |
BENCHMARK_RELATIVE (combining_dedicated_notc_sync_dup, iters) | |
BENCHMARK_RELATIVE (combining_dedicated_notc_async, iters) | |
BENCHMARK_RELATIVE (combining_dedicated_notc_async_dup, iters) | |
BENCHMARK_RELATIVE (combining_dedicated_tc_sync, iters) | |
BENCHMARK_RELATIVE (combining_dedicated_tc_sync_dup, iters) | |
BENCHMARK_RELATIVE (combining_dedicated_tc_async, iters) | |
BENCHMARK_RELATIVE (combining_dedicated_tc_async_dup, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_notc_sync, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_notc_sync_dup, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_notc_async, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_notc_async_dup, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_tc_sync, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_tc_sync_dup, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_tc_async, iters) | |
BENCHMARK_RELATIVE (combining_no_dedicated_tc_async_dup, iters) | |
void | benchmarkSetup () |
TEST (FlatCombining, folly_benchmark) | |
static uint64_t | test (std::string name, bool fc_, bool dedicated_, bool tc_, bool syncops_, uint64_t base) |
TEST (FlatCombining, direct_measurement) | |
Variables | |
static std::vector< int > | nthr = {1, 2, 3, 4, 6, 8, 12, 16, 24, 32, 48, 64} |
static int | nthreads |
static bool | fc |
static bool | simple |
static bool | dedicated |
static bool | tc |
static bool | syncops |
BENCHMARK | ( | no_combining_base | , |
iters | |||
) |
Definition at line 43 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_DRAW_LINE | ( | ) |
BENCHMARK_RELATIVE | ( | no_combining_dup | , |
iters | |||
) |
Definition at line 61 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_notc_sync | , |
iters | |||
) |
Definition at line 80 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_notc_sync_dup | , |
iters | |||
) |
Definition at line 98 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_notc_async | , |
iters | |||
) |
Definition at line 114 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_notc_async_dup | , |
iters | |||
) |
Definition at line 129 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_tc_sync | , |
iters | |||
) |
Definition at line 145 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_tc_sync_dup | , |
iters | |||
) |
Definition at line 161 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_tc_async | , |
iters | |||
) |
Definition at line 177 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_dedicated_tc_async_dup | , |
iters | |||
) |
Definition at line 193 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_notc_sync | , |
iters | |||
) |
Definition at line 213 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_notc_sync_dup | , |
iters | |||
) |
Definition at line 230 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_notc_async | , |
iters | |||
) |
Definition at line 246 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_notc_async_dup | , |
iters | |||
) |
Definition at line 261 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_tc_sync | , |
iters | |||
) |
Definition at line 277 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_tc_sync_dup | , |
iters | |||
) |
Definition at line 293 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_tc_async | , |
iters | |||
) |
Definition at line 309 of file FlatCombiningBenchmark.cpp.
References dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
BENCHMARK_RELATIVE | ( | combining_no_dedicated_tc_async_dup | , |
iters | |||
) |
Definition at line 325 of file FlatCombiningBenchmark.cpp.
References folly::BENCHMARK_DRAW_LINE(), dedicated, fc, nthreads, folly::test::run_test(), simple, syncops, and tc.
void benchmarkSetup | ( | ) |
Definition at line 341 of file FlatCombiningBenchmark.cpp.
Referenced by TEST().
DEFINE_bool | ( | direct | , |
false | , | ||
"run direct measurement" | |||
) |
DEFINE_int32 | ( | reps | , |
10 | , | ||
"number of reps" | |||
) |
DEFINE_int32 | ( | ops | , |
100000 | , | ||
"number of operations per rep" | |||
) |
DEFINE_int32 | ( | lines | , |
5 | , | ||
"number of cache lines accessed per operation" | |||
) |
DEFINE_int32 | ( | numRecs | , |
8 | , | ||
"number of records" | |||
) |
DEFINE_int32 | ( | work | , |
1000 | , | ||
"amount of unrelated work per operation" | |||
) |
TEST | ( | FlatCombining | , |
folly_benchmark | |||
) |
Definition at line 347 of file FlatCombiningBenchmark.cpp.
References b, benchmarkSetup(), i, nthreads, folly::runBenchmarks(), simple, and string.
|
static |
Definition at line 367 of file FlatCombiningBenchmark.cpp.
References i, max, min, name, nthreads, folly::test::run_test(), simple, sum(), and uint64_t.
Referenced by folly::Bits< T, Traits >::blockCount(), clause11_21_4_2_a(), clause11_21_4_4(), clause11_21_4_6_1(), clause11_21_4_7_2_a2(), clause11_21_4_7_2_b2(), clause11_21_4_7_2_c2(), clause11_21_4_8_9_a(), TEST(), folly::io::test::TEST(), test_message(), test_message_pause(), test_multiple3(), test_parse_url(), test_scan(), zeroCopyOff(), zeroCopyOn(), and Foo::~Foo().
TEST | ( | FlatCombining | , |
direct_measurement | |||
) |
Definition at line 408 of file FlatCombiningBenchmark.cpp.
References benchmarkSetup(), i, nthreads, simple, string, test(), and uint64_t.
|
static |
Definition at line 38 of file FlatCombiningBenchmark.cpp.
Referenced by BENCHMARK(), BENCHMARK_RELATIVE(), and folly::test::run_test().
|
static |
Definition at line 36 of file FlatCombiningBenchmark.cpp.
Referenced by BENCHMARK(), and BENCHMARK_RELATIVE().
|
static |
Definition at line 34 of file FlatCombiningBenchmark.cpp.
|
static |
Definition at line 35 of file FlatCombiningBenchmark.cpp.
Referenced by array_bench(), BENCHMARK(), BENCHMARK_RELATIVE(), folly::test::fc_test(), holder_bench(), list_hoh_bench(), list_protect_all_bench(), local_bench(), obj_bench(), run_once(), folly::test::run_test(), runInThreadsAndWait(), TEST(), and test().
|
static |
Definition at line 37 of file FlatCombiningBenchmark.cpp.
Referenced by BENCHMARK(), BENCHMARK_RELATIVE(), main(), TEST(), test(), testing::internal::TEST(), and testing::internal::To::To().
|
static |
Definition at line 40 of file FlatCombiningBenchmark.cpp.
Referenced by BENCHMARK(), BENCHMARK_RELATIVE(), and folly::test::run_test().
|
static |
Definition at line 39 of file FlatCombiningBenchmark.cpp.
Referenced by BENCHMARK(), BENCHMARK_RELATIVE(), folly::test::fc_test(), folly::hazptr_array< 3, Atom >::hazptr_array(), folly::hazptr_local< M, Atom >::hazptr_local(), folly::FlatCombining< FcSimpleExample< Mutex, Atom >, Mutex, Atom >::requestOp(), folly::test::run_test(), TEST(), folly::hazptr_array< 3, Atom >::~hazptr_array(), and folly::hazptr_local< M, Atom >::~hazptr_local().