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

Issue 1468003002: [Interpreter] Add support for cast operators to bytecode graph builder and (Closed)

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

Description

[Interpreter] Add support for cast operators to bytecode graph builder and an optomization to remove redundant cast operations. 1. Adds an optimization to remove redundant ToBoolean and ToName operations. 2. Adds implementation and tests for cast operatorts to bytecode graph builder. BUG=v8:4280 LOG=N Committed: https://crrev.com/b587aa2bc7e811dfe3f107f97485eb978f2ecb45 Cr-Commit-Position: refs/heads/master@{#32408}

Patch Set 1 #

Total comments: 6

Patch Set 2 : fix for bot failure on win_rel #

Patch Set 3 : Trying to fix bot failure on win_rel again #

Patch Set 4 : Addressed review comments. #

Total comments: 4

Patch Set 5 : Addressed review comments #

Total comments: 6

Patch Set 6 : rebased the patch and removed unused definitions of matcher classes in unittests #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+126 lines, -25 lines) Patch
M src/compiler/bytecode-graph-builder.h View 1 2 3 4 5 1 chunk +2 lines, -0 lines 0 comments Download
M src/compiler/bytecode-graph-builder.cc View 1 2 3 4 5 1 chunk +12 lines, -4 lines 0 comments Download
M src/interpreter/bytecode-array-builder.h View 1 2 3 4 5 2 chunks +2 lines, -0 lines 0 comments Download
M src/interpreter/bytecode-array-builder.cc View 1 2 3 4 5 7 chunks +99 lines, -16 lines 2 comments Download
M test/cctest/compiler/test-run-bytecode-graph-builder.cc View 1 2 3 4 5 1 chunk +10 lines, -0 lines 0 comments Download
M test/cctest/interpreter/test-bytecode-generator.cc View 1 2 3 4 5 3 chunks +1 line, -3 lines 0 comments Download
M test/unittests/compiler/node-test-utils.cc View 1 2 3 4 5 1 chunk +0 lines, -2 lines 0 comments Download

Messages

Total messages: 19 (7 generated)
mythria
Could you please review my changes. Thanks, Mythri
5 years ago (2015-11-23 10:54:02 UTC) #2
oth
Overall this looks good. Minor niggle with the naming - it needs to be clearer. ...
5 years ago (2015-11-23 13:46:41 UTC) #3
mythria
Could you please review my changes. Thanks, Mythri https://codereview.chromium.org/1468003002/diff/1/src/compiler/bytecode-graph-builder.cc File src/compiler/bytecode-graph-builder.cc (right): https://codereview.chromium.org/1468003002/diff/1/src/compiler/bytecode-graph-builder.cc#newcode1003 src/compiler/bytecode-graph-builder.cc:1003: Node* ...
5 years ago (2015-11-24 12:58:48 UTC) #4
oth
A couple of nits, but lgtm. thanks! https://codereview.chromium.org/1468003002/diff/60001/src/interpreter/bytecode-array-builder.cc File src/interpreter/bytecode-array-builder.cc (right): https://codereview.chromium.org/1468003002/diff/60001/src/interpreter/bytecode-array-builder.cc#newcode13 src/interpreter/bytecode-array-builder.cc:13: explicit PreviousBytecodeHelper(BytecodeArrayBuilder& ...
5 years ago (2015-11-24 13:49:26 UTC) #5
mythria
Thanks orion, I fixed both of them. https://codereview.chromium.org/1468003002/diff/60001/src/interpreter/bytecode-array-builder.cc File src/interpreter/bytecode-array-builder.cc (right): https://codereview.chromium.org/1468003002/diff/60001/src/interpreter/bytecode-array-builder.cc#newcode13 src/interpreter/bytecode-array-builder.cc:13: explicit PreviousBytecodeHelper(BytecodeArrayBuilder& ...
5 years ago (2015-11-24 14:33:06 UTC) #6
Benedikt Meurer
LGTM on compiler.
5 years ago (2015-11-30 10:05:12 UTC) #7
mythria
Orion, I rebased the patch and removed NodeMatchers for binary operators and type conversion operators ...
5 years ago (2015-11-30 12:34:26 UTC) #9
oth
Thanks, looks fine. lgtm.
5 years ago (2015-11-30 13:39:54 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1468003002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1468003002/100001
5 years ago (2015-11-30 13:41:52 UTC) #13
commit-bot: I haz the power
Committed patchset #6 (id:100001)
5 years ago (2015-11-30 13:50:01 UTC) #15
commit-bot: I haz the power
Patchset 6 (id:??) landed as https://crrev.com/b587aa2bc7e811dfe3f107f97485eb978f2ecb45 Cr-Commit-Position: refs/heads/master@{#32408}
5 years ago (2015-11-30 13:50:24 UTC) #17
rmcilroy
5 years ago (2015-12-07 11:56:03 UTC) #19
Message was sent while issue was closed.
https://codereview.chromium.org/1468003002/diff/100001/src/interpreter/byteco...
File src/interpreter/bytecode-array-builder.cc (right):

https://codereview.chromium.org/1468003002/diff/100001/src/interpreter/byteco...
src/interpreter/bytecode-array-builder.cc:20: return Bytecode::kLast;
Bytecode::kLast is the same as the last valid bytecode declared in bytecodes.h -
i.e., Bytecode::kReturn right now. Are you sure you want to return this as a
'none' value? It seems like it could cause bugs or confusion if you want to do a
test against kReturn or if the bytecode declaration order changes such that
kLast is equal to one of the bytecodes being checked below.

https://codereview.chromium.org/1468003002/diff/100001/src/interpreter/byteco...
src/interpreter/bytecode-array-builder.cc:616: switch
(previous_bytecode.GetBytecode()) {
Optional nit - It would be nice to have some tests of these cases below in
test-bytecode-generator.

Powered by Google App Engine
This is Rietveld 408576698