OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 library function_view_element; | 5 library function_view_element; |
6 | 6 |
7 import 'dart:async'; | 7 import 'dart:async'; |
8 import 'dart:html'; | 8 import 'dart:html'; |
9 import 'package:observatory/models.dart' as M; | 9 import 'package:observatory/models.dart' as M; |
10 import 'package:observatory/src/elements/class_ref.dart'; | 10 import 'package:observatory/src/elements/class_ref.dart'; |
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
266 queue: _r.queue), | 266 queue: _r.queue), |
267 new SpanElement() | 267 new SpanElement() |
268 ..title = 'This count is used to determine when a function ' | 268 ..title = 'This count is used to determine when a function ' |
269 'will be optimized. It is a combination of call ' | 269 'will be optimized. It is a combination of call ' |
270 'counts and other factors.' | 270 'counts and other factors.' |
271 ..text = ' (usage count: ${function.usageCounter })' | 271 ..text = ' (usage count: ${function.usageCounter })' |
272 ] | 272 ] |
273 ] | 273 ] |
274 ); | 274 ); |
275 } | 275 } |
| 276 members.add( |
| 277 new DivElement() |
| 278 ..classes = ['memberItem'] |
| 279 ..text = ' '); |
| 280 |
| 281 if (_function.icDataArray != null) { |
| 282 members.add( |
| 283 new DivElement() |
| 284 ..classes = ['memberItem'] |
| 285 ..children = [ |
| 286 new DivElement() |
| 287 ..classes = ['memberName'] |
| 288 ..text = 'ic data array', |
| 289 new DivElement() |
| 290 ..classes = ['memberName'] |
| 291 ..children = [ |
| 292 new InstanceRefElement(_isolate, _function.icDataArray, |
| 293 _instances, queue: _r.queue) |
| 294 ] |
| 295 ] |
| 296 ); |
| 297 } |
| 298 |
276 members.addAll([ | 299 members.addAll([ |
277 new DivElement()..classes = ['memberItem'] | 300 new DivElement()..classes = ['memberItem'] |
278 ..text = ' ', | |
279 new DivElement()..classes = ['memberItem'] | |
280 ..children = [ | |
281 new DivElement()..classes = ['memberName'] | |
282 ..text = 'ic data array', | |
283 new DivElement()..classes = ['memberName'] | |
284 ..children = [ | |
285 new InstanceRefElement(_isolate, _function.icDataArray, | |
286 _instances, queue: _r.queue) | |
287 ] | |
288 ], | |
289 new DivElement()..classes = ['memberItem'] | |
290 ..children = [ | 301 ..children = [ |
291 new DivElement()..classes = ['memberName'] | 302 new DivElement()..classes = ['memberName'] |
292 ..text = 'deoptimizations', | 303 ..text = 'deoptimizations', |
293 new DivElement()..classes = ['memberName'] | 304 new DivElement()..classes = ['memberName'] |
294 ..text = '${_function.deoptimizations}' | 305 ..text = '${_function.deoptimizations}' |
295 ], | 306 ], |
296 new DivElement()..classes = ['memberItem'] | 307 new DivElement()..classes = ['memberItem'] |
297 ..children = [ | 308 ..children = [ |
298 new DivElement()..classes = ['memberName'] | 309 new DivElement()..classes = ['memberName'] |
299 ..text = 'optimizable', | 310 ..text = 'optimizable', |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
384 case M.FunctionKind.stub: | 395 case M.FunctionKind.stub: |
385 return 'stub'; | 396 return 'stub'; |
386 case M.FunctionKind.tag: | 397 case M.FunctionKind.tag: |
387 return 'tag'; | 398 return 'tag'; |
388 case M.FunctionKind.signatureFunction: | 399 case M.FunctionKind.signatureFunction: |
389 return 'signature function'; | 400 return 'signature function'; |
390 } | 401 } |
391 throw new Exception('Unknown Functionkind ($kind)'); | 402 throw new Exception('Unknown Functionkind ($kind)'); |
392 } | 403 } |
393 } | 404 } |
OLD | NEW |