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

Side by Side Diff: runtime/vm/gc_marker.cc

Issue 1314673008: Migrate logging infrastructure Isolate->Thread (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Finalize marking tasks in parallel, now that it's safe. Created 5 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/gc_marker.h" 5 #include "vm/gc_marker.h"
6 6
7 #include <map> 7 #include <map>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 MainSync(num_tasks); 693 MainSync(num_tasks);
694 // Phase 2: Weak processing and follow-up marking on main thread. 694 // Phase 2: Weak processing and follow-up marking on main thread.
695 SkippedCodeFunctions* skipped_code_functions = 695 SkippedCodeFunctions* skipped_code_functions =
696 collect_code ? new(zone) SkippedCodeFunctions() : NULL; 696 collect_code ? new(zone) SkippedCodeFunctions() : NULL;
697 MarkingVisitor mark(isolate, heap_, page_space, &marking_stack, 697 MarkingVisitor mark(isolate, heap_, page_space, &marking_stack,
698 &delay_set, skipped_code_functions); 698 &delay_set, skipped_code_functions);
699 IterateWeakReferences(isolate, &mark); 699 IterateWeakReferences(isolate, &mark);
700 MarkingWeakVisitor mark_weak; 700 MarkingWeakVisitor mark_weak;
701 IterateWeakRoots(isolate, &mark_weak, 701 IterateWeakRoots(isolate, &mark_weak,
702 !visit_prologue_weak_persistent_handles); 702 !visit_prologue_weak_persistent_handles);
703 // TODO(koda): Move this into Phase 3 after making ISL_Print thread-safe
704 // (used in SkippedCodeFunctions::DetachCode).
705 FinalizeResultsFrom(&mark);
706 MainSync(num_tasks); 703 MainSync(num_tasks);
707 // Phase 3: Finalize results from all markers (detach code, etc.). 704 // Phase 3: Finalize results from all markers (detach code, etc.).
705 FinalizeResultsFrom(&mark);
708 MainSync(num_tasks); 706 MainSync(num_tasks);
709 // Finalization complete and all tasks exited. 707 // Finalization complete and all tasks exited.
710 } 708 }
711 delay_set.ClearReferences(); 709 delay_set.ClearReferences();
712 ProcessWeakTables(page_space); 710 ProcessWeakTables(page_space);
713 ProcessObjectIdTable(isolate); 711 ProcessObjectIdTable(isolate);
714 } 712 }
715 Epilogue(isolate, invoke_api_callbacks); 713 Epilogue(isolate, invoke_api_callbacks);
716 } 714 }
717 715
718 } // namespace dart 716 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698