8145628: hotspot metadata classes shouldn't use HeapWordSize or heap related macros like align_object_size

Use align_metadata_size, align_metadata_offset and is_metadata_aligned for metadata rather than align_object_size, etc.  Use wordSize rather than HeapWordSize for metadata.  Use align_ptr_up rather than align_pointer_up (all the related functions are ptr).

Reviewed-by: hseigel, jmasa, cjplummer
This commit is contained in:
Coleen Phillimore 2016-01-30 11:02:29 -05:00
parent ec7fb4ee2b
commit 97e169ac77
36 changed files with 108 additions and 106 deletions

View file

@ -737,7 +737,7 @@ bool StringTable::copy_compact_table(char** top, char *end, GrowableArray<MemReg
return false;
}
ch_table.dump(top, end);
*top = (char*)align_pointer_up(*top, sizeof(void*));
*top = (char*)align_ptr_up(*top, sizeof(void*));
#endif
return true;
@ -760,7 +760,7 @@ const char* StringTable::init_shared_table(FileMapInfo *mapinfo, char *buffer) {
juint *p = (juint*)buffer;
const char* end = _shared_table.init(
CompactHashtable<oop, char>::_string_table, (char*)p);
const char* aligned_end = (const char*)align_pointer_up(end, sizeof(void*));
const char* aligned_end = (const char*)align_ptr_up(end, sizeof(void*));
if (_ignore_shared_strings) {
_shared_table.reset();