Skip to main content

GC_malloc_many

Function GC_malloc_many 

Source
pub unsafe extern "C" fn GC_malloc_many(arg1: usize) -> *mut c_void
Expand description

This returns a list of objects with the link pointer located at the beginning of each object. The use of such list can greatly reduce lock contention problems, since the allocator lock can be acquired and released many fewer times. Note that there is no “atomic” variant of this function, as otherwise the links would not be seen by the collector. If the argument (lb) is zero, then it is treated as 1. The function is guaranteed never to return NULL unless GC_oom_fn() returns NULL.