aboutsummaryrefslogtreecommitdiff
path: root/gdb/infrun.c
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2011-06-06 12:47:07 +0000
committerPedro Alves <palves@redhat.com>2011-06-06 12:47:07 +0000
commit3dd5b83d5bd7977bb5b98c9ef9bd8345c0f26d80 (patch)
tree5c5c72e79b6fd9a6041dd55e2dad4adf3c77704d /gdb/infrun.c
parent3c0013bf3bcaaf29176017ef8667ce591ad969c5 (diff)
downloadgdb-3dd5b83d5bd7977bb5b98c9ef9bd8345c0f26d80.zip
gdb-3dd5b83d5bd7977bb5b98c9ef9bd8345c0f26d80.tar.gz
gdb-3dd5b83d5bd7977bb5b98c9ef9bd8345c0f26d80.tar.bz2
2011-06-06 Pedro Alves <pedro@codesourcery.com>
gdb/ * infcall.c (run_inferior_call): Don't mask async. Instead force a synchronous wait, if the target can async. * target.h (struct target_ops): Delete to_async_mask. (target_async_mask): Delete. * target.c (update_current_target): Delete references to to_async_mask. * linux-nat.c (linux_nat_async_mask_value): Delete. (linux_nat_is_async_p, linux_nat_can_async_p): Remove references to linux_nat_async_mask_value. (linux_nat_async_mask): Delete. (linux_nat_async, linux_nat_close): Remove references to linux_nat_async_mask_value. * record.c (record_async_mask_value): Delete. (record_async): Remove references to record_async_mask_value. (record_async_mask): Delete. (record_can_async_p, record_is_async_p): Remove references to record_async_mask_value. (init_record_ops, init_record_core_ops): Remove references to record_async_mask. * remote.c (remote_async_mask_value): Delete. (init_remote_ops): Remove reference to remote_async_mask. (remote_can_async_p, remote_is_async_p): Remove references to remote_async_mask_value. (remote_async): Remove references to remote_async_mask_value. (remote_async_mask): Delete. * infrun.c (fetch_inferior_event): Don't claim registers changed if the current thread is already not executing.
Diffstat (limited to 'gdb/infrun.c')
-rw-r--r--gdb/infrun.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/gdb/infrun.c b/gdb/infrun.c
index e0df571..a5dbcbd 100644
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -2739,7 +2739,16 @@ fetch_inferior_event (void *client_data)
status mechanism. */
overlay_cache_invalid = 1;
- registers_changed ();
+
+ /* But don't do it if the current thread is already stopped (hence
+ this is either a delayed event that will result in
+ TARGET_WAITKIND_IGNORE, or it's an event for another thread (and
+ we always clear the register and frame caches when the user
+ switches threads anyway). If we didn't do this, a spurious
+ delayed event in all-stop mode would make the user lose the
+ selected frame. */
+ if (non_stop || is_executing (inferior_ptid))
+ registers_changed ();
make_cleanup_restore_integer (&execution_direction);
execution_direction = target_execution_direction ();