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

Issue 9421035: Support break and labeled statements. (Closed)

Created:
8 years, 10 months ago by Lasse Reichstein Nielsen
Modified:
8 years, 10 months ago
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Support break and labeled statements. Committed: https://code.google.com/p/dart/source/detail?r=4453

Patch Set 1 #

Total comments: 6

Patch Set 2 : Removed unused var. Better trace output. #

Total comments: 22

Patch Set 3 : Address review comments. #

Total comments: 2

Patch Set 4 : Address review comments. Update expectations. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+372 lines, -108 lines) Patch
M frog/leg/resolver.dart View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M frog/leg/ssa/bailout.dart View 1 chunk +4 lines, -0 lines 0 comments Download
M frog/leg/ssa/builder.dart View 1 2 3 14 chunks +210 lines, -13 lines 0 comments Download
M frog/leg/ssa/codegen.dart View 1 2 3 7 chunks +90 lines, -45 lines 0 comments Download
M frog/leg/ssa/nodes.dart View 1 2 3 8 chunks +31 lines, -4 lines 0 comments Download
M frog/leg/ssa/optimize.dart View 1 2 3 1 chunk +9 lines, -2 lines 0 comments Download
M frog/leg/ssa/tracer.dart View 1 1 chunk +8 lines, -0 lines 0 comments Download
M frog/leg/typechecker.dart View 1 2 2 chunks +5 lines, -3 lines 0 comments Download
M frog/tests/leg_only/src/LabelTest.dart View 2 chunks +0 lines, -19 lines 0 comments Download
M tests/co19/co19-leg.status View 1 2 3 7 chunks +7 lines, -13 lines 0 comments Download
M tests/corelib/corelib-leg.status View 1 2 3 2 chunks +3 lines, -5 lines 0 comments Download
M tests/language/language-leg.status View 1 2 3 4 chunks +3 lines, -4 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
Lasse Reichstein Nielsen
https://chromiumcodereview.appspot.com/9421035/diff/1/frog/leg/ssa/nodes.dart File frog/leg/ssa/nodes.dart (right): https://chromiumcodereview.appspot.com/9421035/diff/1/frog/leg/ssa/nodes.dart#newcode354 frog/leg/ssa/nodes.dart:354: HBlockInformation blockInformation = null; I store both loop information ...
8 years, 10 months ago (2012-02-20 13:56:15 UTC) #1
floitsch
small things, but almost LGTM. https://chromiumcodereview.appspot.com/9421035/diff/1/frog/leg/ssa/nodes.dart File frog/leg/ssa/nodes.dart (right): https://chromiumcodereview.appspot.com/9421035/diff/1/frog/leg/ssa/nodes.dart#newcode354 frog/leg/ssa/nodes.dart:354: HBlockInformation blockInformation = null; ...
8 years, 10 months ago (2012-02-20 19:01:54 UTC) #2
ngeoffray
DBC https://chromiumcodereview.appspot.com/9421035/diff/13/frog/leg/ssa/optimize.dart File frog/leg/ssa/optimize.dart (right): https://chromiumcodereview.appspot.com/9421035/diff/13/frog/leg/ssa/optimize.dart#newcode311 frog/leg/ssa/optimize.dart:311: if (!livePhis.contains(current)) { Should we visit post dominator ...
8 years, 10 months ago (2012-02-21 13:12:17 UTC) #3
Lasse Reichstein Nielsen
https://chromiumcodereview.appspot.com/9421035/diff/1/frog/leg/ssa/nodes.dart File frog/leg/ssa/nodes.dart (right): https://chromiumcodereview.appspot.com/9421035/diff/1/frog/leg/ssa/nodes.dart#newcode354 frog/leg/ssa/nodes.dart:354: HBlockInformation blockInformation = null; Done. https://chromiumcodereview.appspot.com/9421035/diff/1/frog/leg/ssa/optimize.dart File frog/leg/ssa/optimize.dart (right): ...
8 years, 10 months ago (2012-02-21 13:53:56 UTC) #4
floitsch
LGTM. https://chromiumcodereview.appspot.com/9421035/diff/13/frog/leg/ssa/builder.dart File frog/leg/ssa/builder.dart (right): https://chromiumcodereview.appspot.com/9421035/diff/13/frog/leg/ssa/builder.dart#newcode2117 frog/leg/ssa/builder.dart:2117: currentBreakHandler = handler; On 2012/02/21 13:53:56, Lasse Reichstein ...
8 years, 10 months ago (2012-02-22 13:17:20 UTC) #5
Lasse Reichstein Nielsen
8 years, 10 months ago (2012-02-22 14:12:24 UTC) #6
https://chromiumcodereview.appspot.com/9421035/diff/13/frog/leg/ssa/builder.dart
File frog/leg/ssa/builder.dart (right):

https://chromiumcodereview.appspot.com/9421035/diff/13/frog/leg/ssa/builder.d...
frog/leg/ssa/builder.dart:2117: currentBreakHandler = handler;
Touche. I'll consider redoing this in a different CL.

https://chromiumcodereview.appspot.com/9421035/diff/13/frog/leg/ssa/builder.d...
frog/leg/ssa/builder.dart:2127: // no breaks anyway.
As discussed offline, the break could be dead code from the beginning - it would
still be resolved by the resolver, but not be visited here in the builder.
If there really is no break for the target, we don't need the label, and without
the HLabeledBlockInformation, we don't need to create a join node at all. So,
much simplified.

https://chromiumcodereview.appspot.com/9421035/diff/7001/frog/leg/ssa/builder...
File frog/leg/ssa/builder.dart (right):

https://chromiumcodereview.appspot.com/9421035/diff/7001/frog/leg/ssa/builder...
frog/leg/ssa/builder.dart:2141: HBasicBlock firstJoinBlock = null;
Done.

Powered by Google App Engine
This is Rietveld 408576698