Message156335
| Author |
vstinner |
| Recipients |
giampaolo.rodola, lemburg, pitrou, vstinner |
| Date |
2012年03月19日.12:46:56 |
| SpamBayes Score |
1.7219289e-05 |
| Marked as misclassified |
No |
| Message-id |
<1332161217.02.0.220671060861.issue14309@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
> There's no other single function providing the same functionality
time.clock() is not portable: it is a different clock depending on the OS. To write portable code, you have to use the right function:
- time.time()
- time.steady()
- os.times(), resource.getrusage()
On Windows, time.clock() should be replaced by time.steady(). On UNIX, time.clock() can be replaced with "usage=os.times(); usage[0]+usage[1]" for example.
Which kind of use case is not covered by these functions? |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2012年03月19日 12:46:57 | vstinner | set | recipients:
+ vstinner, lemburg, pitrou, giampaolo.rodola |
| 2012年03月19日 12:46:57 | vstinner | set | messageid: <1332161217.02.0.220671060861.issue14309@psf.upfronthosting.co.za> |
| 2012年03月19日 12:46:56 | vstinner | link | issue14309 messages |
| 2012年03月19日 12:46:56 | vstinner | create |
|