mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2025-06-17 02:29:12 +00:00
![]() - According to [Link 1](https://webassembly.github.io/gc/core/valid/instructions.html#xref-syntax-instructions-syntax-instr-ref-mathsf-ref-null-mathit-ht), we must ensure that the heap type is valid when ref.null. - According to [Link 2](https://webassembly.github.io/gc/core/valid/types.html#heap-types), a heap type is considered valid if it is either a concrete heap type or an abstract heap type. However, in this function, the check for abstract heap types (absheaptype) was clearly missing, so this condition needs to be added explicitly in the if statement. - When GC is disabled, no change is needed. - When GC is enabled, heap types in WAMR are LEB-encoded values ([Link 3](https://webassembly.github.io/gc/core/appendix/index-types.html)). Therefore, we must use read_leb_int32 to parse the heap type correctly. And we can compute the original type1 using type1 = (uint8)((int32)0x80 + heap_type);. |
||
---|---|---|
.. | ||
iwasm_interp.cmake | ||
SConscript | ||
wasm_interp_classic.c | ||
wasm_interp_fast.c | ||
wasm_interp.h | ||
wasm_loader.c | ||
wasm_loader.h | ||
wasm_mini_loader.c | ||
wasm_opcode.h | ||
wasm_runtime.c | ||
wasm_runtime.h | ||
wasm.h |