Revision f230a1cf deps/v8/src/hydrogen-canonicalize.cc

View differences:

deps/v8/src/hydrogen-canonicalize.cc
26 26
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 27

  
28 28
#include "hydrogen-canonicalize.h"
29
#include "hydrogen-redundant-phi.h"
29 30

  
30 31
namespace v8 {
31 32
namespace internal {
......
57 58
      }
58 59
    }
59 60
  }
61

  
60 62
  // Perform actual Canonicalization pass.
63
  HRedundantPhiEliminationPhase redundant_phi_eliminator(graph());
61 64
  for (int i = 0; i < blocks->length(); ++i) {
65
    // Eliminate redundant phis in the block first; changes to their inputs
66
    // might have made them redundant, and eliminating them creates more
67
    // opportunities for constant folding and strength reduction.
68
    redundant_phi_eliminator.ProcessBlock(blocks->at(i));
69
    // Now canonicalize each instruction.
62 70
    for (HInstructionIterator it(blocks->at(i)); !it.Done(); it.Advance()) {
63 71
      HInstruction* instr = it.Current();
64 72
      HValue* value = instr->Canonicalize();

Also available in: Unified diff