< prev index next >

src/hotspot/share/oops/instanceKlass.hpp

Print this page




 233   jmethodID*      volatile _methods_jmethod_ids;  // jmethodIDs corresponding to method_idnum, or NULL if none
 234   intptr_t        _dep_context;          // packed DependencyContext structure
 235   nmethod*        _osr_nmethods_head;    // Head of list of on-stack replacement nmethods for this class
 236 #if INCLUDE_JVMTI
 237   BreakpointInfo* _breakpoints;          // bpt lists, managed by Method*
 238   // Linked instanceKlasses of previous versions
 239   InstanceKlass* _previous_versions;
 240   // JVMTI fields can be moved to their own structure - see 6315920
 241   // JVMTI: cached class file, before retransformable agent modified it in CFLH
 242   JvmtiCachedClassFileData* _cached_class_file;
 243 #endif
 244 
 245   volatile u2     _idnum_allocated_count;         // JNI/JVMTI: increments with the addition of methods, old ids don't change
 246 
 247   // Class states are defined as ClassState (see above).
 248   // Place the _init_state here to utilize the unused 2-byte after
 249   // _idnum_allocated_count.
 250   u1              _init_state;                    // state of class
 251   u1              _reference_type;                // reference type
 252 

 253 #if INCLUDE_JVMTI
 254   JvmtiCachedClassFieldMap* _jvmti_cached_class_field_map;  // JVMTI: used during heap iteration
 255 #endif
 256 
 257   NOT_PRODUCT(int _verify_count;)  // to avoid redundant verifies
 258 
 259   // Method array.
 260   Array<Method*>* _methods;
 261   // Default Method Array, concrete methods inherited from interfaces
 262   Array<Method*>* _default_methods;
 263   // Interface (Klass*s) this class declares locally to implement.
 264   Array<Klass*>* _local_interfaces;
 265   // Interface (Klass*s) this class implements transitively.
 266   Array<Klass*>* _transitive_interfaces;
 267   // Int array containing the original order of method in the class file (for JVMTI).
 268   Array<int>*     _method_ordering;
 269   // Int array containing the vtable_indices for default_methods
 270   // offset matches _default_methods offset
 271   Array<int>*     _default_vtable_indices;
 272 


 498 
 499   // initialization (virtuals from Klass)
 500   bool should_be_initialized() const;  // means that initialize should be called
 501   void initialize(TRAPS);
 502   void link_class(TRAPS);
 503   bool link_class_or_fail(TRAPS); // returns false on failure
 504   void unlink_class();
 505   void rewrite_class(TRAPS);
 506   void link_methods(TRAPS);
 507   Method* class_initializer() const;
 508 
 509   // set the class to initialized if no static initializer is present
 510   void eager_initialize(Thread *thread);
 511 
 512   // reference type
 513   ReferenceType reference_type() const     { return (ReferenceType)_reference_type; }
 514   void set_reference_type(ReferenceType t) {
 515     assert(t == (u1)t, "overflow");
 516     _reference_type = (u1)t;
 517   }




 518 
 519   static ByteSize reference_type_offset() { return in_ByteSize(offset_of(InstanceKlass, _reference_type)); }
 520 
 521   // find local field, returns true if found
 522   bool find_local_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
 523   // find field in direct superinterfaces, returns the interface in which the field is defined
 524   Klass* find_interface_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
 525   // find field according to JVM spec 5.4.3.2, returns the klass in which the field is defined
 526   Klass* find_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
 527   // find instance or static fields according to JVM spec 5.4.3.2, returns the klass in which the field is defined
 528   Klass* find_field(Symbol* name, Symbol* sig, bool is_static, fieldDescriptor* fd) const;
 529 
 530   // find a non-static or static field given its offset within the class.
 531   bool contains_field_offset(int offset) {
 532     return instanceOopDesc::contains_field_offset(offset, nonstatic_field_size());
 533   }
 534 
 535   bool find_local_field_from_offset(int offset, bool is_static, fieldDescriptor* fd) const;
 536   bool find_field_from_offset(int offset, bool is_static, fieldDescriptor* fd) const;
 537 




 233   jmethodID*      volatile _methods_jmethod_ids;  // jmethodIDs corresponding to method_idnum, or NULL if none
 234   intptr_t        _dep_context;          // packed DependencyContext structure
 235   nmethod*        _osr_nmethods_head;    // Head of list of on-stack replacement nmethods for this class
 236 #if INCLUDE_JVMTI
 237   BreakpointInfo* _breakpoints;          // bpt lists, managed by Method*
 238   // Linked instanceKlasses of previous versions
 239   InstanceKlass* _previous_versions;
 240   // JVMTI fields can be moved to their own structure - see 6315920
 241   // JVMTI: cached class file, before retransformable agent modified it in CFLH
 242   JvmtiCachedClassFileData* _cached_class_file;
 243 #endif
 244 
 245   volatile u2     _idnum_allocated_count;         // JNI/JVMTI: increments with the addition of methods, old ids don't change
 246 
 247   // Class states are defined as ClassState (see above).
 248   // Place the _init_state here to utilize the unused 2-byte after
 249   // _idnum_allocated_count.
 250   u1              _init_state;                    // state of class
 251   u1              _reference_type;                // reference type
 252 
 253   u2              _this_class_index;              // constant pool entry
 254 #if INCLUDE_JVMTI
 255   JvmtiCachedClassFieldMap* _jvmti_cached_class_field_map;  // JVMTI: used during heap iteration
 256 #endif
 257 
 258   NOT_PRODUCT(int _verify_count;)  // to avoid redundant verifies
 259 
 260   // Method array.
 261   Array<Method*>* _methods;
 262   // Default Method Array, concrete methods inherited from interfaces
 263   Array<Method*>* _default_methods;
 264   // Interface (Klass*s) this class declares locally to implement.
 265   Array<Klass*>* _local_interfaces;
 266   // Interface (Klass*s) this class implements transitively.
 267   Array<Klass*>* _transitive_interfaces;
 268   // Int array containing the original order of method in the class file (for JVMTI).
 269   Array<int>*     _method_ordering;
 270   // Int array containing the vtable_indices for default_methods
 271   // offset matches _default_methods offset
 272   Array<int>*     _default_vtable_indices;
 273 


 499 
 500   // initialization (virtuals from Klass)
 501   bool should_be_initialized() const;  // means that initialize should be called
 502   void initialize(TRAPS);
 503   void link_class(TRAPS);
 504   bool link_class_or_fail(TRAPS); // returns false on failure
 505   void unlink_class();
 506   void rewrite_class(TRAPS);
 507   void link_methods(TRAPS);
 508   Method* class_initializer() const;
 509 
 510   // set the class to initialized if no static initializer is present
 511   void eager_initialize(Thread *thread);
 512 
 513   // reference type
 514   ReferenceType reference_type() const     { return (ReferenceType)_reference_type; }
 515   void set_reference_type(ReferenceType t) {
 516     assert(t == (u1)t, "overflow");
 517     _reference_type = (u1)t;
 518   }
 519 
 520   // this class cp index
 521   u2 this_class_index() const             { return _this_class_index; }
 522   void set_this_class_index(u2 index)     { _this_class_index = index; }
 523 
 524   static ByteSize reference_type_offset() { return in_ByteSize(offset_of(InstanceKlass, _reference_type)); }
 525 
 526   // find local field, returns true if found
 527   bool find_local_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
 528   // find field in direct superinterfaces, returns the interface in which the field is defined
 529   Klass* find_interface_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
 530   // find field according to JVM spec 5.4.3.2, returns the klass in which the field is defined
 531   Klass* find_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
 532   // find instance or static fields according to JVM spec 5.4.3.2, returns the klass in which the field is defined
 533   Klass* find_field(Symbol* name, Symbol* sig, bool is_static, fieldDescriptor* fd) const;
 534 
 535   // find a non-static or static field given its offset within the class.
 536   bool contains_field_offset(int offset) {
 537     return instanceOopDesc::contains_field_offset(offset, nonstatic_field_size());
 538   }
 539 
 540   bool find_local_field_from_offset(int offset, bool is_static, fieldDescriptor* fd) const;
 541   bool find_field_from_offset(int offset, bool is_static, fieldDescriptor* fd) const;
 542 


< prev index next >