--- old/src/share/vm/opto/subnode.hpp 2016-07-11 22:46:56.596342084 +0900 +++ new/src/share/vm/opto/subnode.hpp 2016-07-11 22:46:56.455342578 +0900 @@ -69,12 +69,12 @@ class SubINode : public SubNode { public: SubINode( Node *in1, Node *in2 ) : SubNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type *sub( const Type *, const Type * ) const; const Type *add_id() const { return TypeInt::ZERO; } const Type *bottom_type() const { return TypeInt::INT; } - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; //------------------------------SubLNode--------------------------------------- @@ -82,12 +82,12 @@ class SubLNode : public SubNode { public: SubLNode( Node *in1, Node *in2 ) : SubNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type *sub( const Type *, const Type * ) const; const Type *add_id() const { return TypeLong::ZERO; } const Type *bottom_type() const { return TypeLong::LONG; } - virtual uint ideal_reg() const { return Op_RegL; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegL; } }; // NOTE: SubFPNode should be taken away and replaced by add and negate @@ -106,12 +106,12 @@ class SubFNode : public SubFPNode { public: SubFNode( Node *in1, Node *in2 ) : SubFPNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type *sub( const Type *, const Type * ) const; const Type *add_id() const { return TypeF::ZERO; } const Type *bottom_type() const { return Type::FLOAT; } - virtual uint ideal_reg() const { return Op_RegF; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegF; } }; // NOTE: SubDNode should be taken away and replaced by add and negate @@ -120,12 +120,12 @@ class SubDNode : public SubFPNode { public: SubDNode( Node *in1, Node *in2 ) : SubFPNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type *sub( const Type *, const Type * ) const; const Type *add_id() const { return TypeD::ZERO; } const Type *bottom_type() const { return Type::DOUBLE; } - virtual uint ideal_reg() const { return Op_RegD; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegD; } }; //------------------------------CmpNode--------------------------------------- @@ -138,7 +138,7 @@ virtual Node* Identity(PhaseGVN* phase); const Type *add_id() const { return TypeInt::ZERO; } const Type *bottom_type() const { return TypeInt::CC; } - virtual uint ideal_reg() const { return Op_RegFlags; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegFlags; } #ifndef PRODUCT // CmpNode and subclasses include all data inputs (until hitting a control @@ -153,7 +153,7 @@ class CmpINode : public CmpNode { public: CmpINode( Node *in1, Node *in2 ) : CmpNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type *sub( const Type *, const Type * ) const; }; @@ -163,7 +163,7 @@ class CmpUNode : public CmpNode { public: CmpUNode( Node *in1, Node *in2 ) : CmpNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual const Type *sub( const Type *, const Type * ) const; const Type* Value(PhaseGVN* phase) const; bool is_index_range_check() const; @@ -174,7 +174,7 @@ class CmpPNode : public CmpNode { public: CmpPNode( Node *in1, Node *in2 ) : CmpNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type *sub( const Type *, const Type * ) const; }; @@ -184,7 +184,7 @@ class CmpNNode : public CmpNode { public: CmpNNode( Node *in1, Node *in2 ) : CmpNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type *sub( const Type *, const Type * ) const; }; @@ -194,7 +194,7 @@ class CmpLNode : public CmpNode { public: CmpLNode( Node *in1, Node *in2 ) : CmpNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual const Type *sub( const Type *, const Type * ) const; }; @@ -206,8 +206,8 @@ // Since it is not consumed by Bools, it is not really a Cmp. init_class_id(Class_Sub); } - virtual int Opcode() const; - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes Opcode() const; + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; //------------------------------CmpFNode--------------------------------------- @@ -217,7 +217,7 @@ class CmpFNode : public CmpNode { public: CmpFNode( Node *in1, Node *in2 ) : CmpNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual const Type *sub( const Type *, const Type * ) const { ShouldNotReachHere(); return NULL; } const Type* Value(PhaseGVN* phase) const; }; @@ -232,9 +232,9 @@ // Since it is not consumed by Bools, it is not really a Cmp. init_class_id(Class_Sub); } - virtual int Opcode() const; + virtual Opcodes Opcode() const; // Since it is not consumed by Bools, it is not really a Cmp. - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; @@ -245,7 +245,7 @@ class CmpDNode : public CmpNode { public: CmpDNode( Node *in1, Node *in2 ) : CmpNode(in1,in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual const Type *sub( const Type *, const Type * ) const { ShouldNotReachHere(); return NULL; } const Type* Value(PhaseGVN* phase) const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); @@ -261,8 +261,8 @@ // Since it is not consumed by Bools, it is not really a Cmp. init_class_id(Class_Sub); } - virtual int Opcode() const; - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes Opcode() const; + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; @@ -294,8 +294,8 @@ virtual uint size_of() const; // Try to optimize signed integer comparison - Node* fold_cmpI(PhaseGVN* phase, SubNode* cmp, Node* cmp1, int cmp_op, - int cmp1_op, const TypeInt* cmp2_type); + Node* fold_cmpI(PhaseGVN* phase, SubNode* cmp, Node* cmp1, Opcodes cmp_op, + Opcodes cmp1_op, const TypeInt* cmp2_type); public: const BoolTest _test; BoolNode( Node *cc, BoolTest::mask t): _test(t), Node(0,cc) { @@ -307,12 +307,12 @@ Node* as_int_value(PhaseGVN* phase); // Invert sense of self, returning new Bool. BoolNode* negate(PhaseGVN* phase); - virtual int Opcode() const; + virtual Opcodes Opcode() const; virtual Node *Ideal(PhaseGVN *phase, bool can_reshape); virtual const Type* Value(PhaseGVN* phase) const; virtual const Type *bottom_type() const { return TypeInt::BOOL; } uint match_edge(uint idx) const { return 0; } - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } bool is_counted_loop_exit_test(); #ifndef PRODUCT @@ -335,9 +335,9 @@ class AbsINode : public AbsNode { public: AbsINode( Node *in1 ) : AbsNode(in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return TypeInt::INT; } - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; //------------------------------AbsFNode--------------------------------------- @@ -347,9 +347,9 @@ class AbsFNode : public AbsNode { public: AbsFNode( Node *in1 ) : AbsNode(in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return Type::FLOAT; } - virtual uint ideal_reg() const { return Op_RegF; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegF; } }; //------------------------------AbsDNode--------------------------------------- @@ -359,9 +359,9 @@ class AbsDNode : public AbsNode { public: AbsDNode( Node *in1 ) : AbsNode(in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return Type::DOUBLE; } - virtual uint ideal_reg() const { return Op_RegD; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegD; } }; @@ -370,9 +370,9 @@ class CmpLTMaskNode : public Node { public: CmpLTMaskNode( Node *p, Node *q ) : Node(0, p, q) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return TypeInt::INT; } - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; @@ -390,9 +390,9 @@ class NegFNode : public NegNode { public: NegFNode( Node *in1 ) : NegNode(in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return Type::FLOAT; } - virtual uint ideal_reg() const { return Op_RegF; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegF; } }; //------------------------------NegDNode--------------------------------------- @@ -403,9 +403,9 @@ class NegDNode : public NegNode { public: NegDNode( Node *in1 ) : NegNode(in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return Type::DOUBLE; } - virtual uint ideal_reg() const { return Op_RegD; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegD; } }; //------------------------------AtanDNode-------------------------------------- @@ -413,9 +413,9 @@ class AtanDNode : public Node { public: AtanDNode(Node *c, Node *in1, Node *in2 ) : Node(c, in1, in2) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return Type::DOUBLE; } - virtual uint ideal_reg() const { return Op_RegD; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegD; } }; @@ -427,9 +427,9 @@ init_flags(Flag_is_expensive); C->add_expensive_node(this); } - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return Type::DOUBLE; } - virtual uint ideal_reg() const { return Op_RegD; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegD; } virtual const Type* Value(PhaseGVN* phase) const; }; @@ -438,9 +438,9 @@ class ReverseBytesINode : public Node { public: ReverseBytesINode(Node *c, Node *in1) : Node(c, in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return TypeInt::INT; } - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; //-------------------------------ReverseBytesLNode-------------------------------- @@ -448,9 +448,9 @@ class ReverseBytesLNode : public Node { public: ReverseBytesLNode(Node *c, Node *in1) : Node(c, in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return TypeLong::LONG; } - virtual uint ideal_reg() const { return Op_RegL; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegL; } }; //-------------------------------ReverseBytesUSNode-------------------------------- @@ -458,9 +458,9 @@ class ReverseBytesUSNode : public Node { public: ReverseBytesUSNode(Node *c, Node *in1) : Node(c, in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return TypeInt::CHAR; } - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; //-------------------------------ReverseBytesSNode-------------------------------- @@ -468,9 +468,9 @@ class ReverseBytesSNode : public Node { public: ReverseBytesSNode(Node *c, Node *in1) : Node(c, in1) {} - virtual int Opcode() const; + virtual Opcodes Opcode() const; const Type *bottom_type() const { return TypeInt::SHORT; } - virtual uint ideal_reg() const { return Op_RegI; } + virtual Opcodes ideal_reg() const { return Opcodes::Op_RegI; } }; #endif // SHARE_VM_OPTO_SUBNODE_HPP