mirror of
https://github.com/gabime/spdlog.git
synced 2024-11-15 16:35:45 +08:00
fix formatter bench
This commit is contained in:
parent
ccfa3f03b0
commit
e8d99cee70
@ -8,19 +8,6 @@
|
||||
#include "spdlog/spdlog.h"
|
||||
#include "spdlog/details/pattern_formatter.h"
|
||||
|
||||
void bench_scoped_pad(benchmark::State &state, size_t wrapped_size, spdlog::details::padding_info padinfo)
|
||||
{
|
||||
fmt::memory_buffer dest;
|
||||
for (auto _ : state)
|
||||
{
|
||||
{
|
||||
spdlog::details::scoped_pad p(wrapped_size, padinfo, dest);
|
||||
benchmark::DoNotOptimize(p);
|
||||
dest.clear();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void bench_formatter(benchmark::State &state, std::string pattern)
|
||||
{
|
||||
auto formatter = spdlog::details::make_unique<spdlog::pattern_formatter>(pattern);
|
||||
|
Loading…
Reference in New Issue
Block a user