| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 part of service; | 5 part of service; |
| 6 | 6 |
| 7 // Some value smaller than the object ring, so requesting a large array | 7 // Some value smaller than the object ring, so requesting a large array |
| 8 // doesn't result in an expired ref because the elements lapped it in the | 8 // doesn't result in an expired ref because the elements lapped it in the |
| 9 // object ring. | 9 // object ring. |
| 10 const int kDefaultFieldLimit = 100; | 10 const int kDefaultFieldLimit = 100; |
| (...skipping 643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 654 final List<Isolate> isolates = <Isolate>[]; | 654 final List<Isolate> isolates = <Isolate>[]; |
| 655 | 655 |
| 656 String version = 'unknown'; | 656 String version = 'unknown'; |
| 657 String hostCPU; | 657 String hostCPU; |
| 658 String targetCPU; | 658 String targetCPU; |
| 659 int architectureBits; | 659 int architectureBits; |
| 660 bool assertsEnabled = false; | 660 bool assertsEnabled = false; |
| 661 bool typeChecksEnabled = false; | 661 bool typeChecksEnabled = false; |
| 662 int nativeZoneMemoryUsage = 0; | 662 int nativeZoneMemoryUsage = 0; |
| 663 int pid = 0; | 663 int pid = 0; |
| 664 int heapAllocatedMemoryUsage = 0; |
| 665 int heapAllocationCount = 0; |
| 664 int maxRSS = 0; | 666 int maxRSS = 0; |
| 665 bool profileVM = false; | 667 bool profileVM = false; |
| 666 DateTime startTime; | 668 DateTime startTime; |
| 667 DateTime refreshTime; | 669 DateTime refreshTime; |
| 668 Duration get upTime { | 670 Duration get upTime { |
| 669 if (startTime == null) { | 671 if (startTime == null) { |
| 670 return null; | 672 return null; |
| 671 } | 673 } |
| 672 return (new DateTime.now().difference(startTime)); | 674 return (new DateTime.now().difference(startTime)); |
| 673 } | 675 } |
| (...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 944 hostCPU = map['hostCPU']; | 946 hostCPU = map['hostCPU']; |
| 945 targetCPU = map['targetCPU']; | 947 targetCPU = map['targetCPU']; |
| 946 architectureBits = map['architectureBits']; | 948 architectureBits = map['architectureBits']; |
| 947 int startTimeMillis = map['startTime']; | 949 int startTimeMillis = map['startTime']; |
| 948 startTime = new DateTime.fromMillisecondsSinceEpoch(startTimeMillis); | 950 startTime = new DateTime.fromMillisecondsSinceEpoch(startTimeMillis); |
| 949 refreshTime = new DateTime.now(); | 951 refreshTime = new DateTime.now(); |
| 950 if (map['_nativeZoneMemoryUsage'] != null) { | 952 if (map['_nativeZoneMemoryUsage'] != null) { |
| 951 nativeZoneMemoryUsage = map['_nativeZoneMemoryUsage']; | 953 nativeZoneMemoryUsage = map['_nativeZoneMemoryUsage']; |
| 952 } | 954 } |
| 953 pid = map['pid']; | 955 pid = map['pid']; |
| 956 if (map['_heapAllocatedMemoryUsage'] != null) { |
| 957 heapAllocatedMemoryUsage = map['_heapAllocatedMemoryUsage']; |
| 958 } |
| 959 if (map['_heapAllocationCount'] != null) { |
| 960 heapAllocationCount = map['_heapAllocationCount']; |
| 961 } |
| 954 maxRSS = map['_maxRSS']; | 962 maxRSS = map['_maxRSS']; |
| 955 profileVM = map['_profilerMode'] == 'VM'; | 963 profileVM = map['_profilerMode'] == 'VM'; |
| 956 assertsEnabled = map['_assertsEnabled']; | 964 assertsEnabled = map['_assertsEnabled']; |
| 957 typeChecksEnabled = map['_typeChecksEnabled']; | 965 typeChecksEnabled = map['_typeChecksEnabled']; |
| 958 _removeDeadIsolates(map['isolates']); | 966 _removeDeadIsolates(map['isolates']); |
| 959 } | 967 } |
| 960 | 968 |
| 961 // Reload all isolates. | 969 // Reload all isolates. |
| 962 Future reloadIsolates() { | 970 Future reloadIsolates() { |
| 963 var reloads = []; | 971 var reloads = []; |
| (...skipping 3557 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4521 var v = list[i]; | 4529 var v = list[i]; |
| 4522 if ((v is Map) && _isServiceMap(v)) { | 4530 if ((v is Map) && _isServiceMap(v)) { |
| 4523 list[i] = owner.getFromMap(v); | 4531 list[i] = owner.getFromMap(v); |
| 4524 } else if (v is List) { | 4532 } else if (v is List) { |
| 4525 _upgradeList(v, owner); | 4533 _upgradeList(v, owner); |
| 4526 } else if (v is Map) { | 4534 } else if (v is Map) { |
| 4527 _upgradeMap(v, owner); | 4535 _upgradeMap(v, owner); |
| 4528 } | 4536 } |
| 4529 } | 4537 } |
| 4530 } | 4538 } |
| OLD | NEW |