Skip to content

Conversation

@FromLiQg
Copy link
Contributor

@FromLiQg FromLiQg commented Sep 8, 2022

In function wasm_native_init, we ignore to call wasm_native_destroy when failed.

FromLiQg and others added 30 commits August 12, 2022 17:45
Use pointer comparison instead of struct memory comparison.
When using call_indirect, type comparison is required.
I optimized the speed of type comparison,
and changed type structure memory comparison to pointer comparison.
whitch stores the number of type references
in wasm_interp_fast.c and wasm_interp_classic.c
when "globals" initialization fails,
the memory allocated is not released, resulting in memory leakage
after initialize a compilation context for fast jit failed.
The origin code doesn't go to fail when generate insn failed in function local_i32.
when calling jit_cc_new_reg_I64 in jit_compile_op_i32_load.
@FromLiQg FromLiQg changed the title Fix Memory leak bug in function wasm_native_init Fix a memory leak bug in function wasm_native_init Sep 8, 2022
@wenyongh wenyongh merged commit 6820af6 into bytecodealliance:main Sep 8, 2022
vickiegpt pushed a commit to vickiegpt/wamr-aot-gc-checkpoint-restore that referenced this pull request May 27, 2024
…ce#1465)

Should call `wasm_native_destroy` to destroy the registered native libs
when registering native lib failed in `wasm_native_init`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants