diff options
author | yazevnul <yazevnul@yandex-team.ru> | 2022-02-10 16:46:48 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:46:48 +0300 |
commit | 9abfb1a53b7f7b791444d1378e645d8fad9b06ed (patch) | |
tree | 49e222ea1c5804306084bb3ae065bb702625360f /util/system/benchmark/create_destroy_thread | |
parent | 8cbc307de0221f84c80c42dcbe07d40727537e2c (diff) | |
download | ydb-9abfb1a53b7f7b791444d1378e645d8fad9b06ed.tar.gz |
Restoring authorship annotation for <yazevnul@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'util/system/benchmark/create_destroy_thread')
4 files changed, 49 insertions, 49 deletions
diff --git a/util/system/benchmark/create_destroy_thread/main.cpp b/util/system/benchmark/create_destroy_thread/main.cpp index 8f9f5c9850..0ca2a9d96f 100644 --- a/util/system/benchmark/create_destroy_thread/main.cpp +++ b/util/system/benchmark/create_destroy_thread/main.cpp @@ -1,26 +1,26 @@ #include <library/cpp/testing/benchmark/bench.h> - -#include <util/system/thread.h> - -static void* DoNothing(void*) noexcept { - return nullptr; -} - -Y_CPU_BENCHMARK(CreateDestroyThread, iface) { - for (size_t i = 0, iEnd = iface.Iterations(); i < iEnd; ++i) { - NBench::Clobber(); - TThread t(&DoNothing, nullptr); - Y_DO_NOT_OPTIMIZE_AWAY(t); - NBench::Clobber(); - } -} - -Y_CPU_BENCHMARK(CreateRunDestroyThread, iface) { - for (size_t i = 0, iEnd = iface.Iterations(); i < iEnd; ++i) { - NBench::Clobber(); - TThread t(&DoNothing, nullptr); - t.Start(); - NBench::Escape(t.Join()); - NBench::Clobber(); - } -} + +#include <util/system/thread.h> + +static void* DoNothing(void*) noexcept { + return nullptr; +} + +Y_CPU_BENCHMARK(CreateDestroyThread, iface) { + for (size_t i = 0, iEnd = iface.Iterations(); i < iEnd; ++i) { + NBench::Clobber(); + TThread t(&DoNothing, nullptr); + Y_DO_NOT_OPTIMIZE_AWAY(t); + NBench::Clobber(); + } +} + +Y_CPU_BENCHMARK(CreateRunDestroyThread, iface) { + for (size_t i = 0, iEnd = iface.Iterations(); i < iEnd; ++i) { + NBench::Clobber(); + TThread t(&DoNothing, nullptr); + t.Start(); + NBench::Escape(t.Join()); + NBench::Clobber(); + } +} diff --git a/util/system/benchmark/create_destroy_thread/metrics/main.py b/util/system/benchmark/create_destroy_thread/metrics/main.py index 3ee8f8a2ea..45564cda7f 100644 --- a/util/system/benchmark/create_destroy_thread/metrics/main.py +++ b/util/system/benchmark/create_destroy_thread/metrics/main.py @@ -1,7 +1,7 @@ -import yatest.common as yc - - -def test_export_metrics(metrics): +import yatest.common as yc + + +def test_export_metrics(metrics): metrics.set_benchmark( yc.execute_benchmark('util/system/benchmark/create_destroy_thread/create_destroy_thread', threads=8) ) diff --git a/util/system/benchmark/create_destroy_thread/metrics/ya.make b/util/system/benchmark/create_destroy_thread/metrics/ya.make index 9498e47812..d526487e1a 100644 --- a/util/system/benchmark/create_destroy_thread/metrics/ya.make +++ b/util/system/benchmark/create_destroy_thread/metrics/ya.make @@ -1,21 +1,21 @@ -OWNER( - yazevnul +OWNER( + yazevnul g:util -) +) SUBSCRIBER(g:util-subscribers) - + PY2TEST() - + SIZE(LARGE) - -TAG( + +TAG( ya:force_sandbox - sb:intel_e5_2660v1 + sb:intel_e5_2660v1 ya:fat -) - +) + TEST_SRCS(main.py) - + DEPENDS(util/system/benchmark/create_destroy_thread) - -END() + +END() diff --git a/util/system/benchmark/create_destroy_thread/ya.make b/util/system/benchmark/create_destroy_thread/ya.make index c50840aaad..03eb0ec8e0 100644 --- a/util/system/benchmark/create_destroy_thread/ya.make +++ b/util/system/benchmark/create_destroy_thread/ya.make @@ -1,9 +1,9 @@ OWNER(yazevnul) - + Y_BENCHMARK() - -SRCS( - main.cpp -) - -END() + +SRCS( + main.cpp +) + +END() |