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

Issue 655773003: Initialize the async jump variable with a smi to avoid polymorphic comparison. (Closed)

Created:
6 years, 2 months ago by Florian Schneider
Modified:
6 years, 2 months ago
Reviewers:
hausner
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Initialize the async jump variable with a smi to avoid polymorphic comparison. Using the implicit initial null value makes the comparison in the dispatch prologue of async closures polymorphic (Null|Smi). Initializing to it -1 eliminates the unnecessary class check for null. Small clean up of scopes and internal variables used for async functions: Capture them in the parser, so that there is no need to do this later in the async-transformer. R=hausner@google.com Committed: https://code.google.com/p/dart/source/detail?r=41123

Patch Set 1 #

Patch Set 2 : #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+30 lines, -24 lines) Patch
M runtime/vm/ast_transformer.cc View 3 chunks +4 lines, -13 lines 2 comments Download
M runtime/vm/flow_graph_builder.h View 1 chunk +3 lines, -1 line 0 comments Download
M runtime/vm/flow_graph_builder.cc View 5 chunks +14 lines, -10 lines 0 comments Download
M runtime/vm/parser.cc View 2 chunks +9 lines, -0 lines 0 comments Download

Messages

Total messages: 5 (1 generated)
Florian Schneider
These are small unrelated things I noticed while debugging the optimized async-closures.
6 years, 2 months ago (2014-10-14 14:39:57 UTC) #2
hausner
LGTM with a comment. https://codereview.chromium.org/655773003/diff/20001/runtime/vm/ast_transformer.cc File runtime/vm/ast_transformer.cc (left): https://codereview.chromium.org/655773003/diff/20001/runtime/vm/ast_transformer.cc#oldcode145 runtime/vm/ast_transformer.cc:145: GetVariableInScope(is_future_scope, Symbols::AwaitJumpVar()); I am not ...
6 years, 2 months ago (2014-10-14 16:29:56 UTC) #3
Florian Schneider
https://codereview.chromium.org/655773003/diff/20001/runtime/vm/ast_transformer.cc File runtime/vm/ast_transformer.cc (left): https://codereview.chromium.org/655773003/diff/20001/runtime/vm/ast_transformer.cc#oldcode145 runtime/vm/ast_transformer.cc:145: GetVariableInScope(is_future_scope, Symbols::AwaitJumpVar()); On 2014/10/14 16:29:55, hausner wrote: > I ...
6 years, 2 months ago (2014-10-15 11:40:59 UTC) #4
Florian Schneider
6 years, 2 months ago (2014-10-15 11:41:27 UTC) #5
Message was sent while issue was closed.
Committed patchset #2 (id:20001) manually as r41123 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698