| Index: pkg/compiler/lib/src/cps_ir/loop_invariant_branch.dart
|
| diff --git a/pkg/compiler/lib/src/cps_ir/loop_invariant_branch.dart b/pkg/compiler/lib/src/cps_ir/loop_invariant_branch.dart
|
| index e9f04a62df0647911f02da9e6d8ffa42746ec318..98df30a16ec34edd3b29dc5e580bd703a2095718 100644
|
| --- a/pkg/compiler/lib/src/cps_ir/loop_invariant_branch.dart
|
| +++ b/pkg/compiler/lib/src/cps_ir/loop_invariant_branch.dart
|
| @@ -121,7 +121,7 @@ class LoopInvariantBranchMotion extends BlockVisitor implements Pass {
|
| Node use = ref.parent;
|
| if (use is InvokeContinuation) {
|
| for (Parameter loopParam in parameters) {
|
| - use.arguments.add(new Reference<Primitive>(loopParam)..parent = use);
|
| + use.argumentRefs.add(new Reference<Primitive>(loopParam)..parent = use);
|
| }
|
| }
|
| }
|
| @@ -134,11 +134,11 @@ class LoopInvariantBranchMotion extends BlockVisitor implements Pass {
|
| Branch branch = body;
|
|
|
| // Is the condition loop invariant?
|
| - Primitive condition = branch.condition.definition;
|
| + Primitive condition = branch.condition;
|
| if (loopHeaderFor[condition] == loop) return false;
|
|
|
| - Continuation trueCont = branch.trueContinuation.definition;
|
| - Continuation falseCont = branch.falseContinuation.definition;
|
| + Continuation trueCont = branch.trueContinuation;
|
| + Continuation falseCont = branch.falseContinuation;
|
| Continuation hoistedCase; // The branch to hoist.
|
| Continuation loopCase; // The branch that is part of the loop.
|
|
|
| @@ -212,7 +212,7 @@ class LoopInvariantBranchMotion extends BlockVisitor implements Pass {
|
| //
|
| InvokeContinuation loopEntry = loopBinding.body;
|
| List<Primitive> loopArgs =
|
| - loopEntry.arguments.map((ref) => ref.definition).toList();
|
| + loopEntry.arguments.toList();
|
| CpsFragment cps = new CpsFragment();
|
| cps.branch(condition,
|
| strict: branch.isStrictCheck,
|
|
|