alexcrichton added the wasmtime:debugging label to Issue #9731.
alexcrichton opened issue #9731:
Right now they're pinned to ubuntu-22.04 which will eventually get phased out. I tried to do this and failed. Specifically looks like the latest gdb segfaults:
failures: ---- debug::gdb::test_debug_dwarf_gdb stdout ---- Error: failed to execute "gdb" "--batch" "-x" "/tmp/.tmpcntwYN" "--args" "/home/runner/work/wasmtime/wasmtime/target/debug/wasmtime" "-Ccache=n" "-Ddebug-info" "--invoke" "fib" "tests/all/debug/testsuite/fib-wasm.wasm" "3": Function "fib" not defined. warning: Loadable section ".wasmtime.engine" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.bti" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".eh_frame" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.addrmap" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.traps" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".name.wasm" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.info" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> /build/gdb-1WjiBe/gdb-15.0.50.20240403/gdb/dwarf2/read.c:21450: internal-error: set_lang: Assertion `old_value == language_unknown || old_value == lang' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. ----- Backtrace ----- 0x55d7ff6f7bc6 ??? 0x55d7ffb13dd4 ??? 0x55d7ffb140d0 ??? 0x55d7ffca7f74 ??? 0x55d7ff7e1e41 ??? 0x55d7ff7ea796 ??? 0x55d7ff7eac3b ??? 0x55d7ff7ead90 ??? 0x55d7ff7f735c ??? 0x55d7ff7fc30e ??? 0x55d7ff7ffcc0 ??? 0x55d7ff80350a ??? 0x55d7ff7ff19c ??? 0x55d7ff7ff6fa ??? 0x55d7ff80539f ??? 0x55d7ff805b5d ??? 0x55d7ff806259 ??? 0x55d7ffa3f188 ??? 0x55d7ff8bb035 ??? 0x55d7ff8bd5a2 ??? 0x55d7ff8be9eb ??? 0x55d7ff8c1bb6 ??? 0x55d7ff8c2768 ??? 0x55d7ff8c2b9d ??? 0x55d7ff6ddfd8 ??? 0x55d7ff6de24a ??? 0x55d7ff6e0c6f ??? 0x55d7ff6eb38d ??? 0x55d7ffa4916c ??? 0x55d7ff8b6089 ??? 0x55d7ff8b64e8 ??? 0x55d7ff6def27 ??? 0x55d7ff8a500f ??? 0x55d7ff8a9047 ??? 0x55d7ff8aa1ad ??? 0x55d7ff8aba0d ??? 0x55d7ffca8975 ??? 0x55d7ffca952e ??? 0x55d7ffa971a3 ??? 0x55d7ffa9a3dc ??? 0x55d7ff81b967 ??? 0x55d7ffa98480 ??? 0x55d7ff73975b ??? 0x55d7ff72ca52 ??? 0x55d7ff8f7d27 ??? 0x55d7ff8f7dba ??? 0x55d7ff8fa273 ??? 0x55d7ff8faefe ??? 0x55d7ff641dab ??? 0x7f6a9b22a1c9 __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58 0x7f6a9b22a28a __libc_start_main_impl ../csu/libc-start.c:360 0x55d7ff6501f4 ??? 0xffffffffffffffff ??? --------------------- This is a bug, please report it. For instructions, see: <https://www.gnu.org/software/gdb/bugs/>. failures: debug::gdb::test_debug_dwarf_gdb test result: FAILED. 21 passed; 1 failed; 0 ignored; 0 measured; 731 filtered out; finished in 32.48sI'm not sure how best to resolve this, but it's at least not urgent at this time.
bjorn3 commented on issue #9731:
https://sourceware.org/bugzilla/show_bug.cgi?id=32431 was opened for this. It may be fixed in the next GDB release, but haven't checked yet.
bjorn3 edited a comment on issue #9731:
https://sourceware.org/bugzilla/show_bug.cgi?id=32431 was opened for this. It may be fixed in the next GDB release, but haven't checked yet.
Edit: Debugging a simple rust binary compiled to wasm works fine with latest master commit of gdb.
alexcrichton added the ci label to Issue #9731.
bjorn3 edited a comment on issue #9731:
https://sourceware.org/bugzilla/show_bug.cgi?id=32431 was opened for this. It may be fixed in the next GDB release, but haven't checked yet.
Edit: Debugging a simple rust binary compiled to wasm works fine with latest master commit of gdb.
Edit2: For posterity https://github.com/bminor/binutils-gdb/commit/3d6744493634e704b6977924a0cc8082886523f5 is the fix.
bjorn3 edited a comment on issue #9731:
https://sourceware.org/bugzilla/show_bug.cgi?id=32431 was opened for this. It may be fixed in the next GDB release, but haven't checked yet.
Edit: Debugging a simple rust binary compiled to wasm works fine with latest master commit of gdb.
Edit2: For posterity https://github.com/bminor/binutils-gdb/commit/3d6744493634e704b6977924a0cc8082886523f5 is the fix, which should be in gdb 16.3.
alexcrichton closed issue #9731:
Right now they're pinned to ubuntu-22.04 which will eventually get phased out. I tried to do this and failed. Specifically looks like the latest gdb segfaults:
failures: ---- debug::gdb::test_debug_dwarf_gdb stdout ---- Error: failed to execute "gdb" "--batch" "-x" "/tmp/.tmpcntwYN" "--args" "/home/runner/work/wasmtime/wasmtime/target/debug/wasmtime" "-Ccache=n" "-Ddebug-info" "--invoke" "fib" "tests/all/debug/testsuite/fib-wasm.wasm" "3": Function "fib" not defined. warning: Loadable section ".wasmtime.engine" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.bti" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".eh_frame" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.addrmap" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.traps" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".name.wasm" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> warning: Loadable section ".wasmtime.info" outside of ELF segments in <in-memory@0x55555aa86450-0x55555aa8a218> /build/gdb-1WjiBe/gdb-15.0.50.20240403/gdb/dwarf2/read.c:21450: internal-error: set_lang: Assertion `old_value == language_unknown || old_value == lang' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. ----- Backtrace ----- 0x55d7ff6f7bc6 ??? 0x55d7ffb13dd4 ??? 0x55d7ffb140d0 ??? 0x55d7ffca7f74 ??? 0x55d7ff7e1e41 ??? 0x55d7ff7ea796 ??? 0x55d7ff7eac3b ??? 0x55d7ff7ead90 ??? 0x55d7ff7f735c ??? 0x55d7ff7fc30e ??? 0x55d7ff7ffcc0 ??? 0x55d7ff80350a ??? 0x55d7ff7ff19c ??? 0x55d7ff7ff6fa ??? 0x55d7ff80539f ??? 0x55d7ff805b5d ??? 0x55d7ff806259 ??? 0x55d7ffa3f188 ??? 0x55d7ff8bb035 ??? 0x55d7ff8bd5a2 ??? 0x55d7ff8be9eb ??? 0x55d7ff8c1bb6 ??? 0x55d7ff8c2768 ??? 0x55d7ff8c2b9d ??? 0x55d7ff6ddfd8 ??? 0x55d7ff6de24a ??? 0x55d7ff6e0c6f ??? 0x55d7ff6eb38d ??? 0x55d7ffa4916c ??? 0x55d7ff8b6089 ??? 0x55d7ff8b64e8 ??? 0x55d7ff6def27 ??? 0x55d7ff8a500f ??? 0x55d7ff8a9047 ??? 0x55d7ff8aa1ad ??? 0x55d7ff8aba0d ??? 0x55d7ffca8975 ??? 0x55d7ffca952e ??? 0x55d7ffa971a3 ??? 0x55d7ffa9a3dc ??? 0x55d7ff81b967 ??? 0x55d7ffa98480 ??? 0x55d7ff73975b ??? 0x55d7ff72ca52 ??? 0x55d7ff8f7d27 ??? 0x55d7ff8f7dba ??? 0x55d7ff8fa273 ??? 0x55d7ff8faefe ??? 0x55d7ff641dab ??? 0x7f6a9b22a1c9 __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58 0x7f6a9b22a28a __libc_start_main_impl ../csu/libc-start.c:360 0x55d7ff6501f4 ??? 0xffffffffffffffff ??? --------------------- This is a bug, please report it. For instructions, see: <https://www.gnu.org/software/gdb/bugs/>. failures: debug::gdb::test_debug_dwarf_gdb test result: FAILED. 21 passed; 1 failed; 0 ignored; 0 measured; 731 filtered out; finished in 32.48sI'm not sure how best to resolve this, but it's at least not urgent at this time.
Last updated: Dec 13 2025 at 19:03 UTC