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

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

Issue 2814973003: Extract ClosedWorldRefiner implementation from ClosedWorldImpl to ClosedWorldBase (Closed)
Patch Set: Created 3 years, 8 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) 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 import 'dart:collection'; 5 import 'dart:collection';
6 6
7 import 'package:js_runtime/shared/embedded_names.dart'; 7 import 'package:js_runtime/shared/embedded_names.dart';
8 8
9 import '../closure.dart'; 9 import '../closure.dart';
10 import '../common.dart'; 10 import '../common.dart';
(...skipping 646 matching lines...) Expand 10 before | Expand all | Expand 10 after
657 return graph.addConstant(getConstantForNode(node), closedWorld); 657 return graph.addConstant(getConstantForNode(node), closedWorld);
658 } 658 }
659 659
660 /** 660 /**
661 * Documentation wanted -- johnniwinther 661 * Documentation wanted -- johnniwinther
662 * 662 *
663 * Invariant: [functionElement] must be an implementation element. 663 * Invariant: [functionElement] must be an implementation element.
664 */ 664 */
665 HGraph buildMethod(MethodElement functionElement) { 665 HGraph buildMethod(MethodElement functionElement) {
666 assert(invariant(functionElement, functionElement.isImplementation)); 666 assert(invariant(functionElement, functionElement.isImplementation));
667 graph.calledInLoop = closedWorld.isCalledInLoop(functionElement); 667 graph.calledInLoop =
668 closedWorld.isCalledInLoop(functionElement.declaration);
668 ast.FunctionExpression function = resolvedAst.node; 669 ast.FunctionExpression function = resolvedAst.node;
669 assert(function != null); 670 assert(function != null);
670 assert(elements.getFunctionDefinition(function) != null); 671 assert(elements.getFunctionDefinition(function) != null);
671 openFunction(functionElement, function); 672 openFunction(functionElement, function);
672 String name = functionElement.name; 673 String name = functionElement.name;
673 if (nativeData.isJsInteropMember(functionElement)) { 674 if (nativeData.isJsInteropMember(functionElement)) {
674 push(invokeJsInteropFunction(functionElement, parameters.values.toList(), 675 push(invokeJsInteropFunction(functionElement, parameters.values.toList(),
675 sourceInformationBuilder.buildGeneric(function))); 676 sourceInformationBuilder.buildGeneric(function)));
676 var value = pop(); 677 var value = pop();
677 closeAndGotoExit(new HReturn( 678 closeAndGotoExit(new HReturn(
(...skipping 6067 matching lines...) Expand 10 before | Expand all | Expand 10 after
6745 this.oldReturnLocal, 6746 this.oldReturnLocal,
6746 this.oldReturnType, 6747 this.oldReturnType,
6747 this.oldResolvedAst, 6748 this.oldResolvedAst,
6748 this.oldStack, 6749 this.oldStack,
6749 this.oldLocalsHandler, 6750 this.oldLocalsHandler,
6750 this.inTryStatement, 6751 this.inTryStatement,
6751 this.allFunctionsCalledOnce, 6752 this.allFunctionsCalledOnce,
6752 this.oldElementInferenceResults) 6753 this.oldElementInferenceResults)
6753 : super(function); 6754 : super(function);
6754 } 6755 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698