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

Issue 1992963002: Enable optimizer pipeline for DBC. (Closed)

Created:
4 years, 7 months ago by Vyacheslav Egorov (Google)
Modified:
4 years, 7 months ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Base URL:
git@github.com:dart-lang/sdk.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Enable optimizer pipeline for DBC. Most of the infrastructure is fixed to work with DBC stack layout: - register allocator allocates DBC registers with the limitation that we allocate only 20 registers and bail out if anything needs spilling (there is no use implementing spilling on DBC because registers are memory locations themselves). We should be able to bump number of CPU registers on DBC up to 256 but this requires major surgery in some parts - so I postponed this; - lazy deoptimization is implemented, eager deoptimization is not - because we don't emit any code that actually requires it. it's a minor change to support it once we have a target; - stack scanning respects stack maps built by registers allocator; We bailout from all unsupported instructions. R=zra@google.com Committed: https://github.com/dart-lang/sdk/commit/655bc90489a6fa33b39d6a15972e9294d5c9d85a

Patch Set 1 #

Patch Set 2 : #

Total comments: 56

Patch Set 3 : #

Patch Set 4 : address comments #

Total comments: 14

Patch Set 5 : address comments #

Patch Set 6 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1157 lines, -281 lines) Patch
M runtime/tests/vm/vm.status View 1 2 3 4 5 1 chunk +26 lines, -0 lines 0 comments Download
M runtime/vm/code_generator.cc View 1 2 3 4 5 chunks +18 lines, -11 lines 0 comments Download
M runtime/vm/code_patcher_dbc.cc View 1 2 3 1 chunk +1 line, -2 lines 0 comments Download
M runtime/vm/constants_dbc.h View 1 2 3 14 chunks +94 lines, -25 lines 0 comments Download
M runtime/vm/deopt_instructions.h View 1 2 3 4 7 chunks +47 lines, -5 lines 0 comments Download
M runtime/vm/deopt_instructions.cc View 1 2 5 chunks +34 lines, -15 lines 0 comments Download
M runtime/vm/disassembler_dbc.cc View 1 chunk +5 lines, -1 line 0 comments Download
M runtime/vm/flow_graph_allocator.h View 1 chunk +4 lines, -0 lines 0 comments Download
M runtime/vm/flow_graph_allocator.cc View 1 2 14 chunks +86 lines, -6 lines 0 comments Download
M runtime/vm/flow_graph_builder.cc View 1 2 3 4 5 1 chunk +1 line, -9 lines 0 comments Download
M runtime/vm/flow_graph_compiler.h View 1 chunk +4 lines, -0 lines 0 comments Download
M runtime/vm/flow_graph_compiler.cc View 1 2 3 4 5 1 chunk +1 line, -9 lines 0 comments Download
M runtime/vm/flow_graph_compiler_dbc.cc View 1 2 3 4 6 chunks +189 lines, -12 lines 0 comments Download
M runtime/vm/instructions_dbc.cc View 2 chunks +6 lines, -3 lines 0 comments Download
M runtime/vm/intermediate_language.h View 1 2 3 4 5 1 chunk +11 lines, -0 lines 0 comments Download
M runtime/vm/intermediate_language.cc View 1 2 3 5 chunks +27 lines, -6 lines 0 comments Download
M runtime/vm/intermediate_language_dbc.cc View 1 2 3 20 chunks +270 lines, -82 lines 0 comments Download
M runtime/vm/parser.h View 1 chunk +2 lines, -0 lines 0 comments Download
M runtime/vm/parser.cc View 1 chunk +13 lines, -0 lines 0 comments Download
M runtime/vm/simulator_dbc.h View 1 chunk +0 lines, -9 lines 0 comments Download
M runtime/vm/simulator_dbc.cc View 1 2 3 24 chunks +265 lines, -83 lines 0 comments Download
M runtime/vm/stack_frame.cc View 1 2 3 3 chunks +38 lines, -3 lines 0 comments Download
M runtime/vm/stub_code.h View 1 chunk +2 lines, -0 lines 0 comments Download
M runtime/vm/stub_code_dbc.cc View 1 chunk +13 lines, -0 lines 0 comments Download

Messages

Total messages: 14 (4 generated)
Vyacheslav Egorov (Google)
PTAL
4 years, 7 months ago (2016-05-18 20:51:27 UTC) #3
Florian Schneider
First round of comments https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc File runtime/vm/code_generator.cc (right): https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc#newcode1701 runtime/vm/code_generator.cc:1701: #else Needed? I think the ...
4 years, 7 months ago (2016-05-19 13:21:40 UTC) #5
Vyacheslav Egorov (Google)
PTAL https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc File runtime/vm/code_generator.cc (right): https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc#newcode1701 runtime/vm/code_generator.cc:1701: #else On 2016/05/19 13:21:39, Florian Schneider wrote: > ...
4 years, 7 months ago (2016-05-19 15:19:41 UTC) #6
zra
https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc File runtime/vm/code_generator.cc (right): https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc#newcode1643 runtime/vm/code_generator.cc:1643: static const intptr_t kNumberOfSavedCpuRegisters = kNumberOfFpuRegisters; kNumberOfCpuRegisters? https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_patcher_dbc.cc File ...
4 years, 7 months ago (2016-05-19 16:24:28 UTC) #7
Vyacheslav Egorov (Google)
PTAL https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc File runtime/vm/code_generator.cc (right): https://codereview.chromium.org/1992963002/diff/20001/runtime/vm/code_generator.cc#newcode1643 runtime/vm/code_generator.cc:1643: static const intptr_t kNumberOfSavedCpuRegisters = kNumberOfFpuRegisters; On 2016/05/19 ...
4 years, 7 months ago (2016-05-20 12:11:47 UTC) #8
zra
lgtm Is optimization now turned on for DBC? Do I understand correctly that the Bailouts ...
4 years, 7 months ago (2016-05-20 16:56:05 UTC) #9
Vyacheslav Egorov (Google)
Committed patchset #6 (id:100001) manually as 655bc90489a6fa33b39d6a15972e9294d5c9d85a (presubmit successful).
4 years, 7 months ago (2016-05-24 12:35:54 UTC) #11
Vyacheslav Egorov (Google)
Yes, this enables most of the fundamental infrastructure needed for optimizer and enables the optimizer ...
4 years, 7 months ago (2016-05-24 12:42:20 UTC) #12
Florian Schneider
Flushing left-over comment https://codereview.chromium.org/1992963002/diff/60001/runtime/vm/deopt_instructions.h File runtime/vm/deopt_instructions.h (right): https://codereview.chromium.org/1992963002/diff/60001/runtime/vm/deopt_instructions.h#newcode116 runtime/vm/deopt_instructions.h:116: intptr_t* FrameBase(const StackFrame* frame) { static?
4 years, 7 months ago (2016-05-25 11:28:40 UTC) #13
Florian Schneider
4 years, 7 months ago (2016-05-25 11:29:46 UTC) #14
Message was sent while issue was closed.
https://codereview.chromium.org/1992963002/diff/60001/runtime/vm/deopt_instru...
File runtime/vm/deopt_instructions.h (right):

https://codereview.chromium.org/1992963002/diff/60001/runtime/vm/deopt_instru...
runtime/vm/deopt_instructions.h:116: intptr_t* FrameBase(const StackFrame*
frame) {
On 2016/05/25 11:28:40, Florian Schneider wrote:
> static?

Never mind... num_args_ is used.

Powered by Google App Engine
This is Rietveld 408576698