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

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

Issue 23660008: Fix a bug in the variable allocator: a pure instruction between an inlined if and its inlined expre… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 3 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/variable_allocator.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 SsaCodeGeneratorTask extends CompilerTask { 7 class SsaCodeGeneratorTask extends CompilerTask {
8 8
9 final JavaScriptBackend backend; 9 final JavaScriptBackend backend;
10 10
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 endGraph(HGraph graph); 292 endGraph(HGraph graph);
293 293
294 preLabeledBlock(HLabeledBlockInformation labeledBlockInfo); 294 preLabeledBlock(HLabeledBlockInformation labeledBlockInfo);
295 startLabeledBlock(HLabeledBlockInformation labeledBlockInfo); 295 startLabeledBlock(HLabeledBlockInformation labeledBlockInfo);
296 endLabeledBlock(HLabeledBlockInformation labeledBlockInfo); 296 endLabeledBlock(HLabeledBlockInformation labeledBlockInfo);
297 297
298 void preGenerateMethod(HGraph graph) { 298 void preGenerateMethod(HGraph graph) {
299 new SsaInstructionMerger(generateAtUseSite, compiler).visitGraph(graph); 299 new SsaInstructionMerger(generateAtUseSite, compiler).visitGraph(graph);
300 new SsaConditionMerger( 300 new SsaConditionMerger(
301 generateAtUseSite, controlFlowOperators).visitGraph(graph); 301 generateAtUseSite, controlFlowOperators).visitGraph(graph);
302 SsaLiveIntervalBuilder intervalBuilder = 302 SsaLiveIntervalBuilder intervalBuilder = new SsaLiveIntervalBuilder(
303 new SsaLiveIntervalBuilder(compiler, generateAtUseSite); 303 compiler, generateAtUseSite, controlFlowOperators);
304 intervalBuilder.visitGraph(graph); 304 intervalBuilder.visitGraph(graph);
305 SsaVariableAllocator allocator = new SsaVariableAllocator( 305 SsaVariableAllocator allocator = new SsaVariableAllocator(
306 compiler, 306 compiler,
307 intervalBuilder.liveInstructions, 307 intervalBuilder.liveInstructions,
308 intervalBuilder.liveIntervals, 308 intervalBuilder.liveIntervals,
309 generateAtUseSite); 309 generateAtUseSite);
310 allocator.visitGraph(graph); 310 allocator.visitGraph(graph);
311 variableNames = allocator.names; 311 variableNames = allocator.names;
312 shouldGroupVarDeclarations = allocator.names.numberOfVariables > 1; 312 shouldGroupVarDeclarations = allocator.names.numberOfVariables > 1;
313 } 313 }
(...skipping 2674 matching lines...) Expand 10 before | Expand all | Expand 10 after
2988 if (leftType.canBeNull() && rightType.canBeNull()) { 2988 if (leftType.canBeNull() && rightType.canBeNull()) {
2989 if (left.isConstantNull() || right.isConstantNull() || 2989 if (left.isConstantNull() || right.isConstantNull() ||
2990 (leftType.isPrimitive(compiler) && leftType == rightType)) { 2990 (leftType.isPrimitive(compiler) && leftType == rightType)) {
2991 return '=='; 2991 return '==';
2992 } 2992 }
2993 return null; 2993 return null;
2994 } else { 2994 } else {
2995 return '==='; 2995 return '===';
2996 } 2996 }
2997 } 2997 }
OLDNEW
« no previous file with comments | « no previous file | sdk/lib/_internal/compiler/implementation/ssa/variable_allocator.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698