| Anonymous | Login | Signup for a new account | 2013-05-18 08:31 CEST | ![]() |
| Main | My View | View Issues | Change Log | Roadmap |
| View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | |||
| 0001937 | OCaml | OCaml general | public | 2003-11-21 20:53 | 2012-01-27 19:50 | |||
| Reporter | administrator | |||||||
| Assigned To | ||||||||
| Priority | normal | Severity | feature | Reproducibility | always | |||
| Status | closed | Resolution | fixed | |||||
| Platform | OS | OS Version | ||||||
| Product Version | ||||||||
| Target Version | Fixed in Version | 3.09.2 | ||||||
| Summary | 0001937: Unix module, binding to getrusage() | |||||||
| Description | Full_Name: Daniel Bünzli Version: 3.07+2 OS: MacOS X 10.3.1 Submission from: 45.45.203.62.dial.bluewin.ch (62.203.45.45) The resolution of Unix.times() is too low. Subtracting figures returned by two subsequent calls to the function one often gets 0.0 (even if some code was executed meanwhile). # (Unix.times()).Unix.tms_utime -. (Unix.times()).Unix.tms_utime;; - : float = 0. Unix.gettimeofday(), has a good resolution however it doesn't enable one to make the difference between user and system time. # (Unix.gettimeofday()) -. (Unix.gettimeofday());; - : float = 2.02655792236328125e-06 A binding in the Unix module to the getrusage [1] function would give user and system times with the accuracy of gettimeofday, that is possibly down to microseconds (actual resolution is system dependent). Thanks for considering, Daniel [1] <http://www.opengroup.org/onlinepubs/007904975/functions/getrusage.html> [^] <http://www.opengroup.org/onlinepubs/007904975/basedefs/sys/resource.h.html> [^] | |||||||
| Tags | No tags attached. | |||||||
| Attached Files | ||||||||
Notes |
|
|
(0006831) doligez (manager) 2012-01-27 19:50 |
Fixed in 3.09.2 and in trunk (commit 7382): Unix.times now calls getrusage if available. |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2005-11-18 10:13 | administrator | New Issue | |
| 2012-01-27 19:50 | doligez | Note Added: 0006831 | |
| 2012-01-27 19:50 | doligez | Status | acknowledged => closed |
| 2012-01-27 19:50 | doligez | Resolution | open => fixed |
| 2012-01-27 19:50 | doligez | Fixed in Version | => 3.09.2 |
| 2012-01-27 19:50 | doligez | Description Updated | View Revisions |
| Copyright © 2000 - 2011 MantisBT Group |