Preserve selected thread in all-stop w/ background execution
[deliverable/binutils-gdb.git] / gdb / ChangeLog
index 0e5c8a952757e517e8689e42e07f5a501c9779f5..541683f0bf1a4fa4aa663bd7f765d2ebac02affe 100644 (file)
@@ -1,3 +1,20 @@
+2020-01-10  Pedro Alves  <palves@redhat.com>
+
+       * gdbthread.h (scoped_restore_current_thread)
+       <dont_restore, restore, m_dont_restore>: Declare.
+       * thread.c (thread_alive): Add assertion.  Return bool.
+       (switch_to_thread_if_alive): New.
+       (prune_threads): Switch inferior/thread.
+       (print_thread_info_1): Switch thread before calling target methods.
+       (scoped_restore_current_thread::restore): New, factored out from
+       ...
+       (scoped_restore_current_thread::~scoped_restore_current_thread):
+       ... this.
+       (scoped_restore_current_thread::scoped_restore_current_thread):
+       Add assertion.
+       (thread_apply_all_command, thread_select): Use
+       switch_to_thread_if_alive.
+
 2020-01-10  George Barrett  <bob@bob131.so>
 
        * stap-probe.c (stap_modify_semaphore): Don't check for null
This page took 0.02457 seconds and 4 git commands to generate.