Chromium Code Reviews
DescriptionUse short-hand update syntax for simple updating definitions.
For example turn 'i = i + 1' into '++i' and 'i = i / 0.2' into
'i /= 0.2'.
Additionally, only move equivalent instructions to a dominator block
if there is more than one successor. There is no reason to move if
there is only one in any case. This has the added benefit that the
update part of a simple for-loop stays in the update part in the
generated code.
Before:
for (var i = 0; i < 10; ) {
i = i + 1;
}
Now:
for (var i = 0; i < 10; ++i) {
}
This code is a bit hackish. Please let me know if you have suggestions
for better structure of the cod.
R=ngeoffray@google.com,kasperl@google.com
BUG=
TEST=
Committed: https://code.google.com/p/dart/source/detail?r=8250
Patch Set 1 #
Total comments: 16
Patch Set 2 : Address comments. #Patch Set 3 : Address more comments. #
Messages
Total messages: 5 (0 generated)
|
||||||||||||||||||||||||||||