[Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

Sümer Cip sumerc at gmail.com
Tue Apr 17 09:23:13 CEST 2012


On Sun, Apr 15, 2012 at 6:18 PM, Victor Stinner <victor.stinner at gmail.com>wrote:

> > Here is a simplified version of the first draft of the PEP 418. The
> > full version can be read online.
> > http://www.python.org/dev/peps/pep-0418/
>
> FYI there is no time.thread_time() function. It would only be
> available on Windows and Linux. It does not use seconds but CPU
> cycles. No module or program of the Python source code need such
> function,


Just FYI: in MACOSx, you can use  thread_info() to get that information.
Also you can get that information in Solaris,too. In yappi profiler I use
all of these approaches together to have an OS independent thread_times()
functionality. Here is the relevant code:
http://bitbucket.org/sumerc/yappi/src/7c7dc11e8728/timing.c<https://bitbucket.org/sumerc/yappi/src/7c7dc11e8728/timing.c>

I also think that you are right about Python really not have any use case
for this functionality, ...


-- 
Sümer Cip
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20120417/758e75bc/attachment.html>


More information about the Python-Dev mailing list