[][src]Function wasmtime_jit::link_module

pub fn link_module(
    obj: &File<'_>,
    module: &Module,
    code_range: &mut [u8],
    finished_functions: &PrimaryMap<DefinedFuncIndex, *mut [VMFunctionBody]>
)

Links a module that has been compiled with compiled_module in wasmtime-environ.

Performs all required relocations inside the function code, provided the necessary metadata. The relocations data provided in the object file, see object.rs for details.

Currently, the produced ELF image can be trusted. TODO refactor logic to remove panics and add defensive code the image data becomes untrusted.