mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2025-10-24 09:51:17 +00:00
731 B
731 B
WAMR source debugging
Build wasm application with debug information
To debug your application, you need to compile them with debug information. You can use -g option when compiling the source code if you are using wasi-sdk (also work for emcc and rustc):
/opt/wasi-sdk/bin/clang -g test.c -o test.wasm
Then you will get test.wasm which is a WebAssembly module with embedded DWARF sections. Further, you can use llvm-dwarfdump to check if the generated wasm file contains DWARF information:
llvm-dwarfdump-12 test.wasm
Debugging with interpreter
See Debugging with interpreter.
Debugging with AOT
See Debugging with AOT.