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

Issue 659793003: Fix issue 21159: prevent endless inlining of field dispatchers. (Closed)

Created:
6 years, 2 months ago by srdjan
Modified:
6 years, 2 months ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Fix issue 21159: prevent endless inlining of field dispatchers. Committed: https://code.google.com/p/dart/source/detail?r=41156

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Total comments: 1

Patch Set 4 : #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+14 lines, -3 lines) Patch
M runtime/vm/flow_graph_inliner.cc View 1 2 3 2 chunks +3 lines, -3 lines 3 comments Download
A tests/language/isssue_21159.dart View 1 chunk +11 lines, -0 lines 0 comments Download

Messages

Total messages: 9 (2 generated)
srdjan
Do you have a better suggestion? Why did you not use inlining_depth_ for InvokeFieldDispatcher?
6 years, 2 months ago (2014-10-15 20:41:36 UTC) #2
Florian Schneider
On 2014/10/15 20:41:36, srdjan wrote: > Do you have a better suggestion? Why did you ...
6 years, 2 months ago (2014-10-16 10:29:18 UTC) #3
Florian Schneider
https://codereview.chromium.org/659793003/diff/40001/runtime/vm/flow_graph_inliner.cc File runtime/vm/flow_graph_inliner.cc (right): https://codereview.chromium.org/659793003/diff/40001/runtime/vm/flow_graph_inliner.cc#newcode767 runtime/vm/flow_graph_inliner.cc:767: if ((GrowthFactor() < 10.0) && We need to avoid ...
6 years, 2 months ago (2014-10-16 10:34:33 UTC) #4
srdjan
Disabled recursive inlining.
6 years, 2 months ago (2014-10-16 17:12:26 UTC) #5
srdjan
Committed patchset #4 (id:60001) manually as r41156 (presubmit successful).
6 years, 2 months ago (2014-10-16 17:13:06 UTC) #6
zerny-google
So far as we need to cater to the micro benchmarks... https://codereview.chromium.org/659793003/diff/60001/runtime/vm/flow_graph_inliner.cc File runtime/vm/flow_graph_inliner.cc (right): ...
6 years, 2 months ago (2014-10-20 11:28:21 UTC) #8
Florian Schneider
6 years, 2 months ago (2014-10-20 14:01:57 UTC) #9
Message was sent while issue was closed.
https://codereview.chromium.org/659793003/diff/60001/runtime/vm/flow_graph_in...
File runtime/vm/flow_graph_inliner.cc (right):

https://codereview.chromium.org/659793003/diff/60001/runtime/vm/flow_graph_in...
runtime/vm/flow_graph_inliner.cc:617: function.set_is_inlinable(false);
Maybe that should not mark the whole function as not inlinable in this case:

I found that for example the Integer.compareTo could still be inlined into its
caller, but the recursive call-site inside compareTo (which may not be reachable
after constant propagation) should not be inlined.

https://codereview.chromium.org/659793003/diff/60001/runtime/vm/flow_graph_in...
runtime/vm/flow_graph_inliner.cc:773: 0,
On 2014/10/20 11:28:21, zerny-google wrote:
> DBC: It seems this issue is caused by ignoring the inlining depth. We could
> separate the general depth threshold from the recursive depth threshold (I
> recall talking about this, but not implementing it, since, at the time, the
> general depth achieved mostly the same thing.)

I agree that a separate threshold for recursive inlining would be the best if we
do want to inline recursive call-sites. Dispatchers should always be inlined,
since they are so small.

Powered by Google App Engine
This is Rietveld 408576698