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

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

Issue 1157173005: Include 'fixedId' key when printing service ids (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 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
« no previous file with comments | « runtime/vm/report_test.cc ('k') | runtime/vm/service.cc » ('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) 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/scavenger.h" 5 #include "vm/scavenger.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 854 matching lines...) Expand 10 before | Expand all | Expand 10 after
865 ASSERT(from_ == NULL); 865 ASSERT(from_ == NULL);
866 to_->WriteProtect(read_only); 866 to_->WriteProtect(read_only);
867 } 867 }
868 868
869 869
870 void Scavenger::PrintToJSONObject(JSONObject* object) { 870 void Scavenger::PrintToJSONObject(JSONObject* object) {
871 Isolate* isolate = Isolate::Current(); 871 Isolate* isolate = Isolate::Current();
872 ASSERT(isolate != NULL); 872 ASSERT(isolate != NULL);
873 JSONObject space(object, "new"); 873 JSONObject space(object, "new");
874 space.AddProperty("type", "HeapSpace"); 874 space.AddProperty("type", "HeapSpace");
875 space.AddProperty("id", "heaps/new");
876 space.AddProperty("name", "new"); 875 space.AddProperty("name", "new");
877 space.AddProperty("vmName", "Scavenger"); 876 space.AddProperty("vmName", "Scavenger");
878 space.AddProperty("collections", collections()); 877 space.AddProperty("collections", collections());
879 if (collections() > 0) { 878 if (collections() > 0) {
880 int64_t run_time = OS::GetCurrentTimeMicros() - isolate->start_time(); 879 int64_t run_time = OS::GetCurrentTimeMicros() - isolate->start_time();
881 run_time = Utils::Maximum(run_time, static_cast<int64_t>(0)); 880 run_time = Utils::Maximum(run_time, static_cast<int64_t>(0));
882 double run_time_millis = MicrosecondsToMilliseconds(run_time); 881 double run_time_millis = MicrosecondsToMilliseconds(run_time);
883 double avg_time_between_collections = 882 double avg_time_between_collections =
884 run_time_millis / static_cast<double>(collections()); 883 run_time_millis / static_cast<double>(collections());
885 space.AddProperty("avgCollectionPeriodMillis", 884 space.AddProperty("avgCollectionPeriodMillis",
(...skipping 14 matching lines...) Expand all
900 } 899 }
901 900
902 901
903 void Scavenger::FreeExternal(intptr_t size) { 902 void Scavenger::FreeExternal(intptr_t size) {
904 ASSERT(size >= 0); 903 ASSERT(size >= 0);
905 external_size_ -= size; 904 external_size_ -= size;
906 ASSERT(external_size_ >= 0); 905 ASSERT(external_size_ >= 0);
907 } 906 }
908 907
909 } // namespace dart 908 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/report_test.cc ('k') | runtime/vm/service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698