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

Issue 477193002: Reland r39293. (Closed)

Created:
6 years, 4 months ago by Vyacheslav Egorov (Google)
Modified:
6 years, 4 months ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org, srdjan
Visibility:
Public.

Description

Reland r39293. Switch to a fix-point based range analysis to improve its precision. Dominator based algorithm was very imprecise for loop phis. Use widening to ensure fast convergence and narrowing to improve precision. Fixed compared to r39293: Type propagation is more sophisticated now compared to the time when range analysis was originally implemented and is able to derive Smi-ness from more than just CheckSmi instruction (e.g. GuardFieldClass). This creates situations when use's reaching type is Smi but definition itself is not a Smi and thus will never have range assigned to it. It is incorrect to treat ranges of such uses as unknown (_|_), because unknown means "not yet computed". Instead we must use the widest possible approximation: full smi range. InferRange methods were rewritten to use a newly introduced GetRange helper instead of accessing value()->definition()->range() directly. As a side-effect we no longer need to insert artificial constraints after CheckSmi instructions. R=fschneider@google.com Committed: https://code.google.com/p/dart/source/detail?r=39327

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+924 lines, -692 lines) Patch
M runtime/vm/flow_graph_range_analysis.h View 9 chunks +128 lines, -55 lines 0 comments Download
M runtime/vm/flow_graph_range_analysis.cc View 21 chunks +647 lines, -536 lines 2 comments Download
M runtime/vm/flow_graph_range_analysis_test.cc View 2 chunks +135 lines, -89 lines 0 comments Download
M runtime/vm/intermediate_language.h View 13 chunks +14 lines, -12 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Vyacheslav Egorov (Google)
6 years, 4 months ago (2014-08-15 19:13:45 UTC) #1
Vyacheslav Egorov (Google)
PTAL
6 years, 4 months ago (2014-08-15 19:13:52 UTC) #2
Florian Schneider
lgtm https://codereview.chromium.org/477193002/diff/1/runtime/vm/flow_graph_range_analysis.cc File runtime/vm/flow_graph_range_analysis.cc (right): https://codereview.chromium.org/477193002/diff/1/runtime/vm/flow_graph_range_analysis.cc#newcode331 runtime/vm/flow_graph_range_analysis.cc:331: (defn->Type()->ToCid() != kSmiCid)) { Add mint cid here.
6 years, 4 months ago (2014-08-18 10:46:51 UTC) #3
Vyacheslav Egorov (Google)
Thanks! Landing. https://codereview.chromium.org/477193002/diff/1/runtime/vm/flow_graph_range_analysis.cc File runtime/vm/flow_graph_range_analysis.cc (right): https://codereview.chromium.org/477193002/diff/1/runtime/vm/flow_graph_range_analysis.cc#newcode331 runtime/vm/flow_graph_range_analysis.cc:331: (defn->Type()->ToCid() != kSmiCid)) { On 2014/08/18 10:46:51, ...
6 years, 4 months ago (2014-08-18 10:58:19 UTC) #4
Vyacheslav Egorov (Google)
6 years, 4 months ago (2014-08-18 11:06:34 UTC) #5
Message was sent while issue was closed.
Committed patchset #1 manually as 39327 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698