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

Issue 10823022: Improve static type propagation. (Closed)

Created:
8 years, 4 months ago by regis
Modified:
8 years, 4 months ago
Reviewers:
srdjan
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Improve static type propagation. Committed: https://code.google.com/p/dart/source/detail?r=9943

Patch Set 1 #

Total comments: 4

Patch Set 2 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+68 lines, -75 lines) Patch
M runtime/vm/flow_graph_builder.cc View 1 4 chunks +4 lines, -12 lines 0 comments Download
M runtime/vm/flow_graph_compiler_ia32.cc View 1 3 chunks +3 lines, -6 lines 0 comments Download
M runtime/vm/flow_graph_compiler_x64.cc View 1 3 chunks +3 lines, -6 lines 0 comments Download
M runtime/vm/intermediate_language.h View 1 4 chunks +9 lines, -6 lines 0 comments Download
M runtime/vm/intermediate_language.cc View 1 8 chunks +45 lines, -40 lines 0 comments Download
M runtime/vm/object.cc View 1 2 chunks +3 lines, -3 lines 0 comments Download
M runtime/vm/parser.cc View 1 1 chunk +1 line, -2 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
regis
Still work in progress...
8 years, 4 months ago (2012-07-25 20:50:22 UTC) #1
srdjan
LGTM https://chromiumcodereview.appspot.com/10823022/diff/1/runtime/vm/intermediate_language.cc File runtime/vm/intermediate_language.cc (right): https://chromiumcodereview.appspot.com/10823022/diff/1/runtime/vm/intermediate_language.cc#newcode346 runtime/vm/intermediate_language.cc:346: // of a passed-in parameter? I guess with ...
8 years, 4 months ago (2012-07-25 21:50:06 UTC) #2
regis
8 years, 4 months ago (2012-07-26 15:08:50 UTC) #3
Thanks!

https://chromiumcodereview.appspot.com/10823022/diff/1/runtime/vm/intermediat...
File runtime/vm/intermediate_language.cc (right):

https://chromiumcodereview.appspot.com/10823022/diff/1/runtime/vm/intermediat...
runtime/vm/intermediate_language.cc:346: // of a passed-in parameter?
On 2012/07/25 21:50:06, srdjan wrote:
> I guess with FLAG_enable_type_checks we can use the type of the passed in
> parameter.

Good point. You probably mean the type of the formal parameter, though.

Since I am not sure exactly when this ParameterInstr is used, I did not change
the code yet, but added a comment. Indeed, it would be bad if this
ParameterInstr was used to load the value for the parameter type check, which
would then be wrongly eliminated.

https://chromiumcodereview.appspot.com/10823022/diff/1/runtime/vm/intermediat...
runtime/vm/intermediate_language.cc:697: return local().type().raw();
On 2012/07/25 21:50:06, srdjan wrote:
> Is the type of the receiver setup correctly in locals?

Good question. I have added a todo to verify.
I also added a test, since using the declared type only works in checked mode. I
did the same for other cases below.

Powered by Google App Engine
This is Rietveld 408576698