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

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

Issue 889443002: Service isolate rework take 2 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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 | « runtime/vm/class_finalizer.h ('k') | runtime/vm/dart.h » ('j') | no next file with comments »
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/class_table.h" 5 #include "vm/class_table.h"
6 #include "vm/flags.h" 6 #include "vm/flags.h"
7 #include "vm/freelist.h" 7 #include "vm/freelist.h"
8 #include "vm/growable_array.h" 8 #include "vm/growable_array.h"
9 #include "vm/heap.h" 9 #include "vm/heap.h"
10 #include "vm/object.h" 10 #include "vm/object.h"
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 } 188 }
189 } 189 }
190 } 190 }
191 191
192 192
193 void ClassTable::Print() { 193 void ClassTable::Print() {
194 Class& cls = Class::Handle(); 194 Class& cls = Class::Handle();
195 String& name = String::Handle(); 195 String& name = String::Handle();
196 196
197 for (intptr_t i = 1; i < top_; i++) { 197 for (intptr_t i = 1; i < top_; i++) {
198 if (!HasValidClassAt(i)) {
199 continue;
200 }
201 if (i == kFreeListElement) {
202 continue;
203 }
198 cls = At(i); 204 cls = At(i);
199 if (cls.raw() != reinterpret_cast<RawClass*>(0)) { 205 if (cls.raw() != reinterpret_cast<RawClass*>(0)) {
200 name = cls.Name(); 206 name = cls.Name();
201 OS::Print("%" Pd ": %s\n", i, name.ToCString()); 207 OS::Print("%" Pd ": %s\n", i, name.ToCString());
202 } 208 }
203 } 209 }
204 } 210 }
205 211
206 212
207 void ClassTable::PrintToJSONObject(JSONObject* object) { 213 void ClassTable::PrintToJSONObject(JSONObject* object) {
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 478
473 void ClassTable::UpdateLiveNew(intptr_t cid, intptr_t size) { 479 void ClassTable::UpdateLiveNew(intptr_t cid, intptr_t size) {
474 ClassHeapStats* stats = PreliminaryStatsAt(cid); 480 ClassHeapStats* stats = PreliminaryStatsAt(cid);
475 ASSERT(stats != NULL); 481 ASSERT(stats != NULL);
476 ASSERT(size >= 0); 482 ASSERT(size >= 0);
477 stats->post_gc.AddNew(size); 483 stats->post_gc.AddNew(size);
478 } 484 }
479 485
480 486
481 } // namespace dart 487 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/class_finalizer.h ('k') | runtime/vm/dart.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698