diff options
author | Pedro Alves <pedro@palves.net> | 2023-11-17 21:45:06 +0000 |
---|---|---|
committer | Pedro Alves <pedro@palves.net> | 2023-12-20 21:19:14 +0000 |
commit | 45fd40cf54292caad19baef666e6b3318350a9fe (patch) | |
tree | 8a6afdba6a2f7f9db5657ce960d5be29c02fb115 /gdb/python | |
parent | 249d08128787e4e0a977079aa09516d73f196f77 (diff) | |
download | binutils-45fd40cf54292caad19baef666e6b3318350a9fe.zip binutils-45fd40cf54292caad19baef666e6b3318350a9fe.tar.gz binutils-45fd40cf54292caad19baef666e6b3318350a9fe.tar.bz2 |
Step over thread exit, always delete the thread non-silently
With AMD GPU debugging, I noticed that when stepping over a breakpoint
placed on top of the s_endpgm instruction inline (displaced=off), GDB
would behave differently -- it wouldn't print the wave exit. E.g:
With displaced stepping, or no breakpoint at all:
stepi
[AMDGPU Wave 1:4:1:1 (0,0,0)/0 exited]
Command aborted, thread exited.
(gdb)
With inline stepping:
stepi
Command aborted, thread exited.
(gdb)
In the cases we see the "exited" notification, handle_thread_exit is
what first called delete_thread on the exiting thread, which is
non-silent.
With inline stepping, however, handle_thread_exit ends up in
update_thread_list (via restart_threads) before any delete_thread
call. Thus, amd_dbgapi_target::update_thread_list notices that the
wave is gone and deletes it with delete_thread_silent.
This commit fixes it, by making handle_thread_exited call
set_thread_exited (with the default silent=false) early, which emits
the user-visible notification.
Approved-By: Simon Marchi <simon.marchi@efficios.com>
Change-Id: I22ab3145e18d07c99dace45576307b9f9d5d966f
Diffstat (limited to 'gdb/python')
0 files changed, 0 insertions, 0 deletions