comparison src/share/vm/oops/instanceKlass.hpp @ 4762:069ab3f976d3

7118863: Move sizeof(klassOopDesc) into the *Klass::*_offset_in_bytes() functions Summary: Moved sizeof(klassOopDesc), changed the return type to ByteSize and removed the _in_bytes suffix. Reviewed-by: never, bdelsart, coleenp, jrose
author stefank
date Wed, 07 Dec 2011 11:35:03 +0100
parents f6f3bb0ee072
children 22cee0ee8927
comparison
equal deleted inserted replaced
4761:65149e74c706 4762:069ab3f976d3
403 403
404 // reference type 404 // reference type
405 ReferenceType reference_type() const { return _reference_type; } 405 ReferenceType reference_type() const { return _reference_type; }
406 void set_reference_type(ReferenceType t) { _reference_type = t; } 406 void set_reference_type(ReferenceType t) { _reference_type = t; }
407 407
408 static int reference_type_offset_in_bytes() { return offset_of(instanceKlass, _reference_type); } 408 static ByteSize reference_type_offset() { return in_ByteSize(sizeof(klassOopDesc) + offset_of(instanceKlass, _reference_type)); }
409 409
410 // find local field, returns true if found 410 // find local field, returns true if found
411 bool find_local_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const; 411 bool find_local_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
412 // find field in direct superinterfaces, returns the interface in which the field is defined 412 // find field in direct superinterfaces, returns the interface in which the field is defined
413 klassOop find_interface_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const; 413 klassOop find_interface_field(Symbol* name, Symbol* sig, fieldDescriptor* fd) const;
614 // Breakpoint support (see methods on methodOop for details) 614 // Breakpoint support (see methods on methodOop for details)
615 BreakpointInfo* breakpoints() const { return _breakpoints; }; 615 BreakpointInfo* breakpoints() const { return _breakpoints; };
616 void set_breakpoints(BreakpointInfo* bps) { _breakpoints = bps; }; 616 void set_breakpoints(BreakpointInfo* bps) { _breakpoints = bps; };
617 617
618 // support for stub routines 618 // support for stub routines
619 static int init_state_offset_in_bytes() { return offset_of(instanceKlass, _init_state); } 619 static ByteSize init_state_offset() { return in_ByteSize(sizeof(klassOopDesc) + offset_of(instanceKlass, _init_state)); }
620 static int init_thread_offset_in_bytes() { return offset_of(instanceKlass, _init_thread); } 620 static ByteSize init_thread_offset() { return in_ByteSize(sizeof(klassOopDesc) + offset_of(instanceKlass, _init_thread)); }
621 621
622 // subclass/subinterface checks 622 // subclass/subinterface checks
623 bool implements_interface(klassOop k) const; 623 bool implements_interface(klassOop k) const;
624 624
625 // Access to implementors of an interface. We only store the count 625 // Access to implementors of an interface. We only store the count