999e3fca90
The problem appeared due to a fact that stubs doesn't create a stack frame, reusing the stack frame of the caller function. When building stack traces, the current function is retrieved from PC, and its callees are retrieved by traversing the stack backwards. Thus, for stubs, the stub itself was discovered via PC, and then stub's caller's caller was retrieved from stack. To fix this problem, a pointer to JSFunction object is now captured from the topmost stack frame, and is saved into stack trace log record. Then a simple heuristics is applied whether a referred function should be added to decoded stack, or not, to avoid reporting the same function twice (from PC and from the pointer.) BUG=553 TEST=added to mjsunit/tools/tickprocessor Review URL: http://codereview.chromium.org/546089 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3673 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
30 lines
846 B
Plaintext
30 lines
846 B
Plaintext
Statistical profiling result from v8.log, (3 ticks, 0 unaccounted, 0 excluded).
|
|
|
|
[Shared libraries]:
|
|
ticks total nonlib name
|
|
|
|
[JavaScript]:
|
|
ticks total nonlib name
|
|
2 66.7% 66.7% Stub: CompareStub_GE
|
|
1 33.3% 33.3% LazyCompile: DrawLine 3d-cube.js:17
|
|
|
|
[C++]:
|
|
ticks total nonlib name
|
|
|
|
[GC]:
|
|
ticks total nonlib name
|
|
0 0.0%
|
|
|
|
[Bottom up (heavy) profile]:
|
|
Note: percentage shows a share of a particular caller in the total
|
|
amount of its parent calls.
|
|
Callers occupying less than 2.0% are not shown.
|
|
|
|
ticks parent name
|
|
2 66.7% Stub: CompareStub_GE
|
|
2 100.0% LazyCompile: DrawLine 3d-cube.js:17
|
|
2 100.0% LazyCompile: DrawQube 3d-cube.js:188
|
|
|
|
1 33.3% LazyCompile: DrawLine 3d-cube.js:17
|
|
1 100.0% LazyCompile: DrawQube 3d-cube.js:188
|