Line | |
---|
1 | #ifndef BENCHMARK_TOOLS_H |
---|
2 | #define BENCHMARK_TOOLS_H |
---|
3 | |
---|
4 | #include<string> |
---|
5 | #include<iostream> |
---|
6 | #include<iomanip> |
---|
7 | #include<lemon/time_measure.h> |
---|
8 | |
---|
9 | extern const char test_name[]; |
---|
10 | |
---|
11 | inline void logTime(const std::string &subtest_name, const |
---|
12 | lemon::TimeStamp &time) |
---|
13 | { |
---|
14 | std::cout << "*** " << test_name << ' ' << subtest_name << ' ' |
---|
15 | << std::setiosflags(std::ios::fixed) << std::setprecision(4) |
---|
16 | << time.realTime() << ' ' |
---|
17 | << time.realTime()/(time.userTime()+time.systemTime()) - 1.0 |
---|
18 | << std::endl; |
---|
19 | } |
---|
20 | |
---|
21 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.