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

Side by Side Diff: frog/leg/ssa/codegen.dart

Issue 9432022: Make sure the merge block after a try/catch has its dominator the block that contains HTry. This wa… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 10 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 | « frog/leg/ssa/builder.dart ('k') | frog/leg/ssa/nodes.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 String generate(WorkItem work, HGraph graph) { 9 String generate(WorkItem work, HGraph graph) {
10 return measure(() { 10 return measure(() {
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
390 visitBasicBlock(successors[1]); 390 visitBasicBlock(successors[1]);
391 parameterNames.remove(node.exception.element); 391 parameterNames.remove(node.exception.element);
392 indent--; 392 indent--;
393 } 393 }
394 394
395 if (node.finallyBlock != null) { 395 if (node.finallyBlock != null) {
396 addIndentation(); 396 addIndentation();
397 buffer.add('} finally {\n'); 397 buffer.add('} finally {\n');
398 indent++; 398 indent++;
399 visitBasicBlock(node.finallyBlock); 399 visitBasicBlock(node.finallyBlock);
400 indent--;
400 } 401 }
401 indent--;
402 addIndentation(); 402 addIndentation();
403 buffer.add('}\n'); 403 buffer.add('}\n');
404
405 visitBasicBlock(node.joinBlock);
404 } 406 }
405 407
406 visitIf(HIf node) { 408 visitIf(HIf node) {
407 startIf(node); 409 startIf(node);
408 assert(!node.generateAtUseSite()); 410 assert(!node.generateAtUseSite());
409 startThen(node); 411 startThen(node);
410 visitBasicBlock(node.thenBlock); 412 visitBasicBlock(node.thenBlock);
411 endThen(node); 413 endThen(node);
412 if (node.hasElse) { 414 if (node.hasElse) {
413 startElse(node); 415 startElse(node);
(...skipping 848 matching lines...) Expand 10 before | Expand all | Expand 10 after
1262 startBailoutSwitch(); 1264 startBailoutSwitch();
1263 } 1265 }
1264 } 1266 }
1265 1267
1266 void endElse(HIf node) { 1268 void endElse(HIf node) {
1267 if (node.elseBlock.hasBailouts()) { 1269 if (node.elseBlock.hasBailouts()) {
1268 endBailoutSwitch(); 1270 endBailoutSwitch();
1269 } 1271 }
1270 } 1272 }
1271 } 1273 }
OLDNEW
« no previous file with comments | « frog/leg/ssa/builder.dart ('k') | frog/leg/ssa/nodes.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698