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

Side by Side Diff: pkg/compiler/lib/src/js_backend/codegen/task.dart

Issue 1409803003: dart2js cps: More interceptor optimizations and fixes. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Fix indentation Created 5 years, 1 month 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) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 /// Generate code using the cps-based IR pipeline. 5 /// Generate code using the cps-based IR pipeline.
6 library code_generator_task; 6 library code_generator_task;
7 7
8 import 'glue.dart'; 8 import 'glue.dart';
9 import 'codegen.dart'; 9 import 'codegen.dart';
10 import 'unsugar.dart'; 10 import 'unsugar.dart';
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 applyCpsPass(new InsertRefinements(typeSystem), cpsFunction); 207 applyCpsPass(new InsertRefinements(typeSystem), cpsFunction);
208 applyCpsPass(new TypePropagator(compiler, typeSystem, this), cpsFunction); 208 applyCpsPass(new TypePropagator(compiler, typeSystem, this), cpsFunction);
209 applyCpsPass(new RemoveRefinements(), cpsFunction); 209 applyCpsPass(new RemoveRefinements(), cpsFunction);
210 applyCpsPass(new ShrinkingReducer(), cpsFunction); 210 applyCpsPass(new ShrinkingReducer(), cpsFunction);
211 applyCpsPass(new ScalarReplacer(compiler), cpsFunction); 211 applyCpsPass(new ScalarReplacer(compiler), cpsFunction);
212 applyCpsPass(new MutableVariableEliminator(), cpsFunction); 212 applyCpsPass(new MutableVariableEliminator(), cpsFunction);
213 applyCpsPass(new RedundantJoinEliminator(), cpsFunction); 213 applyCpsPass(new RedundantJoinEliminator(), cpsFunction);
214 applyCpsPass(new RedundantPhiEliminator(), cpsFunction); 214 applyCpsPass(new RedundantPhiEliminator(), cpsFunction);
215 applyCpsPass(new BoundsChecker(typeSystem, compiler.world), cpsFunction); 215 applyCpsPass(new BoundsChecker(typeSystem, compiler.world), cpsFunction);
216 applyCpsPass(new ShrinkingReducer(), cpsFunction); 216 applyCpsPass(new ShrinkingReducer(), cpsFunction);
217 applyCpsPass(new ShareInterceptors(), cpsFunction); 217 applyCpsPass(new ShareInterceptors(backend), cpsFunction);
218 applyCpsPass(new ShrinkingReducer(), cpsFunction); 218 applyCpsPass(new ShrinkingReducer(), cpsFunction);
219 }); 219 });
220 return cpsFunction; 220 return cpsFunction;
221 } 221 }
222 222
223 tree_ir.FunctionDefinition compileToTreeIr(cps.FunctionDefinition cpsNode) { 223 tree_ir.FunctionDefinition compileToTreeIr(cps.FunctionDefinition cpsNode) {
224 tree_builder.Builder builder = new tree_builder.Builder( 224 tree_builder.Builder builder = new tree_builder.Builder(
225 reporter.internalError); 225 reporter.internalError);
226 tree_ir.FunctionDefinition treeNode = 226 tree_ir.FunctionDefinition treeNode =
227 treeBuilderTask.measure(() => builder.buildFunction(cpsNode)); 227 treeBuilderTask.measure(() => builder.buildFunction(cpsNode));
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
278 treeOptimizationTask] 278 treeOptimizationTask]
279 ..addAll(fallbackCompiler.tasks); 279 ..addAll(fallbackCompiler.tasks);
280 } 280 }
281 281
282 js.Node attachPosition(js.Node node, AstElement element) { 282 js.Node attachPosition(js.Node node, AstElement element) {
283 return node.withSourceInformation( 283 return node.withSourceInformation(
284 sourceInformationFactory.createBuilderForContext(element) 284 sourceInformationFactory.createBuilderForContext(element)
285 .buildDeclaration(element)); 285 .buildDeclaration(element));
286 } 286 }
287 } 287 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/js_backend/backend.dart ('k') | tests/compiler/dart2js_extra/dart2js_extra.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698