diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/benchmarks/lexer.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/test/benchmarks/lexer.cpp b/test/benchmarks/lexer.cpp index 0f3151f..4279d8b 100644 --- a/test/benchmarks/lexer.cpp +++ b/test/benchmarks/lexer.cpp @@ -15,11 +15,20 @@ protected: }; }; -BENCHMARK_F(SelectionOfNumbers, ParseStdRegex)(benchmark::State &state) { +BENCHMARK_F(SelectionOfNumbers, ParseStdRegex)(benchmark::State& state) { using namespace math::server::lexer::details; for (auto _ : state) { for (const auto& src : m_numbers) { - parse_number(src); + impl::std_parse_number(src); + } + } +} + +BENCHMARK_F(SelectionOfNumbers, ParseBoostRegex)(benchmark::State& state) { + using namespace math::server::lexer::details; + for (auto _ : state) { + for (const auto& src : m_numbers) { + impl::boost_parse_number(src); } } } |