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

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

Issue 1313783003: dart2js cps: Generate interceptors at use-site and share afterwards. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Revert patch #3. I read Golem results backwards. Created 5 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
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 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 // Transformations on the CPS IR. 166 // Transformations on the CPS IR.
167 void applyCpsPass(cps_opt.Pass pass) { 167 void applyCpsPass(cps_opt.Pass pass) {
168 pass.rewrite(cpsNode); 168 pass.rewrite(cpsNode);
169 traceGraph(pass.passName, cpsNode); 169 traceGraph(pass.passName, cpsNode);
170 assert(checkCpsIntegrity(cpsNode)); 170 assert(checkCpsIntegrity(cpsNode));
171 } 171 }
172 172
173 TypePropagator typePropagator = new TypePropagator(compiler, this); 173 TypePropagator typePropagator = new TypePropagator(compiler, this);
174 applyCpsPass(typePropagator); 174 applyCpsPass(typePropagator);
175 dumpTypedIR(cpsNode, typePropagator); 175 dumpTypedIR(cpsNode, typePropagator);
176 applyCpsPass(new LoopInvariantCodeMotion());
177 applyCpsPass(new ShareInterceptors());
176 applyCpsPass(new ShrinkingReducer()); 178 applyCpsPass(new ShrinkingReducer());
177 applyCpsPass(new MutableVariableEliminator()); 179 applyCpsPass(new MutableVariableEliminator());
178 applyCpsPass(new RedundantJoinEliminator()); 180 applyCpsPass(new RedundantJoinEliminator());
179 applyCpsPass(new RedundantPhiEliminator()); 181 applyCpsPass(new RedundantPhiEliminator());
180 applyCpsPass(new ShrinkingReducer()); 182 applyCpsPass(new ShrinkingReducer());
181 applyCpsPass(new LetSinker()); 183 applyCpsPass(new LetSinker());
182 184
183 return cpsNode; 185 return cpsNode;
184 } 186 }
185 187
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 // TODO(sigurdm): Make a better list of tasks. 232 // TODO(sigurdm): Make a better list of tasks.
231 return <CompilerTask>[irBuilderTask]..addAll(fallbackCompiler.tasks); 233 return <CompilerTask>[irBuilderTask]..addAll(fallbackCompiler.tasks);
232 } 234 }
233 235
234 js.Node attachPosition(js.Node node, AstElement element) { 236 js.Node attachPosition(js.Node node, AstElement element) {
235 return node.withSourceInformation( 237 return node.withSourceInformation(
236 sourceInformationFactory.createBuilderForContext(element) 238 sourceInformationFactory.createBuilderForContext(element)
237 .buildDeclaration(element)); 239 .buildDeclaration(element));
238 } 240 }
239 } 241 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/cps_ir/share_interceptors.dart ('k') | pkg/compiler/lib/src/js_backend/codegen/unsugar.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698