homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author exarkun
Recipients exarkun
Date 2010年11月09日.19:15:52
SpamBayes Score 7.1670656e-06
Marked as misclassified No
Message-id <1289330157.64.0.804847448743.issue10377@psf.upfronthosting.co.za>
In-reply-to
Content
Consider this transcript:
>>> cProfile.run("import time; time.sleep(1)")
 4 function calls in 1.012 CPU seconds
 Ordered by: standard name
 ncalls tottime percall cumtime percall filename:lineno(function)
 1 0.011 0.011 1.012 1.012 <string>:1(<module>)
 1 0.000 0.000 1.012 1.012 {built-in method exec}
 1 1.001 1.001 1.001 1.001 {built-in method sleep}
 1 0.000 0.000 0.000 0.000 {method 'disable' of '_lsprof.Profiler' objects}
>>> 
It is not the case that the profiled code uses >1 CPU seconds. It spends the entire time sleeping. The default timer for cProfile is a wallclock timer. The output should reflect this.
History
Date User Action Args
2010年11月09日 19:15:57exarkunsetrecipients: + exarkun
2010年11月09日 19:15:57exarkunsetmessageid: <1289330157.64.0.804847448743.issue10377@psf.upfronthosting.co.za>
2010年11月09日 19:15:52exarkunlinkissue10377 messages
2010年11月09日 19:15:52exarkuncreate

AltStyle によって変換されたページ (->オリジナル) /