mirror of
https://github.com/mii443/wasmer.git
synced 2025-08-24 17:29:26 +00:00
Added custom sections
Based on this document: https://www.notion.so/wasmer/Compiler-Refactor-Proposal-c678a73b0e2c4572834d2dba21263916
This commit is contained in:
@ -62,6 +62,8 @@ impl Compiler for LLVMCompiler {
|
||||
) -> Result<Compilation, CompileError> {
|
||||
//let data = Arc::new(Mutex::new(0));
|
||||
let mut func_names = SecondaryMap::new();
|
||||
let custom_sections = PrimaryMap::new();
|
||||
|
||||
for (func_index, _) in &module.functions {
|
||||
func_names[func_index] = module
|
||||
.func_names
|
||||
@ -90,7 +92,7 @@ impl Compiler for LLVMCompiler {
|
||||
.into_iter()
|
||||
.collect::<PrimaryMap<LocalFuncIndex, _>>();
|
||||
|
||||
Ok(Compilation::new(functions))
|
||||
Ok(Compilation::new(functions, custom_sections))
|
||||
}
|
||||
|
||||
fn compile_wasm_trampolines(
|
||||
|
Reference in New Issue
Block a user