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

Side by Side Diff: lib/compiler/implementation/ssa/codegen.dart

Issue 10115026: Address the remaining review comments on http://chromiumcodereview.appspot.com/9431029. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 8 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « lib/compiler/implementation/resolver.dart ('k') | lib/compiler/implementation/typechecker.dart » ('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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 class SsaCodeGeneratorTask extends CompilerTask { 5 class SsaCodeGeneratorTask extends CompilerTask {
6 SsaCodeGeneratorTask(Compiler compiler) : super(compiler); 6 SsaCodeGeneratorTask(Compiler compiler) : super(compiler);
7 String get name() => 'SSA code generator'; 7 String get name() => 'SSA code generator';
8 8
9 9
10 String generateMethod(WorkItem work, HGraph graph) { 10 String generateMethod(WorkItem work, HGraph graph) {
(...skipping 1743 matching lines...) Expand 10 before | Expand all | Expand 10 after
1754 checkType(input, element); 1754 checkType(input, element);
1755 buffer.add(')'); 1755 buffer.add(')');
1756 endExpression(JSPrecedence.LOGICAL_OR_PRECEDENCE); 1756 endExpression(JSPrecedence.LOGICAL_OR_PRECEDENCE);
1757 endExpression(JSPrecedence.LOGICAL_AND_PRECEDENCE); 1757 endExpression(JSPrecedence.LOGICAL_AND_PRECEDENCE);
1758 } 1758 }
1759 1759
1760 void visitIs(HIs node) { 1760 void visitIs(HIs node) {
1761 Type type = node.typeExpression; 1761 Type type = node.typeExpression;
1762 Element element = type.element; 1762 Element element = type.element;
1763 if (element.kind === ElementKind.TYPE_VARIABLE) { 1763 if (element.kind === ElementKind.TYPE_VARIABLE) {
1764 compiler.unimplemented("visitIs for type variables"); 1764 compiler.unimplemented("visitIs for type variables", instruction: node);
1765 } else if (element.kind === ElementKind.TYPEDEF) { 1765 } else if (element.kind === ElementKind.TYPEDEF) {
1766 compiler.unimplemented("visitIs for typedefs"); 1766 compiler.unimplemented("visitIs for typedefs", instruction: node);
1767 } 1767 }
1768 compiler.registerIsCheck(type.element); 1768 compiler.registerIsCheck(type.element);
1769 LibraryElement coreLibrary = compiler.coreLibrary; 1769 LibraryElement coreLibrary = compiler.coreLibrary;
1770 ClassElement objectClass = compiler.objectClass; 1770 ClassElement objectClass = compiler.objectClass;
1771 HInstruction input = node.expression; 1771 HInstruction input = node.expression;
1772 1772
1773 if (node.nullOk) { 1773 if (node.nullOk) {
1774 beginExpression(JSPrecedence.LOGICAL_OR_PRECEDENCE); 1774 beginExpression(JSPrecedence.LOGICAL_OR_PRECEDENCE);
1775 checkNull(input); 1775 checkNull(input);
1776 buffer.add(' || '); 1776 buffer.add(' || ');
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after
2229 startBailoutSwitch(); 2229 startBailoutSwitch();
2230 } 2230 }
2231 } 2231 }
2232 2232
2233 void endLabeledBlock(HLabeledBlockInformation labeledBlockInfo) { 2233 void endLabeledBlock(HLabeledBlockInformation labeledBlockInfo) {
2234 if (labeledBlockInfo.body.start.hasGuards()) { 2234 if (labeledBlockInfo.body.start.hasGuards()) {
2235 endBailoutSwitch(); 2235 endBailoutSwitch();
2236 } 2236 }
2237 } 2237 }
2238 } 2238 }
OLDNEW
« no previous file with comments | « lib/compiler/implementation/resolver.dart ('k') | lib/compiler/implementation/typechecker.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698