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

Unified Diff: src/heap.cc

Issue 3763012: CPU Profiler: postpone moved functions registration until GC completes. (Closed)
Patch Set: Created 10 years, 2 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/cpu-profiler.cc ('K') | « src/cpu-profiler.cc ('k') | src/log.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap.cc
diff --git a/src/heap.cc b/src/heap.cc
index d1cf4e910520f49c37126bbb1347414fb60413b2..7d92e494ba7265783df223e95d529f709ec89c9e 100644
--- a/src/heap.cc
+++ b/src/heap.cc
@@ -469,6 +469,7 @@ void Heap::CollectGarbage(AllocationSpace space,
#ifdef ENABLE_LOGGING_AND_PROFILING
if (FLAG_log_gc) HeapProfiler::WriteSample();
+ if (CpuProfiler::is_profiling()) CpuProfiler::RegisterMovedFunctions();
#endif
}
@@ -1260,7 +1261,7 @@ class ScavengingVisitor : public StaticVisitorBase {
if (Logger::is_logging() || CpuProfiler::is_profiling()) {
if (target->IsJSFunction()) {
PROFILE(FunctionMoveEvent(source->address(), target->address()));
- PROFILE(FunctionCreateEventFromMove(JSFunction::cast(target), source));
+ PROFILE(FunctionCreateEventFromMove(JSFunction::cast(target)));
}
}
#endif
« src/cpu-profiler.cc ('K') | « src/cpu-profiler.cc ('k') | src/log.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698