equal
deleted
inserted
replaced
90 // Returns the header size in words aligned to the requirements of the |
90 // Returns the header size in words aligned to the requirements of the |
91 // array object type. |
91 // array object type. |
92 static int header_size(BasicType type) { |
92 static int header_size(BasicType type) { |
93 size_t typesize_in_bytes = header_size_in_bytes(); |
93 size_t typesize_in_bytes = header_size_in_bytes(); |
94 return (int)(Universe::element_type_should_be_aligned(type) |
94 return (int)(Universe::element_type_should_be_aligned(type) |
95 ? align_object_size(typesize_in_bytes/HeapWordSize) |
95 ? align_object_offset(typesize_in_bytes/HeapWordSize) |
96 : typesize_in_bytes/HeapWordSize); |
96 : typesize_in_bytes/HeapWordSize); |
97 } |
97 } |
98 |
98 |
99 // Return the maximum length of an array of BasicType. The length can passed |
99 // Return the maximum length of an array of BasicType. The length can passed |
100 // to typeArrayOop::object_size(scale, length, header_size) without causing an |
100 // to typeArrayOop::object_size(scale, length, header_size) without causing an |