aboutsummaryrefslogtreecommitdiff
path: root/src/bench/logging.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/bench/logging.cpp')
-rw-r--r--src/bench/logging.cpp44
1 files changed, 7 insertions, 37 deletions
diff --git a/src/bench/logging.cpp b/src/bench/logging.cpp
index 86891af8fe..3bf2b7edb2 100644
--- a/src/bench/logging.cpp
+++ b/src/bench/logging.cpp
@@ -28,18 +28,6 @@ static void Logging(benchmark::Bench& bench, const std::vector<const char*>& ext
bench.run([&] { log(); });
}
-static void LogPrintLevelWithThreadNames(benchmark::Bench& bench)
-{
- Logging(bench, {"-logthreadnames=1", "-debug=net"}, [] {
- LogPrintLevel(BCLog::NET, BCLog::Level::Error, "%s\n", "test"); });
-}
-
-static void LogPrintLevelWithoutThreadNames(benchmark::Bench& bench)
-{
- Logging(bench, {"-logthreadnames=0", "-debug=net"}, [] {
- LogPrintLevel(BCLog::NET, BCLog::Level::Error, "%s\n", "test"); });
-}
-
static void LogWithDebug(benchmark::Bench& bench)
{
Logging(bench, {"-logthreadnames=0", "-debug=net"}, [] { LogDebug(BCLog::NET, "%s\n", "test"); });
@@ -50,45 +38,27 @@ static void LogWithoutDebug(benchmark::Bench& bench)
Logging(bench, {"-logthreadnames=0", "-debug=0"}, [] { LogDebug(BCLog::NET, "%s\n", "test"); });
}
-static void LogPrintfCategoryWithThreadNames(benchmark::Bench& bench)
-{
- Logging(bench, {"-logthreadnames=1", "-debug=net"}, [] {
- LogPrintfCategory(BCLog::NET, "%s\n", "test");
- });
-}
-
-static void LogPrintfCategoryWithoutThreadNames(benchmark::Bench& bench)
-{
- Logging(bench, {"-logthreadnames=0", "-debug=net"}, [] {
- LogPrintfCategory(BCLog::NET, "%s\n", "test");
- });
-}
-
-static void LogPrintfWithThreadNames(benchmark::Bench& bench)
+static void LogWithThreadNames(benchmark::Bench& bench)
{
- Logging(bench, {"-logthreadnames=1"}, [] { LogPrintf("%s\n", "test"); });
+ Logging(bench, {"-logthreadnames=1"}, [] { LogInfo("%s\n", "test"); });
}
-static void LogPrintfWithoutThreadNames(benchmark::Bench& bench)
+static void LogWithoutThreadNames(benchmark::Bench& bench)
{
- Logging(bench, {"-logthreadnames=0"}, [] { LogPrintf("%s\n", "test"); });
+ Logging(bench, {"-logthreadnames=0"}, [] { LogInfo("%s\n", "test"); });
}
static void LogWithoutWriteToFile(benchmark::Bench& bench)
{
// Disable writing the log to a file, as used for unit tests and fuzzing in `MakeNoLogFileContext`.
Logging(bench, {"-nodebuglogfile", "-debug=1"}, [] {
- LogPrintf("%s\n", "test");
+ LogInfo("%s\n", "test");
LogDebug(BCLog::NET, "%s\n", "test");
});
}
-BENCHMARK(LogPrintLevelWithThreadNames, benchmark::PriorityLevel::HIGH);
-BENCHMARK(LogPrintLevelWithoutThreadNames, benchmark::PriorityLevel::HIGH);
BENCHMARK(LogWithDebug, benchmark::PriorityLevel::HIGH);
BENCHMARK(LogWithoutDebug, benchmark::PriorityLevel::HIGH);
-BENCHMARK(LogPrintfCategoryWithThreadNames, benchmark::PriorityLevel::HIGH);
-BENCHMARK(LogPrintfCategoryWithoutThreadNames, benchmark::PriorityLevel::HIGH);
-BENCHMARK(LogPrintfWithThreadNames, benchmark::PriorityLevel::HIGH);
-BENCHMARK(LogPrintfWithoutThreadNames, benchmark::PriorityLevel::HIGH);
+BENCHMARK(LogWithThreadNames, benchmark::PriorityLevel::HIGH);
+BENCHMARK(LogWithoutThreadNames, benchmark::PriorityLevel::HIGH);
BENCHMARK(LogWithoutWriteToFile, benchmark::PriorityLevel::HIGH);