提交 f38fb765 编写于 作者: C coleenp

7021653: Parfait issue in hotspot/src/share/vm/oops/methodDataOops.hpp

Summary: Fix compilation error(s)
Reviewed-by: kvn, phh, jcoomes, dholmes
上级 df4b4484
...@@ -228,7 +228,7 @@ public: ...@@ -228,7 +228,7 @@ public:
return byte_offset_of(DataLayout, _header._struct._bci); return byte_offset_of(DataLayout, _header._struct._bci);
} }
static ByteSize cell_offset(int index) { static ByteSize cell_offset(int index) {
return byte_offset_of(DataLayout, _cells[index]); return byte_offset_of(DataLayout, _cells) + in_ByteSize(index * cell_size);
} }
// Return a value which, when or-ed as a byte into _flags, sets the flag. // Return a value which, when or-ed as a byte into _flags, sets the flag.
static int flag_number_to_byte_constant(int flag_number) { static int flag_number_to_byte_constant(int flag_number) {
......
...@@ -633,10 +633,10 @@ void os::free(void *memblock) { ...@@ -633,10 +633,10 @@ void os::free(void *memblock) {
*q = (u_char)freeBlockPad; *q = (u_char)freeBlockPad;
} }
if (PrintMalloc && tty != NULL) if (PrintMalloc && tty != NULL)
fprintf(stderr, "os::free " SIZE_FORMAT " bytes --> " PTR_FORMAT "\n", size, memblock); fprintf(stderr, "os::free " SIZE_FORMAT " bytes --> " PTR_FORMAT "\n", size, (uintptr_t)memblock);
} else if (PrintMalloc && tty != NULL) { } else if (PrintMalloc && tty != NULL) {
// tty->print_cr("os::free %p", memblock); // tty->print_cr("os::free %p", memblock);
fprintf(stderr, "os::free " PTR_FORMAT "\n", memblock); fprintf(stderr, "os::free " PTR_FORMAT "\n", (uintptr_t)memblock);
} }
#endif #endif
::free((char*)memblock - space_before); ::free((char*)memblock - space_before);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册