[profiler] reduce incorrectly unaccounted ticks.

No longer invalidate the tick sample if there is no JS frame or only one
non-interpreted JS frame on the stack.

R=jarin@chromium.org

Review-Url: https://codereview.chromium.org/2799603005
Cr-Original-Commit-Position: refs/heads/master@{#44465}
Committed: 57bef9a1e2
Review-Url: https://codereview.chromium.org/2799603005
Cr-Commit-Position: refs/heads/master@{#44478}
This commit is contained in:
yangguo 2017-04-07 02:57:52 -07:00 committed by Commit bot
parent d3e9aade0f
commit 818c6d0ba9

View File

@ -225,12 +225,7 @@ bool TickSample::GetStackSample(Isolate* v8_isolate, RegisterState* regs,
i::SafeStackFrameIterator it(isolate, reinterpret_cast<i::Address>(regs->fp), i::SafeStackFrameIterator it(isolate, reinterpret_cast<i::Address>(regs->fp),
reinterpret_cast<i::Address>(regs->sp), reinterpret_cast<i::Address>(regs->sp),
js_entry_sp); js_entry_sp);
if (it.done()) return true;
// If at this point iterator does not see any frames,
// is usually means something is wrong with the FP,
// e.g. it is used as a general purpose register in the function.
// Bailout.
if (it.done()) return false;
size_t i = 0; size_t i = 0;
if (record_c_entry_frame == kIncludeCEntryFrame && if (record_c_entry_frame == kIncludeCEntryFrame &&