A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2005-November/058260.html below:

[Python-Dev] s/hotshot/lsprof

[Python-Dev] s/hotshot/lsprof [Python-Dev] s/hotshot/lsprofArmin Rigo arigo at tunes.org
Mon Nov 21 22:23:09 CET 2005
Hi Floris,

On Mon, Nov 21, 2005 at 04:45:03PM +0000, Floris Bruynooghe wrote:
> Afaik I did test recursive calls etc.

It seems to show up in any test case I try, e.g.

    import hprofile
    def wait(m):
        if m > 0:
            wait(m-1)
    def f(n):
        wait(n)
        if n > 1:
            return n*f(n-1)
        else:
            return 1
    hprofile.run("f(500)", 'dump-hprof')

The problem is in the cumulative time column, which (on this machine)
says 163 seconds for both f() and wait().  The whole program finishes in
1 second...  The same log file loaded with hotshot.stats doesn't have
this problem.


A bientot,

Armin.
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4