Index: src/sampler.cc |
diff --git a/src/sampler.cc b/src/sampler.cc |
index 4633712f1c4743bbbbdc459e2a9fc231c04a739b..5e79e2a06cd0fb559fdc511091f3f97214c09dd9 100644 |
--- a/src/sampler.cc |
+++ b/src/sampler.cc |
@@ -623,6 +623,9 @@ void TickSample::GetStackSample(Isolate* isolate, const v8::RegisterState& regs, |
SafeStackFrameIterator it(isolate, reinterpret_cast<Address>(regs.fp), |
reinterpret_cast<Address>(regs.sp), js_entry_sp); |
size_t i = 0; |
+ if (!it.done() && it.top_frame_type() == StackFrame::EXIT) { |
+ frames[i++] = isolate->c_function(); |
+ } |
while (!it.done() && i < frames_limit) { |
frames[i++] = it.frame()->pc(); |
it.Advance(); |