[llvm] r295112 - Use "%zd" format specifier for printing number of testcases executed.
Kostya Serebryany via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 14 14:14:36 PST 2017
Author: kcc
Date: Tue Feb 14 16:14:36 2017
New Revision: 295112
URL: http://llvm.org/viewvc/llvm-project?rev=295112&view=rev
Log:
Use "%zd" format specifier for printing number of testcases executed.
Summary:
This helps to avoid signed integer overflow after running a fast fuzz target for several hours, e.g.:
<...>
Done -1097903291 runs in 54001 second(s)
Reviewers: kcc
Reviewed By: kcc
Differential Revision: https://reviews.llvm.org/D29941
Modified:
llvm/trunk/lib/Fuzzer/FuzzerDriver.cpp
Modified: llvm/trunk/lib/Fuzzer/FuzzerDriver.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Fuzzer/FuzzerDriver.cpp?rev=295112&r1=295111&r2=295112&view=diff
==============================================================================
--- llvm/trunk/lib/Fuzzer/FuzzerDriver.cpp (original)
+++ llvm/trunk/lib/Fuzzer/FuzzerDriver.cpp Tue Feb 14 16:14:36 2017
@@ -567,7 +567,7 @@ int FuzzerDriver(int *argc, char ***argv
F->Loop();
if (Flags.verbosity)
- Printf("Done %d runs in %zd second(s)\n", F->getTotalNumberOfRuns(),
+ Printf("Done %zd runs in %zd second(s)\n", F->getTotalNumberOfRuns(),
F->secondsSinceProcessStartUp());
F->PrintFinalStats();
More information about the llvm-commits
mailing list