mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-09-29 11:23:54 +02:00
bench: Use LogInfo instead of the deprecated alias LogPrintf
This commit is contained in:
@@ -64,21 +64,21 @@ static void LogPrintfCategoryWithoutThreadNames(benchmark::Bench& bench)
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
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)
|
static void LogWithoutWriteToFile(benchmark::Bench& bench)
|
||||||
{
|
{
|
||||||
// Disable writing the log to a file, as used for unit tests and fuzzing in `MakeNoLogFileContext`.
|
// Disable writing the log to a file, as used for unit tests and fuzzing in `MakeNoLogFileContext`.
|
||||||
Logging(bench, {"-nodebuglogfile", "-debug=1"}, [] {
|
Logging(bench, {"-nodebuglogfile", "-debug=1"}, [] {
|
||||||
LogPrintf("%s\n", "test");
|
LogInfo("%s\n", "test");
|
||||||
LogDebug(BCLog::NET, "%s\n", "test");
|
LogDebug(BCLog::NET, "%s\n", "test");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -89,6 +89,6 @@ BENCHMARK(LogWithDebug, benchmark::PriorityLevel::HIGH);
|
|||||||
BENCHMARK(LogWithoutDebug, benchmark::PriorityLevel::HIGH);
|
BENCHMARK(LogWithoutDebug, benchmark::PriorityLevel::HIGH);
|
||||||
BENCHMARK(LogPrintfCategoryWithThreadNames, benchmark::PriorityLevel::HIGH);
|
BENCHMARK(LogPrintfCategoryWithThreadNames, benchmark::PriorityLevel::HIGH);
|
||||||
BENCHMARK(LogPrintfCategoryWithoutThreadNames, benchmark::PriorityLevel::HIGH);
|
BENCHMARK(LogPrintfCategoryWithoutThreadNames, benchmark::PriorityLevel::HIGH);
|
||||||
BENCHMARK(LogPrintfWithThreadNames, benchmark::PriorityLevel::HIGH);
|
BENCHMARK(LogWithThreadNames, benchmark::PriorityLevel::HIGH);
|
||||||
BENCHMARK(LogPrintfWithoutThreadNames, benchmark::PriorityLevel::HIGH);
|
BENCHMARK(LogWithoutThreadNames, benchmark::PriorityLevel::HIGH);
|
||||||
BENCHMARK(LogWithoutWriteToFile, benchmark::PriorityLevel::HIGH);
|
BENCHMARK(LogWithoutWriteToFile, benchmark::PriorityLevel::HIGH);
|
||||||
|
Reference in New Issue
Block a user