| 26 | namespace utils { |
| 27 | |
| 28 | void PrintTimerDescription(std::ostream* out, bool measure_mem_usage) { |
| 29 | if (out) { |
| 30 | *out << std::setw(30) << "PASS name" << std::setw(12) << "CPU time" |
| 31 | << std::setw(12) << "WALL time" << std::setw(12) << "USR time" |
| 32 | << std::setw(12) << "SYS time"; |
| 33 | if (measure_mem_usage) { |
| 34 | *out << std::setw(12) << "RSS delta" << std::setw(16) << "PGFault delta"; |
| 35 | } |
| 36 | *out << std::endl; |
| 37 | } |
| 38 | } |
| 39 | |
| 40 | // Do not change the order of invoking system calls. We want to make CPU/Wall |
| 41 | // time correct as much as possible. Calling functions to get CPU/Wall time must |