Explicitly remove unsupported memory usage support

This commit is contained in:
Dominic Hamon 2014-01-08 09:11:50 -08:00
parent dc5b533adb
commit 577f7410d1
2 changed files with 8 additions and 7 deletions

View File

@ -158,13 +158,14 @@ void RunSpecifiedBenchmarks(const BenchmarkReporter* reporter = nullptr);
//
// REQUIRES: a benchmark is currently executing
extern void SetLabel(const std::string& label);
void SetLabel(const std::string& label);
// If this routine is called, peak memory allocation past this point in the
// benchmark is reported at the end of the benchmark report line. (It is
// computed by running the benchmark once with a single iteration and a memory
// tracer.)
extern void MemoryUsage();
// TODO(dominic)
//void MemoryUsage();
// If a particular benchmark is I/O bound, or if for some reason CPU
// timings are not representative, call this method from within the
@ -172,7 +173,7 @@ extern void MemoryUsage();
// control how many iterations are run, and in the printing of
// items/second or MB/seconds values. If not called, the cpu time
// used by the benchmark will be used.
extern void UseRealTime();
void UseRealTime();
namespace internal {
class Benchmark;
@ -436,8 +437,6 @@ class Benchmark {
// Equivalent to ThreadRange(NumCPUs(), NumCPUs())
Benchmark* ThreadPerCpu();
// TODO(dominic): Control whether or not real-time is used for this benchmark
// -------------------------------
// Following methods are not useful for clients

View File

@ -373,13 +373,14 @@ void ConsoleReporter::PrintRunData(const BenchmarkReporter::Run& result) const {
(result.cpu_accumulated_time * 1e9) /
(static_cast<double>(result.iterations)));
ColorPrintf(COLOR_CYAN, "%10lld", result.iterations);
ColorPrintf(COLOR_DEFAULT, "%*s %*s %s%s\n",
16, rate.c_str(),
ColorPrintf(COLOR_DEFAULT, "%*s %*s %s %s\n",
13, rate.c_str(),
18, items.c_str(),
result.report_label.c_str(),
PrintMemoryUsage(result.max_heapbytes_used).c_str());
}
/* TODO(dominic)
void MemoryUsage() {
//if (benchmark_mc) {
// benchmark_mc->Reset();
@ -387,6 +388,7 @@ void MemoryUsage() {
get_memory_usage = true;
//}
}
*/
void UseRealTime() {
use_real_time = true;