aboutsummaryrefslogtreecommitdiffstats
path: root/util/charset/benchmark
diff options
context:
space:
mode:
authorIlnur Khuziev <ilnur.khuziev@yandex.ru>2022-02-10 16:46:13 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:46:13 +0300
commit736dcd8ca259457a136f2f9f9168c44643914323 (patch)
treeddd46a036d68bfa83aa11b892f31243ea6b068a1 /util/charset/benchmark
parent9bf2fa2b060c9881d3135c2208c624a1dd546ecc (diff)
downloadydb-736dcd8ca259457a136f2f9f9168c44643914323.tar.gz
Restoring authorship annotation for Ilnur Khuziev <ilnur.khuziev@yandex.ru>. Commit 1 of 2.
Diffstat (limited to 'util/charset/benchmark')
-rw-r--r--util/charset/benchmark/to_lower/main.cpp2
-rw-r--r--util/charset/benchmark/utf8_to_wide/main.cpp104
2 files changed, 53 insertions, 53 deletions
diff --git a/util/charset/benchmark/to_lower/main.cpp b/util/charset/benchmark/to_lower/main.cpp
index e95fdc2371..56599b1770 100644
--- a/util/charset/benchmark/to_lower/main.cpp
+++ b/util/charset/benchmark/to_lower/main.cpp
@@ -1,4 +1,4 @@
-#include <library/cpp/testing/benchmark/bench.h>
+#include <library/cpp/testing/benchmark/bench.h>
#include <util/charset/wide.h>
#include <util/generic/singleton.h>
diff --git a/util/charset/benchmark/utf8_to_wide/main.cpp b/util/charset/benchmark/utf8_to_wide/main.cpp
index 09fa567fe5..3a56c34361 100644
--- a/util/charset/benchmark/utf8_to_wide/main.cpp
+++ b/util/charset/benchmark/utf8_to_wide/main.cpp
@@ -1,4 +1,4 @@
-#include <library/cpp/testing/benchmark/bench.h>
+#include <library/cpp/testing/benchmark/bench.h>
#include <util/random/fast.h>
#include <util/random/random.h>
@@ -103,59 +103,59 @@ inline size_t UTF8ToWideImplSSE(const char* text, size_t len, TCharType* dest, s
return UTF8ToWideImpl(text, len, dest, written);
}
-static wchar16 WBUF_UTF16[10000000];
-static wchar32 WBUF_UTF32[10000000];
+static wchar16 WBUF_UTF16[10000000];
+static wchar32 WBUF_UTF32[10000000];
-#define UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(impl, length, to) \
- Y_CPU_BENCHMARK(UTF8ToWideASCII##impl##length##to, iface) { \
- const auto& data = *Singleton<RAS##length>(); \
- for (size_t x = 0; x < iface.Iterations(); ++x) { \
- size_t written = 0; \
- Y_DO_NOT_OPTIMIZE_AWAY(UTF8ToWideImpl##impl<false>(data.begin(), data.size(), WBUF_##to, written)); \
- } \
+#define UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(impl, length, to) \
+ Y_CPU_BENCHMARK(UTF8ToWideASCII##impl##length##to, iface) { \
+ const auto& data = *Singleton<RAS##length>(); \
+ for (size_t x = 0; x < iface.Iterations(); ++x) { \
+ size_t written = 0; \
+ Y_DO_NOT_OPTIMIZE_AWAY(UTF8ToWideImpl##impl<false>(data.begin(), data.size(), WBUF_##to, written)); \
+ } \
}
-#define UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(impl, length, to) \
- Y_CPU_BENCHMARK(UTF8ToWideRU##impl##length##to, iface) { \
- const auto& data = *Singleton<RRS##length>(); \
- for (size_t x = 0; x < iface.Iterations(); ++x) { \
- size_t written = 0; \
- Y_DO_NOT_OPTIMIZE_AWAY(UTF8ToWideImpl##impl<false>(data.begin(), data.size(), WBUF_##to, written)); \
- } \
+#define UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(impl, length, to) \
+ Y_CPU_BENCHMARK(UTF8ToWideRU##impl##length##to, iface) { \
+ const auto& data = *Singleton<RRS##length>(); \
+ for (size_t x = 0; x < iface.Iterations(); ++x) { \
+ size_t written = 0; \
+ Y_DO_NOT_OPTIMIZE_AWAY(UTF8ToWideImpl##impl<false>(data.begin(), data.size(), WBUF_##to, written)); \
+ } \
}
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 10, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 10, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000000, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000000, UTF16);
-
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 10, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 10, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000000, UTF16);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000000, UTF16);
-
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 10, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 10, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000000, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000000, UTF32);
-
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 10, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 10, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000000, UTF32);
-UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000000, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 10, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 10, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000000, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000000, UTF16);
+
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 10, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 10, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000000, UTF16);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000000, UTF16);
+
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 10, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 10, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(Scalar, 1000000, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_ASCII(SSE, 1000000, UTF32);
+
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 10, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 10, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(Scalar, 1000000, UTF32);
+UTF8_TO_WIDE_SCALAR_BENCHMARK_RU(SSE, 1000000, UTF32);