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

Unified Diff: runtime/bin/vmservice/observatory/lib/src/service/object.dart

Issue 773303003: observatory: populate 'architecture' in VM, and add numerical vmId in Class. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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 | « no previous file | runtime/bin/vmservice/observatory/test/classes_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/vmservice/observatory/lib/src/service/object.dart
===================================================================
--- runtime/bin/vmservice/observatory/lib/src/service/object.dart (revision 42084)
+++ runtime/bin/vmservice/observatory/lib/src/service/object.dart (working copy)
@@ -333,7 +333,8 @@
@reflectable String relativeLink(String id) => '$id';
@observable String version = 'unknown';
- @observable String architecture = 'unknown';
+ @observable String architecture;
+ @observable int architectureBits;
@observable double uptime = 0.0;
@observable bool assertsEnabled = false;
@observable bool typeChecksEnabled = false;
@@ -557,7 +558,8 @@
}
_loaded = true;
version = map['version'];
- architecture = map['architecture'];
+ architecture = map['targetCPU'];
Cutch 2014/12/04 16:07:21 Why not rename 'architecture' to be targetCPU?
koda 2014/12/04 17:30:14 Done.
+ architectureBits = architecture.contains('64') ? 64 : 32;
Cutch 2014/12/04 16:07:21 Can we ensure this will always be correct? Why not
koda 2014/12/04 17:30:14 Done.
uptime = map['uptime'];
var dateInMillis = int.parse(map['date']);
lastUpdate = new DateTime.fromMillisecondsSinceEpoch(dateInMillis);
@@ -1438,6 +1440,7 @@
@observable int endTokenPos;
@observable ServiceMap error;
+ @observable int vmId;
Cutch 2014/12/04 16:07:21 vmCid?
koda 2014/12/04 17:30:14 Done.
final Allocations newSpace = new Allocations();
final Allocations oldSpace = new Allocations();
@@ -1507,6 +1510,9 @@
superclass._addSubclass(this);
}
error = map['error'];
+ var idPrefix = "classes/";
+ assert(id.startsWith(idPrefix));
+ vmId = int.parse(id.substring(idPrefix.length));
var allocationStats = map['allocationStats'];
if (allocationStats != null) {
« no previous file with comments | « no previous file | runtime/bin/vmservice/observatory/test/classes_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698