public class WindowsOSCommittedMemoryProvider extends OSCommittedMemoryProvider
OSCommittedMemoryProvider.VirtualMemoryTracker
CommittedMemoryProvider.Access
UNALIGNED
Constructor and Description |
---|
WindowsOSCommittedMemoryProvider() |
Modifier and Type | Method and Description |
---|---|
org.graalvm.word.Pointer |
allocate(org.graalvm.word.UnsignedWord size,
org.graalvm.word.UnsignedWord alignment,
boolean executable)
Allocate the requested amount of virtual memory at the requested alignment.
|
boolean |
free(org.graalvm.word.PointerBase start,
org.graalvm.word.UnsignedWord size,
org.graalvm.word.UnsignedWord alignment,
boolean executable)
Release a block of committed memory that was allocated with
CommittedMemoryProvider.allocate(org.graalvm.word.UnsignedWord, org.graalvm.word.UnsignedWord, boolean) , requiring the
exact same parameter values that were originally passed to CommittedMemoryProvider.allocate(org.graalvm.word.UnsignedWord, org.graalvm.word.UnsignedWord, boolean) . |
allocate, defaultAlignment, defaultProtection, free, initialize, tearDown
protect
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
afterGarbageCollection, beforeGarbageCollection, get, getGranularity
public org.graalvm.word.Pointer allocate(org.graalvm.word.UnsignedWord size, org.graalvm.word.UnsignedWord alignment, boolean executable)
OSCommittedMemoryProvider
allocate
in interface CommittedMemoryProvider
allocate
in class OSCommittedMemoryProvider
size
- The number of bytes to allocate, which is rounded up to the next multiple of
the granularity if required.alignment
- The required alignment of the block start, or CommittedMemoryProvider.UNALIGNED
.executable
- Whether the block must be executable.public boolean free(org.graalvm.word.PointerBase start, org.graalvm.word.UnsignedWord size, org.graalvm.word.UnsignedWord alignment, boolean executable)
CommittedMemoryProvider
CommittedMemoryProvider.allocate(org.graalvm.word.UnsignedWord, org.graalvm.word.UnsignedWord, boolean)
, requiring the
exact same parameter values that were originally passed to CommittedMemoryProvider.allocate(org.graalvm.word.UnsignedWord, org.graalvm.word.UnsignedWord, boolean)
.free
in interface CommittedMemoryProvider
free
in class OSCommittedMemoryProvider
start
- The start of the memory block, as returned by CommittedMemoryProvider.allocate(org.graalvm.word.UnsignedWord, org.graalvm.word.UnsignedWord, boolean)
.size
- The originally requested size in bytes.alignment
- The originally requested alignment.executable
- Whether the block was requested to be executable.