Mercurial > hg > graal-compiler
comparison graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/calc/IntegerTestNode.java @ 16895:06c15e88d383
added factory method to all Node classes; replaced Node classes instantiation with calls to factory methods; replaced identity tests on Node classes with ' == <node class>.getGenClass()' idiom
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Mon, 18 Aug 2014 14:04:21 +0200 |
parents | cbd42807a31f |
children | 0fe4732e5181 |
comparison
equal
deleted
inserted
replaced
16894:cc7aaa92c27d | 16895:06c15e88d383 |
---|---|
39 * Constructs a new Test instruction. | 39 * Constructs a new Test instruction. |
40 * | 40 * |
41 * @param x the instruction producing the first input to the instruction | 41 * @param x the instruction producing the first input to the instruction |
42 * @param y the instruction that produces the second input to this instruction | 42 * @param y the instruction that produces the second input to this instruction |
43 */ | 43 */ |
44 public IntegerTestNode(ValueNode x, ValueNode y) { | 44 public static IntegerTestNode create(ValueNode x, ValueNode y) { |
45 return new IntegerTestNodeGen(x, y); | |
46 } | |
47 | |
48 protected IntegerTestNode(ValueNode x, ValueNode y) { | |
45 super(x, y); | 49 super(x, y); |
46 } | 50 } |
47 | 51 |
48 @Override | 52 @Override |
49 public ValueNode canonical(CanonicalizerTool tool, ValueNode forX, ValueNode forY) { | 53 public ValueNode canonical(CanonicalizerTool tool, ValueNode forX, ValueNode forY) { |