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

Unified Diff: runtime/vm/pages.cc

Issue 11428067: Merge the Merlin heap tracing to top-of-trunk. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: address review comments Created 8 years 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 | « runtime/vm/object_set.h ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/pages.cc
diff --git a/runtime/vm/pages.cc b/runtime/vm/pages.cc
index 0aca3477a69152c206791224f90ddbe05b1ba7c3..a37bc24d9390f8b782f10917de9d9bf271e0c922 100644
--- a/runtime/vm/pages.cc
+++ b/runtime/vm/pages.cc
@@ -8,6 +8,7 @@
#include "vm/compiler_stats.h"
#include "vm/gc_marker.h"
#include "vm/gc_sweeper.h"
+#include "vm/heap_trace.h"
#include "vm/object.h"
#include "vm/virtual_memory.h"
@@ -406,6 +407,10 @@ void PageSpace::MarkSweep(bool invoke_api_callbacks, const char* gc_reason) {
Isolate* isolate = Isolate::Current();
NoHandleScope no_handles(isolate);
+ if (HeapTrace::is_enabled()) {
+ isolate->heap()->trace()->TraceMarkSweepStart();
+ }
+
if (FLAG_print_free_list_before_gc) {
OS::Print("Data Freelist (before GC):\n");
freelist_[HeapPage::kData].Print();
@@ -501,6 +506,10 @@ void PageSpace::MarkSweep(bool invoke_api_callbacks, const char* gc_reason) {
OS::PrintErr(" done.\n");
}
+ if (HeapTrace::is_enabled()) {
+ isolate->heap()->trace()->TraceMarkSweepFinish();
+ }
+
count_++;
// Done, reset the marker.
ASSERT(sweeping_);
« no previous file with comments | « runtime/vm/object_set.h ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698