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

Issue 51123003: VM: Fix checked mode crash (issue 13831). (Closed)

Created:
7 years, 1 month ago by fschneider
Modified:
7 years, 1 month ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

VM: Fix checked mode crash (issue 13831). The AST for static getters differs between parsing the first time, and subsequent parsings. This leads to a mismatch in deoptimization-ids between the optimized and the unoptimized code. This CL avoids creating different ASTs for the same static getters. To allow better inlining of these getters, the initialization expression is wrapped in a hidden static initializer-function. As a result the size of such getters is constant and does not depend on the initializer expression. R=srdjan@google.com Committed: https://code.google.com/p/dart/source/detail?r=29680

Patch Set 1 #

Patch Set 2 : #

Total comments: 6

Patch Set 3 : #

Patch Set 4 : #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+151 lines, -76 lines) Patch
M runtime/vm/class_finalizer.cc View 1 2 1 chunk +13 lines, -0 lines 2 comments Download
M runtime/vm/compiler.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/debugger.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M runtime/vm/flow_graph_builder.cc View 1 2 2 chunks +4 lines, -0 lines 0 comments Download
M runtime/vm/flow_graph_compiler.cc View 1 2 1 chunk +0 lines, -1 line 0 comments Download
M runtime/vm/flow_graph_compiler_arm.cc View 1 2 2 chunks +0 lines, -12 lines 0 comments Download
M runtime/vm/flow_graph_compiler_ia32.cc View 1 2 2 chunks +0 lines, -12 lines 0 comments Download
M runtime/vm/flow_graph_compiler_mips.cc View 1 2 2 chunks +0 lines, -12 lines 0 comments Download
M runtime/vm/flow_graph_compiler_x64.cc View 1 2 2 chunks +0 lines, -12 lines 0 comments Download
M runtime/vm/flow_graph_optimizer.cc View 1 2 2 chunks +13 lines, -1 line 0 comments Download
M runtime/vm/mirrors_api_impl.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M runtime/vm/object.h View 1 2 4 chunks +14 lines, -0 lines 0 comments Download
M runtime/vm/object.cc View 1 2 3 4 chunks +38 lines, -1 line 0 comments Download
M runtime/vm/parser.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M runtime/vm/parser.cc View 1 2 9 chunks +61 lines, -24 lines 0 comments Download
M runtime/vm/raw_object.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M runtime/vm/symbols.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M tests/standalone/standalone.status View 1 2 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
Florian Schneider
https://codereview.chromium.org/51123003/diff/120001/runtime/vm/compiler.cc File runtime/vm/compiler.cc (left): https://codereview.chromium.org/51123003/diff/120001/runtime/vm/compiler.cc#oldcode895 runtime/vm/compiler.cc:895: RawFunction::kImplicitStaticFinalGetter, Unrelated change: I found it confusing to use ...
7 years, 1 month ago (2013-10-30 17:37:26 UTC) #1
srdjan
LGTM. When do you plan to add the check that max-deopt-id is always the same ...
7 years, 1 month ago (2013-10-30 17:54:14 UTC) #2
Florian Schneider
I'll add the verification of the deopt-ids used in a separate CL. https://codereview.chromium.org/51123003/diff/120001/runtime/vm/object.cc File runtime/vm/object.cc ...
7 years, 1 month ago (2013-10-31 16:34:53 UTC) #3
fschneider
Committed patchset #4 manually as r29680 (presubmit successful).
7 years, 1 month ago (2013-10-31 16:50:08 UTC) #4
hausner
DBC: I don't like this change because it wastes too much space. Function objects are ...
7 years, 1 month ago (2013-10-31 21:53:47 UTC) #5
hausner
The bug number is 14696
7 years, 1 month ago (2013-10-31 22:17:47 UTC) #6
Florian Schneider
I see the point with the size of the additional Function objects. On the other ...
7 years, 1 month ago (2013-11-01 10:23:41 UTC) #7
hausner
7 years, 1 month ago (2013-11-01 16:02:29 UTC) #8
Message was sent while issue was closed.
We discussed this here in MTV yesterday. First, most of the classes in the
snapshot are not parsed yet, so the newly introduced function objects are not
included in it. Second, we have a history of adding overhead by small increases,
until one day we find out that the snapshot/heap has become too big. Then we try
to solve the problem by adding more complexity, like delayed class parsing,
compressing the token stream, etc.

I think we found a good solution how to gain this space back by using a runtime
call, so we'll be fine.

Powered by Google App Engine
This is Rietveld 408576698