profiler bug

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

profiler bug

John Brant-2
The TimeProfiler is broken when your stack grows over a depth of 127.
This bug makes the profiler almost useless for deep call stacks. For
example, if you have:

Object>>foo: a
        a < 0 ifTrue: [^10000 factorial].
        ^self bar: a

Object>>bar: a
        ^self foo: a - 1

and run "TimeProfiler profile: [Object foo: 1000]", you get a profile
that ends with:

...
        100.0 Object>>foo:
                50.0 Object>>bar:
                50.0 Object>>foo:

>From this profile, it appears that the #foo: method calls itself, but it
doesn't.

It appears that the "optimization" code in MessageTally>>tally:by:
method is causing the problem.


John Brant
_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: profiler bug

Andres Valloud-6
AR 59342.

-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On
Behalf Of John Brant
Sent: Tuesday, February 09, 2010 11:32 AM
To: VW NC
Subject: [vwnc] profiler bug

The TimeProfiler is broken when your stack grows over a depth of 127.
This bug makes the profiler almost useless for deep call stacks. For
example, if you have:

Object>>foo: a
        a < 0 ifTrue: [^10000 factorial].
        ^self bar: a

Object>>bar: a
        ^self foo: a - 1

and run "TimeProfiler profile: [Object foo: 1000]", you get a profile
that ends with:

...
        100.0 Object>>foo:
                50.0 Object>>bar:
                50.0 Object>>foo:

>From this profile, it appears that the #foo: method calls itself, but
>it
doesn't.

It appears that the "optimization" code in MessageTally>>tally:by:
method is causing the problem.


John Brant
_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc