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

Side by Side Diff: sdk/lib/_internal/compiler/implementation/ssa/bailout.dart

Issue 16004005: Fix generation of a bailout method when a BailoutTarget was in the middle of a loop/labeled block. … (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 6 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 | « no previous file | sdk/lib/_internal/compiler/implementation/ssa/tracer.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 part of ssa; 5 part of ssa;
6 6
7 class BailoutInfo { 7 class BailoutInfo {
8 int instructionId; 8 int instructionId;
9 int bailoutId; 9 int bailoutId;
10 BailoutInfo(this.instructionId, this.bailoutId); 10 BailoutInfo(this.instructionId, this.bailoutId);
(...skipping 716 matching lines...) Expand 10 before | Expand all | Expand 10 after
727 int inputLength = target.inputs.length; 727 int inputLength = target.inputs.length;
728 for (HInstruction input in target.inputs) { 728 for (HInstruction input in target.inputs) {
729 String inputName = variableNames.getName(input); 729 String inputName = variableNames.getName(input);
730 int position = parameterNames[inputName]; 730 int position = parameterNames[inputName];
731 if (position == null) { 731 if (position == null) {
732 position = parameterNames[inputName] = bailoutArity++; 732 position = parameterNames[inputName] = bailoutArity++;
733 } 733 }
734 } 734 }
735 735
736 if (blocks.isEmpty) { 736 if (blocks.isEmpty) {
737 if (firstBailoutTarget == null) { 737 // If [currentBlockInformation] is not null, we are in the
738 // middle of a loop/labeled block and this is too complex to handle for
739 // now.
740 if (firstBailoutTarget == null && currentBlockInformation == null) {
738 firstBailoutTarget = target; 741 firstBailoutTarget = target;
739 } else { 742 } else {
740 hasComplexBailoutTargets = true; 743 hasComplexBailoutTargets = true;
741 } 744 }
742 } else { 745 } else {
743 hasComplexBailoutTargets = true; 746 hasComplexBailoutTargets = true;
744 blocks.forEach((HBasicBlock block) { 747 blocks.forEach((HBasicBlock block) {
745 block.bailoutTargets.add(target); 748 block.bailoutTargets.add(target);
746 }); 749 });
747 } 750 }
748 } 751 }
749 } 752 }
OLDNEW
« no previous file with comments | « no previous file | sdk/lib/_internal/compiler/implementation/ssa/tracer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698