Mercurial > hg > graal-compiler
comparison graal/GraalCompiler/src/com/sun/c1x/gen/PhiSimplifier.java @ 2751:0fe79e7435c3
More scheduling. Removed need for cfg iteration in the phi simplifier.
author | Thomas Wuerthinger <thomas@wuerthinger.net> |
---|---|
date | Fri, 20 May 2011 14:22:22 +0200 |
parents | 88123130ede6 |
children | 0c5791bc90fb |
comparison
equal
deleted
inserted
replaced
2745:114fc809462f | 2751:0fe79e7435c3 |
---|---|
20 * or visit www.oracle.com if you need additional information or have any | 20 * or visit www.oracle.com if you need additional information or have any |
21 * questions. | 21 * questions. |
22 */ | 22 */ |
23 package com.sun.c1x.gen; | 23 package com.sun.c1x.gen; |
24 | 24 |
25 import com.oracle.graal.graph.*; | |
25 import com.sun.c1x.graph.*; | 26 import com.sun.c1x.graph.*; |
26 import com.sun.c1x.ir.*; | 27 import com.sun.c1x.ir.*; |
27 import com.sun.c1x.value.*; | 28 import com.sun.c1x.value.*; |
28 | 29 |
29 /** | 30 /** |
35 | 36 |
36 final IR ir; | 37 final IR ir; |
37 | 38 |
38 public PhiSimplifier(IR ir) { | 39 public PhiSimplifier(IR ir) { |
39 this.ir = ir; | 40 this.ir = ir; |
40 ir.getHIRStartBlock().iterateAnyOrder(this, false); | 41 //ir.getHIRStartBlock().iterateAnyOrder(this, false); |
42 | |
43 for (Node n : ir.compilation.graph.getNodes()) { | |
44 if (n instanceof Phi) { | |
45 simplify((Phi)n); | |
46 } | |
47 } | |
48 | |
49 | |
41 } | 50 } |
42 | 51 |
43 /** | 52 /** |
44 * This method is called for each block and processes any phi statements in the block. | 53 * This method is called for each block and processes any phi statements in the block. |
45 * @param block the block to apply the simplification to | 54 * @param block the block to apply the simplification to |