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

Unified Diff: pkg/compiler/lib/src/cps_ir/redundant_phi.dart

Issue 759193005: Add support for fields to the new dart backend. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebase Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/compiler/lib/src/cps_ir/optimizers.dart ('k') | pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/cps_ir/redundant_phi.dart
diff --git a/pkg/compiler/lib/src/cps_ir/redundant_phi.dart b/pkg/compiler/lib/src/cps_ir/redundant_phi.dart
index f297a37ba42eda1d3cbdfea1894b12229f6ebc61..25f4cef97171379a51d43cd313089eb054b7202c 100644
--- a/pkg/compiler/lib/src/cps_ir/redundant_phi.dart
+++ b/pkg/compiler/lib/src/cps_ir/redundant_phi.dart
@@ -15,8 +15,18 @@ part of dart2js.optimizers;
class RedundantPhiEliminator extends RecursiveVisitor implements Pass {
final Set<Continuation> workSet = new Set<Continuation>();
- void rewrite(final FunctionDefinition root) {
+ void rewrite(final ExecutableDefinition root) => root.applyPass(this);
+
+ void rewriteFunctionDefinition(final FunctionDefinition root) {
if (root.isAbstract) return;
+ rewriteExecutableDefinition(root);
+ }
+
+ void rewriteFieldDefinition(final FieldDefinition root) {
+ rewriteExecutableDefinition(root);
+ }
+
+ void rewriteExecutableDefinition(final ExecutableDefinition root) {
// Set all parent pointers.
new ParentVisitor().visit(root);
« no previous file with comments | « pkg/compiler/lib/src/cps_ir/optimizers.dart ('k') | pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698