home *** CD-ROM | disk | FTP | other *** search
- <TITLE>Profiler Changes -- Python library reference</TITLE>
- Next: <A HREF="../i/instant_users_manual" TYPE="Next">Instant Users Manual</A>
- Prev: <A HREF="../p/profiler_introduction" TYPE="Prev">Profiler Introduction</A>
- Up: <A HREF="../t/the_python_profiler" TYPE="Up">The Python Profiler</A>
- Top: <A HREF="../t/top" TYPE="Top">Top</A>
- <H1>9.2. How Is This Profiler Different From The Old Profiler?</H1>
- The big changes from old profiling module are that you get more
- information, and you pay less CPU time. It's not a trade-off, it's a
- trade-up.
- <P>
- To be specific:
- <P>
- <DL>
- <DT><B>Bugs removed:</B><DD>Local stack frame is no longer molested, execution time is now charged
- to correct functions.
- <P>
- <DT><B>Accuracy increased:</B><DD>Profiler execution time is no longer charged to user's code,
- calibration for platform is supported, file reads are not done <I>by</I>
- profiler <I>during</I> profiling (and charged to user's code!).
- <P>
- <DT><B>Speed increased:</B><DD>Overhead CPU cost was reduced by more than a factor of two (perhaps a
- factor of five), lightweight profiler module is all that must be
- loaded, and the report generating module (<CODE>pstats</CODE>) is not needed
- during profiling.
- <P>
- <DT><B>Recursive functions support:</B><DD>Cumulative times in recursive functions are correctly calculated;
- recursive entries are counted.
- <P>
- <DT><B>Large growth in report generating UI:</B><DD>Distinct profiles runs can be added together forming a comprehensive
- report; functions that import statistics take arbitrary lists of
- files; sorting criteria is now based on keywords (instead of 4 integer
- options); reports shows what functions were profiled as well as what
- profile file was referenced; output format has been improved.
- <P>
- </DL>
-