tech:notes_gdb_debug
Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
| tech:notes_gdb_debug [2026/07/28 05:21] – Jean-Baptiste | tech:notes_gdb_debug [2026/11/03 17:27] (Version actuelle) – Jean-Baptiste | ||
|---|---|---|---|
| Ligne 27: | Ligne 27: | ||
| (gdb) r | (gdb) r | ||
| (gdb) bt | (gdb) bt | ||
| + | ~~~ | ||
| + | |||
| + | ~~~ | ||
| + | gdb --args scsynth | ||
| + | at gdb prompt: | ||
| + | run | ||
| + | |||
| + | gdb -p <process id> | ||
| ~~~ | ~~~ | ||
| Ligne 39: | Ligne 47: | ||
| quit | quit | ||
| ~~~ | ~~~ | ||
| + | |||
| + | ---- | ||
| + | |||
| + | Source : https:// | ||
| + | |||
| + | |||
| + | ~~~ | ||
| + | $ ./crash -p param1 -o param2 | ||
| + | Segmentation fault (core dumped) | ||
| + | ~~~ | ||
| + | |||
| + | ~~~bash | ||
| + | gdb --args ./crash -p param1 -o param2 | ||
| + | ~~~ | ||
| + | |||
| + | Man pages will be helpful to see other GDB options. | ||
| + | |||
| + | Most useful commands are: | ||
| + | * **bt (backtrace)** | ||
| + | * **info locals** (show values of local variables) | ||
| + | * **info registers** (show values of CPU registers) | ||
| + | * **frame X** (change to stack frame X) | ||
| + | * **up** and **down** (navigate in the stack frame (call chain)) | ||
| + | |||
tech/notes_gdb_debug.1785208904.txt.gz · Dernière modification : de Jean-Baptiste
