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

Unified Diff: src/log.cc

Issue 1752173003: Additional fixes for external callback logging in profiler. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix test-log-stack-tracer.cc Created 4 years, 10 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
« no previous file with comments | « no previous file | src/profiler/profile-generator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/log.cc
diff --git a/src/log.cc b/src/log.cc
index d5395150147fe33d041a8e1de81f13be41a03452..27f8ae70ff20146bad599b98c06c70adc13a3262 100644
--- a/src/log.cc
+++ b/src/log.cc
@@ -1418,11 +1418,7 @@ void Logger::TickEvent(TickSample* sample, bool overflow) {
msg.Append(",%ld", static_cast<int>(timer_.Elapsed().InMicroseconds()));
if (sample->has_external_callback) {
msg.Append(",1,");
-#if USES_FUNCTION_DESCRIPTORS
- msg.AppendAddress(*FUNCTION_ENTRYPOINT_ADDRESS(sample->external_callback));
-#else
- msg.AppendAddress(sample->external_callback);
-#endif
+ msg.AppendAddress(sample->external_callback_entry);
} else {
msg.Append(",0,");
msg.AppendAddress(sample->tos);
@@ -1635,6 +1631,9 @@ void Logger::LogExistingFunction(Handle<SharedFunctionInfo> shared,
CallHandlerInfo* call_data = CallHandlerInfo::cast(raw_call_data);
Object* callback_obj = call_data->callback();
Address entry_point = v8::ToCData<Address>(callback_obj);
+#if USES_FUNCTION_DESCRIPTORS
+ entry_point = *FUNCTION_ENTRYPOINT_ADDRESS(entry_point);
+#endif
PROFILE(isolate_, CallbackEvent(*func_name, entry_point));
}
} else {
@@ -1678,10 +1677,16 @@ void Logger::LogAccessorCallbacks() {
Address getter_entry = v8::ToCData<Address>(ai->getter());
Name* name = Name::cast(ai->name());
if (getter_entry != 0) {
+#if USES_FUNCTION_DESCRIPTORS
+ getter_entry = *FUNCTION_ENTRYPOINT_ADDRESS(getter_entry);
+#endif
PROFILE(isolate_, GetterCallbackEvent(name, getter_entry));
}
Address setter_entry = v8::ToCData<Address>(ai->setter());
if (setter_entry != 0) {
+#if USES_FUNCTION_DESCRIPTORS
+ setter_entry = *FUNCTION_ENTRYPOINT_ADDRESS(setter_entry);
+#endif
PROFILE(isolate_, SetterCallbackEvent(name, setter_entry));
}
}
« no previous file with comments | « no previous file | src/profiler/profile-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698