mirror of
https://github.com/openjdk/jdk.git
synced 2026-05-20 10:27:52 +00:00
8076212: AllocateHeap() and ReallocateHeap() should be inlined
NMT with detail option reports incorrect caller address on Linux. Reviewed-by: dholmes, coleenp
This commit is contained in:
parent
ad5f4f4f84
commit
649f4e881e
@ -62,11 +62,18 @@ inline char* AllocateHeap(size_t size, MEMFLAGS flags,
|
||||
}
|
||||
return p;
|
||||
}
|
||||
|
||||
#ifdef __GNUC__
|
||||
__attribute__((always_inline))
|
||||
#endif
|
||||
inline char* AllocateHeap(size_t size, MEMFLAGS flags,
|
||||
AllocFailType alloc_failmode = AllocFailStrategy::EXIT_OOM) {
|
||||
return AllocateHeap(size, flags, CURRENT_PC, alloc_failmode);
|
||||
}
|
||||
|
||||
#ifdef __GNUC__
|
||||
__attribute__((always_inline))
|
||||
#endif
|
||||
inline char* ReallocateHeap(char *old, size_t size, MEMFLAGS flag,
|
||||
AllocFailType alloc_failmode = AllocFailStrategy::EXIT_OOM) {
|
||||
char* p = (char*) os::realloc(old, size, flag, CURRENT_PC);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user