diff options
author | Alex Bennée <alex.bennee@linaro.org> | 2023-05-02 15:23:50 +0100 |
---|---|---|
committer | Alex Bennée <alex.bennee@linaro.org> | 2023-05-10 15:58:17 +0100 |
commit | ab9d29b0a4ab2fec433f18b809b66bc43db1d228 (patch) | |
tree | 5b8c31370252bd6651348ea56d91881a17a637ab | |
parent | 3217b84f3cd813a7daffc64b26543c313f3a042a (diff) | |
download | qemu-ab9d29b0a4ab2fec433f18b809b66bc43db1d228.zip qemu-ab9d29b0a4ab2fec433f18b809b66bc43db1d228.tar.gz qemu-ab9d29b0a4ab2fec433f18b809b66bc43db1d228.tar.bz2 |
docs: document breakpoint and watchpoint support
This varies by accelerator. Also mention the modern bear trap that is
ASLR.
Message-Id: <20230503091244.1450613-4-alex.bennee@linaro.org>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
-rw-r--r-- | docs/system/gdb.rst | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/docs/system/gdb.rst b/docs/system/gdb.rst index 453eb73..7d3718d 100644 --- a/docs/system/gdb.rst +++ b/docs/system/gdb.rst @@ -46,6 +46,28 @@ Here are some useful tips in order to use gdb on system code: 3. Use ``set architecture i8086`` to dump 16 bit code. Then use ``x/10i $cs*16+$eip`` to dump the code at the PC position. +Breakpoint and Watchpoint support +================================= + +While GDB can always fall back to inserting breakpoints into memory +(if writable) other features are very much dependent on support of the +accelerator. For TCG system emulation we advertise an infinite number +of hardware assisted breakpoints and watchpoints. For other +accelerators it will depend on if support has been added (see +supports_guest_debug and related hooks in AccelOpsClass). + +As TCG cannot track all memory accesses in user-mode there is no +support for watchpoints. + +Relocating code +--------------- + +On modern kernels confusion can be caused by code being relocated by +features such as address space layout randomisation. To avoid +confusion when debugging such things you either need to update gdb's +view of where things are in memory or perhaps more trivially disable +ASLR when booting the system. + Debugging multicore machines ============================ |