Mercurial > hg > truffle
comparison graal/GraalCompiler/src/com/sun/c1x/ir/IfOp.java @ 2834:bfce42cd9c07
Graph duplication now passes all tests
author | Lukas Stadler <lukas.stadler@jku.at> |
---|---|
date | Tue, 31 May 2011 13:34:52 +0200 |
parents | bd17ac598c6e |
children | 14708c03abba |
comparison
equal
deleted
inserted
replaced
2829:27c00b180416 | 2834:bfce42cd9c07 |
---|---|
78 Condition condition; | 78 Condition condition; |
79 | 79 |
80 /** | 80 /** |
81 * Constructs a new IfOp. | 81 * Constructs a new IfOp. |
82 * @param x the instruction producing the first value to be compared | 82 * @param x the instruction producing the first value to be compared |
83 * @param cond the condition of the comparison | 83 * @param condition the condition of the comparison |
84 * @param y the instruction producing the second value to be compared | 84 * @param y the instruction producing the second value to be compared |
85 * @param trueValue the value produced if the condition is true | 85 * @param trueValue the value produced if the condition is true |
86 * @param falseValue the value produced if the condition is false | 86 * @param falseValue the value produced if the condition is false |
87 */ | 87 */ |
88 public IfOp(Value x, Condition cond, Value y, Value trueValue, Value falseValue, Graph graph) { | 88 public IfOp(Value x, Condition condition, Value y, Value trueValue, Value falseValue, Graph graph) { |
89 // TODO: return the appropriate bytecode IF_ICMPEQ, etc | 89 // TODO: return the appropriate bytecode IF_ICMPEQ, etc |
90 super(trueValue.kind.meet(falseValue.kind), Bytecodes.ILLEGAL, x, y, INPUT_COUNT, SUCCESSOR_COUNT, graph); | 90 super(trueValue.kind.meet(falseValue.kind), Bytecodes.ILLEGAL, x, y, INPUT_COUNT, SUCCESSOR_COUNT, graph); |
91 this.condition = cond; | 91 this.condition = condition; |
92 setTrueValue(trueValue); | 92 setTrueValue(trueValue); |
93 setFalseValue(falseValue); | 93 setFalseValue(falseValue); |
94 } | 94 } |
95 | 95 |
96 // for copying | |
96 private IfOp(CiKind kind, Condition cond, Graph graph) { | 97 private IfOp(CiKind kind, Condition cond, Graph graph) { |
97 super(kind, Bytecodes.ILLEGAL, null, null, INPUT_COUNT, SUCCESSOR_COUNT, graph); | 98 super(kind, Bytecodes.ILLEGAL, null, null, INPUT_COUNT, SUCCESSOR_COUNT, graph); |
98 this.condition = cond; | 99 this.condition = cond; |
99 } | 100 } |
100 | 101 |