75 // GC specific object visitors
76 //
77 // Mark Sweep
78 void oop_ms_follow_contents(oop obj);
79 int oop_ms_adjust_pointers(oop obj);
80 #if INCLUDE_ALL_GCS
81 // Parallel Scavenge
82 void oop_ps_push_contents( oop obj, PSPromotionManager* pm);
83 // Parallel Compact
84 void oop_pc_follow_contents(oop obj, ParCompactionManager* cm);
85 void oop_pc_update_pointers(oop obj);
86 #endif
87
88 // Oop iterators. Since there are no oops in TypeArrayKlasses,
89 // these functions only return the size of the object.
90
91 private:
92 // The implementation used by all oop_oop_iterate functions in TypeArrayKlasses.
93 inline int oop_oop_iterate_impl(oop obj, ExtendedOopClosure* closure);
94
95 public:
96
97 #define TypeArrayKlass_OOP_OOP_ITERATE_DECL(OopClosureType, nv_suffix) \
98 int oop_oop_iterate##nv_suffix(oop obj, OopClosureType* closure); \
99 int oop_oop_iterate##nv_suffix##_m(oop obj, OopClosureType* closure, \
100 MemRegion mr); \
101 int oop_oop_iterate_range##nv_suffix(oop obj, OopClosureType* closure, \
102 int start, int end);
103
104 ALL_OOP_OOP_ITERATE_CLOSURES_1(TypeArrayKlass_OOP_OOP_ITERATE_DECL)
105 ALL_OOP_OOP_ITERATE_CLOSURES_2(TypeArrayKlass_OOP_OOP_ITERATE_DECL)
106
107 #if INCLUDE_ALL_GCS
108 #define TypeArrayKlass_OOP_OOP_ITERATE_BACKWARDS_DECL(OopClosureType, nv_suffix) \
109 int oop_oop_iterate_backwards##nv_suffix(oop obj, OopClosureType* closure);
110
111 ALL_OOP_OOP_ITERATE_CLOSURES_1(TypeArrayKlass_OOP_OOP_ITERATE_BACKWARDS_DECL)
112 ALL_OOP_OOP_ITERATE_CLOSURES_2(TypeArrayKlass_OOP_OOP_ITERATE_BACKWARDS_DECL)
113 #endif // INCLUDE_ALL_GCS
114
115
116 protected:
117 // Find n'th dimensional array
118 virtual Klass* array_klass_impl(bool or_null, int n, TRAPS);
119
120 // Returns the array class with this class as element type
121 virtual Klass* array_klass_impl(bool or_null, TRAPS);
122
123 public:
124 // Casting from Klass*
125 static TypeArrayKlass* cast(Klass* k) {
126 assert(k->oop_is_typeArray(), "cast to TypeArrayKlass");
127 return (TypeArrayKlass*) k;
128 }
129
130 // Naming
131 static const char* external_name(BasicType type);
132
|
75 // GC specific object visitors
76 //
77 // Mark Sweep
78 void oop_ms_follow_contents(oop obj);
79 int oop_ms_adjust_pointers(oop obj);
80 #if INCLUDE_ALL_GCS
81 // Parallel Scavenge
82 void oop_ps_push_contents( oop obj, PSPromotionManager* pm);
83 // Parallel Compact
84 void oop_pc_follow_contents(oop obj, ParCompactionManager* cm);
85 void oop_pc_update_pointers(oop obj);
86 #endif
87
88 // Oop iterators. Since there are no oops in TypeArrayKlasses,
89 // these functions only return the size of the object.
90
91 private:
92 // The implementation used by all oop_oop_iterate functions in TypeArrayKlasses.
93 inline int oop_oop_iterate_impl(oop obj, ExtendedOopClosure* closure);
94
95 // Wraps oop_oop_iterate_impl to conform to macros.
96 template <bool nv, typename OopClosureType>
97 inline int oop_oop_iterate(oop obj, OopClosureType* closure);
98
99 // Wraps oop_oop_iterate_impl to conform to macros.
100 template <bool nv, typename OopClosureType>
101 inline int oop_oop_iterate_bounded(oop obj, OopClosureType* closure, MemRegion mr);
102
103 public:
104
105 ALL_OOP_OOP_ITERATE_CLOSURES_1(OOP_OOP_ITERATE_DECL)
106 ALL_OOP_OOP_ITERATE_CLOSURES_2(OOP_OOP_ITERATE_DECL)
107 ALL_OOP_OOP_ITERATE_CLOSURES_1(OOP_OOP_ITERATE_DECL_RANGE)
108 ALL_OOP_OOP_ITERATE_CLOSURES_2(OOP_OOP_ITERATE_DECL_RANGE)
109
110 #if INCLUDE_ALL_GCS
111 ALL_OOP_OOP_ITERATE_CLOSURES_1(OOP_OOP_ITERATE_DECL_NO_BACKWARDS)
112 ALL_OOP_OOP_ITERATE_CLOSURES_2(OOP_OOP_ITERATE_DECL_NO_BACKWARDS)
113 #endif // INCLUDE_ALL_GCS
114
115
116 protected:
117 // Find n'th dimensional array
118 virtual Klass* array_klass_impl(bool or_null, int n, TRAPS);
119
120 // Returns the array class with this class as element type
121 virtual Klass* array_klass_impl(bool or_null, TRAPS);
122
123 public:
124 // Casting from Klass*
125 static TypeArrayKlass* cast(Klass* k) {
126 assert(k->oop_is_typeArray(), "cast to TypeArrayKlass");
127 return (TypeArrayKlass*) k;
128 }
129
130 // Naming
131 static const char* external_name(BasicType type);
132
|