Package org.lwjgl.system.jemalloc
Class JEmallocAllocator
java.lang.Object
org.lwjgl.system.jemalloc.JEmallocAllocator
- All Implemented Interfaces:
MemoryUtil.MemoryAllocator
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlong
aligned_alloc
(long alignment, long size) Called byMemoryUtil.memAlignedAlloc(int, int)
.void
aligned_free
(long ptr) long
calloc
(long num, long size) Called byMemoryUtil.memCalloc(int, int)
.void
free
(long ptr) Called byMemoryUtil.memFree(java.nio.Buffer)
.long
Returns a pointer to the aligned_alloc function.long
Returns a pointer to the aligned_free function.long
Returns a pointer to the calloc function.long
getFree()
Returns a pointer to the free function.long
Returns a pointer to the malloc function.long
Returns a pointer to the realloc function.long
malloc
(long size) Called byMemoryUtil.memAlloc(int)
.long
realloc
(long ptr, long size)
-
Constructor Details
-
JEmallocAllocator
public JEmallocAllocator()
-
-
Method Details
-
getMalloc
public long getMalloc()Description copied from interface:MemoryUtil.MemoryAllocator
Returns a pointer to the malloc function.- Specified by:
getMalloc
in interfaceMemoryUtil.MemoryAllocator
-
getCalloc
public long getCalloc()Description copied from interface:MemoryUtil.MemoryAllocator
Returns a pointer to the calloc function.- Specified by:
getCalloc
in interfaceMemoryUtil.MemoryAllocator
-
getRealloc
public long getRealloc()Description copied from interface:MemoryUtil.MemoryAllocator
Returns a pointer to the realloc function.- Specified by:
getRealloc
in interfaceMemoryUtil.MemoryAllocator
-
getFree
public long getFree()Description copied from interface:MemoryUtil.MemoryAllocator
Returns a pointer to the free function.- Specified by:
getFree
in interfaceMemoryUtil.MemoryAllocator
-
getAlignedAlloc
public long getAlignedAlloc()Description copied from interface:MemoryUtil.MemoryAllocator
Returns a pointer to the aligned_alloc function.- Specified by:
getAlignedAlloc
in interfaceMemoryUtil.MemoryAllocator
-
getAlignedFree
public long getAlignedFree()Description copied from interface:MemoryUtil.MemoryAllocator
Returns a pointer to the aligned_free function.- Specified by:
getAlignedFree
in interfaceMemoryUtil.MemoryAllocator
-
malloc
public long malloc(long size) Description copied from interface:MemoryUtil.MemoryAllocator
Called byMemoryUtil.memAlloc(int)
.- Specified by:
malloc
in interfaceMemoryUtil.MemoryAllocator
-
calloc
public long calloc(long num, long size) Description copied from interface:MemoryUtil.MemoryAllocator
Called byMemoryUtil.memCalloc(int, int)
.- Specified by:
calloc
in interfaceMemoryUtil.MemoryAllocator
-
realloc
public long realloc(long ptr, long size) Description copied from interface:MemoryUtil.MemoryAllocator
- Specified by:
realloc
in interfaceMemoryUtil.MemoryAllocator
-
free
public void free(long ptr) Description copied from interface:MemoryUtil.MemoryAllocator
Called byMemoryUtil.memFree(java.nio.Buffer)
.- Specified by:
free
in interfaceMemoryUtil.MemoryAllocator
-
aligned_alloc
public long aligned_alloc(long alignment, long size) Description copied from interface:MemoryUtil.MemoryAllocator
Called byMemoryUtil.memAlignedAlloc(int, int)
.- Specified by:
aligned_alloc
in interfaceMemoryUtil.MemoryAllocator
-
aligned_free
public void aligned_free(long ptr) Description copied from interface:MemoryUtil.MemoryAllocator
- Specified by:
aligned_free
in interfaceMemoryUtil.MemoryAllocator
-