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

Issue 1531693002: [Interpreter] Implement ForIn in bytecode graph builder. (Closed)

Created:
5 years ago by oth
Modified:
5 years ago
CC:
v8-reviews_googlegroups.com, rmcilroy
Base URL:
https://chromium.googlesource.com/v8/v8.git@oth-0009-phi
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[Interpreter] Implement ForIn in bytecode graph builder. A pre-requisite for this change was changing the interpreter to use Runtime::ForInStep to bring the interpreter implementation closer to the turbofan implementation. Also required to flatten out the cache parameters into the interpreter frame for de-opt. BUG=v8:4280 LOG=N Committed: https://crrev.com/4926be6eb21e1add4144eba0a398a28f289ce2d5 Cr-Commit-Position: refs/heads/master@{#32986}

Patch Set 1 #

Total comments: 1

Patch Set 2 : Fix ForInPrepare. #

Total comments: 2

Patch Set 3 : Re-work ForInPrepare. #

Total comments: 12

Patch Set 4 : Move ToObject out. #

Patch Set 5 : Fix missing comment. #

Total comments: 2

Patch Set 6 : Fix poor choice of comments. #

Patch Set 7 : Rebase after de-opt landed. #

Total comments: 4

Patch Set 8 : Fix tests. #

Patch Set 9 : Overlooked review comment incorporated. #

Patch Set 10 : Testing only - avoid exception badness and try regular ToObject. #

Patch Set 11 : Minor clean-up/simplication in Runtime_InterpreterForInPrepare. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+369 lines, -204 lines) Patch
M src/compiler/bytecode-graph-builder.cc View 1 2 3 4 5 6 7 2 chunks +44 lines, -8 lines 0 comments Download
M src/interpreter/bytecode-array-builder.h View 1 2 3 4 5 6 7 3 chunks +10 lines, -4 lines 0 comments Download
M src/interpreter/bytecode-array-builder.cc View 1 2 3 4 5 6 7 5 chunks +24 lines, -6 lines 0 comments Download
M src/interpreter/bytecode-generator.cc View 1 2 3 4 5 6 7 2 chunks +20 lines, -19 lines 0 comments Download
M src/interpreter/bytecodes.h View 1 2 3 4 5 6 7 1 chunk +5 lines, -3 lines 0 comments Download
M src/interpreter/control-flow-builders.h View 1 2 3 4 5 6 7 2 chunks +1 line, -2 lines 0 comments Download
M src/interpreter/control-flow-builders.cc View 1 2 3 4 5 6 7 1 chunk +10 lines, -0 lines 0 comments Download
M src/interpreter/interpreter.cc View 1 2 3 4 5 6 7 8 9 2 chunks +41 lines, -26 lines 0 comments Download
M src/runtime/runtime-interpreter.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +15 lines, -11 lines 0 comments Download
M test/cctest/compiler/test-run-bytecode-graph-builder.cc View 1 2 3 4 5 6 7 1 chunk +73 lines, -0 lines 0 comments Download
M test/cctest/interpreter/test-bytecode-generator.cc View 1 2 3 4 5 6 7 2 chunks +122 lines, -124 lines 0 comments Download
M test/unittests/interpreter/bytecode-array-builder-unittest.cc View 1 2 3 4 5 6 7 1 chunk +4 lines, -1 line 0 comments Download

Messages

Total messages: 31 (8 generated)
oth
rmcilroy@chromium.org: Please review changes all over. bmeurer@chromium.org: Please review changes in the compiler.
5 years ago (2015-12-16 09:59:03 UTC) #2
Benedikt Meurer
Looking into compiler. https://codereview.chromium.org/1531693002/diff/1/src/compiler/bytecode-graph-builder.cc File src/compiler/bytecode-graph-builder.cc (right): https://codereview.chromium.org/1531693002/diff/1/src/compiler/bytecode-graph-builder.cc#newcode1375 src/compiler/bytecode-graph-builder.cc:1375: javascript()->CallRuntime(Runtime::kInterpreterForInPrepare, 2); What about JSForInPrepare? Calling ...
5 years ago (2015-12-16 10:53:25 UTC) #3
oth
On 2015/12/16 10:53:25, Benedikt Meurer wrote: > Looking into compiler. > > https://codereview.chromium.org/1531693002/diff/1/src/compiler/bytecode-graph-builder.cc > File ...
5 years ago (2015-12-16 16:29:57 UTC) #4
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1531693002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1531693002/20001
5 years ago (2015-12-16 17:04:22 UTC) #6
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years ago (2015-12-16 17:25:53 UTC) #8
Benedikt Meurer
https://codereview.chromium.org/1531693002/diff/20001/src/interpreter/bytecode-generator.cc File src/interpreter/bytecode-generator.cc (right): https://codereview.chromium.org/1531693002/diff/20001/src/interpreter/bytecode-generator.cc#newcode876 src/interpreter/bytecode-generator.cc:876: loop_builder.BreakIfUndefined(); This looks wrong/unnecessary (now). As far as I ...
5 years ago (2015-12-16 20:00:14 UTC) #9
oth
On 2015/12/16 20:00:14, Benedikt Meurer wrote: > https://codereview.chromium.org/1531693002/diff/20001/src/interpreter/bytecode-generator.cc > File src/interpreter/bytecode-generator.cc (right): > > https://codereview.chromium.org/1531693002/diff/20001/src/interpreter/bytecode-generator.cc#newcode876 ...
5 years ago (2015-12-16 21:50:20 UTC) #10
oth
I think this finally unifies handling of ForInPrepare. PTAL. More tests to follow in test-run-bytecode-graph-builder, ...
5 years ago (2015-12-17 14:46:56 UTC) #11
rmcilroy
Looks good apart from deoptimization comment. https://codereview.chromium.org/1531693002/diff/40001/src/compiler/bytecode-graph-builder.cc File src/compiler/bytecode-graph-builder.cc (right): https://codereview.chromium.org/1531693002/diff/40001/src/compiler/bytecode-graph-builder.cc#newcode1376 src/compiler/bytecode-graph-builder.cc:1376: AddEmptyFrameStateInputs(prepare); Hmm, this ...
5 years ago (2015-12-17 15:43:27 UTC) #12
oth
Thanks, all done. It stinks, but can't think of a good excuse, it's just horrible. ...
5 years ago (2015-12-17 19:28:24 UTC) #13
Benedikt Meurer
https://codereview.chromium.org/1531693002/diff/80001/src/compiler/bytecode-graph-builder.cc File src/compiler/bytecode-graph-builder.cc (right): https://codereview.chromium.org/1531693002/diff/80001/src/compiler/bytecode-graph-builder.cc#newcode1378 src/compiler/bytecode-graph-builder.cc:1378: // have already cast the object to JSReceiver, but ...
5 years ago (2015-12-18 07:55:50 UTC) #14
oth
On 2015/12/18 07:55:50, Benedikt Meurer wrote: > https://codereview.chromium.org/1531693002/diff/80001/src/compiler/bytecode-graph-builder.cc > File src/compiler/bytecode-graph-builder.cc (right): > > https://codereview.chromium.org/1531693002/diff/80001/src/compiler/bytecode-graph-builder.cc#newcode1378 ...
5 years ago (2015-12-18 09:00:02 UTC) #15
oth
On 2015/12/18 09:00:02, oth wrote: > On 2015/12/18 07:55:50, Benedikt Meurer wrote: > > > ...
5 years ago (2015-12-18 16:01:47 UTC) #16
oth
On 2015/12/18 09:00:02, oth wrote: > On 2015/12/18 07:55:50, Benedikt Meurer wrote: > > > ...
5 years ago (2015-12-18 16:01:47 UTC) #17
rmcilroy
LGTM once Benedikt is happy. https://codereview.chromium.org/1531693002/diff/120001/src/interpreter/interpreter.cc File src/interpreter/interpreter.cc (right): https://codereview.chromium.org/1531693002/diff/120001/src/interpreter/interpreter.cc#newcode1528 src/interpreter/interpreter.cc:1528: Node* object = __ ...
5 years ago (2015-12-18 16:01:55 UTC) #18
rmcilroy
LGTM once Benedikt is happy.
5 years ago (2015-12-18 16:01:56 UTC) #19
Benedikt Meurer
LGTM once test failures are addressed.
5 years ago (2015-12-18 20:19:00 UTC) #20
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1531693002/160001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1531693002/160001
5 years ago (2015-12-20 15:25:27 UTC) #22
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: v8_linux_rel on tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_linux_rel/builds/13315)
5 years ago (2015-12-20 15:42:12 UTC) #24
oth
Thanks for the feedback and patience with this CL. Quite an interesting set of constraints. ...
5 years ago (2015-12-21 10:05:53 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1531693002/200001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1531693002/200001
5 years ago (2015-12-21 13:29:49 UTC) #28
commit-bot: I haz the power
Committed patchset #11 (id:200001)
5 years ago (2015-12-21 13:30:51 UTC) #29
commit-bot: I haz the power
5 years ago (2015-12-21 13:31:19 UTC) #31
Message was sent while issue was closed.
Patchset 11 (id:??) landed as
https://crrev.com/4926be6eb21e1add4144eba0a398a28f289ce2d5
Cr-Commit-Position: refs/heads/master@{#32986}

Powered by Google App Engine
This is Rietveld 408576698