]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/config/pa/tm-hppa.h
2004-04-17 Randolph Chung <tausq@debian.org>
[thirdparty/binutils-gdb.git] / gdb / config / pa / tm-hppa.h
1 /* Parameters for execution on any Hewlett-Packard PA-RISC machine.
2
3 Copyright 1986, 1987, 1989, 1990, 1991, 1992, 1993, 1994, 1995,
4 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free Software
5 Foundation, Inc.
6
7 Contributed by the Center for Software Science at the
8 University of Utah (pa-gdb-bugs@cs.utah.edu).
9
10 This file is part of GDB.
11
12 This program is free software; you can redistribute it and/or modify
13 it under the terms of the GNU General Public License as published by
14 the Free Software Foundation; either version 2 of the License, or
15 (at your option) any later version.
16
17 This program is distributed in the hope that it will be useful,
18 but WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 GNU General Public License for more details.
21
22 You should have received a copy of the GNU General Public License
23 along with this program; if not, write to the Free Software
24 Foundation, Inc., 59 Temple Place - Suite 330,
25 Boston, MA 02111-1307, USA. */
26
27 #include "regcache.h"
28
29 #define GDB_MULTI_ARCH 1
30
31 extern int hppa_pc_requires_run_before_use (CORE_ADDR pc);
32 #define PC_REQUIRES_RUN_BEFORE_USE(pc) hppa_pc_requires_run_before_use (pc)
33
34 /* Register numbers of various important registers.
35 Note that some of these values are "real" register numbers,
36 and correspond to the general registers of the machine,
37 and some are "phony" register numbers which are too large
38 to be actual register numbers as far as the user is concerned
39 but do serve to get the desired values when passed to read_register. */
40
41 #define R0_REGNUM 0 /* Doesn't actually exist, used as base for
42 other r registers. */
43 #define FLAGS_REGNUM 0 /* Various status flags */
44 #define RP_REGNUM 2 /* return pointer */
45 #define HPPA_FP_REGNUM 3 /* The ABI's frame pointer, when used */
46 #define HPPA_SP_REGNUM 30 /* Stack pointer. */
47 #define SAR_REGNUM 32 /* Shift Amount Register */
48 #define IPSW_REGNUM 41 /* Interrupt Processor Status Word */
49 #define PCOQ_HEAD_REGNUM 33 /* instruction offset queue head */
50 #define PCSQ_HEAD_REGNUM 34 /* instruction space queue head */
51 #define PCOQ_TAIL_REGNUM 35 /* instruction offset queue tail */
52 #define PCSQ_TAIL_REGNUM 36 /* instruction space queue tail */
53 #define EIEM_REGNUM 37 /* External Interrupt Enable Mask */
54 #define IIR_REGNUM 38 /* Interrupt Instruction Register */
55 #define IOR_REGNUM 40 /* Interrupt Offset Register */
56 #define SR4_REGNUM 43 /* space register 4 */
57 #define RCR_REGNUM 51 /* Recover Counter (also known as cr0) */
58 #define CCR_REGNUM 54 /* Coprocessor Configuration Register */
59 #define TR0_REGNUM 57 /* Temporary Registers (cr24 -> cr31) */
60 #define CR27_REGNUM 60 /* Base register for thread-local storage, cr27 */
61 #define HPPA_FP0_REGNUM 64 /* First floating-point. */
62 #define FP4_REGNUM 72
63
64 #define ARG0_REGNUM 26 /* The first argument of a callee. */
65 #define ARG1_REGNUM 25 /* The second argument of a callee. */
66 #define ARG2_REGNUM 24 /* The third argument of a callee. */
67 #define ARG3_REGNUM 23 /* The fourth argument of a callee. */
68
69 /* PA specific macro to see if the current instruction is nullified. */
70 #ifndef INSTRUCTION_NULLIFIED
71 extern int hppa_instruction_nullified (void);
72 #define INSTRUCTION_NULLIFIED hppa_instruction_nullified ()
73 #endif
74
75 /* Here's how to step off a permanent breakpoint. */
76 #define SKIP_PERMANENT_BREAKPOINT (hppa_skip_permanent_breakpoint)
77 extern void hppa_skip_permanent_breakpoint (void);
78
79 /* On HP-UX, certain system routines (millicode) have names beginning
80 with $ or $$, e.g. $$dyncall, which handles inter-space procedure
81 calls on PA-RISC. Tell the expression parser to check for those
82 when parsing tokens that begin with "$". */
83 #define SYMBOLS_CAN_START_WITH_DOLLAR (1)