In general, this isn't a good idea. AFAICT, you can't be sure that an
HElementsTransition dominates all of the uses of its inputs. It might work
for
this benchmark, but I can think of straight-forward situations where this
won't
be the case.
Furthermore, some instructions that depend on the input to the
HElementsTransition, like simple property Loads and Stores, may not benefit
from
depending on the HTransition. It will prevent them from being hoisted into
an
outer loop beyond the inner loop's preheader by doing this. Probably also
not
the right thing to do.
What is the motivation of the change? If we are missing GVN opportunities
for
selected instructions because they should be treated equivalently regardless
whether they depend on a HElementsTransition or the inputs to the
HElementsTransition, then the Equal method of those affected instructions
should
be modified appropriately to handle those cases.
http://codereview.chromium.org/10544133/
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev