Skip to content
This repository was archived by the owner on Oct 23, 2023. It is now read-only.

Commit 92ec61e

Browse files
committed
Fix the printf problem -- use std::cout :)
1 parent 54f346f commit 92ec61e

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

btree_bench.cc

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ void BenchmarkRun::Reset() {
133133
void BenchmarkRun::Run() {
134134
assert(current_benchmark == NULL);
135135
current_benchmark = this;
136-
int64_t iters = FLAGS_benchmark_min_iters;
136+
int iters = FLAGS_benchmark_min_iters;
137137
for (;;) {
138138
Reset();
139139
Start();
@@ -150,10 +150,9 @@ void BenchmarkRun::Run() {
150150
}
151151
iters = min(iters, FLAGS_benchmark_max_iters);
152152
}
153-
fprintf(stdout, "%s\t%qu\t%qu\n",
154-
benchmark_name,
155-
accum_micros * 1000ULL / iters,
156-
iters);
153+
std::cout << benchmark_name << "\t"
154+
<< accum_micros * 1000 / iters << "\t"
155+
<< iters;
157156
current_benchmark = NULL;
158157
}
159158

0 commit comments

Comments
 (0)