Function llvm_sys::execution_engine::LLVMCreateSimpleMCJITMemoryManager
source ยท pub unsafe extern "C" fn LLVMCreateSimpleMCJITMemoryManager(
Opaque: *mut c_void,
AllocateCodeSection: LLVMMemoryManagerAllocateCodeSectionCallback,
AllocateDataSection: LLVMMemoryManagerAllocateDataSectionCallback,
FinalizeMemory: LLVMMemoryManagerFinalizeMemoryCallback,
Destroy: LLVMMemoryManagerDestroyCallback,
) -> LLVMMCJITMemoryManagerRefExpand description
Create a simple custom MCJIT memory manager.
This memory manager can intercept allocations in a module-oblivious way. It will return NULL if any of the passed functions are NULL.
AllocateCodeSection and AllocateDataSection are called to allocate blocks
of memory for executable code and data, respectively. FinalizeMemory is called
to set page permissions and flush caches, returning 0 on success and 1 on error.
Opaque will be passed to the callbacks.