MCPcopy Create free account
hub / github.com/catboost/catboost / BenchDecode

Function BenchDecode

library/cpp/string_utils/base64/bench/main.cpp:121–131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

119
120template <typename T>
121static inline void BenchDecode(T& d, const NBench::NCpu::TParams& iface) {
122 for (const auto it : xrange(iface.Iterations())) {
123 Y_UNUSED(it);
124 for (size_t i = 0; i < d.Size; ++i) {
125 NBench::Escape(d.PlaceToDecode[i].data());
126 Y_DO_NOT_OPTIMIZE_AWAY(
127 Base64Decode(d.PlaceToDecode[i].data(), (const char*)d.DataEncoded[i].data(), (const char*)(d.DataEncoded[i].data() + d.DataEncoded[i].size())));
128 NBench::Clobber();
129 }
130 }
131}
132
133Y_CPU_BENCHMARK(EncodeF1, iface) {
134 auto& d = *Singleton<FSRDH_1>();

Callers 1

Y_CPU_BENCHMARKFunction · 0.85

Calls 8

xrangeFunction · 0.85
Y_UNUSEDFunction · 0.85
ClobberFunction · 0.85
EscapeFunction · 0.50
Base64DecodeFunction · 0.50
IterationsMethod · 0.45
dataMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected