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

Unified Diff: gin/v8_platform.cc

Issue 1850603002: [tracing] Use trace event profiling for heap profiling Base URL: https://chromium.googlesource.com/chromium/src.git@all_categories
Patch Set: Created 4 years, 9 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 | « gin/public/v8_platform.h ('k') | skia/ext/event_tracer_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gin/v8_platform.cc
diff --git a/gin/v8_platform.cc b/gin/v8_platform.cc
index 556f7fc5f24f0b1c924138a6b77709e7aea5bc5d..f7e21cf217f45506d456daa199ec9f85530333a3 100644
--- a/gin/v8_platform.cc
+++ b/gin/v8_platform.cc
@@ -8,6 +8,7 @@
#include "base/location.h"
#include "base/sys_info.h"
#include "base/threading/worker_pool.h"
+#include "base/trace_event/heap_profiler_allocation_context_tracker.h"
#include "base/trace_event/trace_event.h"
#include "gin/per_isolate_data.h"
@@ -116,4 +117,14 @@ void V8Platform::UpdateTraceEventDuration(const uint8_t* category_enabled_flag,
traceEventHandle);
}
+void V8Platform::PushTracingPseudoStackFrame(const char* stack_frame) {
+ base::trace_event::AllocationContextTracker::GetInstanceForCurrentThread()
+ ->PushPseudoStackFrame(stack_frame);
+}
+
+void V8Platform::PopTracingPseudoStackFrame(const char* stack_frame) {
+ base::trace_event::AllocationContextTracker::GetInstanceForCurrentThread()
+ ->PopPseudoStackFrame(stack_frame);
+}
+
} // namespace gin
« no previous file with comments | « gin/public/v8_platform.h ('k') | skia/ext/event_tracer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698