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

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

Issue 10442073: Implement growth policy for old space using time and space signals. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | runtime/vm/heap.h » ('j') | runtime/vm/pages.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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/dart.h" 5 #include "vm/dart.h"
6 6
7 #include "vm/dart_api_state.h" 7 #include "vm/dart_api_state.h"
8 #include "vm/flags.h" 8 #include "vm/flags.h"
9 #include "vm/freelist.h" 9 #include "vm/freelist.h"
10 #include "vm/handles.h" 10 #include "vm/handles.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 } else { 89 } else {
90 // Initialize from snapshot (this should replicate the functionality 90 // Initialize from snapshot (this should replicate the functionality
91 // of Object::Init(..) in a regular isolate creation path. 91 // of Object::Init(..) in a regular isolate creation path.
92 Object::InitFromSnapshot(isolate); 92 Object::InitFromSnapshot(isolate);
93 const Snapshot* snapshot = Snapshot::SetupFromBuffer(snapshot_buffer); 93 const Snapshot* snapshot = Snapshot::SetupFromBuffer(snapshot_buffer);
94 if (FLAG_trace_isolates) { 94 if (FLAG_trace_isolates) {
95 OS::Print("Size of isolate snapshot = %ld\n", snapshot->length()); 95 OS::Print("Size of isolate snapshot = %ld\n", snapshot->length());
96 } 96 }
97 SnapshotReader reader(snapshot, isolate); 97 SnapshotReader reader(snapshot, isolate);
98 reader.ReadFullSnapshot(); 98 reader.ReadFullSnapshot();
99 isolate->heap()->EnableGrowthControl();
Ivan Posva 2012/05/29 23:27:37 This means that the growth policy is only active w
cshapiro 2012/05/30 17:56:24 Done.
99 if (FLAG_trace_isolates) { 100 if (FLAG_trace_isolates) {
100 isolate->heap()->PrintSizes(); 101 isolate->heap()->PrintSizes();
101 } 102 }
102 } 103 }
103 104
104 StubCode::Init(isolate); 105 StubCode::Init(isolate);
105 isolate->set_init_callback_data(data); 106 isolate->set_init_callback_data(data);
106 if (FLAG_print_class_table) { 107 if (FLAG_print_class_table) {
107 isolate->class_table()->Print(); 108 isolate->class_table()->Print();
108 } 109 }
109 return Error::null(); 110 return Error::null();
110 } 111 }
111 112
112 113
113 void Dart::ShutdownIsolate() { 114 void Dart::ShutdownIsolate() {
114 Isolate* isolate = Isolate::Current(); 115 Isolate* isolate = Isolate::Current();
115 isolate->Shutdown(); 116 isolate->Shutdown();
116 delete isolate; 117 delete isolate;
117 } 118 }
118 119
119 } // namespace dart 120 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/heap.h » ('j') | runtime/vm/pages.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698