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

Issue 1485183002: [turbofan] Deopt support for escape analysis (Closed)

Created:
5 years ago by sigurds
Modified:
4 years, 11 months ago
CC:
v8-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/v8/v8.git@ea-local
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[turbofan] Deopt support for escape analysis Deopt support is added on two levels. On the IR level, a new ObjectState node is added, which represenents an object to be materialized. ObjectState nodes appear as inputs of FrameState and StateValues nodes. On the instruction select/code-generation level, the FrameStateDescriptor class handles the nesting introduced by ObjectState, and ensures that deopt code with CAPTURED_OBJECT/DUPLICATED_OBJECT entries are generated similarly to what crankshaft's escape analysis does. Two unittests test correctness of the IR level implementation. Correctness for instruction selection / code generation is tested by mjsunit tests. R=jarin@chromium.org,mstarzinger@chromium.org BUG=v8:4586 LOG=n Committed: https://crrev.com/3b473d7aadbf135dd8da5a6fb3eda882f1ecd3f1 Cr-Commit-Position: refs/heads/master@{#33115}

Patch Set 1 #

Total comments: 22

Patch Set 2 : Address comments #

Patch Set 3 : Minor improvements #

Patch Set 4 : Add comment and make old compilers happy #

Patch Set 5 : Rebase #

Patch Set 6 : Make more old C compilers happy #

Patch Set 7 : Fix --always-opt triggered bug #

Total comments: 1

Patch Set 8 : Probably too much #

Patch Set 9 : Remove simplified part #

Patch Set 10 : Refactor #

Patch Set 11 : Improve performance #

Patch Set 12 : Double arrays #

Patch Set 13 : Improve #

Patch Set 14 : Refactor, so CL gets smaller #

Patch Set 15 : Remove counters from this CL #

Patch Set 16 : Remove parts of next change #

Patch Set 17 : Fix return value enforcement issue #

Patch Set 18 : Add mjsunit tests #

Patch Set 19 : Improve Unittest and guard printf behind --trace-turbo-escape #

Total comments: 10

Patch Set 20 : Rebase #

Patch Set 21 : Address comments #

Patch Set 22 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+763 lines, -216 lines) Patch
M src/compiler/code-generator.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 2 chunks +23 lines, -3 lines 0 comments Download
M src/compiler/code-generator.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 4 chunks +71 lines, -51 lines 0 comments Download
M src/compiler/common-operator.h View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M src/compiler/common-operator.cc View 1 2 3 4 5 6 7 1 chunk +8 lines, -0 lines 0 comments Download
M src/compiler/escape-analysis.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +3 lines, -1 line 0 comments Download
M src/compiler/escape-analysis.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 17 chunks +108 lines, -24 lines 0 comments Download
M src/compiler/escape-analysis-reducer.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 1 chunk +5 lines, -2 lines 0 comments Download
M src/compiler/escape-analysis-reducer.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 3 chunks +131 lines, -33 lines 0 comments Download
M src/compiler/frame-states.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -1 line 0 comments Download
M src/compiler/instruction.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 6 chunks +67 lines, -5 lines 0 comments Download
M src/compiler/instruction.cc View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +3 lines, -15 lines 0 comments Download
M src/compiler/instruction-selector.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +0 lines, -2 lines 0 comments Download
M src/compiler/instruction-selector.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 9 chunks +123 lines, -37 lines 0 comments Download
M src/compiler/opcodes.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -0 lines 0 comments Download
M src/compiler/typer.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -0 lines 0 comments Download
M src/compiler/verifier.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M src/deoptimizer.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 1 chunk +31 lines, -0 lines 0 comments Download
A + test/mjsunit/compiler/escape-analysis-deopt-1.js View 1 2 3 4 5 6 7 9 10 11 12 13 14 15 16 17 1 chunk +17 lines, -4 lines 0 comments Download
A + test/mjsunit/compiler/escape-analysis-deopt-2.js View 9 10 11 12 13 14 15 16 17 1 chunk +20 lines, -4 lines 0 comments Download
A + test/mjsunit/compiler/escape-analysis-deopt-3.js View 9 10 11 12 13 14 15 16 17 1 chunk +21 lines, -4 lines 0 comments Download
A + test/mjsunit/compiler/escape-analysis-deopt-4.js View 1 2 3 4 5 6 9 10 11 12 13 14 15 16 17 1 chunk +27 lines, -4 lines 0 comments Download
A + test/mjsunit/compiler/escape-analysis-deopt-5.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 2 chunks +11 lines, -13 lines 0 comments Download
M test/mjsunit/mjsunit.status View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 1 chunk +0 lines, -13 lines 0 comments Download
M test/unittests/compiler/escape-analysis-unittest.cc View 1 2 3 4 5 6 7 1 chunk +84 lines, -0 lines 0 comments Download

Messages

Total messages: 21 (11 generated)
sigurds
This is an implementation of deopt support for escape analysis. I have touched quite a ...
5 years ago (2015-12-01 16:19:36 UTC) #1
Jarin
I like it! However, I am not too happy about moving the translation generation out ...
5 years ago (2015-12-02 12:24:35 UTC) #2
sigurds
jarin: Please take a look again, I the code (back). mstarzinger: FYI. https://codereview.chromium.org/1485183002/diff/1/src/compiler/escape-analysis-reducer.cc File src/compiler/escape-analysis-reducer.cc ...
5 years ago (2015-12-02 16:35:13 UTC) #7
Jarin
It looks awesome. As discussed offline, I'll give a real l-g-t-m once the fixed array ...
5 years ago (2015-12-04 13:41:11 UTC) #8
sigurds
Jarin, please take a look again. Benedikt, this is mainly FYI.
4 years, 11 months ago (2016-01-04 17:51:47 UTC) #11
Jarin
lgtm. nice! https://codereview.chromium.org/1485183002/diff/360001/src/compiler/code-generator.cc File src/compiler/code-generator.cc (right): https://codereview.chromium.org/1485183002/diff/360001/src/compiler/code-generator.cc#newcode497 src/compiler/code-generator.cc:497: if (desc->IsRecursive()) { Idea: Recursive -> Nested? ...
4 years, 11 months ago (2016-01-05 12:51:19 UTC) #13
sigurds
Thanks for the comments :) https://codereview.chromium.org/1485183002/diff/360001/src/compiler/code-generator.cc File src/compiler/code-generator.cc (right): https://codereview.chromium.org/1485183002/diff/360001/src/compiler/code-generator.cc#newcode497 src/compiler/code-generator.cc:497: if (desc->IsRecursive()) { On ...
4 years, 11 months ago (2016-01-05 13:08:57 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1485183002/420001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1485183002/420001
4 years, 11 months ago (2016-01-05 13:10:19 UTC) #17
commit-bot: I haz the power
Committed patchset #22 (id:420001)
4 years, 11 months ago (2016-01-05 13:30:37 UTC) #19
commit-bot: I haz the power
4 years, 11 months ago (2016-01-05 13:31:10 UTC) #21
Message was sent while issue was closed.
Patchset 22 (id:??) landed as
https://crrev.com/3b473d7aadbf135dd8da5a6fb3eda882f1ecd3f1
Cr-Commit-Position: refs/heads/master@{#33115}

Powered by Google App Engine
This is Rietveld 408576698