1164 static int rtype_offset_in_bytes() { return _rtype_offset; }
1165 static int ptypes_offset_in_bytes() { return _ptypes_offset; }
1166 };
1167
1168
1169 // Interface to java.lang.invoke.CallSite objects
1170
1171 class java_lang_invoke_CallSite: AllStatic {
1172 friend class JavaClasses;
1173
1174 private:
1175 static int _target_offset;
1176
1177 static void compute_offsets();
1178
1179 public:
1180 // Accessors
1181 static oop target( oop site) { return site->obj_field( _target_offset); }
1182 static void set_target( oop site, oop target) { site->obj_field_put( _target_offset, target); }
1183
1184 static volatile oop target_volatile(oop site) { return site->obj_field_volatile( _target_offset); }
1185 static void set_target_volatile(oop site, oop target) { site->obj_field_put_volatile(_target_offset, target); }
1186
1187 // Testers
1188 static bool is_subclass(Klass* klass) {
1189 return klass->is_subclass_of(SystemDictionary::CallSite_klass());
1190 }
1191 static bool is_instance(oop obj) {
1192 return obj != NULL && is_subclass(obj->klass());
1193 }
1194
1195 // Accessors for code generation:
1196 static int target_offset_in_bytes() { return _target_offset; }
1197 };
1198
1199
1200 // Interface to java.security.AccessControlContext objects
1201
1202 class java_security_AccessControlContext: AllStatic {
1203 private:
1204 // Note that for this class the layout changed between JDK1.2 and JDK1.3,
|
1164 static int rtype_offset_in_bytes() { return _rtype_offset; }
1165 static int ptypes_offset_in_bytes() { return _ptypes_offset; }
1166 };
1167
1168
1169 // Interface to java.lang.invoke.CallSite objects
1170
1171 class java_lang_invoke_CallSite: AllStatic {
1172 friend class JavaClasses;
1173
1174 private:
1175 static int _target_offset;
1176
1177 static void compute_offsets();
1178
1179 public:
1180 // Accessors
1181 static oop target( oop site) { return site->obj_field( _target_offset); }
1182 static void set_target( oop site, oop target) { site->obj_field_put( _target_offset, target); }
1183
1184 static volatile oop target_volatile(oop site) { return oop((oopDesc *)(site->obj_field_volatile(_target_offset))); }
1185 static void set_target_volatile(oop site, oop target) { site->obj_field_put_volatile(_target_offset, target); }
1186
1187 // Testers
1188 static bool is_subclass(Klass* klass) {
1189 return klass->is_subclass_of(SystemDictionary::CallSite_klass());
1190 }
1191 static bool is_instance(oop obj) {
1192 return obj != NULL && is_subclass(obj->klass());
1193 }
1194
1195 // Accessors for code generation:
1196 static int target_offset_in_bytes() { return _target_offset; }
1197 };
1198
1199
1200 // Interface to java.security.AccessControlContext objects
1201
1202 class java_security_AccessControlContext: AllStatic {
1203 private:
1204 // Note that for this class the layout changed between JDK1.2 and JDK1.3,
|