Further multiarching work mostly for hppa64-*-hpux11:
[deliverable/binutils-gdb.git] / gdb / config / pa / tm-hppa64.h
CommitLineData
adf40b2e 1/* Parameters for execution on any Hewlett-Packard PA-RISC machine.
b6ba6518
KB
2 Copyright 1986, 1987, 1989, 1990, 1991, 1992, 1993, 1995, 1999, 2000
3 Free Software Foundation, Inc.
adf40b2e
JM
4
5 Contributed by the Center for Software Science at the
6 University of Utah (pa-gdb-bugs@cs.utah.edu).
7
8This file is part of GDB.
9
10This program is free software; you can redistribute it and/or modify
11it under the terms of the GNU General Public License as published by
12the Free Software Foundation; either version 2 of the License, or
13(at your option) any later version.
14
15This program is distributed in the hope that it will be useful,
16but WITHOUT ANY WARRANTY; without even the implied warranty of
17MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18GNU General Public License for more details.
19
20You should have received a copy of the GNU General Public License
21along with this program; if not, write to the Free Software
22Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
23
24/* PA 64-bit specific definitions. Override those which are in
25 tm-hppa.h */
26
adf40b2e
JM
27/* jimb: this must go. I'm just using it to disable code I haven't
28 gotten working yet. */
29#define GDB_TARGET_IS_HPPA_20W
30
a7e9a47e
AC
31/* NOTE: cagney/2003-07-27: Using CC='cc +DA2.0W -Ae' configure
32 hppa64-hp-hpux11.00; GDB managed to build / start / break main /
33 run with multi-arch enabled. Not sure about much else as there
34 appears to be an unrelated problem in the SOM symbol table reader
d84defb1 35 causing GDB to lose line number information. Since prior to this
a7e9a47e
AC
36 switch and a other recent tweaks, 64 bit PA hadn't been building
37 for some months, this is probably the lesser of several evils. */
38#define GDB_MULTI_ARCH GDB_MULTI_ARCH_PARTIAL
61995b3b 39
7be570e7
JM
40#include "pa/tm-hppah.h"
41
adf40b2e 42#undef FP4_REGNUM
adf40b2e 43#define FP4_REGNUM 68
3ff7cf9e 44#define AP_REGNUM 29 /* Argument Pointer Register */
adf40b2e 45#define DP_REGNUM 27
adf40b2e 46#define FP5_REGNUM 70
adf40b2e
JM
47#define SR5_REGNUM 48
48
adf40b2e 49
adf40b2e
JM
50/* For a number of horrible reasons we may have to adjust the location
51 of variables on the stack. Ugh. jimb: why? */
52#define HPREAD_ADJUST_STACK_ADDRESS(ADDR) hpread_adjust_stack_address(ADDR)
53
a14ed312 54extern int hpread_adjust_stack_address (CORE_ADDR);
adf40b2e
JM
55
56
57/* jimb: omitted dynamic linking stuff here */
58
59/* This sequence of words is the instructions
60
61; Call stack frame has already been built by gdb. Since we could be calling
62; a varargs function, and we do not have the benefit of a stub to put things in
63; the right place, we load the first 8 word of arguments into both the general
64; and fp registers.
65call_dummy
53a5351d 66 nop
adf40b2e
JM
67 copy %r4,%r29
68 copy %r5,%r22
69 copy %r6,%r27
70 fldd -64(0,%r29),%fr4
71 fldd -56(0,%r29),%fr5
72 fldd -48(0,%r29),%fr6
73 fldd -40(0,%r29),%fr7
74 fldd -32(0,%r29),%fr8
75 fldd -24(0,%r29),%fr9
76 fldd -16(0,%r29),%fr10
77 fldd -8(0,%r29),%fr11
78 copy %r22,%r1
79 ldd -64(%r29), %r26
80 ldd -56(%r29), %r25
81 ldd -48(%r29), %r24
82 ldd -40(%r29), %r23
83 ldd -32(%r29), %r22
84 ldd -24(%r29), %r21
85 ldd -16(%r29), %r20
86 bve,l (%r1),%r2
87 ldd -8(%r29), %r19
88 break 4, 8
89 mtsp %r21, %sr0
90 ble 0(%sr0, %r22)
91 nop
92*/
93
53a5351d
JM
94/* Call dummys are sized and written out in word sized hunks. So we have
95 to pack the instructions into words. Ugh. */
adf40b2e 96#undef CALL_DUMMY
53a5351d
JM
97#define CALL_DUMMY {0x08000240349d0000LL, 0x34b6000034db0000LL, \
98 0x53a43f8353a53f93LL, 0x53a63fa353a73fb3LL,\
99 0x53a83fc353a93fd3LL, 0x2fa1100a2fb1100bLL,\
100 0x36c1000053ba3f81LL, 0x53b93f9153b83fa1LL,\
101 0x53b73fb153b63fc1LL, 0x53b53fd10fa110d4LL,\
102 0xe820f0000fb110d3LL, 0x0001000400151820LL,\
103 0xe6c0000008000240LL}
104
7be570e7
JM
105/* The PA64 ABI reserves 64 bytes of stack space for outgoing register
106 parameters. */
107#undef REG_PARM_STACK_SPACE
108#define REG_PARM_STACK_SPACE 64
109
c2c6d25f
JM
110/* Use the 64-bit calling conventions designed for the PA2.0 in wide mode. */
111#define PA20W_CALLING_CONVENTIONS
53a5351d 112
adf40b2e
JM
113#undef FUNC_LDIL_OFFSET
114#undef FUNC_LDO_OFFSET
115#undef SR4EXPORT_LDIL_OFFSET
116#undef SR4EXPORT_LDO_OFFSET
7be570e7 117
adf40b2e 118#undef FRAME_SAVED_PC_IN_SIGTRAMP
3ff7cf9e
JB
119extern void hppa64_hpux_frame_saved_pc_in_sigtramp (struct frame_info *fi,
120 CORE_ADDR *tmp);
adf40b2e 121#define FRAME_SAVED_PC_IN_SIGTRAMP(FRAME, TMP) \
3ff7cf9e 122 hppa64_hpux_frame_saved_pc_in_sigtramp (FRAME, TMP)
adf40b2e
JM
123
124#undef FRAME_BASE_BEFORE_SIGTRAMP
3ff7cf9e
JB
125extern void hppa64_hpux_frame_base_before_sigtramp (struct frame_info *fi,
126 CORE_ADDR *tmp);
adf40b2e 127#define FRAME_BASE_BEFORE_SIGTRAMP(FRAME, TMP) \
3ff7cf9e 128 hppa64_hpux_frame_base_before_sigtramp (FRAME, TMP)
adf40b2e
JM
129
130#undef FRAME_FIND_SAVED_REGS_IN_SIGTRAMP
3ff7cf9e
JB
131extern void hppa64_hpux_frame_find_saved_regs_in_sigtramp
132 (struct frame_info *fi, CORE_ADDR *fsr);
adf40b2e 133#define FRAME_FIND_SAVED_REGS_IN_SIGTRAMP(FRAME, FSR) \
3ff7cf9e 134 hppa64_hpux_frame_find_saved_regs_in_sigtramp (FRAME, FSR)
adf40b2e
JM
135
136/* jimb: omitted purify call support */
This page took 0.249114 seconds and 4 git commands to generate.