userver
C++ Async Framework
Toggle main menu visibility
Loading...
Searching...
No Matches
samples/hello_service/benchmarks/say_hello_bench.cpp
#include <
userver/utest/using_namespace_userver.hpp
>
#include "say_hello.hpp"
#include <string_view>
#include <benchmark/benchmark.h>
#include <
userver/engine/run_standalone.hpp
>
void
HelloBenchmark(benchmark::State& state) {
engine::RunStandalone
([&] {
for
(
auto
_ : state) {
auto
result = samples::hello::SayHelloTo(
"userver"
);
benchmark::DoNotOptimize(result);
}
});
}
BENCHMARK(HelloBenchmark);
Generated on
for userver by
Doxygen
1.17.0