]> git.pld-linux.org Git - packages/gdb.git/blame - gdb-6.3-ia64-sigill-20051115.patch
- typo
[packages/gdb.git] / gdb-6.3-ia64-sigill-20051115.patch
CommitLineData
3a58abaf
AM
12005-11-15 Jeff Johnston <jjohnstn@redhat.com>
2
3 * linux-thread-db.c (thread_db_wait): Don't bother continuing if
4 the wait result indicates the program terminated with a signal.
5 * linux-nat.c (linux_nat_wait): For SIGILL and SIGTRAP, don't
6 throw away the event if the user has specified nostop noprint.
7
8gdb/testsuite:
9
102005-11-15 Jeff Johnston <jjohnstn@redhat.com>
11
12 * gdb.arch/ia64-sigill.c: New test.
13 * gdb.arch/ia64-sigill.exp: Ditto.
14
f412e1b4 15Index: gdb-7.3.50.20110722/gdb/testsuite/gdb.arch/ia64-sigill.exp
3a58abaf
AM
16===================================================================
17--- /dev/null 1970-01-01 00:00:00.000000000 +0000
f412e1b4 18+++ gdb-7.3.50.20110722/gdb/testsuite/gdb.arch/ia64-sigill.exp 2011-07-22 19:16:13.000000000 +0200
51a5ef0f 19@@ -0,0 +1,49 @@
3a58abaf
AM
20+# Copyright 2005 Free Software Foundation, Inc.
21+
22+# This program is free software; you can redistribute it and/or modify
23+# it under the terms of the GNU General Public License as published by
24+# the Free Software Foundation; either version 2 of the License, or
25+# (at your option) any later version.
26+#
27+# This program is distributed in the hope that it will be useful,
28+# but WITHOUT ANY WARRANTY; without even the implied warranty of
29+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30+# GNU General Public License for more details.
31+#
32+# You should have received a copy of the GNU General Public License
33+# along with this program; if not, write to the Free Software
34+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
35+
36+# Please email any bugs, comments, and/or additions to this file to:
37+# bug-gdb@prep.ai.mit.edu
38+
39+# This file was written by Jeff Johnston (jjohnstn@redhat.com)
40+
3a58abaf
AM
41+if ![istarget "ia64-*-*"] then {
42+ return
43+}
44+
45+set testfile "ia64-sigill"
46+set srcfile ${testfile}.c
47+set binfile ${objdir}/${subdir}/${testfile}
48+
49+# Deliberately compile with pthreads, even though test is single-threaded.
50+# We want to force gdb thread code to be exercised.
51+if { [gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug additional_flags=-w}] != "" } {
52+ gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
53+}
54+
55+if [get_compiler_info ${binfile}] {
56+ return -1
57+}
58+
59+gdb_exit
60+gdb_start
61+gdb_reinitialize_dir $srcdir/$subdir
62+gdb_load ${binfile}
63+
64+# We set up SIGILL nostop, noprint, pass and then run the program.
65+# We expect to just see a normal run.
66+gdb_test "handle SIGILL nostop noprint" "SIGILL.*No.*No.*Yes.*" "handle sigill"
67+gdb_test "run" "Starting program.*ia64-sigill.*\[New thread.*\].*hello world.*Program exited normally." "run to exit"
68+
f412e1b4 69Index: gdb-7.3.50.20110722/gdb/testsuite/gdb.arch/ia64-sigill.c
3a58abaf
AM
70===================================================================
71--- /dev/null 1970-01-01 00:00:00.000000000 +0000
f412e1b4 72+++ gdb-7.3.50.20110722/gdb/testsuite/gdb.arch/ia64-sigill.c 2011-07-22 19:16:13.000000000 +0200
3a58abaf
AM
73@@ -0,0 +1,8 @@
74+#include <stdio.h>
75+
76+int main()
77+{
78+ printf ("hello world\n");
79+ return 0;
80+}
81+
f412e1b4 82Index: gdb-7.3.50.20110722/gdb/linux-nat.c
3a58abaf 83===================================================================
f412e1b4
PS
84--- gdb-7.3.50.20110722.orig/gdb/linux-nat.c 2011-07-22 19:15:05.000000000 +0200
85+++ gdb-7.3.50.20110722/gdb/linux-nat.c 2011-07-22 19:16:13.000000000 +0200
86@@ -3733,7 +3733,8 @@ retry:
3a58abaf
AM
87 threads can be a bit time-consuming so if we want decent
88 performance with heavily multi-threaded programs, especially when
89 they're using a high frequency timer, we'd better avoid it if we
90- can. */
91+ can. For possible trap signals like SIGTRAP and SIGILL, don't
92+ avoid reporting. */
93
94 if (WIFSTOPPED (status))
95 {
This page took 0.046776 seconds and 4 git commands to generate.