Bad precision of TimeStats on Windows
Actual behavior
The TimeStats timer uses time.time() which has a high precision on UNIX/Linux, but a pretty bad precision of only 1/60 sec on Windows.
Expected behavior
The precision on Windows should be improved.
Possible solutions
time.clock() provides high precision on Windows, but no good precision on UNIX/Linux. besides that, it is deprecated since Python 3.3.
timeit.default_timer() seems to be a solution but requires to fit the code to be measured into a statement string that is interpreted inside of a timeit() method. That might be a solution but requires more investigation.
Execution environment
- zhmcclient version: 0.9.0
- Operating system (type+version): Windows 7
I don't think timeit is the solution we're looking for. It would likely require a complete rewrite of TimeStats if it even could provide the same functionality, which I don't think it can.