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

Unified Diff: dart/frog/leg/ssa/optimize.dart

Issue 9599026: Generate code for some switch statements. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Add a few comments Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: dart/frog/leg/ssa/optimize.dart
diff --git a/dart/frog/leg/ssa/optimize.dart b/dart/frog/leg/ssa/optimize.dart
index 7fdf1b0dcabaaea1b11b0a6aa0b9d002301519ec..1aa1891731ed58e196e7071e3c61d8f38c8fb694 100644
--- a/dart/frog/leg/ssa/optimize.dart
+++ b/dart/frog/leg/ssa/optimize.dart
@@ -326,7 +326,9 @@ class SsaDeadPhiEliminator implements OptimizationPhase {
HPhi next = null;
while (current != null) {
next = current.next;
- if (!livePhis.contains(current)) {
+ if (!livePhis.contains(current)
+ // TODO(ahe): Not sure the following is correct.
ngeoffray 2012/03/06 11:49:48 Why did you need to add this? Was it on one test c
ahe 2012/03/06 12:24:35 Just one test case, I think.
ngeoffray 2012/03/06 12:32:55 Worth fixing? I'd rather keep the bug and try to f
ahe 2012/03/06 13:10:51 I wanted to get rid of the assertion error. This i
ngeoffray 2012/03/07 08:55:31 But you're fixing a symptom, not the bug. I think
+ && current.usedBy.isEmpty()) {
block.removePhi(current);
}
current = next;

Powered by Google App Engine
This is Rietveld 408576698