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

Side by Side Diff: pkg/compiler/lib/src/ssa/ssa_tracer.dart

Issue 1250633002: Add operators test to source_mapping_test. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Cleanup Created 5 years, 5 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
OLDNEW
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 ssa.tracer; 5 library ssa.tracer;
6 6
7 import 'dart:async' show EventSink; 7 import 'dart:async' show EventSink;
8 8
9 import 'ssa.dart'; 9 import 'ssa.dart';
10 import '../js_backend/js_backend.dart'; 10 import '../js_backend/js_backend.dart';
(...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 StringBuffer buffer = new StringBuffer(); 382 StringBuffer buffer = new StringBuffer();
383 buffer.write("Phi("); 383 buffer.write("Phi(");
384 for (int i = 0; i < phi.inputs.length; i++) { 384 for (int i = 0; i < phi.inputs.length; i++) {
385 if (i > 0) buffer.write(", "); 385 if (i > 0) buffer.write(", ");
386 buffer.write(temporaryId(phi.inputs[i])); 386 buffer.write(temporaryId(phi.inputs[i]));
387 } 387 }
388 buffer.write(")"); 388 buffer.write(")");
389 return buffer.toString(); 389 return buffer.toString();
390 } 390 }
391 391
392 String visitRef(HRef node) {
393 return 'Ref ${temporaryId(node.value)}';
394 }
395
392 String visitReturn(HReturn node) => "Return ${temporaryId(node.inputs[0])}"; 396 String visitReturn(HReturn node) => "Return ${temporaryId(node.inputs[0])}";
393 397
394 String visitShiftLeft(HShiftLeft node) => handleInvokeBinary(node, '<<'); 398 String visitShiftLeft(HShiftLeft node) => handleInvokeBinary(node, '<<');
395 String visitShiftRight(HShiftRight node) => handleInvokeBinary(node, '>>'); 399 String visitShiftRight(HShiftRight node) => handleInvokeBinary(node, '>>');
396 400
397 String visitStatic(HStatic node) 401 String visitStatic(HStatic node)
398 => "Static ${node.element.name}"; 402 => "Static ${node.element.name}";
399 403
400 String visitLazyStatic(HLazyStatic node) 404 String visitLazyStatic(HLazyStatic node)
401 => "LazyStatic ${node.element.name}"; 405 => "LazyStatic ${node.element.name}";
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
523 } 527 }
524 528
525 String visitAwait(HAwait node) { 529 String visitAwait(HAwait node) {
526 return "await ${temporaryId(node.inputs[0])}"; 530 return "await ${temporaryId(node.inputs[0])}";
527 } 531 }
528 532
529 String visitYield(HYield node) { 533 String visitYield(HYield node) {
530 return "yield${node.hasStar ? "*" : ""} ${temporaryId(node.inputs[0])}"; 534 return "yield${node.hasStar ? "*" : ""} ${temporaryId(node.inputs[0])}";
531 } 535 }
532 } 536 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698