* testsuite/Makefile.am: Add incremental_test_2, incremental_test_3,
[binutils.git] / include / gdb / signals.h
blob73643974c87c551ef6510d9e06e62a88e6e850a6
1 /* Target signal numbers for GDB and the GDB remote protocol.
2 Copyright 1986, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
3 1998, 1999, 2000, 2001, 2002, 2007, 2008, 2009, 2010, 2011
4 Free Software Foundation, Inc.
6 This file is part of GDB.
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 3 of the License, or
11 (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>. */
21 #ifndef GDB_SIGNALS_H
22 #define GDB_SIGNALS_H
24 /* The numbering of these signals is chosen to match traditional unix
25 signals (insofar as various unices use the same numbers, anyway).
26 It is also the numbering of the GDB remote protocol. Other remote
27 protocols, if they use a different numbering, should make sure to
28 translate appropriately.
30 Since these numbers have actually made it out into other software
31 (stubs, etc.), you mustn't disturb the assigned numbering. If you
32 need to add new signals here, add them to the end of the explicitly
33 numbered signals, at the comment marker. Add them unconditionally,
34 not within any #if or #ifdef.
36 This is based strongly on Unix/POSIX signals for several reasons:
37 (1) This set of signals represents a widely-accepted attempt to
38 represent events of this sort in a portable fashion, (2) we want a
39 signal to make it from wait to child_wait to the user intact, (3) many
40 remote protocols use a similar encoding. However, it is
41 recognized that this set of signals has limitations (such as not
42 distinguishing between various kinds of SIGSEGV, or not
43 distinguishing hitting a breakpoint from finishing a single step).
44 So in the future we may get around this either by adding additional
45 signals for breakpoint, single-step, etc., or by adding signal
46 codes; the latter seems more in the spirit of what BSD, System V,
47 etc. are doing to address these issues. */
49 /* For an explanation of what each signal means, see
50 target_signal_to_string. */
52 enum target_signal
54 #define SET(symbol, constant, name, string) \
55 symbol = constant,
56 #include "gdb/signals.def"
57 #undef SET
60 #endif /* #ifndef GDB_SIGNALS_H */