Trace how long it takes to compute the weak closure during mark-compact

BUG=none
R=hpayer@chromium.org
LOG=n

Review URL: https://codereview.chromium.org/769253002

Cr-Commit-Position: refs/heads/master@{#25618}
This commit is contained in:
jochen 2014-12-02 07:09:19 -08:00 committed by Commit bot
parent dba8e83b41
commit 4fcc2dca7e
3 changed files with 27 additions and 21 deletions

View File

@ -339,6 +339,7 @@ void GCTracer::PrintNVP() const {
current_.scopes[Scope::MC_UPDATE_POINTERS_BETWEEN_EVACUATED]);
PrintF("misc_compaction=%.1f ",
current_.scopes[Scope::MC_UPDATE_MISC_POINTERS]);
PrintF("weak_closure=%.1f ", current_.scopes[Scope::MC_WEAKCLOSURE]);
PrintF("weakcollection_process=%.1f ",
current_.scopes[Scope::MC_WEAKCOLLECTION_PROCESS]);
PrintF("weakcollection_clear=%.1f ",

View File

@ -103,6 +103,7 @@ class GCTracer {
MC_UPDATE_POINTERS_TO_EVACUATED,
MC_UPDATE_POINTERS_BETWEEN_EVACUATED,
MC_UPDATE_MISC_POINTERS,
MC_WEAKCLOSURE,
MC_WEAKCOLLECTION_PROCESS,
MC_WEAKCOLLECTION_CLEAR,
MC_WEAKCOLLECTION_ABORT,

View File

@ -2222,6 +2222,9 @@ void MarkCompactCollector::MarkLiveObjects() {
ProcessTopOptimizedFrame(&root_visitor);
{
GCTracer::Scope gc_scope(heap()->tracer(), GCTracer::Scope::MC_WEAKCLOSURE);
// The objects reachable from the roots are marked, yet unreachable
// objects are unmarked. Mark objects reachable due to host
// application specific logic or through Harmony weak maps.
@ -2245,6 +2248,7 @@ void MarkCompactCollector::MarkLiveObjects() {
// We only process harmony collections, as all object groups have been fully
// processed and no weakly reachable node can discover new objects groups.
ProcessEphemeralMarking(&root_visitor, true);
}
AfterMarking();