Index: src/sampler.cc |
diff --git a/src/sampler.cc b/src/sampler.cc |
index 948b0540736d629a1d861b9db6371c0711590a96..e271470bd2d01ee841eae39d4f51ee59e98061ba 100644 |
--- a/src/sampler.cc |
+++ b/src/sampler.cc |
@@ -636,7 +636,16 @@ DISABLE_ASAN void TickSample::Trace(Isolate* isolate) { |
return; |
} |
- external_callback = isolate->external_callback(); |
+ const Address callback = isolate->external_callback(); |
+ if (callback != NULL) { |
+ external_callback = callback; |
+ has_external_callback = true; |
+ } else { |
+ // Sample potential return address value for frameless invocation of |
+ // stubs (we'll figure out later, if this value makes sense). |
+ tos = Memory::Address_at(sp); |
+ has_external_callback = false; |
+ } |
SafeStackTraceFrameIterator it(isolate, fp, sp, sp, js_entry_sp); |
int i = 0; |