66 class CheckCastPPNode;
67 class ClearArrayNode;
68 class CmpNode;
69 class CodeBuffer;
70 class ConstraintCastNode;
71 class ConNode;
72 class ConINode;
73 class ConvertNode;
74 class CompareAndSwapNode;
75 class CompareAndExchangeNode;
76 class CountedLoopNode;
77 class CountedLoopEndNode;
78 class DecodeNarrowPtrNode;
79 class DecodeNNode;
80 class DecodeNKlassNode;
81 class EncodeNarrowPtrNode;
82 class EncodePNode;
83 class EncodePKlassNode;
84 class FastLockNode;
85 class FastUnlockNode;
86 class HaltNode;
87 class IfNode;
88 class IfProjNode;
89 class IfFalseNode;
90 class IfTrueNode;
91 class InitializeNode;
92 class JVMState;
93 class JumpNode;
94 class JumpProjNode;
95 class LoadNode;
96 class LoadStoreNode;
97 class LoadStoreConditionalNode;
98 class LockNode;
99 class LongCountedLoopNode;
100 class LongCountedLoopEndNode;
101 class LoopNode;
102 class LShiftNode;
103 class MachBranchNode;
104 class MachCallDynamicJavaNode;
105 class MachCallJavaNode;
106 class MachCallLeafNode;
107 class MachCallNode;
108 class MachCallRuntimeNode;
109 class MachCallStaticJavaNode;
110 class MachConstantBaseNode;
111 class MachConstantNode;
112 class MachGotoNode;
113 class MachIfNode;
114 class MachJumpNode;
115 class MachNode;
116 class MachNullCheckNode;
117 class MachProjNode;
118 class MachReturnNode;
119 class MachSafePointNode;
120 class MachSpillCopyNode;
121 class MachTempNode;
122 class MachMergeNode;
123 class MachMemBarNode;
124 class Matcher;
125 class MemBarNode;
126 class MemBarStoreStoreNode;
127 class MemNode;
128 class MergeMemNode;
129 class MoveNode;
130 class MulNode;
131 class MultiNode;
132 class MultiBranchNode;
133 class NegNode;
134 class NegVNode;
135 class NeverBranchNode;
136 class Opaque1Node;
137 class OuterStripMinedLoopNode;
138 class OuterStripMinedLoopEndNode;
139 class Node;
140 class Node_Array;
141 class Node_List;
142 class Node_Stack;
143 class OopMap;
153 class PhiNode;
154 class Pipeline;
155 class PopulateIndexNode;
156 class ProjNode;
157 class RangeCheckNode;
158 class ReductionNode;
159 class RegMask;
160 class RegionNode;
161 class RootNode;
162 class SafePointNode;
163 class SafePointScalarObjectNode;
164 class SafePointScalarMergeNode;
165 class StartNode;
166 class State;
167 class StoreNode;
168 class SubNode;
169 class SubTypeCheckNode;
170 class Type;
171 class TypeNode;
172 class UnlockNode;
173 class UnorderedReductionNode;
174 class VectorNode;
175 class LoadVectorNode;
176 class LoadVectorMaskedNode;
177 class StoreVectorMaskedNode;
178 class LoadVectorGatherNode;
179 class StoreVectorNode;
180 class StoreVectorScatterNode;
181 class VectorMaskCmpNode;
182 class VectorUnboxNode;
183 class VectorSet;
184 class VectorReinterpretNode;
185 class ShiftVNode;
186 class ExpandVNode;
187 class CompressVNode;
188 class CompressMNode;
189
190
191 #ifndef OPTO_DU_ITERATOR_ASSERT
192 #ifdef ASSERT
662 DEFINE_CLASS_ID(AbstractLock, Call, 3)
663 DEFINE_CLASS_ID(Lock, AbstractLock, 0)
664 DEFINE_CLASS_ID(Unlock, AbstractLock, 1)
665 DEFINE_CLASS_ID(ArrayCopy, Call, 4)
666 DEFINE_CLASS_ID(MultiBranch, Multi, 1)
667 DEFINE_CLASS_ID(PCTable, MultiBranch, 0)
668 DEFINE_CLASS_ID(Catch, PCTable, 0)
669 DEFINE_CLASS_ID(Jump, PCTable, 1)
670 DEFINE_CLASS_ID(If, MultiBranch, 1)
671 DEFINE_CLASS_ID(BaseCountedLoopEnd, If, 0)
672 DEFINE_CLASS_ID(CountedLoopEnd, BaseCountedLoopEnd, 0)
673 DEFINE_CLASS_ID(LongCountedLoopEnd, BaseCountedLoopEnd, 1)
674 DEFINE_CLASS_ID(RangeCheck, If, 1)
675 DEFINE_CLASS_ID(OuterStripMinedLoopEnd, If, 2)
676 DEFINE_CLASS_ID(ParsePredicate, If, 3)
677 DEFINE_CLASS_ID(NeverBranch, MultiBranch, 2)
678 DEFINE_CLASS_ID(Start, Multi, 2)
679 DEFINE_CLASS_ID(MemBar, Multi, 3)
680 DEFINE_CLASS_ID(Initialize, MemBar, 0)
681 DEFINE_CLASS_ID(MemBarStoreStore, MemBar, 1)
682
683 DEFINE_CLASS_ID(Mach, Node, 1)
684 DEFINE_CLASS_ID(MachReturn, Mach, 0)
685 DEFINE_CLASS_ID(MachSafePoint, MachReturn, 0)
686 DEFINE_CLASS_ID(MachCall, MachSafePoint, 0)
687 DEFINE_CLASS_ID(MachCallJava, MachCall, 0)
688 DEFINE_CLASS_ID(MachCallStaticJava, MachCallJava, 0)
689 DEFINE_CLASS_ID(MachCallDynamicJava, MachCallJava, 1)
690 DEFINE_CLASS_ID(MachCallRuntime, MachCall, 1)
691 DEFINE_CLASS_ID(MachCallLeaf, MachCallRuntime, 0)
692 DEFINE_CLASS_ID(MachBranch, Mach, 1)
693 DEFINE_CLASS_ID(MachIf, MachBranch, 0)
694 DEFINE_CLASS_ID(MachGoto, MachBranch, 1)
695 DEFINE_CLASS_ID(MachNullCheck, MachBranch, 2)
696 DEFINE_CLASS_ID(MachSpillCopy, Mach, 2)
697 DEFINE_CLASS_ID(MachTemp, Mach, 3)
698 DEFINE_CLASS_ID(MachConstantBase, Mach, 4)
699 DEFINE_CLASS_ID(MachConstant, Mach, 5)
700 DEFINE_CLASS_ID(MachJump, MachConstant, 0)
701 DEFINE_CLASS_ID(MachMerge, Mach, 6)
702 DEFINE_CLASS_ID(MachMemBar, Mach, 7)
703
704 DEFINE_CLASS_ID(Type, Node, 2)
705 DEFINE_CLASS_ID(Phi, Type, 0)
706 DEFINE_CLASS_ID(ConstraintCast, Type, 1)
707 DEFINE_CLASS_ID(CastII, ConstraintCast, 0)
708 DEFINE_CLASS_ID(CheckCastPP, ConstraintCast, 1)
709 DEFINE_CLASS_ID(CastLL, ConstraintCast, 2)
710 DEFINE_CLASS_ID(CastFF, ConstraintCast, 3)
711 DEFINE_CLASS_ID(CastDD, ConstraintCast, 4)
712 DEFINE_CLASS_ID(CastVV, ConstraintCast, 5)
713 DEFINE_CLASS_ID(CMove, Type, 3)
714 DEFINE_CLASS_ID(SafePointScalarObject, Type, 4)
715 DEFINE_CLASS_ID(DecodeNarrowPtr, Type, 5)
716 DEFINE_CLASS_ID(DecodeN, DecodeNarrowPtr, 0)
717 DEFINE_CLASS_ID(DecodeNKlass, DecodeNarrowPtr, 1)
718 DEFINE_CLASS_ID(EncodeNarrowPtr, Type, 6)
719 DEFINE_CLASS_ID(EncodeP, EncodeNarrowPtr, 0)
720 DEFINE_CLASS_ID(EncodePKlass, EncodeNarrowPtr, 1)
721 DEFINE_CLASS_ID(Vector, Type, 7)
722 DEFINE_CLASS_ID(VectorMaskCmp, Vector, 0)
723 DEFINE_CLASS_ID(VectorUnbox, Vector, 1)
724 DEFINE_CLASS_ID(VectorReinterpret, Vector, 2)
725 DEFINE_CLASS_ID(ShiftV, Vector, 3)
726 DEFINE_CLASS_ID(CompressV, Vector, 4)
727 DEFINE_CLASS_ID(ExpandV, Vector, 5)
728 DEFINE_CLASS_ID(CompressM, Vector, 6)
729 DEFINE_CLASS_ID(Reduction, Vector, 7)
730 DEFINE_CLASS_ID(UnorderedReduction, Reduction, 0)
731 DEFINE_CLASS_ID(NegV, Vector, 8)
732 DEFINE_CLASS_ID(Con, Type, 8)
733 DEFINE_CLASS_ID(ConI, Con, 0)
734 DEFINE_CLASS_ID(SafePointScalarMerge, Type, 9)
735 DEFINE_CLASS_ID(Convert, Type, 10)
736
737
738 DEFINE_CLASS_ID(Proj, Node, 3)
739 DEFINE_CLASS_ID(CatchProj, Proj, 0)
740 DEFINE_CLASS_ID(JumpProj, Proj, 1)
741 DEFINE_CLASS_ID(IfProj, Proj, 2)
742 DEFINE_CLASS_ID(IfTrue, IfProj, 0)
743 DEFINE_CLASS_ID(IfFalse, IfProj, 1)
744 DEFINE_CLASS_ID(Parm, Proj, 4)
745 DEFINE_CLASS_ID(MachProj, Proj, 5)
746
747 DEFINE_CLASS_ID(Mem, Node, 4)
748 DEFINE_CLASS_ID(Load, Mem, 0)
749 DEFINE_CLASS_ID(LoadVector, Load, 0)
750 DEFINE_CLASS_ID(LoadVectorGather, LoadVector, 0)
751 DEFINE_CLASS_ID(LoadVectorGatherMasked, LoadVector, 1)
752 DEFINE_CLASS_ID(LoadVectorMasked, LoadVector, 2)
753 DEFINE_CLASS_ID(Store, Mem, 1)
754 DEFINE_CLASS_ID(StoreVector, Store, 0)
755 DEFINE_CLASS_ID(StoreVectorScatter, StoreVector, 0)
756 DEFINE_CLASS_ID(StoreVectorScatterMasked, StoreVector, 1)
757 DEFINE_CLASS_ID(StoreVectorMasked, StoreVector, 2)
758 DEFINE_CLASS_ID(LoadStore, Mem, 2)
759 DEFINE_CLASS_ID(LoadStoreConditional, LoadStore, 0)
760 DEFINE_CLASS_ID(CompareAndSwap, LoadStoreConditional, 0)
761 DEFINE_CLASS_ID(CompareAndExchangeNode, LoadStore, 1)
762
763 DEFINE_CLASS_ID(Region, Node, 5)
764 DEFINE_CLASS_ID(Loop, Region, 0)
765 DEFINE_CLASS_ID(Root, Loop, 0)
766 DEFINE_CLASS_ID(BaseCountedLoop, Loop, 1)
767 DEFINE_CLASS_ID(CountedLoop, BaseCountedLoop, 0)
768 DEFINE_CLASS_ID(LongCountedLoop, BaseCountedLoop, 1)
769 DEFINE_CLASS_ID(OuterStripMinedLoop, Loop, 2)
770
771 DEFINE_CLASS_ID(Sub, Node, 6)
772 DEFINE_CLASS_ID(Cmp, Sub, 0)
773 DEFINE_CLASS_ID(FastLock, Cmp, 0)
774 DEFINE_CLASS_ID(FastUnlock, Cmp, 1)
775 DEFINE_CLASS_ID(SubTypeCheck,Cmp, 2)
776
777 DEFINE_CLASS_ID(MergeMem, Node, 7)
778 DEFINE_CLASS_ID(Bool, Node, 8)
779 DEFINE_CLASS_ID(AddP, Node, 9)
780 DEFINE_CLASS_ID(BoxLock, Node, 10)
781 DEFINE_CLASS_ID(Add, Node, 11)
782 DEFINE_CLASS_ID(Mul, Node, 12)
783 DEFINE_CLASS_ID(ClearArray, Node, 14)
784 DEFINE_CLASS_ID(Halt, Node, 15)
785 DEFINE_CLASS_ID(Opaque1, Node, 16)
786 DEFINE_CLASS_ID(Move, Node, 17)
787 DEFINE_CLASS_ID(LShift, Node, 18)
788 DEFINE_CLASS_ID(Neg, Node, 19)
789
790 _max_classes = ClassMask_Neg
791 };
792 #undef DEFINE_CLASS_ID
793
794 // Flags are sorted by usage frequency.
795 enum NodeFlags {
855 #define DEFINE_CLASS_QUERY(type) \
856 bool is_##type() const { \
857 return ((_class_id & ClassMask_##type) == Class_##type); \
858 } \
859 type##Node *as_##type() const { \
860 assert(is_##type(), "invalid node class: %s", Name()); \
861 return (type##Node*)this; \
862 } \
863 type##Node* isa_##type() const { \
864 return (is_##type()) ? as_##type() : nullptr; \
865 }
866
867 DEFINE_CLASS_QUERY(AbstractLock)
868 DEFINE_CLASS_QUERY(Add)
869 DEFINE_CLASS_QUERY(AddP)
870 DEFINE_CLASS_QUERY(Allocate)
871 DEFINE_CLASS_QUERY(AllocateArray)
872 DEFINE_CLASS_QUERY(ArrayCopy)
873 DEFINE_CLASS_QUERY(BaseCountedLoop)
874 DEFINE_CLASS_QUERY(BaseCountedLoopEnd)
875 DEFINE_CLASS_QUERY(Bool)
876 DEFINE_CLASS_QUERY(BoxLock)
877 DEFINE_CLASS_QUERY(Call)
878 DEFINE_CLASS_QUERY(CallDynamicJava)
879 DEFINE_CLASS_QUERY(CallJava)
880 DEFINE_CLASS_QUERY(CallLeaf)
881 DEFINE_CLASS_QUERY(CallLeafNoFP)
882 DEFINE_CLASS_QUERY(CallRuntime)
883 DEFINE_CLASS_QUERY(CallStaticJava)
884 DEFINE_CLASS_QUERY(Catch)
885 DEFINE_CLASS_QUERY(CatchProj)
886 DEFINE_CLASS_QUERY(CheckCastPP)
887 DEFINE_CLASS_QUERY(CastII)
888 DEFINE_CLASS_QUERY(CastLL)
889 DEFINE_CLASS_QUERY(ConI)
890 DEFINE_CLASS_QUERY(ConstraintCast)
891 DEFINE_CLASS_QUERY(ClearArray)
892 DEFINE_CLASS_QUERY(CMove)
893 DEFINE_CLASS_QUERY(Cmp)
894 DEFINE_CLASS_QUERY(Convert)
895 DEFINE_CLASS_QUERY(CountedLoop)
896 DEFINE_CLASS_QUERY(CountedLoopEnd)
897 DEFINE_CLASS_QUERY(DecodeNarrowPtr)
898 DEFINE_CLASS_QUERY(DecodeN)
899 DEFINE_CLASS_QUERY(DecodeNKlass)
900 DEFINE_CLASS_QUERY(EncodeNarrowPtr)
901 DEFINE_CLASS_QUERY(EncodeP)
902 DEFINE_CLASS_QUERY(EncodePKlass)
903 DEFINE_CLASS_QUERY(FastLock)
904 DEFINE_CLASS_QUERY(FastUnlock)
905 DEFINE_CLASS_QUERY(Halt)
906 DEFINE_CLASS_QUERY(If)
907 DEFINE_CLASS_QUERY(RangeCheck)
908 DEFINE_CLASS_QUERY(IfProj)
909 DEFINE_CLASS_QUERY(IfFalse)
910 DEFINE_CLASS_QUERY(IfTrue)
911 DEFINE_CLASS_QUERY(Initialize)
912 DEFINE_CLASS_QUERY(Jump)
913 DEFINE_CLASS_QUERY(JumpProj)
914 DEFINE_CLASS_QUERY(LongCountedLoop)
915 DEFINE_CLASS_QUERY(LongCountedLoopEnd)
916 DEFINE_CLASS_QUERY(Load)
917 DEFINE_CLASS_QUERY(LoadStore)
918 DEFINE_CLASS_QUERY(LoadStoreConditional)
919 DEFINE_CLASS_QUERY(Lock)
920 DEFINE_CLASS_QUERY(Loop)
921 DEFINE_CLASS_QUERY(LShift)
922 DEFINE_CLASS_QUERY(Mach)
923 DEFINE_CLASS_QUERY(MachBranch)
924 DEFINE_CLASS_QUERY(MachCall)
925 DEFINE_CLASS_QUERY(MachCallDynamicJava)
926 DEFINE_CLASS_QUERY(MachCallJava)
927 DEFINE_CLASS_QUERY(MachCallLeaf)
928 DEFINE_CLASS_QUERY(MachCallRuntime)
929 DEFINE_CLASS_QUERY(MachCallStaticJava)
930 DEFINE_CLASS_QUERY(MachConstantBase)
931 DEFINE_CLASS_QUERY(MachConstant)
932 DEFINE_CLASS_QUERY(MachGoto)
933 DEFINE_CLASS_QUERY(MachIf)
934 DEFINE_CLASS_QUERY(MachJump)
935 DEFINE_CLASS_QUERY(MachNullCheck)
936 DEFINE_CLASS_QUERY(MachProj)
937 DEFINE_CLASS_QUERY(MachReturn)
938 DEFINE_CLASS_QUERY(MachSafePoint)
939 DEFINE_CLASS_QUERY(MachSpillCopy)
940 DEFINE_CLASS_QUERY(MachTemp)
941 DEFINE_CLASS_QUERY(MachMemBar)
942 DEFINE_CLASS_QUERY(MachMerge)
943 DEFINE_CLASS_QUERY(Mem)
944 DEFINE_CLASS_QUERY(MemBar)
945 DEFINE_CLASS_QUERY(MemBarStoreStore)
946 DEFINE_CLASS_QUERY(MergeMem)
947 DEFINE_CLASS_QUERY(Move)
948 DEFINE_CLASS_QUERY(Mul)
949 DEFINE_CLASS_QUERY(Multi)
950 DEFINE_CLASS_QUERY(MultiBranch)
951 DEFINE_CLASS_QUERY(Neg)
952 DEFINE_CLASS_QUERY(NegV)
953 DEFINE_CLASS_QUERY(NeverBranch)
954 DEFINE_CLASS_QUERY(Opaque1)
955 DEFINE_CLASS_QUERY(OuterStripMinedLoop)
956 DEFINE_CLASS_QUERY(OuterStripMinedLoopEnd)
957 DEFINE_CLASS_QUERY(Parm)
958 DEFINE_CLASS_QUERY(ParsePredicate)
959 DEFINE_CLASS_QUERY(PCTable)
960 DEFINE_CLASS_QUERY(Phi)
961 DEFINE_CLASS_QUERY(Proj)
962 DEFINE_CLASS_QUERY(Reduction)
963 DEFINE_CLASS_QUERY(Region)
964 DEFINE_CLASS_QUERY(Root)
965 DEFINE_CLASS_QUERY(SafePoint)
966 DEFINE_CLASS_QUERY(SafePointScalarObject)
967 DEFINE_CLASS_QUERY(SafePointScalarMerge)
968 DEFINE_CLASS_QUERY(Start)
969 DEFINE_CLASS_QUERY(Store)
970 DEFINE_CLASS_QUERY(Sub)
971 DEFINE_CLASS_QUERY(SubTypeCheck)
972 DEFINE_CLASS_QUERY(Type)
973 DEFINE_CLASS_QUERY(UnorderedReduction)
974 DEFINE_CLASS_QUERY(Vector)
975 DEFINE_CLASS_QUERY(VectorMaskCmp)
976 DEFINE_CLASS_QUERY(VectorUnbox)
977 DEFINE_CLASS_QUERY(VectorReinterpret)
978 DEFINE_CLASS_QUERY(CompressV)
979 DEFINE_CLASS_QUERY(ExpandV)
980 DEFINE_CLASS_QUERY(CompressM)
981 DEFINE_CLASS_QUERY(LoadVector)
982 DEFINE_CLASS_QUERY(LoadVectorGather)
983 DEFINE_CLASS_QUERY(StoreVector)
984 DEFINE_CLASS_QUERY(StoreVectorScatter)
985 DEFINE_CLASS_QUERY(ShiftV)
986 DEFINE_CLASS_QUERY(Unlock)
987
988 #undef DEFINE_CLASS_QUERY
989
990 // duplicate of is_MachSpillCopy()
991 bool is_SpillCopy () const {
992 return ((_class_id & ClassMask_MachSpillCopy) == Class_MachSpillCopy);
|
66 class CheckCastPPNode;
67 class ClearArrayNode;
68 class CmpNode;
69 class CodeBuffer;
70 class ConstraintCastNode;
71 class ConNode;
72 class ConINode;
73 class ConvertNode;
74 class CompareAndSwapNode;
75 class CompareAndExchangeNode;
76 class CountedLoopNode;
77 class CountedLoopEndNode;
78 class DecodeNarrowPtrNode;
79 class DecodeNNode;
80 class DecodeNKlassNode;
81 class EncodeNarrowPtrNode;
82 class EncodePNode;
83 class EncodePKlassNode;
84 class FastLockNode;
85 class FastUnlockNode;
86 class FlatArrayCheckNode;
87 class HaltNode;
88 class IfNode;
89 class IfProjNode;
90 class IfFalseNode;
91 class IfTrueNode;
92 class InitializeNode;
93 class JVMState;
94 class JumpNode;
95 class JumpProjNode;
96 class LoadNode;
97 class LoadStoreNode;
98 class LoadStoreConditionalNode;
99 class LockNode;
100 class LongCountedLoopNode;
101 class LongCountedLoopEndNode;
102 class LoopNode;
103 class LShiftNode;
104 class MachBranchNode;
105 class MachCallDynamicJavaNode;
106 class MachCallJavaNode;
107 class MachCallLeafNode;
108 class MachCallNode;
109 class MachCallRuntimeNode;
110 class MachCallStaticJavaNode;
111 class MachConstantBaseNode;
112 class MachConstantNode;
113 class MachGotoNode;
114 class MachIfNode;
115 class MachJumpNode;
116 class MachNode;
117 class MachNullCheckNode;
118 class MachProjNode;
119 class MachPrologNode;
120 class MachReturnNode;
121 class MachSafePointNode;
122 class MachSpillCopyNode;
123 class MachTempNode;
124 class MachMergeNode;
125 class MachMemBarNode;
126 class MachVEPNode;
127 class Matcher;
128 class MemBarNode;
129 class MemBarStoreStoreNode;
130 class MemNode;
131 class MergeMemNode;
132 class MoveNode;
133 class MulNode;
134 class MultiNode;
135 class MultiBranchNode;
136 class NegNode;
137 class NegVNode;
138 class NeverBranchNode;
139 class Opaque1Node;
140 class OuterStripMinedLoopNode;
141 class OuterStripMinedLoopEndNode;
142 class Node;
143 class Node_Array;
144 class Node_List;
145 class Node_Stack;
146 class OopMap;
156 class PhiNode;
157 class Pipeline;
158 class PopulateIndexNode;
159 class ProjNode;
160 class RangeCheckNode;
161 class ReductionNode;
162 class RegMask;
163 class RegionNode;
164 class RootNode;
165 class SafePointNode;
166 class SafePointScalarObjectNode;
167 class SafePointScalarMergeNode;
168 class StartNode;
169 class State;
170 class StoreNode;
171 class SubNode;
172 class SubTypeCheckNode;
173 class Type;
174 class TypeNode;
175 class UnlockNode;
176 class InlineTypeNode;
177 class UnorderedReductionNode;
178 class VectorNode;
179 class LoadVectorNode;
180 class LoadVectorMaskedNode;
181 class StoreVectorMaskedNode;
182 class LoadVectorGatherNode;
183 class StoreVectorNode;
184 class StoreVectorScatterNode;
185 class VectorMaskCmpNode;
186 class VectorUnboxNode;
187 class VectorSet;
188 class VectorReinterpretNode;
189 class ShiftVNode;
190 class ExpandVNode;
191 class CompressVNode;
192 class CompressMNode;
193
194
195 #ifndef OPTO_DU_ITERATOR_ASSERT
196 #ifdef ASSERT
666 DEFINE_CLASS_ID(AbstractLock, Call, 3)
667 DEFINE_CLASS_ID(Lock, AbstractLock, 0)
668 DEFINE_CLASS_ID(Unlock, AbstractLock, 1)
669 DEFINE_CLASS_ID(ArrayCopy, Call, 4)
670 DEFINE_CLASS_ID(MultiBranch, Multi, 1)
671 DEFINE_CLASS_ID(PCTable, MultiBranch, 0)
672 DEFINE_CLASS_ID(Catch, PCTable, 0)
673 DEFINE_CLASS_ID(Jump, PCTable, 1)
674 DEFINE_CLASS_ID(If, MultiBranch, 1)
675 DEFINE_CLASS_ID(BaseCountedLoopEnd, If, 0)
676 DEFINE_CLASS_ID(CountedLoopEnd, BaseCountedLoopEnd, 0)
677 DEFINE_CLASS_ID(LongCountedLoopEnd, BaseCountedLoopEnd, 1)
678 DEFINE_CLASS_ID(RangeCheck, If, 1)
679 DEFINE_CLASS_ID(OuterStripMinedLoopEnd, If, 2)
680 DEFINE_CLASS_ID(ParsePredicate, If, 3)
681 DEFINE_CLASS_ID(NeverBranch, MultiBranch, 2)
682 DEFINE_CLASS_ID(Start, Multi, 2)
683 DEFINE_CLASS_ID(MemBar, Multi, 3)
684 DEFINE_CLASS_ID(Initialize, MemBar, 0)
685 DEFINE_CLASS_ID(MemBarStoreStore, MemBar, 1)
686 DEFINE_CLASS_ID(Blackhole, MemBar, 2)
687
688 DEFINE_CLASS_ID(Mach, Node, 1)
689 DEFINE_CLASS_ID(MachReturn, Mach, 0)
690 DEFINE_CLASS_ID(MachSafePoint, MachReturn, 0)
691 DEFINE_CLASS_ID(MachCall, MachSafePoint, 0)
692 DEFINE_CLASS_ID(MachCallJava, MachCall, 0)
693 DEFINE_CLASS_ID(MachCallStaticJava, MachCallJava, 0)
694 DEFINE_CLASS_ID(MachCallDynamicJava, MachCallJava, 1)
695 DEFINE_CLASS_ID(MachCallRuntime, MachCall, 1)
696 DEFINE_CLASS_ID(MachCallLeaf, MachCallRuntime, 0)
697 DEFINE_CLASS_ID(MachBranch, Mach, 1)
698 DEFINE_CLASS_ID(MachIf, MachBranch, 0)
699 DEFINE_CLASS_ID(MachGoto, MachBranch, 1)
700 DEFINE_CLASS_ID(MachNullCheck, MachBranch, 2)
701 DEFINE_CLASS_ID(MachSpillCopy, Mach, 2)
702 DEFINE_CLASS_ID(MachTemp, Mach, 3)
703 DEFINE_CLASS_ID(MachConstantBase, Mach, 4)
704 DEFINE_CLASS_ID(MachConstant, Mach, 5)
705 DEFINE_CLASS_ID(MachJump, MachConstant, 0)
706 DEFINE_CLASS_ID(MachMerge, Mach, 6)
707 DEFINE_CLASS_ID(MachMemBar, Mach, 7)
708 DEFINE_CLASS_ID(MachProlog, Mach, 8)
709 DEFINE_CLASS_ID(MachVEP, Mach, 9)
710
711 DEFINE_CLASS_ID(Type, Node, 2)
712 DEFINE_CLASS_ID(Phi, Type, 0)
713 DEFINE_CLASS_ID(ConstraintCast, Type, 1)
714 DEFINE_CLASS_ID(CastII, ConstraintCast, 0)
715 DEFINE_CLASS_ID(CheckCastPP, ConstraintCast, 1)
716 DEFINE_CLASS_ID(CastLL, ConstraintCast, 2)
717 DEFINE_CLASS_ID(CastFF, ConstraintCast, 3)
718 DEFINE_CLASS_ID(CastDD, ConstraintCast, 4)
719 DEFINE_CLASS_ID(CastVV, ConstraintCast, 5)
720 DEFINE_CLASS_ID(CMove, Type, 3)
721 DEFINE_CLASS_ID(SafePointScalarObject, Type, 4)
722 DEFINE_CLASS_ID(DecodeNarrowPtr, Type, 5)
723 DEFINE_CLASS_ID(DecodeN, DecodeNarrowPtr, 0)
724 DEFINE_CLASS_ID(DecodeNKlass, DecodeNarrowPtr, 1)
725 DEFINE_CLASS_ID(EncodeNarrowPtr, Type, 6)
726 DEFINE_CLASS_ID(EncodeP, EncodeNarrowPtr, 0)
727 DEFINE_CLASS_ID(EncodePKlass, EncodeNarrowPtr, 1)
728 DEFINE_CLASS_ID(Vector, Type, 7)
729 DEFINE_CLASS_ID(VectorMaskCmp, Vector, 0)
730 DEFINE_CLASS_ID(VectorUnbox, Vector, 1)
731 DEFINE_CLASS_ID(VectorReinterpret, Vector, 2)
732 DEFINE_CLASS_ID(ShiftV, Vector, 3)
733 DEFINE_CLASS_ID(CompressV, Vector, 4)
734 DEFINE_CLASS_ID(ExpandV, Vector, 5)
735 DEFINE_CLASS_ID(CompressM, Vector, 6)
736 DEFINE_CLASS_ID(Reduction, Vector, 9)
737 DEFINE_CLASS_ID(UnorderedReduction, Reduction, 0)
738 DEFINE_CLASS_ID(NegV, Vector, 8)
739 DEFINE_CLASS_ID(InlineType, Type, 8)
740 DEFINE_CLASS_ID(Con, Type, 9)
741 DEFINE_CLASS_ID(ConI, Con, 0)
742 DEFINE_CLASS_ID(SafePointScalarMerge, Type, 10)
743 DEFINE_CLASS_ID(Convert, Type, 11)
744
745
746 DEFINE_CLASS_ID(Proj, Node, 3)
747 DEFINE_CLASS_ID(CatchProj, Proj, 0)
748 DEFINE_CLASS_ID(JumpProj, Proj, 1)
749 DEFINE_CLASS_ID(IfProj, Proj, 2)
750 DEFINE_CLASS_ID(IfTrue, IfProj, 0)
751 DEFINE_CLASS_ID(IfFalse, IfProj, 1)
752 DEFINE_CLASS_ID(Parm, Proj, 4)
753 DEFINE_CLASS_ID(MachProj, Proj, 5)
754
755 DEFINE_CLASS_ID(Mem, Node, 4)
756 DEFINE_CLASS_ID(Load, Mem, 0)
757 DEFINE_CLASS_ID(LoadVector, Load, 0)
758 DEFINE_CLASS_ID(LoadVectorGather, LoadVector, 0)
759 DEFINE_CLASS_ID(LoadVectorGatherMasked, LoadVector, 1)
760 DEFINE_CLASS_ID(LoadVectorMasked, LoadVector, 2)
761 DEFINE_CLASS_ID(Store, Mem, 1)
762 DEFINE_CLASS_ID(StoreVector, Store, 0)
763 DEFINE_CLASS_ID(StoreVectorScatter, StoreVector, 0)
764 DEFINE_CLASS_ID(StoreVectorScatterMasked, StoreVector, 1)
765 DEFINE_CLASS_ID(StoreVectorMasked, StoreVector, 2)
766 DEFINE_CLASS_ID(LoadStore, Mem, 2)
767 DEFINE_CLASS_ID(LoadStoreConditional, LoadStore, 0)
768 DEFINE_CLASS_ID(CompareAndSwap, LoadStoreConditional, 0)
769 DEFINE_CLASS_ID(CompareAndExchangeNode, LoadStore, 1)
770
771 DEFINE_CLASS_ID(Region, Node, 5)
772 DEFINE_CLASS_ID(Loop, Region, 0)
773 DEFINE_CLASS_ID(Root, Loop, 0)
774 DEFINE_CLASS_ID(BaseCountedLoop, Loop, 1)
775 DEFINE_CLASS_ID(CountedLoop, BaseCountedLoop, 0)
776 DEFINE_CLASS_ID(LongCountedLoop, BaseCountedLoop, 1)
777 DEFINE_CLASS_ID(OuterStripMinedLoop, Loop, 2)
778
779 DEFINE_CLASS_ID(Sub, Node, 6)
780 DEFINE_CLASS_ID(Cmp, Sub, 0)
781 DEFINE_CLASS_ID(FastLock, Cmp, 0)
782 DEFINE_CLASS_ID(FastUnlock, Cmp, 1)
783 DEFINE_CLASS_ID(SubTypeCheck, Cmp, 2)
784 DEFINE_CLASS_ID(FlatArrayCheck, Cmp, 3)
785
786 DEFINE_CLASS_ID(MergeMem, Node, 7)
787 DEFINE_CLASS_ID(Bool, Node, 8)
788 DEFINE_CLASS_ID(AddP, Node, 9)
789 DEFINE_CLASS_ID(BoxLock, Node, 10)
790 DEFINE_CLASS_ID(Add, Node, 11)
791 DEFINE_CLASS_ID(Mul, Node, 12)
792 DEFINE_CLASS_ID(ClearArray, Node, 14)
793 DEFINE_CLASS_ID(Halt, Node, 15)
794 DEFINE_CLASS_ID(Opaque1, Node, 16)
795 DEFINE_CLASS_ID(Move, Node, 17)
796 DEFINE_CLASS_ID(LShift, Node, 18)
797 DEFINE_CLASS_ID(Neg, Node, 19)
798
799 _max_classes = ClassMask_Neg
800 };
801 #undef DEFINE_CLASS_ID
802
803 // Flags are sorted by usage frequency.
804 enum NodeFlags {
864 #define DEFINE_CLASS_QUERY(type) \
865 bool is_##type() const { \
866 return ((_class_id & ClassMask_##type) == Class_##type); \
867 } \
868 type##Node *as_##type() const { \
869 assert(is_##type(), "invalid node class: %s", Name()); \
870 return (type##Node*)this; \
871 } \
872 type##Node* isa_##type() const { \
873 return (is_##type()) ? as_##type() : nullptr; \
874 }
875
876 DEFINE_CLASS_QUERY(AbstractLock)
877 DEFINE_CLASS_QUERY(Add)
878 DEFINE_CLASS_QUERY(AddP)
879 DEFINE_CLASS_QUERY(Allocate)
880 DEFINE_CLASS_QUERY(AllocateArray)
881 DEFINE_CLASS_QUERY(ArrayCopy)
882 DEFINE_CLASS_QUERY(BaseCountedLoop)
883 DEFINE_CLASS_QUERY(BaseCountedLoopEnd)
884 DEFINE_CLASS_QUERY(Blackhole)
885 DEFINE_CLASS_QUERY(Bool)
886 DEFINE_CLASS_QUERY(BoxLock)
887 DEFINE_CLASS_QUERY(Call)
888 DEFINE_CLASS_QUERY(CallDynamicJava)
889 DEFINE_CLASS_QUERY(CallJava)
890 DEFINE_CLASS_QUERY(CallLeaf)
891 DEFINE_CLASS_QUERY(CallLeafNoFP)
892 DEFINE_CLASS_QUERY(CallRuntime)
893 DEFINE_CLASS_QUERY(CallStaticJava)
894 DEFINE_CLASS_QUERY(Catch)
895 DEFINE_CLASS_QUERY(CatchProj)
896 DEFINE_CLASS_QUERY(CheckCastPP)
897 DEFINE_CLASS_QUERY(CastII)
898 DEFINE_CLASS_QUERY(CastLL)
899 DEFINE_CLASS_QUERY(ConI)
900 DEFINE_CLASS_QUERY(ConstraintCast)
901 DEFINE_CLASS_QUERY(ClearArray)
902 DEFINE_CLASS_QUERY(CMove)
903 DEFINE_CLASS_QUERY(Cmp)
904 DEFINE_CLASS_QUERY(Convert)
905 DEFINE_CLASS_QUERY(CountedLoop)
906 DEFINE_CLASS_QUERY(CountedLoopEnd)
907 DEFINE_CLASS_QUERY(DecodeNarrowPtr)
908 DEFINE_CLASS_QUERY(DecodeN)
909 DEFINE_CLASS_QUERY(DecodeNKlass)
910 DEFINE_CLASS_QUERY(EncodeNarrowPtr)
911 DEFINE_CLASS_QUERY(EncodeP)
912 DEFINE_CLASS_QUERY(EncodePKlass)
913 DEFINE_CLASS_QUERY(FastLock)
914 DEFINE_CLASS_QUERY(FastUnlock)
915 DEFINE_CLASS_QUERY(FlatArrayCheck)
916 DEFINE_CLASS_QUERY(Halt)
917 DEFINE_CLASS_QUERY(If)
918 DEFINE_CLASS_QUERY(RangeCheck)
919 DEFINE_CLASS_QUERY(IfProj)
920 DEFINE_CLASS_QUERY(IfFalse)
921 DEFINE_CLASS_QUERY(IfTrue)
922 DEFINE_CLASS_QUERY(Initialize)
923 DEFINE_CLASS_QUERY(Jump)
924 DEFINE_CLASS_QUERY(JumpProj)
925 DEFINE_CLASS_QUERY(LongCountedLoop)
926 DEFINE_CLASS_QUERY(LongCountedLoopEnd)
927 DEFINE_CLASS_QUERY(Load)
928 DEFINE_CLASS_QUERY(LoadStore)
929 DEFINE_CLASS_QUERY(LoadStoreConditional)
930 DEFINE_CLASS_QUERY(Lock)
931 DEFINE_CLASS_QUERY(Loop)
932 DEFINE_CLASS_QUERY(LShift)
933 DEFINE_CLASS_QUERY(Mach)
934 DEFINE_CLASS_QUERY(MachBranch)
935 DEFINE_CLASS_QUERY(MachCall)
936 DEFINE_CLASS_QUERY(MachCallDynamicJava)
937 DEFINE_CLASS_QUERY(MachCallJava)
938 DEFINE_CLASS_QUERY(MachCallLeaf)
939 DEFINE_CLASS_QUERY(MachCallRuntime)
940 DEFINE_CLASS_QUERY(MachCallStaticJava)
941 DEFINE_CLASS_QUERY(MachConstantBase)
942 DEFINE_CLASS_QUERY(MachConstant)
943 DEFINE_CLASS_QUERY(MachGoto)
944 DEFINE_CLASS_QUERY(MachIf)
945 DEFINE_CLASS_QUERY(MachJump)
946 DEFINE_CLASS_QUERY(MachNullCheck)
947 DEFINE_CLASS_QUERY(MachProj)
948 DEFINE_CLASS_QUERY(MachProlog)
949 DEFINE_CLASS_QUERY(MachReturn)
950 DEFINE_CLASS_QUERY(MachSafePoint)
951 DEFINE_CLASS_QUERY(MachSpillCopy)
952 DEFINE_CLASS_QUERY(MachTemp)
953 DEFINE_CLASS_QUERY(MachMemBar)
954 DEFINE_CLASS_QUERY(MachMerge)
955 DEFINE_CLASS_QUERY(MachVEP)
956 DEFINE_CLASS_QUERY(Mem)
957 DEFINE_CLASS_QUERY(MemBar)
958 DEFINE_CLASS_QUERY(MemBarStoreStore)
959 DEFINE_CLASS_QUERY(MergeMem)
960 DEFINE_CLASS_QUERY(Move)
961 DEFINE_CLASS_QUERY(Mul)
962 DEFINE_CLASS_QUERY(Multi)
963 DEFINE_CLASS_QUERY(MultiBranch)
964 DEFINE_CLASS_QUERY(Neg)
965 DEFINE_CLASS_QUERY(NegV)
966 DEFINE_CLASS_QUERY(NeverBranch)
967 DEFINE_CLASS_QUERY(Opaque1)
968 DEFINE_CLASS_QUERY(OuterStripMinedLoop)
969 DEFINE_CLASS_QUERY(OuterStripMinedLoopEnd)
970 DEFINE_CLASS_QUERY(Parm)
971 DEFINE_CLASS_QUERY(ParsePredicate)
972 DEFINE_CLASS_QUERY(PCTable)
973 DEFINE_CLASS_QUERY(Phi)
974 DEFINE_CLASS_QUERY(Proj)
975 DEFINE_CLASS_QUERY(Reduction)
976 DEFINE_CLASS_QUERY(Region)
977 DEFINE_CLASS_QUERY(Root)
978 DEFINE_CLASS_QUERY(SafePoint)
979 DEFINE_CLASS_QUERY(SafePointScalarObject)
980 DEFINE_CLASS_QUERY(SafePointScalarMerge)
981 DEFINE_CLASS_QUERY(Start)
982 DEFINE_CLASS_QUERY(Store)
983 DEFINE_CLASS_QUERY(Sub)
984 DEFINE_CLASS_QUERY(SubTypeCheck)
985 DEFINE_CLASS_QUERY(Type)
986 DEFINE_CLASS_QUERY(InlineType)
987 DEFINE_CLASS_QUERY(UnorderedReduction)
988 DEFINE_CLASS_QUERY(Vector)
989 DEFINE_CLASS_QUERY(VectorMaskCmp)
990 DEFINE_CLASS_QUERY(VectorUnbox)
991 DEFINE_CLASS_QUERY(VectorReinterpret)
992 DEFINE_CLASS_QUERY(CompressV)
993 DEFINE_CLASS_QUERY(ExpandV)
994 DEFINE_CLASS_QUERY(CompressM)
995 DEFINE_CLASS_QUERY(LoadVector)
996 DEFINE_CLASS_QUERY(LoadVectorGather)
997 DEFINE_CLASS_QUERY(StoreVector)
998 DEFINE_CLASS_QUERY(StoreVectorScatter)
999 DEFINE_CLASS_QUERY(ShiftV)
1000 DEFINE_CLASS_QUERY(Unlock)
1001
1002 #undef DEFINE_CLASS_QUERY
1003
1004 // duplicate of is_MachSpillCopy()
1005 bool is_SpillCopy () const {
1006 return ((_class_id & ClassMask_MachSpillCopy) == Class_MachSpillCopy);
|