Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Issue 6672066: Make HDeoptimize to explicitly use environment values.... (Closed)

Created:
9 years, 9 months ago by Vyacheslav Egorov (Chromium)
Modified:
9 years, 7 months ago
CC:
v8-dev
Visibility:
Public.

Description

Make HDeoptimize to explicitly use environment values. Otherwise dead phi elimination can actually remove some of the implicitly used phis. BUG=1257 TEST=test/mjsunit/regress/regress-1257.js Committed: http://code.google.com/p/v8/source/detail?r=7221

Patch Set 1 #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+49 lines, -6 lines) Patch
M src/hydrogen.h View 2 chunks +9 lines, -0 lines 2 comments Download
M src/hydrogen.cc View 5 chunks +20 lines, -4 lines 1 comment Download
M src/hydrogen-instructions.h View 1 chunk +20 lines, -2 lines 0 comments Download

Messages

Total messages: 2 (0 generated)
Vyacheslav Egorov (Chromium)
9 years, 9 months ago (2011-03-17 00:58:42 UTC) #1
Kevin Millikin (Chromium)
9 years, 9 months ago (2011-03-17 05:31:02 UTC) #2
Did you already commit the regression test?

LGTM if comments are adressed.

http://codereview.chromium.org/6672066/diff/1/src/hydrogen.cc
File src/hydrogen.cc (right):

http://codereview.chromium.org/6672066/diff/1/src/hydrogen.cc#newcode2514
src/hydrogen.cc:2514: current_block()->FinishWithDeoptimization();
We had code to try to handle this issue with a hack (which obviously didn't
work.  We inserted HSimulate immediate before HDeoptimize to create uses of all
environment values).  That code is immediately above what you just wrote.

Delete it please :)

http://codereview.chromium.org/6672066/diff/1/src/hydrogen.h
File src/hydrogen.h (right):

http://codereview.chromium.org/6672066/diff/1/src/hydrogen.h#newcode128
src/hydrogen.h:128: Finish(CreateDeoptimize());
I'd rather not have these helpers.  It doesn't save anything over:

block->Finish(CreateDeoptimize());

which has the advantage of being explicit about what happens.  There are too
many minor variations on "Finish" already.

http://codereview.chromium.org/6672066/diff/1/src/hydrogen.h#newcode131
src/hydrogen.h:131: void FinishExitWithDeoptimization() {
There's no reason to have both "Finish" and "FinishExit" for this case.  It
should always be "FinishExit".

(Though, I don't know whey we even have FinishExit at all.  All it does is clear
the environment and call Finish.  I can't think of a reason why we need to do
that.  I'd be in favor of getting rid of FinishExit too.)

Powered by Google App Engine
This is Rietveld 408576698