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

Issue 9657003: Support for loops without conditions. (Closed)

Created:
8 years, 9 months ago by ngeoffray
Modified:
8 years, 9 months ago
CC:
reviews_dartlang.org, karlklose, ahe, kasperl
Visibility:
Public.

Description

Support for loops without conditions. Committed: https://code.google.com/p/dart/source/detail?r=5222

Patch Set 1 #

Total comments: 2

Patch Set 2 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -8 lines) Patch
M frog/leg/ssa/builder.dart View 1 3 chunks +13 lines, -8 lines 0 comments Download
A tests/language/src/ForWithoutConditionTest.dart View 1 chunk +12 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
ngeoffray
8 years, 9 months ago (2012-03-08 20:57:54 UTC) #1
Lasse Reichstein Nielsen
LGTM http://codereview.chromium.org/9657003/diff/1/frog/leg/ssa/builder.dart File frog/leg/ssa/builder.dart (right): http://codereview.chromium.org/9657003/diff/1/frog/leg/ssa/builder.dart#newcode1080 frog/leg/ssa/builder.dart:1080: conditionExitBlock = close(new HLoopBranch(graph.addConstantBool(true))); This could be one ...
8 years, 9 months ago (2012-03-09 07:16:46 UTC) #2
floitsch
LGTM.
8 years, 9 months ago (2012-03-09 08:07:09 UTC) #3
ngeoffray
8 years, 9 months ago (2012-03-09 09:16:44 UTC) #4
Thanks Lasse and Florian,

http://codereview.chromium.org/9657003/diff/1/frog/leg/ssa/builder.dart
File frog/leg/ssa/builder.dart (right):

http://codereview.chromium.org/9657003/diff/1/frog/leg/ssa/builder.dart#newco...
frog/leg/ssa/builder.dart:1080: conditionExitBlock = close(new
HLoopBranch(graph.addConstantBool(true)));
On 2012/03/09 07:16:46, Lasse Reichstein Nielsen wrote:
> This could be one line with a conditional expression as argument to new
> HLoopBranch, or a variable holding just that instruction.
> 

Done.

> Or, preferably, please add a TODO in the second branch about not making it a
> branch when it's unconditional. We could do with just a HGoto, if we make our
> loop logic recognize it.

I added a TODO.

Powered by Google App Engine
This is Rietveld 408576698