Crate tikv_jemallocator

Crate tikv_jemallocator 

Source
Expand description

Bindings for jemalloc as an allocator

This crate provides bindings to jemalloc as a memory allocator for Rust. This crate mainly exports, one type, Jemalloc, which implements the GlobalAlloc trait and optionally the Alloc trait, and is suitable both as a memory allocator and as a global allocator.

Modulesยง

ffi ๐Ÿ”’
Raw bindings to jemalloc

Macrosยง

assume ๐Ÿ”’

Structsยง

Jemalloc
Handle to the jemalloc allocator

Constantsยง

ALIGNOF_MAX_ALIGN_T ๐Ÿ”’

Functionsยง

layout_to_flags ๐Ÿ”’
If align is less than _Alignof(max_align_t), and if the requested allocation size is larger than the alignment, we are guaranteed to get a suitably aligned allocation by default, without passing extra flags, and this function returns 0.
usable_sizeโš 
Return the usable size of the allocation pointed to by ptr.