mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8309675: Generational ZGC: compiler/gcbarriers/UnsafeIntrinsicsTest.java fails in nmt_commit
Reviewed-by: aboldtch, dcubed
This commit is contained in:
parent
34f0a6ec6a
commit
c4e6542514
1 changed files with 4 additions and 4 deletions
|
@ -283,15 +283,15 @@ void ZPhysicalMemoryManager::nmt_commit(zoffset offset, size_t size) const {
|
||||||
// When this function is called we don't know where in the virtual memory
|
// When this function is called we don't know where in the virtual memory
|
||||||
// this physical memory will be mapped. So we fake that the virtual memory
|
// this physical memory will be mapped. So we fake that the virtual memory
|
||||||
// address is the heap base + the given offset.
|
// address is the heap base + the given offset.
|
||||||
const zaddress addr = ZOffset::address(offset);
|
const uintptr_t addr = ZAddressHeapBase + untype(offset);
|
||||||
MemTracker::record_virtual_memory_commit((void*)untype(addr), size, CALLER_PC);
|
MemTracker::record_virtual_memory_commit((void*)addr, size, CALLER_PC);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ZPhysicalMemoryManager::nmt_uncommit(zoffset offset, size_t size) const {
|
void ZPhysicalMemoryManager::nmt_uncommit(zoffset offset, size_t size) const {
|
||||||
if (MemTracker::enabled()) {
|
if (MemTracker::enabled()) {
|
||||||
const zaddress addr = ZOffset::address(offset);
|
const uintptr_t addr = ZAddressHeapBase + untype(offset);
|
||||||
Tracker tracker(Tracker::uncommit);
|
Tracker tracker(Tracker::uncommit);
|
||||||
tracker.record((address)untype(addr), size);
|
tracker.record((address)addr, size);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue