-
Notifications
You must be signed in to change notification settings - Fork 94
Description
When attempting to use gdb to debug why a process crashed with renode, I attempted to follow the docs: https://betrusted.io/xous-book/ch03-04-debugging-programs.html, but ran into some issues.
-
The docs reference port
:3456
, but doesn't seem to exist. GDB seems to be started in renode on :3333 on the SoC here. -
The book recommends to use
riscv-none-elf-gdb
. It is unclear which binary that is. Is it from here? I tried just usingriscv64-unknown-elf-gdb
from here and usingset architecture riscv:rv32
. It seems to work, but could be causing the issues I see below? -
I changed opt-level to
1
and debug totrue
in the profile in the main Cargo.toml, rancargo xtask renode-image --gdb-stub
, ranrenode emulation/xous-release.resc
, and connected usingriscv64-unknown-elf-gdb -ex 'tar ext :3333'
. Loading symbols for the kernel withfile target/riscv32imac-unknown-none-elf/release/xous-kernel
seems to work, but loading symbols for any process, e.g.file target/riscv32imac-unknown-xous-elf/release/shellchat
, does not. I can enable breakpoints in the kernel, but breakpoints seem to be ignored in processes. Furthermore,mon pr
does not work sayingNo such command or device: pr
.
I did all of this on main
without my changes to any process to see if I had messed something up. When running on my branch, root-keys crashes, and I would like to connect over gdb to see why, but could not. Does it appear that I am doing anything incorrect?