Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(883)

Unified Diff: src/sampler.cc

Issue 19775017: Fix call stack sampling for the case when native callback invokes JS function (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Comments addressed Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« src/frames.cc ('K') | « src/profile-generator.cc ('k') | src/vm-state.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/sampler.cc
diff --git a/src/sampler.cc b/src/sampler.cc
index 222b3182e81219609e88229c55c7a5a462c9d877..7b2b906177b7c150f6043b01fe01dc8522db30b2 100644
--- a/src/sampler.cc
+++ b/src/sampler.cc
@@ -69,6 +69,7 @@
#include "platform.h"
#include "simulator.h"
#include "v8threads.h"
+#include "vm-state.h"
#if defined(__ANDROID__) && !defined(__BIONIC_HAVE_UCONTEXT_T)
@@ -621,9 +622,9 @@ DISABLE_ASAN void TickSample::Init(Isolate* isolate,
return;
}
- const Address callback = isolate->external_callback();
- if (callback != NULL) {
- external_callback = callback;
+ ExternalCallbackScope* scope = isolate->external_callback_scope();
+ if (scope) {
+ external_callback = scope->callback();
has_external_callback = true;
} else {
// Sample potential return address value for frameless invocation of
« src/frames.cc ('K') | « src/profile-generator.cc ('k') | src/vm-state.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698