[turbofan] Remove unused diamonds during control reduction.
authorbmeurer <bmeurer@chromium.org>
Thu, 12 Mar 2015 09:02:07 +0000 (02:02 -0700)
committerCommit bot <commit-bot@chromium.org>
Thu, 12 Mar 2015 09:02:22 +0000 (09:02 +0000)
commitb5197ea478e37e4629ec49348ce3a11d0ec15cb1
tree8ae55799f7b2361113c613b393bdb3e9500a5d80
parent8329f04abe2970ac65489a9ddadceb00a0095e39
[turbofan] Remove unused diamonds during control reduction.

A diamond is unused if the Merge node has no Phi/EffectPhi uses, exactly
two inputs, one IfTrue and one IfFalse, which have the same Branch
control input and no other uses except for the Merge. In this case the
diamond can safely be removed.

R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1000883003

Cr-Commit-Position: refs/heads/master@{#27148}
src/compiler/control-reducer.cc
test/cctest/compiler/test-control-reducer.cc