Chromium Code Reviews| Index: src/compiler/loop-analysis.cc |
| diff --git a/src/compiler/loop-analysis.cc b/src/compiler/loop-analysis.cc |
| index e839130b43a191f5c3389e379e548438250c3552..28438eccfefb0d3a168b4a77292e883a8632b354 100644 |
| --- a/src/compiler/loop-analysis.cc |
| +++ b/src/compiler/loop-analysis.cc |
| @@ -1,4 +1,4 @@ |
| -// Copyright 2013 the V8 project authors. All rights reserved. |
| +// Copyright 2014 the V8 project authors. All rights reserved. |
|
Benedikt Meurer
2015/01/16 17:55:36
2015 :-)
titzer
2015/01/19 09:47:12
First committed last month...
|
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| @@ -156,8 +156,7 @@ class LoopFinderImpl { |
| if (node->opcode() == IrOpcode::kLoop) { |
| // found the loop node first. |
| CreateLoopInfo(node, ni); |
| - } else if (node->opcode() == IrOpcode::kPhi || |
| - node->opcode() == IrOpcode::kEffectPhi) { |
| + } else if (IrOpcode::IsPhiOpcode(node->opcode())) { |
| // found a phi first. |
| Node* merge = node->InputAt(node->InputCount() - 1); |
| if (merge->opcode() == IrOpcode::kLoop) { |
| @@ -204,8 +203,7 @@ class LoopFinderImpl { |
| // Setup loop mark for phis attached to loop header. |
| for (Node* use : node->uses()) { |
| - if (use->opcode() == IrOpcode::kPhi || |
| - use->opcode() == IrOpcode::kEffectPhi) { |
| + if (IrOpcode::IsPhiOpcode(use->opcode())) { |
| info(use).loop_mark = loop_mark; |
| } |
| } |
| @@ -242,8 +240,7 @@ class LoopFinderImpl { |
| // TODO(titzer): checking for backedges here is ugly. |
| if (!ui.IsLoopHeader()) return false; |
| if (edge.index() == kAssumedLoopEntryIndex) return false; |
| - if (use->opcode() == IrOpcode::kPhi || |
| - use->opcode() == IrOpcode::kEffectPhi) { |
| + if (IrOpcode::IsPhiOpcode(use->opcode())) { |
| return !NodeProperties::IsControlEdge(edge); |
| } |
| return true; |