diff options
author | Jan Kratochvil <jan.kratochvil@redhat.com> | 2010-07-27 20:51:37 +0000 |
---|---|---|
committer | Jan Kratochvil <jan.kratochvil@redhat.com> | 2010-07-27 20:51:37 +0000 |
commit | 7d84bcda6efce413dd48c2c8480c97fc57fd78d3 (patch) | |
tree | 02a1d1e88445698727423bd3d653d3c8bd4e95f0 /gdb/ia64-linux-nat.c | |
parent | 790f671028d5fbb71f79ac4947e5534b5cb96678 (diff) | |
download | gdb-7d84bcda6efce413dd48c2c8480c97fc57fd78d3.tar.gz |
gdb/
* ia64-linux-nat.c (ia64_linux_status_is_event): New function.
(_initialize_ia64_linux_nat): Install it.
* linux-nat.c (sigtrap_is_event, linux_nat_status_is_event)
(linux_nat_set_status_is_event): New.
(stop_wait_callback, count_events_callback, select_event_lwp_callback)
cancel_breakpoints_callback, linux_nat_filter_event)
(linux_nat_wait_1): Use linux_nat_status_is_event.
* linux-nat.h (linux_nat_set_status_is_event): New prototype.
gdb/testsuite/
* gdb.threads/ia64-sigill.exp: New file.
* gdb.threads/ia64-sigill.c: New file.
Diffstat (limited to 'gdb/ia64-linux-nat.c')
-rw-r--r-- | gdb/ia64-linux-nat.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gdb/ia64-linux-nat.c b/gdb/ia64-linux-nat.c index d33e88e1546..f9f5bf36e91 100644 --- a/gdb/ia64-linux-nat.c +++ b/gdb/ia64-linux-nat.c @@ -809,6 +809,18 @@ ia64_linux_xfer_partial (struct target_ops *ops, offset, len); } +/* For break.b instruction ia64 CPU forgets the immediate value and generates + SIGILL with ILL_ILLOPC instead of more common SIGTRAP with TRAP_BRKPT. + ia64 does not use gdbarch_decr_pc_after_break so we do not have to make any + difference for the signals here. */ + +static int +ia64_linux_status_is_event (int status) +{ + return WIFSTOPPED (status) && (WSTOPSIG (status) == SIGTRAP + || WSTOPSIG (status) == SIGILL); +} + void _initialize_ia64_linux_nat (void); void @@ -848,4 +860,5 @@ _initialize_ia64_linux_nat (void) /* Register the target. */ linux_nat_add_target (t); linux_nat_set_new_thread (t, ia64_linux_new_thread); + linux_nat_set_status_is_event (t, ia64_linux_status_is_event); } |