Commit Graph

5 Commits

Author SHA1 Message Date
Matias N
a150e03e24 gdbinit: add support for reporting total and used stack size
This checks if the required function is defined (when stack coloration
is enabled) and, if so, calls it to get used stack. Otherwise it just
reports zero used stack.
2021-01-16 21:33:42 -08:00
Masayuki Ishikawa
03d461f7e2 tools: Add 'handle SIGUSR1' to nuttx-gdbinit for the NuttX sim SMP
Summary:
- The NuttX sim SMP uses SIGUSR1 for IPI
- However, gdb traps the signal by default
- With this commit, gdb just ignores this signal

Impact:
- NuttX sim SMP only

Testing:
- Tested with sim:smp

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-11-26 19:26:44 -08:00
Masayuki Ishikawa
3c11825cda tools: Fix nuttx-gdbinit for armv7-m with FPU
Summary:
- Brennan reported the script does not work with nucleo-h743zi:otg_fs_host
- Actually, the config uses FPU but the script did not detect it
- The script assumed that the nuttx contains fpuconfig symbol
- However, this assumption was incorrect
- This commit fixes this issue by detecting FPU with tcb->xcp.regs

Impact:
- Cortex-M targets

Testing:
- Tested with lm3s6965-ek:discover (Cortex-M3)
- Tested with spresense:wifi_smp (Cortex-M4F)
- Tested with sim:smp (x86_64)

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-11-22 16:13:22 -08:00
Masayuki Ishikawa
a92e394884 tools: Fix nuttx-gdbinit for armv7-m without FPU
Summary:
- I noticed that call stack for Cortex-M3 was incorrect
- This commit fixes this issue

Impact:
- Affects nuttx-gdbinit for armv7-m without FPU

Testing:
- Tested with lm3s6965-ek:discover (qemu)
- Tested with spresense:wifi
- Tested with sim

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-09-23 02:58:33 -07:00
Masayuki Ishikawa
2c8aa8629e tools: Add nuttx-gdbinit for nuttx thread debugging
Summary:
- This commit enables nuttx thread debugging without openocd-nuttx
- To use this script, gdb must support python
- To show all thread, use 'info_nxthreads'
- To switch thread, use 'nxthread pid'
- To continue, use 'nxcontinue'

Impact:
- No impact

Testing:
- Tested with spresense (Cortex-M4F), sim (x86_64), lm3s6965-ek (Cortex-M3)
- Tested with GNU Tools for Arm Embedded Processors 9-2019-q4-major
- Tested with GNU gdb (Ubuntu 8.1-0ubuntu3.2) 8.1.0.20180409-git

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-09-10 08:53:15 +02:00