]>
Commit | Line | Data |
---|---|---|
59233f88 AC |
1 | /* *INDENT-OFF* */ /* THIS FILE IS GENERATED */ |
2 | ||
adf40b2e | 3 | /* Dynamic architecture support for GDB, the GNU debugger. |
1e698235 | 4 | Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. |
c906108c | 5 | |
c5aa993b | 6 | This file is part of GDB. |
c906108c | 7 | |
c5aa993b JM |
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 2 of the License, or | |
11 | (at your option) any later version. | |
c906108c | 12 | |
c5aa993b JM |
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. | |
c906108c | 17 | |
c5aa993b JM |
18 | You should have received a copy of the GNU General Public License |
19 | along with this program; if not, write to the Free Software | |
20 | Foundation, Inc., 59 Temple Place - Suite 330, | |
21 | Boston, MA 02111-1307, USA. */ | |
c906108c | 22 | |
104c1213 JM |
23 | /* This file was created with the aid of ``gdbarch.sh''. |
24 | ||
52204a0b | 25 | The Bourne shell script ``gdbarch.sh'' creates the files |
104c1213 JM |
26 | ``new-gdbarch.c'' and ``new-gdbarch.h and then compares them |
27 | against the existing ``gdbarch.[hc]''. Any differences found | |
28 | being reported. | |
29 | ||
30 | If editing this file, please also run gdbarch.sh and merge any | |
52204a0b | 31 | changes into that script. Conversely, when making sweeping changes |
104c1213 JM |
32 | to this file, modifying gdbarch.sh and using its output may prove |
33 | easier. */ | |
adf40b2e | 34 | |
c906108c SS |
35 | #ifndef GDBARCH_H |
36 | #define GDBARCH_H | |
37 | ||
2bf0cb65 | 38 | #include "dis-asm.h" /* Get defs for disassemble_info, which unfortunately is a typedef. */ |
fd0407d6 | 39 | #if !GDB_MULTI_ARCH |
67a2b77e | 40 | /* Pull in function declarations refered to, indirectly, via macros. */ |
67a2b77e | 41 | #include "inferior.h" /* For unsigned_address_to_pointer(). */ |
e9a2674e | 42 | #include "symfile.h" /* For entry_point_address(). */ |
fd0407d6 | 43 | #endif |
2bf0cb65 | 44 | |
da3331ec AC |
45 | struct floatformat; |
46 | struct ui_file; | |
cce74817 JM |
47 | struct frame_info; |
48 | struct value; | |
b6af0555 | 49 | struct objfile; |
a2cf933a | 50 | struct minimal_symbol; |
049ee0e4 | 51 | struct regcache; |
b59ff9d5 | 52 | struct reggroup; |
0f71a2f6 | 53 | |
0f71a2f6 JM |
54 | extern struct gdbarch *current_gdbarch; |
55 | ||
56 | ||
0f71a2f6 JM |
57 | /* If any of the following are defined, the target wasn't correctly |
58 | converted. */ | |
59 | ||
83905903 AC |
60 | #if (GDB_MULTI_ARCH >= GDB_MULTI_ARCH_PURE) && defined (GDB_TM_FILE) |
61 | #error "GDB_TM_FILE: Pure multi-arch targets do not have a tm.h file." | |
62 | #endif | |
63 | ||
0f71a2f6 JM |
64 | |
65 | /* The following are pre-initialized by GDBARCH. */ | |
66 | ||
104c1213 | 67 | extern const struct bfd_arch_info * gdbarch_bfd_arch_info (struct gdbarch *gdbarch); |
0f71a2f6 | 68 | /* set_gdbarch_bfd_arch_info() - not applicable - pre-initialized. */ |
83905903 AC |
69 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_ARCHITECTURE) |
70 | #error "Non multi-arch definition of TARGET_ARCHITECTURE" | |
71 | #endif | |
c25083af | 72 | #if !defined (TARGET_ARCHITECTURE) |
0f71a2f6 JM |
73 | #define TARGET_ARCHITECTURE (gdbarch_bfd_arch_info (current_gdbarch)) |
74 | #endif | |
0f71a2f6 | 75 | |
104c1213 | 76 | extern int gdbarch_byte_order (struct gdbarch *gdbarch); |
0f71a2f6 | 77 | /* set_gdbarch_byte_order() - not applicable - pre-initialized. */ |
83905903 AC |
78 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_BYTE_ORDER) |
79 | #error "Non multi-arch definition of TARGET_BYTE_ORDER" | |
80 | #endif | |
c25083af | 81 | #if !defined (TARGET_BYTE_ORDER) |
0f71a2f6 JM |
82 | #define TARGET_BYTE_ORDER (gdbarch_byte_order (current_gdbarch)) |
83 | #endif | |
0f71a2f6 | 84 | |
4be87837 DJ |
85 | extern enum gdb_osabi gdbarch_osabi (struct gdbarch *gdbarch); |
86 | /* set_gdbarch_osabi() - not applicable - pre-initialized. */ | |
87 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_OSABI) | |
88 | #error "Non multi-arch definition of TARGET_OSABI" | |
89 | #endif | |
c25083af | 90 | #if !defined (TARGET_OSABI) |
4be87837 DJ |
91 | #define TARGET_OSABI (gdbarch_osabi (current_gdbarch)) |
92 | #endif | |
4be87837 | 93 | |
0f71a2f6 | 94 | |
99e7bb18 | 95 | /* The following are initialized by the target dependent code. */ |
0f71a2f6 | 96 | |
66b43ecb AC |
97 | /* Number of bits in a char or unsigned char for the target machine. |
98 | Just like CHAR_BIT in <limits.h> but describes the target machine. | |
e669114a | 99 | v:2:TARGET_CHAR_BIT:int:char_bit::::8 * sizeof (char):8::0: |
66b43ecb AC |
100 | |
101 | Number of bits in a short or unsigned short for the target machine. */ | |
c4093a6a | 102 | |
66b43ecb AC |
103 | /* Default (value) for non- multi-arch platforms. */ |
104 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_SHORT_BIT) | |
105 | #define TARGET_SHORT_BIT (2*TARGET_CHAR_BIT) | |
0f71a2f6 JM |
106 | #endif |
107 | ||
104c1213 JM |
108 | extern int gdbarch_short_bit (struct gdbarch *gdbarch); |
109 | extern void set_gdbarch_short_bit (struct gdbarch *gdbarch, int short_bit); | |
83905903 AC |
110 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_SHORT_BIT) |
111 | #error "Non multi-arch definition of TARGET_SHORT_BIT" | |
112 | #endif | |
c25083af | 113 | #if !defined (TARGET_SHORT_BIT) |
0f71a2f6 JM |
114 | #define TARGET_SHORT_BIT (gdbarch_short_bit (current_gdbarch)) |
115 | #endif | |
0f71a2f6 | 116 | |
66b43ecb AC |
117 | /* Number of bits in an int or unsigned int for the target machine. */ |
118 | ||
119 | /* Default (value) for non- multi-arch platforms. */ | |
120 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_INT_BIT) | |
121 | #define TARGET_INT_BIT (4*TARGET_CHAR_BIT) | |
122 | #endif | |
123 | ||
104c1213 JM |
124 | extern int gdbarch_int_bit (struct gdbarch *gdbarch); |
125 | extern void set_gdbarch_int_bit (struct gdbarch *gdbarch, int int_bit); | |
83905903 AC |
126 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_INT_BIT) |
127 | #error "Non multi-arch definition of TARGET_INT_BIT" | |
128 | #endif | |
c25083af | 129 | #if !defined (TARGET_INT_BIT) |
0f71a2f6 JM |
130 | #define TARGET_INT_BIT (gdbarch_int_bit (current_gdbarch)) |
131 | #endif | |
0f71a2f6 | 132 | |
66b43ecb AC |
133 | /* Number of bits in a long or unsigned long for the target machine. */ |
134 | ||
135 | /* Default (value) for non- multi-arch platforms. */ | |
136 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_LONG_BIT) | |
137 | #define TARGET_LONG_BIT (4*TARGET_CHAR_BIT) | |
138 | #endif | |
139 | ||
104c1213 JM |
140 | extern int gdbarch_long_bit (struct gdbarch *gdbarch); |
141 | extern void set_gdbarch_long_bit (struct gdbarch *gdbarch, int long_bit); | |
83905903 AC |
142 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_LONG_BIT) |
143 | #error "Non multi-arch definition of TARGET_LONG_BIT" | |
144 | #endif | |
c25083af | 145 | #if !defined (TARGET_LONG_BIT) |
0f71a2f6 JM |
146 | #define TARGET_LONG_BIT (gdbarch_long_bit (current_gdbarch)) |
147 | #endif | |
0f71a2f6 | 148 | |
66b43ecb AC |
149 | /* Number of bits in a long long or unsigned long long for the target |
150 | machine. */ | |
151 | ||
152 | /* Default (value) for non- multi-arch platforms. */ | |
153 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_LONG_LONG_BIT) | |
154 | #define TARGET_LONG_LONG_BIT (2*TARGET_LONG_BIT) | |
155 | #endif | |
156 | ||
104c1213 JM |
157 | extern int gdbarch_long_long_bit (struct gdbarch *gdbarch); |
158 | extern void set_gdbarch_long_long_bit (struct gdbarch *gdbarch, int long_long_bit); | |
83905903 AC |
159 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_LONG_LONG_BIT) |
160 | #error "Non multi-arch definition of TARGET_LONG_LONG_BIT" | |
161 | #endif | |
c25083af | 162 | #if !defined (TARGET_LONG_LONG_BIT) |
0f71a2f6 JM |
163 | #define TARGET_LONG_LONG_BIT (gdbarch_long_long_bit (current_gdbarch)) |
164 | #endif | |
0f71a2f6 | 165 | |
66b43ecb AC |
166 | /* Number of bits in a float for the target machine. */ |
167 | ||
168 | /* Default (value) for non- multi-arch platforms. */ | |
169 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_FLOAT_BIT) | |
170 | #define TARGET_FLOAT_BIT (4*TARGET_CHAR_BIT) | |
171 | #endif | |
172 | ||
104c1213 JM |
173 | extern int gdbarch_float_bit (struct gdbarch *gdbarch); |
174 | extern void set_gdbarch_float_bit (struct gdbarch *gdbarch, int float_bit); | |
83905903 AC |
175 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_FLOAT_BIT) |
176 | #error "Non multi-arch definition of TARGET_FLOAT_BIT" | |
177 | #endif | |
c25083af | 178 | #if !defined (TARGET_FLOAT_BIT) |
0f71a2f6 JM |
179 | #define TARGET_FLOAT_BIT (gdbarch_float_bit (current_gdbarch)) |
180 | #endif | |
0f71a2f6 | 181 | |
66b43ecb AC |
182 | /* Number of bits in a double for the target machine. */ |
183 | ||
184 | /* Default (value) for non- multi-arch platforms. */ | |
185 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_DOUBLE_BIT) | |
186 | #define TARGET_DOUBLE_BIT (8*TARGET_CHAR_BIT) | |
187 | #endif | |
188 | ||
104c1213 JM |
189 | extern int gdbarch_double_bit (struct gdbarch *gdbarch); |
190 | extern void set_gdbarch_double_bit (struct gdbarch *gdbarch, int double_bit); | |
83905903 AC |
191 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_DOUBLE_BIT) |
192 | #error "Non multi-arch definition of TARGET_DOUBLE_BIT" | |
193 | #endif | |
c25083af | 194 | #if !defined (TARGET_DOUBLE_BIT) |
0f71a2f6 JM |
195 | #define TARGET_DOUBLE_BIT (gdbarch_double_bit (current_gdbarch)) |
196 | #endif | |
0f71a2f6 | 197 | |
66b43ecb AC |
198 | /* Number of bits in a long double for the target machine. */ |
199 | ||
200 | /* Default (value) for non- multi-arch platforms. */ | |
201 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_LONG_DOUBLE_BIT) | |
17ef5d92 | 202 | #define TARGET_LONG_DOUBLE_BIT (8*TARGET_CHAR_BIT) |
66b43ecb AC |
203 | #endif |
204 | ||
104c1213 JM |
205 | extern int gdbarch_long_double_bit (struct gdbarch *gdbarch); |
206 | extern void set_gdbarch_long_double_bit (struct gdbarch *gdbarch, int long_double_bit); | |
83905903 AC |
207 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_LONG_DOUBLE_BIT) |
208 | #error "Non multi-arch definition of TARGET_LONG_DOUBLE_BIT" | |
209 | #endif | |
c25083af | 210 | #if !defined (TARGET_LONG_DOUBLE_BIT) |
0f71a2f6 JM |
211 | #define TARGET_LONG_DOUBLE_BIT (gdbarch_long_double_bit (current_gdbarch)) |
212 | #endif | |
0f71a2f6 | 213 | |
52204a0b DT |
214 | /* For most targets, a pointer on the target and its representation as an |
215 | address in GDB have the same size and "look the same". For such a | |
216 | target, you need only set TARGET_PTR_BIT / ptr_bit and TARGET_ADDR_BIT | |
217 | / addr_bit will be set from it. | |
218 | ||
219 | If TARGET_PTR_BIT and TARGET_ADDR_BIT are different, you'll probably | |
220 | also need to set POINTER_TO_ADDRESS and ADDRESS_TO_POINTER as well. | |
221 | ||
222 | ptr_bit is the size of a pointer on the target */ | |
66b43ecb AC |
223 | |
224 | /* Default (value) for non- multi-arch platforms. */ | |
225 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_PTR_BIT) | |
226 | #define TARGET_PTR_BIT (TARGET_INT_BIT) | |
227 | #endif | |
228 | ||
229 | extern int gdbarch_ptr_bit (struct gdbarch *gdbarch); | |
230 | extern void set_gdbarch_ptr_bit (struct gdbarch *gdbarch, int ptr_bit); | |
83905903 AC |
231 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_PTR_BIT) |
232 | #error "Non multi-arch definition of TARGET_PTR_BIT" | |
233 | #endif | |
c25083af | 234 | #if !defined (TARGET_PTR_BIT) |
66b43ecb AC |
235 | #define TARGET_PTR_BIT (gdbarch_ptr_bit (current_gdbarch)) |
236 | #endif | |
66b43ecb | 237 | |
52204a0b DT |
238 | /* addr_bit is the size of a target address as represented in gdb */ |
239 | ||
240 | /* Default (value) for non- multi-arch platforms. */ | |
241 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_ADDR_BIT) | |
242 | #define TARGET_ADDR_BIT (TARGET_PTR_BIT) | |
243 | #endif | |
244 | ||
245 | extern int gdbarch_addr_bit (struct gdbarch *gdbarch); | |
246 | extern void set_gdbarch_addr_bit (struct gdbarch *gdbarch, int addr_bit); | |
83905903 AC |
247 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_ADDR_BIT) |
248 | #error "Non multi-arch definition of TARGET_ADDR_BIT" | |
249 | #endif | |
c25083af | 250 | #if !defined (TARGET_ADDR_BIT) |
52204a0b DT |
251 | #define TARGET_ADDR_BIT (gdbarch_addr_bit (current_gdbarch)) |
252 | #endif | |
52204a0b | 253 | |
66b43ecb AC |
254 | /* Number of bits in a BFD_VMA for the target object file format. */ |
255 | ||
256 | /* Default (value) for non- multi-arch platforms. */ | |
257 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_BFD_VMA_BIT) | |
258 | #define TARGET_BFD_VMA_BIT (TARGET_ARCHITECTURE->bits_per_address) | |
259 | #endif | |
260 | ||
261 | extern int gdbarch_bfd_vma_bit (struct gdbarch *gdbarch); | |
262 | extern void set_gdbarch_bfd_vma_bit (struct gdbarch *gdbarch, int bfd_vma_bit); | |
83905903 AC |
263 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_BFD_VMA_BIT) |
264 | #error "Non multi-arch definition of TARGET_BFD_VMA_BIT" | |
265 | #endif | |
c25083af | 266 | #if !defined (TARGET_BFD_VMA_BIT) |
66b43ecb AC |
267 | #define TARGET_BFD_VMA_BIT (gdbarch_bfd_vma_bit (current_gdbarch)) |
268 | #endif | |
66b43ecb | 269 | |
4e409299 JB |
270 | /* One if `char' acts like `signed char', zero if `unsigned char'. */ |
271 | ||
272 | /* Default (value) for non- multi-arch platforms. */ | |
273 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_CHAR_SIGNED) | |
274 | #define TARGET_CHAR_SIGNED (1) | |
275 | #endif | |
276 | ||
277 | extern int gdbarch_char_signed (struct gdbarch *gdbarch); | |
278 | extern void set_gdbarch_char_signed (struct gdbarch *gdbarch, int char_signed); | |
279 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_CHAR_SIGNED) | |
280 | #error "Non multi-arch definition of TARGET_CHAR_SIGNED" | |
281 | #endif | |
c25083af | 282 | #if !defined (TARGET_CHAR_SIGNED) |
4e409299 JB |
283 | #define TARGET_CHAR_SIGNED (gdbarch_char_signed (current_gdbarch)) |
284 | #endif | |
4e409299 | 285 | |
be8dfb87 AC |
286 | /* Default (function) for non- multi-arch platforms. */ |
287 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_READ_PC) | |
39f77062 | 288 | #define TARGET_READ_PC(ptid) (generic_target_read_pc (ptid)) |
be8dfb87 AC |
289 | #endif |
290 | ||
39f77062 KB |
291 | typedef CORE_ADDR (gdbarch_read_pc_ftype) (ptid_t ptid); |
292 | extern CORE_ADDR gdbarch_read_pc (struct gdbarch *gdbarch, ptid_t ptid); | |
104c1213 | 293 | extern void set_gdbarch_read_pc (struct gdbarch *gdbarch, gdbarch_read_pc_ftype *read_pc); |
83905903 AC |
294 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_READ_PC) |
295 | #error "Non multi-arch definition of TARGET_READ_PC" | |
296 | #endif | |
c25083af | 297 | #if !defined (TARGET_READ_PC) |
39f77062 | 298 | #define TARGET_READ_PC(ptid) (gdbarch_read_pc (current_gdbarch, ptid)) |
0f71a2f6 | 299 | #endif |
0f71a2f6 | 300 | |
be8dfb87 AC |
301 | /* Default (function) for non- multi-arch platforms. */ |
302 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_WRITE_PC) | |
39f77062 | 303 | #define TARGET_WRITE_PC(val, ptid) (generic_target_write_pc (val, ptid)) |
be8dfb87 AC |
304 | #endif |
305 | ||
39f77062 KB |
306 | typedef void (gdbarch_write_pc_ftype) (CORE_ADDR val, ptid_t ptid); |
307 | extern void gdbarch_write_pc (struct gdbarch *gdbarch, CORE_ADDR val, ptid_t ptid); | |
104c1213 | 308 | extern void set_gdbarch_write_pc (struct gdbarch *gdbarch, gdbarch_write_pc_ftype *write_pc); |
83905903 AC |
309 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_WRITE_PC) |
310 | #error "Non multi-arch definition of TARGET_WRITE_PC" | |
311 | #endif | |
c25083af | 312 | #if !defined (TARGET_WRITE_PC) |
39f77062 | 313 | #define TARGET_WRITE_PC(val, ptid) (gdbarch_write_pc (current_gdbarch, val, ptid)) |
0f71a2f6 | 314 | #endif |
0f71a2f6 | 315 | |
0ba6dca9 AC |
316 | /* This is simply not needed. See value_of_builtin_frame_fp_reg and |
317 | call_function_by_hand. */ | |
318 | ||
319 | #if defined (DEPRECATED_TARGET_READ_FP) | |
320 | /* Legacy for systems yet to multi-arch DEPRECATED_TARGET_READ_FP */ | |
321 | #if !defined (DEPRECATED_TARGET_READ_FP_P) | |
322 | #define DEPRECATED_TARGET_READ_FP_P() (1) | |
323 | #endif | |
324 | #endif | |
325 | ||
326 | /* Default predicate for non- multi-arch targets. */ | |
327 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_TARGET_READ_FP_P) | |
328 | #define DEPRECATED_TARGET_READ_FP_P() (0) | |
329 | #endif | |
330 | ||
331 | extern int gdbarch_deprecated_target_read_fp_p (struct gdbarch *gdbarch); | |
332 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_TARGET_READ_FP_P) | |
333 | #error "Non multi-arch definition of DEPRECATED_TARGET_READ_FP" | |
334 | #endif | |
335 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_TARGET_READ_FP_P) | |
336 | #define DEPRECATED_TARGET_READ_FP_P() (gdbarch_deprecated_target_read_fp_p (current_gdbarch)) | |
337 | #endif | |
338 | ||
be8dfb87 | 339 | /* Default (function) for non- multi-arch platforms. */ |
0ba6dca9 AC |
340 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_TARGET_READ_FP) |
341 | #define DEPRECATED_TARGET_READ_FP() (internal_error (__FILE__, __LINE__, "DEPRECATED_TARGET_READ_FP"), 0) | |
be8dfb87 AC |
342 | #endif |
343 | ||
0ba6dca9 AC |
344 | typedef CORE_ADDR (gdbarch_deprecated_target_read_fp_ftype) (void); |
345 | extern CORE_ADDR gdbarch_deprecated_target_read_fp (struct gdbarch *gdbarch); | |
346 | extern void set_gdbarch_deprecated_target_read_fp (struct gdbarch *gdbarch, gdbarch_deprecated_target_read_fp_ftype *deprecated_target_read_fp); | |
347 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_TARGET_READ_FP) | |
348 | #error "Non multi-arch definition of DEPRECATED_TARGET_READ_FP" | |
83905903 | 349 | #endif |
c25083af | 350 | #if !defined (DEPRECATED_TARGET_READ_FP) |
0ba6dca9 | 351 | #define DEPRECATED_TARGET_READ_FP() (gdbarch_deprecated_target_read_fp (current_gdbarch)) |
0f71a2f6 | 352 | #endif |
0f71a2f6 | 353 | |
be8dfb87 AC |
354 | /* Default (function) for non- multi-arch platforms. */ |
355 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_READ_SP) | |
356 | #define TARGET_READ_SP() (generic_target_read_sp ()) | |
357 | #endif | |
358 | ||
104c1213 JM |
359 | typedef CORE_ADDR (gdbarch_read_sp_ftype) (void); |
360 | extern CORE_ADDR gdbarch_read_sp (struct gdbarch *gdbarch); | |
361 | extern void set_gdbarch_read_sp (struct gdbarch *gdbarch, gdbarch_read_sp_ftype *read_sp); | |
83905903 AC |
362 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_READ_SP) |
363 | #error "Non multi-arch definition of TARGET_READ_SP" | |
364 | #endif | |
c25083af | 365 | #if !defined (TARGET_READ_SP) |
0f71a2f6 JM |
366 | #define TARGET_READ_SP() (gdbarch_read_sp (current_gdbarch)) |
367 | #endif | |
0f71a2f6 | 368 | |
6c0e89ed AC |
369 | /* The dummy call frame SP should be set by push_dummy_call. */ |
370 | ||
371 | #if defined (DEPRECATED_DUMMY_WRITE_SP) | |
372 | /* Legacy for systems yet to multi-arch DEPRECATED_DUMMY_WRITE_SP */ | |
373 | #if !defined (DEPRECATED_DUMMY_WRITE_SP_P) | |
374 | #define DEPRECATED_DUMMY_WRITE_SP_P() (1) | |
375 | #endif | |
376 | #endif | |
377 | ||
378 | /* Default predicate for non- multi-arch targets. */ | |
379 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_DUMMY_WRITE_SP_P) | |
380 | #define DEPRECATED_DUMMY_WRITE_SP_P() (0) | |
381 | #endif | |
382 | ||
383 | extern int gdbarch_deprecated_dummy_write_sp_p (struct gdbarch *gdbarch); | |
384 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_DUMMY_WRITE_SP_P) | |
385 | #error "Non multi-arch definition of DEPRECATED_DUMMY_WRITE_SP" | |
386 | #endif | |
387 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_DUMMY_WRITE_SP_P) | |
388 | #define DEPRECATED_DUMMY_WRITE_SP_P() (gdbarch_deprecated_dummy_write_sp_p (current_gdbarch)) | |
389 | #endif | |
390 | ||
be8dfb87 | 391 | /* Default (function) for non- multi-arch platforms. */ |
6c0e89ed AC |
392 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_DUMMY_WRITE_SP) |
393 | #define DEPRECATED_DUMMY_WRITE_SP(val) (internal_error (__FILE__, __LINE__, "DEPRECATED_DUMMY_WRITE_SP"), 0) | |
be8dfb87 AC |
394 | #endif |
395 | ||
6c0e89ed AC |
396 | typedef void (gdbarch_deprecated_dummy_write_sp_ftype) (CORE_ADDR val); |
397 | extern void gdbarch_deprecated_dummy_write_sp (struct gdbarch *gdbarch, CORE_ADDR val); | |
398 | extern void set_gdbarch_deprecated_dummy_write_sp (struct gdbarch *gdbarch, gdbarch_deprecated_dummy_write_sp_ftype *deprecated_dummy_write_sp); | |
399 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_DUMMY_WRITE_SP) | |
400 | #error "Non multi-arch definition of DEPRECATED_DUMMY_WRITE_SP" | |
83905903 | 401 | #endif |
c25083af | 402 | #if !defined (DEPRECATED_DUMMY_WRITE_SP) |
6c0e89ed | 403 | #define DEPRECATED_DUMMY_WRITE_SP(val) (gdbarch_deprecated_dummy_write_sp (current_gdbarch, val)) |
0f71a2f6 | 404 | #endif |
0f71a2f6 | 405 | |
39d4ef09 AC |
406 | /* Function for getting target's idea of a frame pointer. FIXME: GDB's |
407 | whole scheme for dealing with "frames" and "frame pointers" needs a | |
408 | serious shakedown. */ | |
409 | ||
410 | /* Default (function) for non- multi-arch platforms. */ | |
411 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_VIRTUAL_FRAME_POINTER) | |
412 | #define TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset) (legacy_virtual_frame_pointer (pc, frame_regnum, frame_offset)) | |
413 | #endif | |
414 | ||
415 | typedef void (gdbarch_virtual_frame_pointer_ftype) (CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset); | |
416 | extern void gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset); | |
417 | extern void set_gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, gdbarch_virtual_frame_pointer_ftype *virtual_frame_pointer); | |
418 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_VIRTUAL_FRAME_POINTER) | |
419 | #error "Non multi-arch definition of TARGET_VIRTUAL_FRAME_POINTER" | |
420 | #endif | |
c25083af | 421 | #if !defined (TARGET_VIRTUAL_FRAME_POINTER) |
39d4ef09 AC |
422 | #define TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset) (gdbarch_virtual_frame_pointer (current_gdbarch, pc, frame_regnum, frame_offset)) |
423 | #endif | |
39d4ef09 | 424 | |
d8124050 | 425 | extern int gdbarch_pseudo_register_read_p (struct gdbarch *gdbarch); |
61a0eb5b | 426 | |
d8124050 AC |
427 | typedef void (gdbarch_pseudo_register_read_ftype) (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, void *buf); |
428 | extern void gdbarch_pseudo_register_read (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, void *buf); | |
429 | extern void set_gdbarch_pseudo_register_read (struct gdbarch *gdbarch, gdbarch_pseudo_register_read_ftype *pseudo_register_read); | |
61a0eb5b | 430 | |
d8124050 | 431 | extern int gdbarch_pseudo_register_write_p (struct gdbarch *gdbarch); |
61a0eb5b | 432 | |
d8124050 AC |
433 | typedef void (gdbarch_pseudo_register_write_ftype) (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, const void *buf); |
434 | extern void gdbarch_pseudo_register_write (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, const void *buf); | |
435 | extern void set_gdbarch_pseudo_register_write (struct gdbarch *gdbarch, gdbarch_pseudo_register_write_ftype *pseudo_register_write); | |
61a0eb5b | 436 | |
104c1213 JM |
437 | extern int gdbarch_num_regs (struct gdbarch *gdbarch); |
438 | extern void set_gdbarch_num_regs (struct gdbarch *gdbarch, int num_regs); | |
83905903 AC |
439 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (NUM_REGS) |
440 | #error "Non multi-arch definition of NUM_REGS" | |
441 | #endif | |
c25083af | 442 | #if !defined (NUM_REGS) |
0f71a2f6 JM |
443 | #define NUM_REGS (gdbarch_num_regs (current_gdbarch)) |
444 | #endif | |
0f71a2f6 | 445 | |
34620563 AC |
446 | /* This macro gives the number of pseudo-registers that live in the |
447 | register namespace but do not get fetched or stored on the target. | |
448 | These pseudo-registers may be aliases for other registers, | |
449 | combinations of other registers, or they may be computed by GDB. */ | |
450 | ||
0aba1244 | 451 | /* Default (value) for non- multi-arch platforms. */ |
6166d547 | 452 | #if (!GDB_MULTI_ARCH) && !defined (NUM_PSEUDO_REGS) |
0aba1244 EZ |
453 | #define NUM_PSEUDO_REGS (0) |
454 | #endif | |
455 | ||
456 | extern int gdbarch_num_pseudo_regs (struct gdbarch *gdbarch); | |
457 | extern void set_gdbarch_num_pseudo_regs (struct gdbarch *gdbarch, int num_pseudo_regs); | |
83905903 AC |
458 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (NUM_PSEUDO_REGS) |
459 | #error "Non multi-arch definition of NUM_PSEUDO_REGS" | |
460 | #endif | |
c25083af | 461 | #if !defined (NUM_PSEUDO_REGS) |
0aba1244 EZ |
462 | #define NUM_PSEUDO_REGS (gdbarch_num_pseudo_regs (current_gdbarch)) |
463 | #endif | |
0aba1244 | 464 | |
c2169756 AC |
465 | /* GDB's standard (or well known) register numbers. These can map onto |
466 | a real register or a pseudo (computed) register or not be defined at | |
1200cd6e AC |
467 | all (-1). */ |
468 | ||
469 | /* Default (value) for non- multi-arch platforms. */ | |
470 | #if (!GDB_MULTI_ARCH) && !defined (SP_REGNUM) | |
471 | #define SP_REGNUM (-1) | |
472 | #endif | |
c2169756 | 473 | |
104c1213 JM |
474 | extern int gdbarch_sp_regnum (struct gdbarch *gdbarch); |
475 | extern void set_gdbarch_sp_regnum (struct gdbarch *gdbarch, int sp_regnum); | |
83905903 AC |
476 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SP_REGNUM) |
477 | #error "Non multi-arch definition of SP_REGNUM" | |
478 | #endif | |
c25083af | 479 | #if !defined (SP_REGNUM) |
0f71a2f6 JM |
480 | #define SP_REGNUM (gdbarch_sp_regnum (current_gdbarch)) |
481 | #endif | |
0f71a2f6 | 482 | |
0ba6dca9 AC |
483 | /* This is simply not needed. See value_of_builtin_frame_fp_reg and |
484 | call_function_by_hand. */ | |
485 | ||
1200cd6e | 486 | /* Default (value) for non- multi-arch platforms. */ |
0ba6dca9 AC |
487 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FP_REGNUM) |
488 | #define DEPRECATED_FP_REGNUM (-1) | |
1200cd6e AC |
489 | #endif |
490 | ||
0ba6dca9 AC |
491 | extern int gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch); |
492 | extern void set_gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch, int deprecated_fp_regnum); | |
493 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FP_REGNUM) | |
494 | #error "Non multi-arch definition of DEPRECATED_FP_REGNUM" | |
83905903 | 495 | #endif |
c25083af | 496 | #if !defined (DEPRECATED_FP_REGNUM) |
0ba6dca9 | 497 | #define DEPRECATED_FP_REGNUM (gdbarch_deprecated_fp_regnum (current_gdbarch)) |
0f71a2f6 | 498 | #endif |
0f71a2f6 | 499 | |
1200cd6e AC |
500 | /* Default (value) for non- multi-arch platforms. */ |
501 | #if (!GDB_MULTI_ARCH) && !defined (PC_REGNUM) | |
502 | #define PC_REGNUM (-1) | |
503 | #endif | |
504 | ||
104c1213 JM |
505 | extern int gdbarch_pc_regnum (struct gdbarch *gdbarch); |
506 | extern void set_gdbarch_pc_regnum (struct gdbarch *gdbarch, int pc_regnum); | |
83905903 AC |
507 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (PC_REGNUM) |
508 | #error "Non multi-arch definition of PC_REGNUM" | |
509 | #endif | |
c25083af | 510 | #if !defined (PC_REGNUM) |
0f71a2f6 JM |
511 | #define PC_REGNUM (gdbarch_pc_regnum (current_gdbarch)) |
512 | #endif | |
0f71a2f6 | 513 | |
c2169756 AC |
514 | /* Default (value) for non- multi-arch platforms. */ |
515 | #if (!GDB_MULTI_ARCH) && !defined (PS_REGNUM) | |
516 | #define PS_REGNUM (-1) | |
517 | #endif | |
518 | ||
519 | extern int gdbarch_ps_regnum (struct gdbarch *gdbarch); | |
520 | extern void set_gdbarch_ps_regnum (struct gdbarch *gdbarch, int ps_regnum); | |
521 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (PS_REGNUM) | |
522 | #error "Non multi-arch definition of PS_REGNUM" | |
523 | #endif | |
c25083af | 524 | #if !defined (PS_REGNUM) |
c2169756 AC |
525 | #define PS_REGNUM (gdbarch_ps_regnum (current_gdbarch)) |
526 | #endif | |
c2169756 | 527 | |
60054393 | 528 | /* Default (value) for non- multi-arch platforms. */ |
6166d547 | 529 | #if (!GDB_MULTI_ARCH) && !defined (FP0_REGNUM) |
60054393 MS |
530 | #define FP0_REGNUM (-1) |
531 | #endif | |
532 | ||
533 | extern int gdbarch_fp0_regnum (struct gdbarch *gdbarch); | |
534 | extern void set_gdbarch_fp0_regnum (struct gdbarch *gdbarch, int fp0_regnum); | |
83905903 AC |
535 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (FP0_REGNUM) |
536 | #error "Non multi-arch definition of FP0_REGNUM" | |
537 | #endif | |
c25083af | 538 | #if !defined (FP0_REGNUM) |
60054393 MS |
539 | #define FP0_REGNUM (gdbarch_fp0_regnum (current_gdbarch)) |
540 | #endif | |
60054393 | 541 | |
03863182 | 542 | /* Default (value) for non- multi-arch platforms. */ |
6166d547 | 543 | #if (!GDB_MULTI_ARCH) && !defined (NPC_REGNUM) |
03863182 AC |
544 | #define NPC_REGNUM (-1) |
545 | #endif | |
546 | ||
547 | extern int gdbarch_npc_regnum (struct gdbarch *gdbarch); | |
548 | extern void set_gdbarch_npc_regnum (struct gdbarch *gdbarch, int npc_regnum); | |
83905903 AC |
549 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (NPC_REGNUM) |
550 | #error "Non multi-arch definition of NPC_REGNUM" | |
551 | #endif | |
c25083af | 552 | #if !defined (NPC_REGNUM) |
03863182 AC |
553 | #define NPC_REGNUM (gdbarch_npc_regnum (current_gdbarch)) |
554 | #endif | |
03863182 | 555 | |
88c72b7d AC |
556 | /* Convert stab register number (from `r' declaration) to a gdb REGNUM. */ |
557 | ||
558 | /* Default (function) for non- multi-arch platforms. */ | |
559 | #if (!GDB_MULTI_ARCH) && !defined (STAB_REG_TO_REGNUM) | |
560 | #define STAB_REG_TO_REGNUM(stab_regnr) (no_op_reg_to_regnum (stab_regnr)) | |
561 | #endif | |
562 | ||
563 | typedef int (gdbarch_stab_reg_to_regnum_ftype) (int stab_regnr); | |
564 | extern int gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, int stab_regnr); | |
565 | extern void set_gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, gdbarch_stab_reg_to_regnum_ftype *stab_reg_to_regnum); | |
83905903 AC |
566 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (STAB_REG_TO_REGNUM) |
567 | #error "Non multi-arch definition of STAB_REG_TO_REGNUM" | |
568 | #endif | |
c25083af | 569 | #if !defined (STAB_REG_TO_REGNUM) |
88c72b7d AC |
570 | #define STAB_REG_TO_REGNUM(stab_regnr) (gdbarch_stab_reg_to_regnum (current_gdbarch, stab_regnr)) |
571 | #endif | |
88c72b7d AC |
572 | |
573 | /* Provide a default mapping from a ecoff register number to a gdb REGNUM. */ | |
574 | ||
575 | /* Default (function) for non- multi-arch platforms. */ | |
576 | #if (!GDB_MULTI_ARCH) && !defined (ECOFF_REG_TO_REGNUM) | |
577 | #define ECOFF_REG_TO_REGNUM(ecoff_regnr) (no_op_reg_to_regnum (ecoff_regnr)) | |
578 | #endif | |
579 | ||
580 | typedef int (gdbarch_ecoff_reg_to_regnum_ftype) (int ecoff_regnr); | |
581 | extern int gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, int ecoff_regnr); | |
582 | extern void set_gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, gdbarch_ecoff_reg_to_regnum_ftype *ecoff_reg_to_regnum); | |
83905903 AC |
583 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (ECOFF_REG_TO_REGNUM) |
584 | #error "Non multi-arch definition of ECOFF_REG_TO_REGNUM" | |
585 | #endif | |
c25083af | 586 | #if !defined (ECOFF_REG_TO_REGNUM) |
88c72b7d AC |
587 | #define ECOFF_REG_TO_REGNUM(ecoff_regnr) (gdbarch_ecoff_reg_to_regnum (current_gdbarch, ecoff_regnr)) |
588 | #endif | |
88c72b7d AC |
589 | |
590 | /* Provide a default mapping from a DWARF register number to a gdb REGNUM. */ | |
591 | ||
592 | /* Default (function) for non- multi-arch platforms. */ | |
593 | #if (!GDB_MULTI_ARCH) && !defined (DWARF_REG_TO_REGNUM) | |
594 | #define DWARF_REG_TO_REGNUM(dwarf_regnr) (no_op_reg_to_regnum (dwarf_regnr)) | |
595 | #endif | |
596 | ||
597 | typedef int (gdbarch_dwarf_reg_to_regnum_ftype) (int dwarf_regnr); | |
598 | extern int gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch, int dwarf_regnr); | |
599 | extern void set_gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch, gdbarch_dwarf_reg_to_regnum_ftype *dwarf_reg_to_regnum); | |
83905903 AC |
600 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DWARF_REG_TO_REGNUM) |
601 | #error "Non multi-arch definition of DWARF_REG_TO_REGNUM" | |
602 | #endif | |
c25083af | 603 | #if !defined (DWARF_REG_TO_REGNUM) |
88c72b7d AC |
604 | #define DWARF_REG_TO_REGNUM(dwarf_regnr) (gdbarch_dwarf_reg_to_regnum (current_gdbarch, dwarf_regnr)) |
605 | #endif | |
88c72b7d AC |
606 | |
607 | /* Convert from an sdb register number to an internal gdb register number. | |
608 | This should be defined in tm.h, if REGISTER_NAMES is not set up | |
609 | to map one to one onto the sdb register numbers. */ | |
610 | ||
611 | /* Default (function) for non- multi-arch platforms. */ | |
612 | #if (!GDB_MULTI_ARCH) && !defined (SDB_REG_TO_REGNUM) | |
613 | #define SDB_REG_TO_REGNUM(sdb_regnr) (no_op_reg_to_regnum (sdb_regnr)) | |
614 | #endif | |
615 | ||
616 | typedef int (gdbarch_sdb_reg_to_regnum_ftype) (int sdb_regnr); | |
617 | extern int gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, int sdb_regnr); | |
618 | extern void set_gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, gdbarch_sdb_reg_to_regnum_ftype *sdb_reg_to_regnum); | |
83905903 AC |
619 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SDB_REG_TO_REGNUM) |
620 | #error "Non multi-arch definition of SDB_REG_TO_REGNUM" | |
621 | #endif | |
c25083af | 622 | #if !defined (SDB_REG_TO_REGNUM) |
88c72b7d AC |
623 | #define SDB_REG_TO_REGNUM(sdb_regnr) (gdbarch_sdb_reg_to_regnum (current_gdbarch, sdb_regnr)) |
624 | #endif | |
88c72b7d AC |
625 | |
626 | /* Default (function) for non- multi-arch platforms. */ | |
627 | #if (!GDB_MULTI_ARCH) && !defined (DWARF2_REG_TO_REGNUM) | |
628 | #define DWARF2_REG_TO_REGNUM(dwarf2_regnr) (no_op_reg_to_regnum (dwarf2_regnr)) | |
629 | #endif | |
630 | ||
631 | typedef int (gdbarch_dwarf2_reg_to_regnum_ftype) (int dwarf2_regnr); | |
632 | extern int gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, int dwarf2_regnr); | |
633 | extern void set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum); | |
83905903 AC |
634 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DWARF2_REG_TO_REGNUM) |
635 | #error "Non multi-arch definition of DWARF2_REG_TO_REGNUM" | |
636 | #endif | |
c25083af | 637 | #if !defined (DWARF2_REG_TO_REGNUM) |
88c72b7d AC |
638 | #define DWARF2_REG_TO_REGNUM(dwarf2_regnr) (gdbarch_dwarf2_reg_to_regnum (current_gdbarch, dwarf2_regnr)) |
639 | #endif | |
88c72b7d | 640 | |
33489c5b | 641 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 642 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_NAME) |
33489c5b AC |
643 | #define REGISTER_NAME(regnr) (legacy_register_name (regnr)) |
644 | #endif | |
645 | ||
fa88f677 AC |
646 | typedef const char * (gdbarch_register_name_ftype) (int regnr); |
647 | extern const char * gdbarch_register_name (struct gdbarch *gdbarch, int regnr); | |
104c1213 | 648 | extern void set_gdbarch_register_name (struct gdbarch *gdbarch, gdbarch_register_name_ftype *register_name); |
83905903 AC |
649 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_NAME) |
650 | #error "Non multi-arch definition of REGISTER_NAME" | |
651 | #endif | |
c25083af | 652 | #if !defined (REGISTER_NAME) |
0f71a2f6 JM |
653 | #define REGISTER_NAME(regnr) (gdbarch_register_name (current_gdbarch, regnr)) |
654 | #endif | |
0f71a2f6 | 655 | |
b1e29e33 AC |
656 | extern int gdbarch_deprecated_register_size (struct gdbarch *gdbarch); |
657 | extern void set_gdbarch_deprecated_register_size (struct gdbarch *gdbarch, int deprecated_register_size); | |
658 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_SIZE) | |
659 | #error "Non multi-arch definition of DEPRECATED_REGISTER_SIZE" | |
83905903 | 660 | #endif |
b1e29e33 AC |
661 | #if !defined (DEPRECATED_REGISTER_SIZE) |
662 | #define DEPRECATED_REGISTER_SIZE (gdbarch_deprecated_register_size (current_gdbarch)) | |
0f71a2f6 | 663 | #endif |
0f71a2f6 | 664 | |
b8b527c5 AC |
665 | extern int gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch); |
666 | extern void set_gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch, int deprecated_register_bytes); | |
667 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_BYTES) | |
668 | #error "Non multi-arch definition of DEPRECATED_REGISTER_BYTES" | |
83905903 | 669 | #endif |
b8b527c5 AC |
670 | #if !defined (DEPRECATED_REGISTER_BYTES) |
671 | #define DEPRECATED_REGISTER_BYTES (gdbarch_deprecated_register_bytes (current_gdbarch)) | |
0f71a2f6 | 672 | #endif |
0f71a2f6 | 673 | |
46654a5b AC |
674 | /* NOTE: cagney/2002-05-02: This function with predicate has a valid |
675 | (callable) initial value. As a consequence, even when the predicate | |
676 | is false, the corresponding function works. This simplifies the | |
677 | migration process - old code, calling REGISTER_BYTE, doesn't need to | |
678 | be modified. */ | |
679 | ||
680 | #if defined (REGISTER_BYTE) | |
681 | /* Legacy for systems yet to multi-arch REGISTER_BYTE */ | |
682 | #if !defined (REGISTER_BYTE_P) | |
683 | #define REGISTER_BYTE_P() (1) | |
684 | #endif | |
685 | #endif | |
686 | ||
687 | /* Default predicate for non- multi-arch targets. */ | |
688 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_BYTE_P) | |
689 | #define REGISTER_BYTE_P() (0) | |
690 | #endif | |
691 | ||
692 | extern int gdbarch_register_byte_p (struct gdbarch *gdbarch); | |
693 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_BYTE_P) | |
694 | #error "Non multi-arch definition of REGISTER_BYTE" | |
695 | #endif | |
696 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (REGISTER_BYTE_P) | |
697 | #define REGISTER_BYTE_P() (gdbarch_register_byte_p (current_gdbarch)) | |
698 | #endif | |
699 | ||
a7e3c2ad AC |
700 | /* Default (function) for non- multi-arch platforms. */ |
701 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_BYTE) | |
702 | #define REGISTER_BYTE(reg_nr) (generic_register_byte (reg_nr)) | |
703 | #endif | |
704 | ||
104c1213 JM |
705 | typedef int (gdbarch_register_byte_ftype) (int reg_nr); |
706 | extern int gdbarch_register_byte (struct gdbarch *gdbarch, int reg_nr); | |
707 | extern void set_gdbarch_register_byte (struct gdbarch *gdbarch, gdbarch_register_byte_ftype *register_byte); | |
83905903 AC |
708 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_BYTE) |
709 | #error "Non multi-arch definition of REGISTER_BYTE" | |
710 | #endif | |
c25083af | 711 | #if !defined (REGISTER_BYTE) |
0f71a2f6 JM |
712 | #define REGISTER_BYTE(reg_nr) (gdbarch_register_byte (current_gdbarch, reg_nr)) |
713 | #endif | |
0f71a2f6 | 714 | |
0c92afe8 AC |
715 | /* The methods REGISTER_VIRTUAL_TYPE, REGISTER_VIRTUAL_SIZE and |
716 | REGISTER_RAW_SIZE are all being replaced by REGISTER_TYPE. */ | |
35cac7cf | 717 | |
b2e75d78 AC |
718 | /* Default (function) for non- multi-arch platforms. */ |
719 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_RAW_SIZE) | |
720 | #define REGISTER_RAW_SIZE(reg_nr) (generic_register_size (reg_nr)) | |
721 | #endif | |
722 | ||
104c1213 JM |
723 | typedef int (gdbarch_register_raw_size_ftype) (int reg_nr); |
724 | extern int gdbarch_register_raw_size (struct gdbarch *gdbarch, int reg_nr); | |
725 | extern void set_gdbarch_register_raw_size (struct gdbarch *gdbarch, gdbarch_register_raw_size_ftype *register_raw_size); | |
83905903 AC |
726 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_RAW_SIZE) |
727 | #error "Non multi-arch definition of REGISTER_RAW_SIZE" | |
728 | #endif | |
c25083af | 729 | #if !defined (REGISTER_RAW_SIZE) |
0f71a2f6 JM |
730 | #define REGISTER_RAW_SIZE(reg_nr) (gdbarch_register_raw_size (current_gdbarch, reg_nr)) |
731 | #endif | |
0f71a2f6 | 732 | |
d9d9c31f AC |
733 | /* The methods DEPRECATED_MAX_REGISTER_RAW_SIZE and |
734 | DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE are all being replaced by | |
735 | MAX_REGISTER_SIZE (a constant). */ | |
35cac7cf | 736 | |
a0ed5532 AC |
737 | #if defined (DEPRECATED_MAX_REGISTER_RAW_SIZE) |
738 | /* Legacy for systems yet to multi-arch DEPRECATED_MAX_REGISTER_RAW_SIZE */ | |
739 | #if !defined (DEPRECATED_MAX_REGISTER_RAW_SIZE_P) | |
740 | #define DEPRECATED_MAX_REGISTER_RAW_SIZE_P() (1) | |
741 | #endif | |
742 | #endif | |
743 | ||
744 | /* Default predicate for non- multi-arch targets. */ | |
745 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_MAX_REGISTER_RAW_SIZE_P) | |
746 | #define DEPRECATED_MAX_REGISTER_RAW_SIZE_P() (0) | |
747 | #endif | |
748 | ||
749 | extern int gdbarch_deprecated_max_register_raw_size_p (struct gdbarch *gdbarch); | |
750 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_MAX_REGISTER_RAW_SIZE_P) | |
751 | #error "Non multi-arch definition of DEPRECATED_MAX_REGISTER_RAW_SIZE" | |
752 | #endif | |
753 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_MAX_REGISTER_RAW_SIZE_P) | |
754 | #define DEPRECATED_MAX_REGISTER_RAW_SIZE_P() (gdbarch_deprecated_max_register_raw_size_p (current_gdbarch)) | |
755 | #endif | |
756 | ||
757 | /* Default (value) for non- multi-arch platforms. */ | |
758 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_MAX_REGISTER_RAW_SIZE) | |
759 | #define DEPRECATED_MAX_REGISTER_RAW_SIZE (0) | |
760 | #endif | |
761 | ||
762 | extern int gdbarch_deprecated_max_register_raw_size (struct gdbarch *gdbarch); | |
763 | extern void set_gdbarch_deprecated_max_register_raw_size (struct gdbarch *gdbarch, int deprecated_max_register_raw_size); | |
764 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_MAX_REGISTER_RAW_SIZE) | |
765 | #error "Non multi-arch definition of DEPRECATED_MAX_REGISTER_RAW_SIZE" | |
83905903 | 766 | #endif |
c25083af | 767 | #if !defined (DEPRECATED_MAX_REGISTER_RAW_SIZE) |
a0ed5532 | 768 | #define DEPRECATED_MAX_REGISTER_RAW_SIZE (gdbarch_deprecated_max_register_raw_size (current_gdbarch)) |
0f71a2f6 | 769 | #endif |
0f71a2f6 | 770 | |
0c92afe8 AC |
771 | /* The methods REGISTER_VIRTUAL_TYPE, REGISTER_VIRTUAL_SIZE and |
772 | REGISTER_RAW_SIZE are all being replaced by REGISTER_TYPE. */ | |
35cac7cf | 773 | |
b2e75d78 AC |
774 | /* Default (function) for non- multi-arch platforms. */ |
775 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_VIRTUAL_SIZE) | |
776 | #define REGISTER_VIRTUAL_SIZE(reg_nr) (generic_register_size (reg_nr)) | |
777 | #endif | |
778 | ||
104c1213 JM |
779 | typedef int (gdbarch_register_virtual_size_ftype) (int reg_nr); |
780 | extern int gdbarch_register_virtual_size (struct gdbarch *gdbarch, int reg_nr); | |
781 | extern void set_gdbarch_register_virtual_size (struct gdbarch *gdbarch, gdbarch_register_virtual_size_ftype *register_virtual_size); | |
83905903 AC |
782 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_VIRTUAL_SIZE) |
783 | #error "Non multi-arch definition of REGISTER_VIRTUAL_SIZE" | |
784 | #endif | |
c25083af | 785 | #if !defined (REGISTER_VIRTUAL_SIZE) |
0f71a2f6 JM |
786 | #define REGISTER_VIRTUAL_SIZE(reg_nr) (gdbarch_register_virtual_size (current_gdbarch, reg_nr)) |
787 | #endif | |
0f71a2f6 | 788 | |
d9d9c31f AC |
789 | /* The methods DEPRECATED_MAX_REGISTER_RAW_SIZE and |
790 | DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE are all being replaced by | |
791 | MAX_REGISTER_SIZE (a constant). */ | |
35cac7cf | 792 | |
a0ed5532 AC |
793 | #if defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE) |
794 | /* Legacy for systems yet to multi-arch DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE */ | |
795 | #if !defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P) | |
796 | #define DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P() (1) | |
797 | #endif | |
798 | #endif | |
799 | ||
800 | /* Default predicate for non- multi-arch targets. */ | |
801 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P) | |
802 | #define DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P() (0) | |
803 | #endif | |
804 | ||
805 | extern int gdbarch_deprecated_max_register_virtual_size_p (struct gdbarch *gdbarch); | |
806 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P) | |
807 | #error "Non multi-arch definition of DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE" | |
808 | #endif | |
809 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P) | |
810 | #define DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P() (gdbarch_deprecated_max_register_virtual_size_p (current_gdbarch)) | |
811 | #endif | |
812 | ||
813 | /* Default (value) for non- multi-arch platforms. */ | |
814 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE) | |
815 | #define DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE (0) | |
816 | #endif | |
817 | ||
818 | extern int gdbarch_deprecated_max_register_virtual_size (struct gdbarch *gdbarch); | |
819 | extern void set_gdbarch_deprecated_max_register_virtual_size (struct gdbarch *gdbarch, int deprecated_max_register_virtual_size); | |
820 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE) | |
821 | #error "Non multi-arch definition of DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE" | |
83905903 | 822 | #endif |
c25083af | 823 | #if !defined (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE) |
a0ed5532 | 824 | #define DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE (gdbarch_deprecated_max_register_virtual_size (current_gdbarch)) |
0f71a2f6 | 825 | #endif |
0f71a2f6 | 826 | |
0c92afe8 AC |
827 | /* The methods REGISTER_VIRTUAL_TYPE, REGISTER_VIRTUAL_SIZE and |
828 | REGISTER_RAW_SIZE are all being replaced by REGISTER_TYPE. */ | |
35cac7cf AC |
829 | |
830 | #if defined (REGISTER_VIRTUAL_TYPE) | |
831 | /* Legacy for systems yet to multi-arch REGISTER_VIRTUAL_TYPE */ | |
832 | #if !defined (REGISTER_VIRTUAL_TYPE_P) | |
833 | #define REGISTER_VIRTUAL_TYPE_P() (1) | |
834 | #endif | |
835 | #endif | |
836 | ||
837 | /* Default predicate for non- multi-arch targets. */ | |
838 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_VIRTUAL_TYPE_P) | |
839 | #define REGISTER_VIRTUAL_TYPE_P() (0) | |
840 | #endif | |
841 | ||
842 | extern int gdbarch_register_virtual_type_p (struct gdbarch *gdbarch); | |
843 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_VIRTUAL_TYPE_P) | |
844 | #error "Non multi-arch definition of REGISTER_VIRTUAL_TYPE" | |
845 | #endif | |
846 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (REGISTER_VIRTUAL_TYPE_P) | |
847 | #define REGISTER_VIRTUAL_TYPE_P() (gdbarch_register_virtual_type_p (current_gdbarch)) | |
848 | #endif | |
849 | ||
850 | /* Default (function) for non- multi-arch platforms. */ | |
851 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_VIRTUAL_TYPE) | |
852 | #define REGISTER_VIRTUAL_TYPE(reg_nr) (internal_error (__FILE__, __LINE__, "REGISTER_VIRTUAL_TYPE"), 0) | |
853 | #endif | |
854 | ||
104c1213 JM |
855 | typedef struct type * (gdbarch_register_virtual_type_ftype) (int reg_nr); |
856 | extern struct type * gdbarch_register_virtual_type (struct gdbarch *gdbarch, int reg_nr); | |
857 | extern void set_gdbarch_register_virtual_type (struct gdbarch *gdbarch, gdbarch_register_virtual_type_ftype *register_virtual_type); | |
83905903 AC |
858 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_VIRTUAL_TYPE) |
859 | #error "Non multi-arch definition of REGISTER_VIRTUAL_TYPE" | |
860 | #endif | |
c25083af | 861 | #if !defined (REGISTER_VIRTUAL_TYPE) |
0f71a2f6 JM |
862 | #define REGISTER_VIRTUAL_TYPE(reg_nr) (gdbarch_register_virtual_type (current_gdbarch, reg_nr)) |
863 | #endif | |
0f71a2f6 | 864 | |
35cac7cf AC |
865 | extern int gdbarch_register_type_p (struct gdbarch *gdbarch); |
866 | ||
867 | typedef struct type * (gdbarch_register_type_ftype) (struct gdbarch *gdbarch, int reg_nr); | |
868 | extern struct type * gdbarch_register_type (struct gdbarch *gdbarch, int reg_nr); | |
869 | extern void set_gdbarch_register_type (struct gdbarch *gdbarch, gdbarch_register_type_ftype *register_type); | |
870 | ||
903ad3a6 AC |
871 | #if defined (DEPRECATED_DO_REGISTERS_INFO) |
872 | /* Legacy for systems yet to multi-arch DEPRECATED_DO_REGISTERS_INFO */ | |
873 | #if !defined (DEPRECATED_DO_REGISTERS_INFO_P) | |
874 | #define DEPRECATED_DO_REGISTERS_INFO_P() (1) | |
0ab7a791 AC |
875 | #endif |
876 | #endif | |
877 | ||
878 | /* Default predicate for non- multi-arch targets. */ | |
903ad3a6 AC |
879 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_DO_REGISTERS_INFO_P) |
880 | #define DEPRECATED_DO_REGISTERS_INFO_P() (0) | |
0ab7a791 AC |
881 | #endif |
882 | ||
903ad3a6 AC |
883 | extern int gdbarch_deprecated_do_registers_info_p (struct gdbarch *gdbarch); |
884 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_DO_REGISTERS_INFO_P) | |
885 | #error "Non multi-arch definition of DEPRECATED_DO_REGISTERS_INFO" | |
0ab7a791 | 886 | #endif |
903ad3a6 AC |
887 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_DO_REGISTERS_INFO_P) |
888 | #define DEPRECATED_DO_REGISTERS_INFO_P() (gdbarch_deprecated_do_registers_info_p (current_gdbarch)) | |
0ab7a791 AC |
889 | #endif |
890 | ||
666e11c5 | 891 | /* Default (function) for non- multi-arch platforms. */ |
903ad3a6 AC |
892 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_DO_REGISTERS_INFO) |
893 | #define DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs) (internal_error (__FILE__, __LINE__, "DEPRECATED_DO_REGISTERS_INFO"), 0) | |
666e11c5 EZ |
894 | #endif |
895 | ||
903ad3a6 AC |
896 | typedef void (gdbarch_deprecated_do_registers_info_ftype) (int reg_nr, int fpregs); |
897 | extern void gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, int reg_nr, int fpregs); | |
898 | extern void set_gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, gdbarch_deprecated_do_registers_info_ftype *deprecated_do_registers_info); | |
899 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_DO_REGISTERS_INFO) | |
900 | #error "Non multi-arch definition of DEPRECATED_DO_REGISTERS_INFO" | |
83905903 | 901 | #endif |
c25083af | 902 | #if !defined (DEPRECATED_DO_REGISTERS_INFO) |
903ad3a6 | 903 | #define DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs) (gdbarch_deprecated_do_registers_info (current_gdbarch, reg_nr, fpregs)) |
666e11c5 | 904 | #endif |
666e11c5 | 905 | |
0ab7a791 AC |
906 | typedef void (gdbarch_print_registers_info_ftype) (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int all); |
907 | extern void gdbarch_print_registers_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int all); | |
908 | extern void set_gdbarch_print_registers_info (struct gdbarch *gdbarch, gdbarch_print_registers_info_ftype *print_registers_info); | |
909 | ||
23e3a7ac AC |
910 | extern int gdbarch_print_float_info_p (struct gdbarch *gdbarch); |
911 | ||
912 | typedef void (gdbarch_print_float_info_ftype) (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args); | |
913 | extern void gdbarch_print_float_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args); | |
5e74b15c | 914 | extern void set_gdbarch_print_float_info (struct gdbarch *gdbarch, gdbarch_print_float_info_ftype *print_float_info); |
5e74b15c | 915 | |
e76f1f2e AC |
916 | extern int gdbarch_print_vector_info_p (struct gdbarch *gdbarch); |
917 | ||
918 | typedef void (gdbarch_print_vector_info_ftype) (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args); | |
919 | extern void gdbarch_print_vector_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args); | |
920 | extern void set_gdbarch_print_vector_info (struct gdbarch *gdbarch, gdbarch_print_vector_info_ftype *print_vector_info); | |
921 | ||
7c7651b2 AC |
922 | /* MAP a GDB RAW register number onto a simulator register number. See |
923 | also include/...-sim.h. */ | |
924 | ||
925 | /* Default (function) for non- multi-arch platforms. */ | |
926 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_SIM_REGNO) | |
8238d0bf | 927 | #define REGISTER_SIM_REGNO(reg_nr) (legacy_register_sim_regno (reg_nr)) |
7c7651b2 AC |
928 | #endif |
929 | ||
930 | typedef int (gdbarch_register_sim_regno_ftype) (int reg_nr); | |
931 | extern int gdbarch_register_sim_regno (struct gdbarch *gdbarch, int reg_nr); | |
932 | extern void set_gdbarch_register_sim_regno (struct gdbarch *gdbarch, gdbarch_register_sim_regno_ftype *register_sim_regno); | |
83905903 AC |
933 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_SIM_REGNO) |
934 | #error "Non multi-arch definition of REGISTER_SIM_REGNO" | |
935 | #endif | |
c25083af | 936 | #if !defined (REGISTER_SIM_REGNO) |
7c7651b2 AC |
937 | #define REGISTER_SIM_REGNO(reg_nr) (gdbarch_register_sim_regno (current_gdbarch, reg_nr)) |
938 | #endif | |
7c7651b2 | 939 | |
2649061d AC |
940 | #if defined (REGISTER_BYTES_OK) |
941 | /* Legacy for systems yet to multi-arch REGISTER_BYTES_OK */ | |
eee30e78 | 942 | #if !defined (REGISTER_BYTES_OK_P) |
2649061d AC |
943 | #define REGISTER_BYTES_OK_P() (1) |
944 | #endif | |
eee30e78 | 945 | #endif |
2649061d AC |
946 | |
947 | /* Default predicate for non- multi-arch targets. */ | |
948 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_BYTES_OK_P) | |
949 | #define REGISTER_BYTES_OK_P() (0) | |
950 | #endif | |
951 | ||
952 | extern int gdbarch_register_bytes_ok_p (struct gdbarch *gdbarch); | |
83905903 AC |
953 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_BYTES_OK_P) |
954 | #error "Non multi-arch definition of REGISTER_BYTES_OK" | |
955 | #endif | |
2649061d AC |
956 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (REGISTER_BYTES_OK_P) |
957 | #define REGISTER_BYTES_OK_P() (gdbarch_register_bytes_ok_p (current_gdbarch)) | |
958 | #endif | |
959 | ||
960 | /* Default (function) for non- multi-arch platforms. */ | |
961 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_BYTES_OK) | |
8e65ff28 | 962 | #define REGISTER_BYTES_OK(nr_bytes) (internal_error (__FILE__, __LINE__, "REGISTER_BYTES_OK"), 0) |
2649061d AC |
963 | #endif |
964 | ||
965 | typedef int (gdbarch_register_bytes_ok_ftype) (long nr_bytes); | |
966 | extern int gdbarch_register_bytes_ok (struct gdbarch *gdbarch, long nr_bytes); | |
967 | extern void set_gdbarch_register_bytes_ok (struct gdbarch *gdbarch, gdbarch_register_bytes_ok_ftype *register_bytes_ok); | |
83905903 AC |
968 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_BYTES_OK) |
969 | #error "Non multi-arch definition of REGISTER_BYTES_OK" | |
970 | #endif | |
c25083af | 971 | #if !defined (REGISTER_BYTES_OK) |
2649061d AC |
972 | #define REGISTER_BYTES_OK(nr_bytes) (gdbarch_register_bytes_ok (current_gdbarch, nr_bytes)) |
973 | #endif | |
2649061d | 974 | |
01fb7433 AC |
975 | /* Default (function) for non- multi-arch platforms. */ |
976 | #if (!GDB_MULTI_ARCH) && !defined (CANNOT_FETCH_REGISTER) | |
977 | #define CANNOT_FETCH_REGISTER(regnum) (cannot_register_not (regnum)) | |
978 | #endif | |
979 | ||
980 | typedef int (gdbarch_cannot_fetch_register_ftype) (int regnum); | |
981 | extern int gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, int regnum); | |
982 | extern void set_gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, gdbarch_cannot_fetch_register_ftype *cannot_fetch_register); | |
83905903 AC |
983 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (CANNOT_FETCH_REGISTER) |
984 | #error "Non multi-arch definition of CANNOT_FETCH_REGISTER" | |
985 | #endif | |
c25083af | 986 | #if !defined (CANNOT_FETCH_REGISTER) |
01fb7433 AC |
987 | #define CANNOT_FETCH_REGISTER(regnum) (gdbarch_cannot_fetch_register (current_gdbarch, regnum)) |
988 | #endif | |
01fb7433 AC |
989 | |
990 | /* Default (function) for non- multi-arch platforms. */ | |
991 | #if (!GDB_MULTI_ARCH) && !defined (CANNOT_STORE_REGISTER) | |
992 | #define CANNOT_STORE_REGISTER(regnum) (cannot_register_not (regnum)) | |
993 | #endif | |
994 | ||
995 | typedef int (gdbarch_cannot_store_register_ftype) (int regnum); | |
996 | extern int gdbarch_cannot_store_register (struct gdbarch *gdbarch, int regnum); | |
997 | extern void set_gdbarch_cannot_store_register (struct gdbarch *gdbarch, gdbarch_cannot_store_register_ftype *cannot_store_register); | |
83905903 AC |
998 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (CANNOT_STORE_REGISTER) |
999 | #error "Non multi-arch definition of CANNOT_STORE_REGISTER" | |
1000 | #endif | |
c25083af | 1001 | #if !defined (CANNOT_STORE_REGISTER) |
01fb7433 AC |
1002 | #define CANNOT_STORE_REGISTER(regnum) (gdbarch_cannot_store_register (current_gdbarch, regnum)) |
1003 | #endif | |
01fb7433 | 1004 | |
9df628e0 RE |
1005 | /* setjmp/longjmp support. */ |
1006 | ||
1007 | #if defined (GET_LONGJMP_TARGET) | |
1008 | /* Legacy for systems yet to multi-arch GET_LONGJMP_TARGET */ | |
1009 | #if !defined (GET_LONGJMP_TARGET_P) | |
1010 | #define GET_LONGJMP_TARGET_P() (1) | |
1011 | #endif | |
1012 | #endif | |
1013 | ||
1014 | /* Default predicate for non- multi-arch targets. */ | |
1015 | #if (!GDB_MULTI_ARCH) && !defined (GET_LONGJMP_TARGET_P) | |
1016 | #define GET_LONGJMP_TARGET_P() (0) | |
1017 | #endif | |
1018 | ||
1019 | extern int gdbarch_get_longjmp_target_p (struct gdbarch *gdbarch); | |
1020 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (GET_LONGJMP_TARGET_P) | |
1021 | #error "Non multi-arch definition of GET_LONGJMP_TARGET" | |
1022 | #endif | |
1023 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (GET_LONGJMP_TARGET_P) | |
1024 | #define GET_LONGJMP_TARGET_P() (gdbarch_get_longjmp_target_p (current_gdbarch)) | |
1025 | #endif | |
1026 | ||
1027 | /* Default (function) for non- multi-arch platforms. */ | |
1028 | #if (!GDB_MULTI_ARCH) && !defined (GET_LONGJMP_TARGET) | |
1029 | #define GET_LONGJMP_TARGET(pc) (internal_error (__FILE__, __LINE__, "GET_LONGJMP_TARGET"), 0) | |
1030 | #endif | |
1031 | ||
1032 | typedef int (gdbarch_get_longjmp_target_ftype) (CORE_ADDR *pc); | |
1033 | extern int gdbarch_get_longjmp_target (struct gdbarch *gdbarch, CORE_ADDR *pc); | |
1034 | extern void set_gdbarch_get_longjmp_target (struct gdbarch *gdbarch, gdbarch_get_longjmp_target_ftype *get_longjmp_target); | |
1035 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (GET_LONGJMP_TARGET) | |
1036 | #error "Non multi-arch definition of GET_LONGJMP_TARGET" | |
1037 | #endif | |
c25083af | 1038 | #if !defined (GET_LONGJMP_TARGET) |
9df628e0 RE |
1039 | #define GET_LONGJMP_TARGET(pc) (gdbarch_get_longjmp_target (current_gdbarch, pc)) |
1040 | #endif | |
9df628e0 | 1041 | |
028c194b AC |
1042 | /* Non multi-arch DUMMY_FRAMES are a mess (multi-arch ones are not that |
1043 | much better but at least they are vaguely consistent). The headers | |
1044 | and body contain convoluted #if/#else sequences for determine how | |
1045 | things should be compiled. Instead of trying to mimic that | |
1046 | behaviour here (and hence entrench it further) gdbarch simply | |
1047 | reqires that these methods be set up from the word go. This also | |
1048 | avoids any potential problems with moving beyond multi-arch partial. */ | |
1049 | ||
b99fa2d2 | 1050 | /* Default (value) for non- multi-arch platforms. */ |
07555a72 AC |
1051 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_USE_GENERIC_DUMMY_FRAMES) |
1052 | #define DEPRECATED_USE_GENERIC_DUMMY_FRAMES (1) | |
b99fa2d2 AC |
1053 | #endif |
1054 | ||
07555a72 AC |
1055 | extern int gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch *gdbarch); |
1056 | extern void set_gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch *gdbarch, int deprecated_use_generic_dummy_frames); | |
55e1d7e7 | 1057 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_USE_GENERIC_DUMMY_FRAMES) |
07555a72 | 1058 | #error "Non multi-arch definition of DEPRECATED_USE_GENERIC_DUMMY_FRAMES" |
83905903 | 1059 | #endif |
55e1d7e7 | 1060 | #if !defined (DEPRECATED_USE_GENERIC_DUMMY_FRAMES) |
07555a72 | 1061 | #define DEPRECATED_USE_GENERIC_DUMMY_FRAMES (gdbarch_deprecated_use_generic_dummy_frames (current_gdbarch)) |
0f71a2f6 | 1062 | #endif |
0f71a2f6 | 1063 | |
7043d8dc AC |
1064 | /* Replaced by push_dummy_code. */ |
1065 | ||
b99fa2d2 AC |
1066 | /* Default (value) for non- multi-arch platforms. */ |
1067 | #if (!GDB_MULTI_ARCH) && !defined (CALL_DUMMY_LOCATION) | |
1068 | #define CALL_DUMMY_LOCATION (AT_ENTRY_POINT) | |
1069 | #endif | |
1070 | ||
104c1213 JM |
1071 | extern int gdbarch_call_dummy_location (struct gdbarch *gdbarch); |
1072 | extern void set_gdbarch_call_dummy_location (struct gdbarch *gdbarch, int call_dummy_location); | |
55e1d7e7 | 1073 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (CALL_DUMMY_LOCATION) |
83905903 AC |
1074 | #error "Non multi-arch definition of CALL_DUMMY_LOCATION" |
1075 | #endif | |
55e1d7e7 | 1076 | #if !defined (CALL_DUMMY_LOCATION) |
0f71a2f6 JM |
1077 | #define CALL_DUMMY_LOCATION (gdbarch_call_dummy_location (current_gdbarch)) |
1078 | #endif | |
0f71a2f6 | 1079 | |
7043d8dc AC |
1080 | /* Replaced by push_dummy_code. */ |
1081 | ||
e9a2674e AC |
1082 | /* Default (function) for non- multi-arch platforms. */ |
1083 | #if (!GDB_MULTI_ARCH) && !defined (CALL_DUMMY_ADDRESS) | |
1084 | #define CALL_DUMMY_ADDRESS() (entry_point_address ()) | |
1085 | #endif | |
1086 | ||
104c1213 JM |
1087 | typedef CORE_ADDR (gdbarch_call_dummy_address_ftype) (void); |
1088 | extern CORE_ADDR gdbarch_call_dummy_address (struct gdbarch *gdbarch); | |
1089 | extern void set_gdbarch_call_dummy_address (struct gdbarch *gdbarch, gdbarch_call_dummy_address_ftype *call_dummy_address); | |
83905903 AC |
1090 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (CALL_DUMMY_ADDRESS) |
1091 | #error "Non multi-arch definition of CALL_DUMMY_ADDRESS" | |
1092 | #endif | |
c25083af | 1093 | #if !defined (CALL_DUMMY_ADDRESS) |
0f71a2f6 JM |
1094 | #define CALL_DUMMY_ADDRESS() (gdbarch_call_dummy_address (current_gdbarch)) |
1095 | #endif | |
0f71a2f6 | 1096 | |
7043d8dc AC |
1097 | /* Replaced by push_dummy_code. */ |
1098 | ||
b1e29e33 AC |
1099 | extern CORE_ADDR gdbarch_deprecated_call_dummy_start_offset (struct gdbarch *gdbarch); |
1100 | extern void set_gdbarch_deprecated_call_dummy_start_offset (struct gdbarch *gdbarch, CORE_ADDR deprecated_call_dummy_start_offset); | |
1101 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_CALL_DUMMY_START_OFFSET) | |
1102 | #error "Non multi-arch definition of DEPRECATED_CALL_DUMMY_START_OFFSET" | |
83905903 | 1103 | #endif |
b1e29e33 AC |
1104 | #if !defined (DEPRECATED_CALL_DUMMY_START_OFFSET) |
1105 | #define DEPRECATED_CALL_DUMMY_START_OFFSET (gdbarch_deprecated_call_dummy_start_offset (current_gdbarch)) | |
0f71a2f6 | 1106 | #endif |
0f71a2f6 | 1107 | |
7043d8dc AC |
1108 | /* Replaced by push_dummy_code. */ |
1109 | ||
b1e29e33 AC |
1110 | extern CORE_ADDR gdbarch_deprecated_call_dummy_breakpoint_offset (struct gdbarch *gdbarch); |
1111 | extern void set_gdbarch_deprecated_call_dummy_breakpoint_offset (struct gdbarch *gdbarch, CORE_ADDR deprecated_call_dummy_breakpoint_offset); | |
1112 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET) | |
1113 | #error "Non multi-arch definition of DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET" | |
83905903 | 1114 | #endif |
b1e29e33 AC |
1115 | #if !defined (DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET) |
1116 | #define DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET (gdbarch_deprecated_call_dummy_breakpoint_offset (current_gdbarch)) | |
0f71a2f6 | 1117 | #endif |
0f71a2f6 | 1118 | |
7043d8dc AC |
1119 | /* Replaced by push_dummy_code. */ |
1120 | ||
b1e29e33 AC |
1121 | extern int gdbarch_deprecated_call_dummy_length (struct gdbarch *gdbarch); |
1122 | extern void set_gdbarch_deprecated_call_dummy_length (struct gdbarch *gdbarch, int deprecated_call_dummy_length); | |
1123 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_CALL_DUMMY_LENGTH) | |
1124 | #error "Non multi-arch definition of DEPRECATED_CALL_DUMMY_LENGTH" | |
83905903 | 1125 | #endif |
b1e29e33 AC |
1126 | #if !defined (DEPRECATED_CALL_DUMMY_LENGTH) |
1127 | #define DEPRECATED_CALL_DUMMY_LENGTH (gdbarch_deprecated_call_dummy_length (current_gdbarch)) | |
0f71a2f6 | 1128 | #endif |
0f71a2f6 | 1129 | |
ae45cd16 AC |
1130 | /* NOTE: cagney/2002-11-24: This function with predicate has a valid |
1131 | (callable) initial value. As a consequence, even when the predicate | |
1132 | is false, the corresponding function works. This simplifies the | |
1133 | migration process - old code, calling DEPRECATED_PC_IN_CALL_DUMMY(), | |
1134 | doesn't need to be modified. */ | |
1135 | ||
1136 | #if defined (DEPRECATED_PC_IN_CALL_DUMMY) | |
1137 | /* Legacy for systems yet to multi-arch DEPRECATED_PC_IN_CALL_DUMMY */ | |
1138 | #if !defined (DEPRECATED_PC_IN_CALL_DUMMY_P) | |
1139 | #define DEPRECATED_PC_IN_CALL_DUMMY_P() (1) | |
1140 | #endif | |
1141 | #endif | |
1142 | ||
1143 | /* Default predicate for non- multi-arch targets. */ | |
1144 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PC_IN_CALL_DUMMY_P) | |
1145 | #define DEPRECATED_PC_IN_CALL_DUMMY_P() (0) | |
1146 | #endif | |
1147 | ||
1148 | extern int gdbarch_deprecated_pc_in_call_dummy_p (struct gdbarch *gdbarch); | |
55e1d7e7 | 1149 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PC_IN_CALL_DUMMY_P) |
ae45cd16 AC |
1150 | #error "Non multi-arch definition of DEPRECATED_PC_IN_CALL_DUMMY" |
1151 | #endif | |
55e1d7e7 | 1152 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_PC_IN_CALL_DUMMY_P) |
ae45cd16 AC |
1153 | #define DEPRECATED_PC_IN_CALL_DUMMY_P() (gdbarch_deprecated_pc_in_call_dummy_p (current_gdbarch)) |
1154 | #endif | |
1155 | ||
b99fa2d2 | 1156 | /* Default (function) for non- multi-arch platforms. */ |
ae45cd16 AC |
1157 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PC_IN_CALL_DUMMY) |
1158 | #define DEPRECATED_PC_IN_CALL_DUMMY(pc, sp, frame_address) (generic_pc_in_call_dummy (pc, sp, frame_address)) | |
b99fa2d2 AC |
1159 | #endif |
1160 | ||
ae45cd16 AC |
1161 | typedef int (gdbarch_deprecated_pc_in_call_dummy_ftype) (CORE_ADDR pc, CORE_ADDR sp, CORE_ADDR frame_address); |
1162 | extern int gdbarch_deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, CORE_ADDR pc, CORE_ADDR sp, CORE_ADDR frame_address); | |
1163 | extern void set_gdbarch_deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, gdbarch_deprecated_pc_in_call_dummy_ftype *deprecated_pc_in_call_dummy); | |
55e1d7e7 | 1164 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PC_IN_CALL_DUMMY) |
ae45cd16 | 1165 | #error "Non multi-arch definition of DEPRECATED_PC_IN_CALL_DUMMY" |
83905903 | 1166 | #endif |
c25083af | 1167 | #if !defined (DEPRECATED_PC_IN_CALL_DUMMY) |
ae45cd16 | 1168 | #define DEPRECATED_PC_IN_CALL_DUMMY(pc, sp, frame_address) (gdbarch_deprecated_pc_in_call_dummy (current_gdbarch, pc, sp, frame_address)) |
0f71a2f6 | 1169 | #endif |
0f71a2f6 | 1170 | |
7043d8dc AC |
1171 | /* Replaced by push_dummy_code. */ |
1172 | ||
33489c5b | 1173 | /* Default (value) for non- multi-arch platforms. */ |
b1e29e33 AC |
1174 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_CALL_DUMMY_WORDS) |
1175 | #define DEPRECATED_CALL_DUMMY_WORDS (legacy_call_dummy_words) | |
33489c5b AC |
1176 | #endif |
1177 | ||
b1e29e33 AC |
1178 | extern LONGEST * gdbarch_deprecated_call_dummy_words (struct gdbarch *gdbarch); |
1179 | extern void set_gdbarch_deprecated_call_dummy_words (struct gdbarch *gdbarch, LONGEST * deprecated_call_dummy_words); | |
1180 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_CALL_DUMMY_WORDS) | |
1181 | #error "Non multi-arch definition of DEPRECATED_CALL_DUMMY_WORDS" | |
83905903 | 1182 | #endif |
b1e29e33 AC |
1183 | #if !defined (DEPRECATED_CALL_DUMMY_WORDS) |
1184 | #define DEPRECATED_CALL_DUMMY_WORDS (gdbarch_deprecated_call_dummy_words (current_gdbarch)) | |
0f71a2f6 | 1185 | #endif |
33489c5b | 1186 | |
7043d8dc AC |
1187 | /* Replaced by push_dummy_code. */ |
1188 | ||
33489c5b | 1189 | /* Default (value) for non- multi-arch platforms. */ |
b1e29e33 AC |
1190 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_SIZEOF_CALL_DUMMY_WORDS) |
1191 | #define DEPRECATED_SIZEOF_CALL_DUMMY_WORDS (legacy_sizeof_call_dummy_words) | |
33489c5b | 1192 | #endif |
0f71a2f6 | 1193 | |
b1e29e33 AC |
1194 | extern int gdbarch_deprecated_sizeof_call_dummy_words (struct gdbarch *gdbarch); |
1195 | extern void set_gdbarch_deprecated_sizeof_call_dummy_words (struct gdbarch *gdbarch, int deprecated_sizeof_call_dummy_words); | |
1196 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_SIZEOF_CALL_DUMMY_WORDS) | |
1197 | #error "Non multi-arch definition of DEPRECATED_SIZEOF_CALL_DUMMY_WORDS" | |
83905903 | 1198 | #endif |
b1e29e33 AC |
1199 | #if !defined (DEPRECATED_SIZEOF_CALL_DUMMY_WORDS) |
1200 | #define DEPRECATED_SIZEOF_CALL_DUMMY_WORDS (gdbarch_deprecated_sizeof_call_dummy_words (current_gdbarch)) | |
0f71a2f6 | 1201 | #endif |
0f71a2f6 | 1202 | |
7043d8dc AC |
1203 | /* Replaced by push_dummy_code. */ |
1204 | ||
1bf6d5cc AC |
1205 | #if defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST) |
1206 | /* Legacy for systems yet to multi-arch DEPRECATED_CALL_DUMMY_STACK_ADJUST */ | |
1207 | #if !defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P) | |
1208 | #define DEPRECATED_CALL_DUMMY_STACK_ADJUST_P() (1) | |
83905903 | 1209 | #endif |
0f71a2f6 | 1210 | #endif |
1bf6d5cc AC |
1211 | |
1212 | /* Default predicate for non- multi-arch targets. */ | |
1213 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P) | |
1214 | #define DEPRECATED_CALL_DUMMY_STACK_ADJUST_P() (0) | |
1215 | #endif | |
1216 | ||
1217 | extern int gdbarch_deprecated_call_dummy_stack_adjust_p (struct gdbarch *gdbarch); | |
1218 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P) | |
1219 | #error "Non multi-arch definition of DEPRECATED_CALL_DUMMY_STACK_ADJUST" | |
1220 | #endif | |
1221 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P) | |
1222 | #define DEPRECATED_CALL_DUMMY_STACK_ADJUST_P() (gdbarch_deprecated_call_dummy_stack_adjust_p (current_gdbarch)) | |
1223 | #endif | |
1224 | ||
1225 | /* Default (value) for non- multi-arch platforms. */ | |
1226 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST) | |
1227 | #define DEPRECATED_CALL_DUMMY_STACK_ADJUST (0) | |
0f71a2f6 JM |
1228 | #endif |
1229 | ||
1bf6d5cc AC |
1230 | extern int gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch *gdbarch); |
1231 | extern void set_gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch *gdbarch, int deprecated_call_dummy_stack_adjust); | |
1232 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST) | |
1233 | #error "Non multi-arch definition of DEPRECATED_CALL_DUMMY_STACK_ADJUST" | |
83905903 | 1234 | #endif |
c25083af | 1235 | #if !defined (DEPRECATED_CALL_DUMMY_STACK_ADJUST) |
1bf6d5cc | 1236 | #define DEPRECATED_CALL_DUMMY_STACK_ADJUST (gdbarch_deprecated_call_dummy_stack_adjust (current_gdbarch)) |
0f71a2f6 | 1237 | #endif |
0f71a2f6 | 1238 | |
7043d8dc AC |
1239 | /* Replaced by push_dummy_code. */ |
1240 | ||
b1e29e33 AC |
1241 | #if defined (DEPRECATED_FIX_CALL_DUMMY) |
1242 | /* Legacy for systems yet to multi-arch DEPRECATED_FIX_CALL_DUMMY */ | |
1243 | #if !defined (DEPRECATED_FIX_CALL_DUMMY_P) | |
1244 | #define DEPRECATED_FIX_CALL_DUMMY_P() (1) | |
e8ab51f7 AC |
1245 | #endif |
1246 | #endif | |
1247 | ||
1248 | /* Default predicate for non- multi-arch targets. */ | |
b1e29e33 AC |
1249 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FIX_CALL_DUMMY_P) |
1250 | #define DEPRECATED_FIX_CALL_DUMMY_P() (0) | |
e8ab51f7 AC |
1251 | #endif |
1252 | ||
b1e29e33 AC |
1253 | extern int gdbarch_deprecated_fix_call_dummy_p (struct gdbarch *gdbarch); |
1254 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FIX_CALL_DUMMY_P) | |
1255 | #error "Non multi-arch definition of DEPRECATED_FIX_CALL_DUMMY" | |
e8ab51f7 | 1256 | #endif |
b1e29e33 AC |
1257 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_FIX_CALL_DUMMY_P) |
1258 | #define DEPRECATED_FIX_CALL_DUMMY_P() (gdbarch_deprecated_fix_call_dummy_p (current_gdbarch)) | |
e8ab51f7 AC |
1259 | #endif |
1260 | ||
1261 | /* Default (function) for non- multi-arch platforms. */ | |
b1e29e33 AC |
1262 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FIX_CALL_DUMMY) |
1263 | #define DEPRECATED_FIX_CALL_DUMMY(dummy, pc, fun, nargs, args, type, gcc_p) (internal_error (__FILE__, __LINE__, "DEPRECATED_FIX_CALL_DUMMY"), 0) | |
e8ab51f7 AC |
1264 | #endif |
1265 | ||
b1e29e33 AC |
1266 | typedef void (gdbarch_deprecated_fix_call_dummy_ftype) (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs, struct value **args, struct type *type, int gcc_p); |
1267 | extern void gdbarch_deprecated_fix_call_dummy (struct gdbarch *gdbarch, char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs, struct value **args, struct type *type, int gcc_p); | |
1268 | extern void set_gdbarch_deprecated_fix_call_dummy (struct gdbarch *gdbarch, gdbarch_deprecated_fix_call_dummy_ftype *deprecated_fix_call_dummy); | |
1269 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FIX_CALL_DUMMY) | |
1270 | #error "Non multi-arch definition of DEPRECATED_FIX_CALL_DUMMY" | |
83905903 | 1271 | #endif |
c25083af | 1272 | #if !defined (DEPRECATED_FIX_CALL_DUMMY) |
b1e29e33 | 1273 | #define DEPRECATED_FIX_CALL_DUMMY(dummy, pc, fun, nargs, args, type, gcc_p) (gdbarch_deprecated_fix_call_dummy (current_gdbarch, dummy, pc, fun, nargs, args, type, gcc_p)) |
0f71a2f6 | 1274 | #endif |
0f71a2f6 | 1275 | |
b1e29e33 | 1276 | /* This is a replacement for DEPRECATED_FIX_CALL_DUMMY et.al. */ |
7043d8dc AC |
1277 | |
1278 | extern int gdbarch_push_dummy_code_p (struct gdbarch *gdbarch); | |
1279 | ||
1280 | typedef CORE_ADDR (gdbarch_push_dummy_code_ftype) (struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, int using_gcc, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr); | |
1281 | extern CORE_ADDR gdbarch_push_dummy_code (struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, int using_gcc, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr); | |
1282 | extern void set_gdbarch_push_dummy_code (struct gdbarch *gdbarch, gdbarch_push_dummy_code_ftype *push_dummy_code); | |
1283 | ||
2ca6c561 AC |
1284 | #if defined (DEPRECATED_INIT_FRAME_PC_FIRST) |
1285 | /* Legacy for systems yet to multi-arch DEPRECATED_INIT_FRAME_PC_FIRST */ | |
1286 | #if !defined (DEPRECATED_INIT_FRAME_PC_FIRST_P) | |
1287 | #define DEPRECATED_INIT_FRAME_PC_FIRST_P() (1) | |
1288 | #endif | |
1289 | #endif | |
1290 | ||
1291 | /* Default predicate for non- multi-arch targets. */ | |
1292 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_INIT_FRAME_PC_FIRST_P) | |
1293 | #define DEPRECATED_INIT_FRAME_PC_FIRST_P() (0) | |
1294 | #endif | |
1295 | ||
1296 | extern int gdbarch_deprecated_init_frame_pc_first_p (struct gdbarch *gdbarch); | |
1297 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_INIT_FRAME_PC_FIRST_P) | |
1298 | #error "Non multi-arch definition of DEPRECATED_INIT_FRAME_PC_FIRST" | |
1299 | #endif | |
1300 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_INIT_FRAME_PC_FIRST_P) | |
1301 | #define DEPRECATED_INIT_FRAME_PC_FIRST_P() (gdbarch_deprecated_init_frame_pc_first_p (current_gdbarch)) | |
1302 | #endif | |
1303 | ||
10312cc4 | 1304 | /* Default (function) for non- multi-arch platforms. */ |
2ca6c561 AC |
1305 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_INIT_FRAME_PC_FIRST) |
1306 | #define DEPRECATED_INIT_FRAME_PC_FIRST(fromleaf, prev) (internal_error (__FILE__, __LINE__, "DEPRECATED_INIT_FRAME_PC_FIRST"), 0) | |
10312cc4 AC |
1307 | #endif |
1308 | ||
97f46953 AC |
1309 | typedef CORE_ADDR (gdbarch_deprecated_init_frame_pc_first_ftype) (int fromleaf, struct frame_info *prev); |
1310 | extern CORE_ADDR gdbarch_deprecated_init_frame_pc_first (struct gdbarch *gdbarch, int fromleaf, struct frame_info *prev); | |
2ca6c561 AC |
1311 | extern void set_gdbarch_deprecated_init_frame_pc_first (struct gdbarch *gdbarch, gdbarch_deprecated_init_frame_pc_first_ftype *deprecated_init_frame_pc_first); |
1312 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_INIT_FRAME_PC_FIRST) | |
1313 | #error "Non multi-arch definition of DEPRECATED_INIT_FRAME_PC_FIRST" | |
83905903 | 1314 | #endif |
c25083af | 1315 | #if !defined (DEPRECATED_INIT_FRAME_PC_FIRST) |
2ca6c561 | 1316 | #define DEPRECATED_INIT_FRAME_PC_FIRST(fromleaf, prev) (gdbarch_deprecated_init_frame_pc_first (current_gdbarch, fromleaf, prev)) |
10312cc4 | 1317 | #endif |
10312cc4 | 1318 | |
a5afb99f AC |
1319 | #if defined (DEPRECATED_INIT_FRAME_PC) |
1320 | /* Legacy for systems yet to multi-arch DEPRECATED_INIT_FRAME_PC */ | |
1321 | #if !defined (DEPRECATED_INIT_FRAME_PC_P) | |
1322 | #define DEPRECATED_INIT_FRAME_PC_P() (1) | |
1323 | #endif | |
1324 | #endif | |
1325 | ||
1326 | /* Default predicate for non- multi-arch targets. */ | |
1327 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_INIT_FRAME_PC_P) | |
1328 | #define DEPRECATED_INIT_FRAME_PC_P() (0) | |
1329 | #endif | |
1330 | ||
1331 | extern int gdbarch_deprecated_init_frame_pc_p (struct gdbarch *gdbarch); | |
1332 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_INIT_FRAME_PC_P) | |
1333 | #error "Non multi-arch definition of DEPRECATED_INIT_FRAME_PC" | |
1334 | #endif | |
1335 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_INIT_FRAME_PC_P) | |
1336 | #define DEPRECATED_INIT_FRAME_PC_P() (gdbarch_deprecated_init_frame_pc_p (current_gdbarch)) | |
1337 | #endif | |
1338 | ||
10312cc4 | 1339 | /* Default (function) for non- multi-arch platforms. */ |
a5afb99f AC |
1340 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_INIT_FRAME_PC) |
1341 | #define DEPRECATED_INIT_FRAME_PC(fromleaf, prev) (internal_error (__FILE__, __LINE__, "DEPRECATED_INIT_FRAME_PC"), 0) | |
10312cc4 AC |
1342 | #endif |
1343 | ||
a5afb99f AC |
1344 | typedef CORE_ADDR (gdbarch_deprecated_init_frame_pc_ftype) (int fromleaf, struct frame_info *prev); |
1345 | extern CORE_ADDR gdbarch_deprecated_init_frame_pc (struct gdbarch *gdbarch, int fromleaf, struct frame_info *prev); | |
1346 | extern void set_gdbarch_deprecated_init_frame_pc (struct gdbarch *gdbarch, gdbarch_deprecated_init_frame_pc_ftype *deprecated_init_frame_pc); | |
1347 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_INIT_FRAME_PC) | |
1348 | #error "Non multi-arch definition of DEPRECATED_INIT_FRAME_PC" | |
83905903 | 1349 | #endif |
c25083af | 1350 | #if !defined (DEPRECATED_INIT_FRAME_PC) |
a5afb99f | 1351 | #define DEPRECATED_INIT_FRAME_PC(fromleaf, prev) (gdbarch_deprecated_init_frame_pc (current_gdbarch, fromleaf, prev)) |
10312cc4 | 1352 | #endif |
10312cc4 | 1353 | |
104c1213 JM |
1354 | extern int gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch); |
1355 | extern void set_gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch, int believe_pcc_promotion); | |
83905903 AC |
1356 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (BELIEVE_PCC_PROMOTION) |
1357 | #error "Non multi-arch definition of BELIEVE_PCC_PROMOTION" | |
1358 | #endif | |
c25083af | 1359 | #if !defined (BELIEVE_PCC_PROMOTION) |
0f71a2f6 JM |
1360 | #define BELIEVE_PCC_PROMOTION (gdbarch_believe_pcc_promotion (current_gdbarch)) |
1361 | #endif | |
0f71a2f6 | 1362 | |
104c1213 JM |
1363 | extern int gdbarch_believe_pcc_promotion_type (struct gdbarch *gdbarch); |
1364 | extern void set_gdbarch_believe_pcc_promotion_type (struct gdbarch *gdbarch, int believe_pcc_promotion_type); | |
83905903 AC |
1365 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (BELIEVE_PCC_PROMOTION_TYPE) |
1366 | #error "Non multi-arch definition of BELIEVE_PCC_PROMOTION_TYPE" | |
1367 | #endif | |
e669114a | 1368 | #if !defined (BELIEVE_PCC_PROMOTION_TYPE) |
0f71a2f6 JM |
1369 | #define BELIEVE_PCC_PROMOTION_TYPE (gdbarch_believe_pcc_promotion_type (current_gdbarch)) |
1370 | #endif | |
0f71a2f6 | 1371 | |
129c1cd6 AC |
1372 | #if defined (DEPRECATED_GET_SAVED_REGISTER) |
1373 | /* Legacy for systems yet to multi-arch DEPRECATED_GET_SAVED_REGISTER */ | |
1374 | #if !defined (DEPRECATED_GET_SAVED_REGISTER_P) | |
1375 | #define DEPRECATED_GET_SAVED_REGISTER_P() (1) | |
a216a322 AC |
1376 | #endif |
1377 | #endif | |
1378 | ||
1379 | /* Default predicate for non- multi-arch targets. */ | |
129c1cd6 AC |
1380 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_GET_SAVED_REGISTER_P) |
1381 | #define DEPRECATED_GET_SAVED_REGISTER_P() (0) | |
a216a322 AC |
1382 | #endif |
1383 | ||
129c1cd6 AC |
1384 | extern int gdbarch_deprecated_get_saved_register_p (struct gdbarch *gdbarch); |
1385 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_GET_SAVED_REGISTER_P) | |
1386 | #error "Non multi-arch definition of DEPRECATED_GET_SAVED_REGISTER" | |
a216a322 | 1387 | #endif |
129c1cd6 AC |
1388 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_GET_SAVED_REGISTER_P) |
1389 | #define DEPRECATED_GET_SAVED_REGISTER_P() (gdbarch_deprecated_get_saved_register_p (current_gdbarch)) | |
a216a322 AC |
1390 | #endif |
1391 | ||
e4b415d9 | 1392 | /* Default (function) for non- multi-arch platforms. */ |
129c1cd6 AC |
1393 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_GET_SAVED_REGISTER) |
1394 | #define DEPRECATED_GET_SAVED_REGISTER(raw_buffer, optimized, addrp, frame, regnum, lval) (internal_error (__FILE__, __LINE__, "DEPRECATED_GET_SAVED_REGISTER"), 0) | |
e4b415d9 | 1395 | #endif |
028c194b | 1396 | |
129c1cd6 AC |
1397 | typedef void (gdbarch_deprecated_get_saved_register_ftype) (char *raw_buffer, int *optimized, CORE_ADDR *addrp, struct frame_info *frame, int regnum, enum lval_type *lval); |
1398 | extern void gdbarch_deprecated_get_saved_register (struct gdbarch *gdbarch, char *raw_buffer, int *optimized, CORE_ADDR *addrp, struct frame_info *frame, int regnum, enum lval_type *lval); | |
1399 | extern void set_gdbarch_deprecated_get_saved_register (struct gdbarch *gdbarch, gdbarch_deprecated_get_saved_register_ftype *deprecated_get_saved_register); | |
1400 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_GET_SAVED_REGISTER) | |
1401 | #error "Non multi-arch definition of DEPRECATED_GET_SAVED_REGISTER" | |
83905903 | 1402 | #endif |
c25083af | 1403 | #if !defined (DEPRECATED_GET_SAVED_REGISTER) |
129c1cd6 | 1404 | #define DEPRECATED_GET_SAVED_REGISTER(raw_buffer, optimized, addrp, frame, regnum, lval) (gdbarch_deprecated_get_saved_register (current_gdbarch, raw_buffer, optimized, addrp, frame, regnum, lval)) |
0f71a2f6 | 1405 | #endif |
0f71a2f6 | 1406 | |
33489c5b | 1407 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 1408 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_CONVERTIBLE) |
33489c5b AC |
1409 | #define REGISTER_CONVERTIBLE(nr) (generic_register_convertible_not (nr)) |
1410 | #endif | |
1411 | ||
104c1213 JM |
1412 | typedef int (gdbarch_register_convertible_ftype) (int nr); |
1413 | extern int gdbarch_register_convertible (struct gdbarch *gdbarch, int nr); | |
1414 | extern void set_gdbarch_register_convertible (struct gdbarch *gdbarch, gdbarch_register_convertible_ftype *register_convertible); | |
83905903 AC |
1415 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_CONVERTIBLE) |
1416 | #error "Non multi-arch definition of REGISTER_CONVERTIBLE" | |
1417 | #endif | |
c25083af | 1418 | #if !defined (REGISTER_CONVERTIBLE) |
0f71a2f6 JM |
1419 | #define REGISTER_CONVERTIBLE(nr) (gdbarch_register_convertible (current_gdbarch, nr)) |
1420 | #endif | |
33489c5b AC |
1421 | |
1422 | /* Default (function) for non- multi-arch platforms. */ | |
6166d547 | 1423 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_CONVERT_TO_VIRTUAL) |
8e65ff28 | 1424 | #define REGISTER_CONVERT_TO_VIRTUAL(regnum, type, from, to) (internal_error (__FILE__, __LINE__, "REGISTER_CONVERT_TO_VIRTUAL"), 0) |
33489c5b | 1425 | #endif |
0f71a2f6 | 1426 | |
104c1213 JM |
1427 | typedef void (gdbarch_register_convert_to_virtual_ftype) (int regnum, struct type *type, char *from, char *to); |
1428 | extern void gdbarch_register_convert_to_virtual (struct gdbarch *gdbarch, int regnum, struct type *type, char *from, char *to); | |
1429 | extern void set_gdbarch_register_convert_to_virtual (struct gdbarch *gdbarch, gdbarch_register_convert_to_virtual_ftype *register_convert_to_virtual); | |
83905903 AC |
1430 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_CONVERT_TO_VIRTUAL) |
1431 | #error "Non multi-arch definition of REGISTER_CONVERT_TO_VIRTUAL" | |
1432 | #endif | |
c25083af | 1433 | #if !defined (REGISTER_CONVERT_TO_VIRTUAL) |
0f71a2f6 JM |
1434 | #define REGISTER_CONVERT_TO_VIRTUAL(regnum, type, from, to) (gdbarch_register_convert_to_virtual (current_gdbarch, regnum, type, from, to)) |
1435 | #endif | |
33489c5b AC |
1436 | |
1437 | /* Default (function) for non- multi-arch platforms. */ | |
6166d547 | 1438 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_CONVERT_TO_RAW) |
8e65ff28 | 1439 | #define REGISTER_CONVERT_TO_RAW(type, regnum, from, to) (internal_error (__FILE__, __LINE__, "REGISTER_CONVERT_TO_RAW"), 0) |
33489c5b | 1440 | #endif |
0f71a2f6 | 1441 | |
104c1213 JM |
1442 | typedef void (gdbarch_register_convert_to_raw_ftype) (struct type *type, int regnum, char *from, char *to); |
1443 | extern void gdbarch_register_convert_to_raw (struct gdbarch *gdbarch, struct type *type, int regnum, char *from, char *to); | |
1444 | extern void set_gdbarch_register_convert_to_raw (struct gdbarch *gdbarch, gdbarch_register_convert_to_raw_ftype *register_convert_to_raw); | |
83905903 AC |
1445 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_CONVERT_TO_RAW) |
1446 | #error "Non multi-arch definition of REGISTER_CONVERT_TO_RAW" | |
1447 | #endif | |
c25083af | 1448 | #if !defined (REGISTER_CONVERT_TO_RAW) |
0f71a2f6 JM |
1449 | #define REGISTER_CONVERT_TO_RAW(type, regnum, from, to) (gdbarch_register_convert_to_raw (current_gdbarch, type, regnum, from, to)) |
1450 | #endif | |
33489c5b | 1451 | |
13d01224 AC |
1452 | /* Default (function) for non- multi-arch platforms. */ |
1453 | #if (!GDB_MULTI_ARCH) && !defined (CONVERT_REGISTER_P) | |
1454 | #define CONVERT_REGISTER_P(regnum) (legacy_convert_register_p (regnum)) | |
1455 | #endif | |
1456 | ||
1457 | typedef int (gdbarch_convert_register_p_ftype) (int regnum); | |
1458 | extern int gdbarch_convert_register_p (struct gdbarch *gdbarch, int regnum); | |
1459 | extern void set_gdbarch_convert_register_p (struct gdbarch *gdbarch, gdbarch_convert_register_p_ftype *convert_register_p); | |
1460 | #if (GDB_MULTI_ARCH >= GDB_MULTI_ARCH_PARTIAL) && defined (CONVERT_REGISTER_P) | |
1461 | #error "Non multi-arch definition of CONVERT_REGISTER_P" | |
1462 | #endif | |
c25083af | 1463 | #if !defined (CONVERT_REGISTER_P) |
13d01224 AC |
1464 | #define CONVERT_REGISTER_P(regnum) (gdbarch_convert_register_p (current_gdbarch, regnum)) |
1465 | #endif | |
13d01224 AC |
1466 | |
1467 | /* Default (function) for non- multi-arch platforms. */ | |
1468 | #if (!GDB_MULTI_ARCH) && !defined (REGISTER_TO_VALUE) | |
1469 | #define REGISTER_TO_VALUE(regnum, type, from, to) (legacy_register_to_value (regnum, type, from, to)) | |
1470 | #endif | |
1471 | ||
1472 | typedef void (gdbarch_register_to_value_ftype) (int regnum, struct type *type, char *from, char *to); | |
1473 | extern void gdbarch_register_to_value (struct gdbarch *gdbarch, int regnum, struct type *type, char *from, char *to); | |
1474 | extern void set_gdbarch_register_to_value (struct gdbarch *gdbarch, gdbarch_register_to_value_ftype *register_to_value); | |
1475 | #if (GDB_MULTI_ARCH >= GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_TO_VALUE) | |
1476 | #error "Non multi-arch definition of REGISTER_TO_VALUE" | |
1477 | #endif | |
c25083af | 1478 | #if !defined (REGISTER_TO_VALUE) |
13d01224 AC |
1479 | #define REGISTER_TO_VALUE(regnum, type, from, to) (gdbarch_register_to_value (current_gdbarch, regnum, type, from, to)) |
1480 | #endif | |
13d01224 AC |
1481 | |
1482 | /* Default (function) for non- multi-arch platforms. */ | |
1483 | #if (!GDB_MULTI_ARCH) && !defined (VALUE_TO_REGISTER) | |
1484 | #define VALUE_TO_REGISTER(type, regnum, from, to) (legacy_value_to_register (type, regnum, from, to)) | |
1485 | #endif | |
1486 | ||
1487 | typedef void (gdbarch_value_to_register_ftype) (struct type *type, int regnum, char *from, char *to); | |
1488 | extern void gdbarch_value_to_register (struct gdbarch *gdbarch, struct type *type, int regnum, char *from, char *to); | |
1489 | extern void set_gdbarch_value_to_register (struct gdbarch *gdbarch, gdbarch_value_to_register_ftype *value_to_register); | |
1490 | #if (GDB_MULTI_ARCH >= GDB_MULTI_ARCH_PARTIAL) && defined (VALUE_TO_REGISTER) | |
1491 | #error "Non multi-arch definition of VALUE_TO_REGISTER" | |
1492 | #endif | |
c25083af | 1493 | #if !defined (VALUE_TO_REGISTER) |
13d01224 AC |
1494 | #define VALUE_TO_REGISTER(type, regnum, from, to) (gdbarch_value_to_register (current_gdbarch, type, regnum, from, to)) |
1495 | #endif | |
13d01224 | 1496 | |
33489c5b | 1497 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 1498 | #if (!GDB_MULTI_ARCH) && !defined (POINTER_TO_ADDRESS) |
ac2e2ef7 | 1499 | #define POINTER_TO_ADDRESS(type, buf) (unsigned_pointer_to_address (type, buf)) |
33489c5b | 1500 | #endif |
4478b372 | 1501 | |
66140c26 AC |
1502 | typedef CORE_ADDR (gdbarch_pointer_to_address_ftype) (struct type *type, const void *buf); |
1503 | extern CORE_ADDR gdbarch_pointer_to_address (struct gdbarch *gdbarch, struct type *type, const void *buf); | |
4478b372 | 1504 | extern void set_gdbarch_pointer_to_address (struct gdbarch *gdbarch, gdbarch_pointer_to_address_ftype *pointer_to_address); |
83905903 AC |
1505 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (POINTER_TO_ADDRESS) |
1506 | #error "Non multi-arch definition of POINTER_TO_ADDRESS" | |
1507 | #endif | |
c25083af | 1508 | #if !defined (POINTER_TO_ADDRESS) |
4478b372 JB |
1509 | #define POINTER_TO_ADDRESS(type, buf) (gdbarch_pointer_to_address (current_gdbarch, type, buf)) |
1510 | #endif | |
33489c5b AC |
1511 | |
1512 | /* Default (function) for non- multi-arch platforms. */ | |
6166d547 | 1513 | #if (!GDB_MULTI_ARCH) && !defined (ADDRESS_TO_POINTER) |
ac2e2ef7 | 1514 | #define ADDRESS_TO_POINTER(type, buf, addr) (unsigned_address_to_pointer (type, buf, addr)) |
33489c5b | 1515 | #endif |
4478b372 | 1516 | |
ac2e2ef7 AC |
1517 | typedef void (gdbarch_address_to_pointer_ftype) (struct type *type, void *buf, CORE_ADDR addr); |
1518 | extern void gdbarch_address_to_pointer (struct gdbarch *gdbarch, struct type *type, void *buf, CORE_ADDR addr); | |
4478b372 | 1519 | extern void set_gdbarch_address_to_pointer (struct gdbarch *gdbarch, gdbarch_address_to_pointer_ftype *address_to_pointer); |
83905903 AC |
1520 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (ADDRESS_TO_POINTER) |
1521 | #error "Non multi-arch definition of ADDRESS_TO_POINTER" | |
1522 | #endif | |
c25083af | 1523 | #if !defined (ADDRESS_TO_POINTER) |
4478b372 JB |
1524 | #define ADDRESS_TO_POINTER(type, buf, addr) (gdbarch_address_to_pointer (current_gdbarch, type, buf, addr)) |
1525 | #endif | |
33489c5b | 1526 | |
fc0c74b1 AC |
1527 | #if defined (INTEGER_TO_ADDRESS) |
1528 | /* Legacy for systems yet to multi-arch INTEGER_TO_ADDRESS */ | |
1529 | #if !defined (INTEGER_TO_ADDRESS_P) | |
1530 | #define INTEGER_TO_ADDRESS_P() (1) | |
1531 | #endif | |
1532 | #endif | |
1533 | ||
1534 | /* Default predicate for non- multi-arch targets. */ | |
1535 | #if (!GDB_MULTI_ARCH) && !defined (INTEGER_TO_ADDRESS_P) | |
1536 | #define INTEGER_TO_ADDRESS_P() (0) | |
1537 | #endif | |
1538 | ||
1539 | extern int gdbarch_integer_to_address_p (struct gdbarch *gdbarch); | |
1540 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (INTEGER_TO_ADDRESS_P) | |
1541 | #error "Non multi-arch definition of INTEGER_TO_ADDRESS" | |
1542 | #endif | |
1543 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (INTEGER_TO_ADDRESS_P) | |
1544 | #define INTEGER_TO_ADDRESS_P() (gdbarch_integer_to_address_p (current_gdbarch)) | |
1545 | #endif | |
1546 | ||
1547 | /* Default (function) for non- multi-arch platforms. */ | |
1548 | #if (!GDB_MULTI_ARCH) && !defined (INTEGER_TO_ADDRESS) | |
73d3c16e | 1549 | #define INTEGER_TO_ADDRESS(type, buf) (internal_error (__FILE__, __LINE__, "INTEGER_TO_ADDRESS"), 0) |
fc0c74b1 AC |
1550 | #endif |
1551 | ||
1552 | typedef CORE_ADDR (gdbarch_integer_to_address_ftype) (struct type *type, void *buf); | |
1553 | extern CORE_ADDR gdbarch_integer_to_address (struct gdbarch *gdbarch, struct type *type, void *buf); | |
1554 | extern void set_gdbarch_integer_to_address (struct gdbarch *gdbarch, gdbarch_integer_to_address_ftype *integer_to_address); | |
1555 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (INTEGER_TO_ADDRESS) | |
1556 | #error "Non multi-arch definition of INTEGER_TO_ADDRESS" | |
1557 | #endif | |
c25083af | 1558 | #if !defined (INTEGER_TO_ADDRESS) |
fc0c74b1 AC |
1559 | #define INTEGER_TO_ADDRESS(type, buf) (gdbarch_integer_to_address (current_gdbarch, type, buf)) |
1560 | #endif | |
fc0c74b1 | 1561 | |
33489c5b | 1562 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 1563 | #if (!GDB_MULTI_ARCH) && !defined (RETURN_VALUE_ON_STACK) |
33489c5b AC |
1564 | #define RETURN_VALUE_ON_STACK(type) (generic_return_value_on_stack_not (type)) |
1565 | #endif | |
0f71a2f6 | 1566 | |
71a9f22e JB |
1567 | typedef int (gdbarch_return_value_on_stack_ftype) (struct type *type); |
1568 | extern int gdbarch_return_value_on_stack (struct gdbarch *gdbarch, struct type *type); | |
1569 | extern void set_gdbarch_return_value_on_stack (struct gdbarch *gdbarch, gdbarch_return_value_on_stack_ftype *return_value_on_stack); | |
83905903 AC |
1570 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (RETURN_VALUE_ON_STACK) |
1571 | #error "Non multi-arch definition of RETURN_VALUE_ON_STACK" | |
1572 | #endif | |
c25083af | 1573 | #if !defined (RETURN_VALUE_ON_STACK) |
71a9f22e JB |
1574 | #define RETURN_VALUE_ON_STACK(type) (gdbarch_return_value_on_stack (current_gdbarch, type)) |
1575 | #endif | |
1576 | ||
b81774d8 AC |
1577 | /* Replaced by PUSH_DUMMY_CALL */ |
1578 | ||
1579 | #if defined (DEPRECATED_PUSH_ARGUMENTS) | |
1580 | /* Legacy for systems yet to multi-arch DEPRECATED_PUSH_ARGUMENTS */ | |
1581 | #if !defined (DEPRECATED_PUSH_ARGUMENTS_P) | |
1582 | #define DEPRECATED_PUSH_ARGUMENTS_P() (1) | |
1583 | #endif | |
1584 | #endif | |
1585 | ||
1586 | /* Default predicate for non- multi-arch targets. */ | |
1587 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PUSH_ARGUMENTS_P) | |
1588 | #define DEPRECATED_PUSH_ARGUMENTS_P() (0) | |
1589 | #endif | |
1590 | ||
1591 | extern int gdbarch_deprecated_push_arguments_p (struct gdbarch *gdbarch); | |
1592 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PUSH_ARGUMENTS_P) | |
1593 | #error "Non multi-arch definition of DEPRECATED_PUSH_ARGUMENTS" | |
1594 | #endif | |
1595 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_PUSH_ARGUMENTS_P) | |
1596 | #define DEPRECATED_PUSH_ARGUMENTS_P() (gdbarch_deprecated_push_arguments_p (current_gdbarch)) | |
1597 | #endif | |
1598 | ||
c203844d | 1599 | /* Default (function) for non- multi-arch platforms. */ |
b81774d8 AC |
1600 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PUSH_ARGUMENTS) |
1601 | #define DEPRECATED_PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr) (internal_error (__FILE__, __LINE__, "DEPRECATED_PUSH_ARGUMENTS"), 0) | |
c203844d AC |
1602 | #endif |
1603 | ||
b81774d8 AC |
1604 | typedef CORE_ADDR (gdbarch_deprecated_push_arguments_ftype) (int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr); |
1605 | extern CORE_ADDR gdbarch_deprecated_push_arguments (struct gdbarch *gdbarch, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr); | |
1606 | extern void set_gdbarch_deprecated_push_arguments (struct gdbarch *gdbarch, gdbarch_deprecated_push_arguments_ftype *deprecated_push_arguments); | |
1607 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PUSH_ARGUMENTS) | |
1608 | #error "Non multi-arch definition of DEPRECATED_PUSH_ARGUMENTS" | |
83905903 | 1609 | #endif |
c25083af | 1610 | #if !defined (DEPRECATED_PUSH_ARGUMENTS) |
b81774d8 | 1611 | #define DEPRECATED_PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr) (gdbarch_deprecated_push_arguments (current_gdbarch, nargs, args, sp, struct_return, struct_addr)) |
0f71a2f6 | 1612 | #endif |
0f71a2f6 | 1613 | |
b81774d8 AC |
1614 | extern int gdbarch_push_dummy_call_p (struct gdbarch *gdbarch); |
1615 | ||
6a65450a AC |
1616 | typedef CORE_ADDR (gdbarch_push_dummy_call_ftype) (struct gdbarch *gdbarch, CORE_ADDR func_addr, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr); |
1617 | extern CORE_ADDR gdbarch_push_dummy_call (struct gdbarch *gdbarch, CORE_ADDR func_addr, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr); | |
b81774d8 AC |
1618 | extern void set_gdbarch_push_dummy_call (struct gdbarch *gdbarch, gdbarch_push_dummy_call_ftype *push_dummy_call); |
1619 | ||
f3824013 AC |
1620 | #if defined (DEPRECATED_PUSH_DUMMY_FRAME) |
1621 | /* Legacy for systems yet to multi-arch DEPRECATED_PUSH_DUMMY_FRAME */ | |
1622 | #if !defined (DEPRECATED_PUSH_DUMMY_FRAME_P) | |
1623 | #define DEPRECATED_PUSH_DUMMY_FRAME_P() (1) | |
1624 | #endif | |
1625 | #endif | |
1626 | ||
1627 | /* Default predicate for non- multi-arch targets. */ | |
1628 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PUSH_DUMMY_FRAME_P) | |
1629 | #define DEPRECATED_PUSH_DUMMY_FRAME_P() (0) | |
1630 | #endif | |
1631 | ||
1632 | extern int gdbarch_deprecated_push_dummy_frame_p (struct gdbarch *gdbarch); | |
1633 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PUSH_DUMMY_FRAME_P) | |
1634 | #error "Non multi-arch definition of DEPRECATED_PUSH_DUMMY_FRAME" | |
1635 | #endif | |
1636 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_PUSH_DUMMY_FRAME_P) | |
1637 | #define DEPRECATED_PUSH_DUMMY_FRAME_P() (gdbarch_deprecated_push_dummy_frame_p (current_gdbarch)) | |
1638 | #endif | |
1639 | ||
1640 | /* Default (function) for non- multi-arch platforms. */ | |
1641 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PUSH_DUMMY_FRAME) | |
1642 | #define DEPRECATED_PUSH_DUMMY_FRAME (internal_error (__FILE__, __LINE__, "DEPRECATED_PUSH_DUMMY_FRAME"), 0) | |
f3824013 AC |
1643 | #endif |
1644 | ||
1645 | typedef void (gdbarch_deprecated_push_dummy_frame_ftype) (void); | |
1646 | extern void gdbarch_deprecated_push_dummy_frame (struct gdbarch *gdbarch); | |
1647 | extern void set_gdbarch_deprecated_push_dummy_frame (struct gdbarch *gdbarch, gdbarch_deprecated_push_dummy_frame_ftype *deprecated_push_dummy_frame); | |
1648 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PUSH_DUMMY_FRAME) | |
1649 | #error "Non multi-arch definition of DEPRECATED_PUSH_DUMMY_FRAME" | |
83905903 | 1650 | #endif |
c25083af | 1651 | #if !defined (DEPRECATED_PUSH_DUMMY_FRAME) |
f3824013 | 1652 | #define DEPRECATED_PUSH_DUMMY_FRAME (gdbarch_deprecated_push_dummy_frame (current_gdbarch)) |
0f71a2f6 | 1653 | #endif |
0f71a2f6 | 1654 | |
28f617b3 AC |
1655 | /* NOTE: This can be handled directly in push_dummy_call. */ |
1656 | ||
1657 | #if defined (DEPRECATED_PUSH_RETURN_ADDRESS) | |
1658 | /* Legacy for systems yet to multi-arch DEPRECATED_PUSH_RETURN_ADDRESS */ | |
1659 | #if !defined (DEPRECATED_PUSH_RETURN_ADDRESS_P) | |
1660 | #define DEPRECATED_PUSH_RETURN_ADDRESS_P() (1) | |
69a0d5f4 AC |
1661 | #endif |
1662 | #endif | |
1663 | ||
1664 | /* Default predicate for non- multi-arch targets. */ | |
28f617b3 AC |
1665 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PUSH_RETURN_ADDRESS_P) |
1666 | #define DEPRECATED_PUSH_RETURN_ADDRESS_P() (0) | |
69a0d5f4 AC |
1667 | #endif |
1668 | ||
28f617b3 AC |
1669 | extern int gdbarch_deprecated_push_return_address_p (struct gdbarch *gdbarch); |
1670 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PUSH_RETURN_ADDRESS_P) | |
1671 | #error "Non multi-arch definition of DEPRECATED_PUSH_RETURN_ADDRESS" | |
69a0d5f4 | 1672 | #endif |
28f617b3 AC |
1673 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_PUSH_RETURN_ADDRESS_P) |
1674 | #define DEPRECATED_PUSH_RETURN_ADDRESS_P() (gdbarch_deprecated_push_return_address_p (current_gdbarch)) | |
69a0d5f4 AC |
1675 | #endif |
1676 | ||
1677 | /* Default (function) for non- multi-arch platforms. */ | |
28f617b3 AC |
1678 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_PUSH_RETURN_ADDRESS) |
1679 | #define DEPRECATED_PUSH_RETURN_ADDRESS(pc, sp) (internal_error (__FILE__, __LINE__, "DEPRECATED_PUSH_RETURN_ADDRESS"), 0) | |
69a0d5f4 AC |
1680 | #endif |
1681 | ||
28f617b3 AC |
1682 | typedef CORE_ADDR (gdbarch_deprecated_push_return_address_ftype) (CORE_ADDR pc, CORE_ADDR sp); |
1683 | extern CORE_ADDR gdbarch_deprecated_push_return_address (struct gdbarch *gdbarch, CORE_ADDR pc, CORE_ADDR sp); | |
1684 | extern void set_gdbarch_deprecated_push_return_address (struct gdbarch *gdbarch, gdbarch_deprecated_push_return_address_ftype *deprecated_push_return_address); | |
1685 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_PUSH_RETURN_ADDRESS) | |
1686 | #error "Non multi-arch definition of DEPRECATED_PUSH_RETURN_ADDRESS" | |
83905903 | 1687 | #endif |
c25083af | 1688 | #if !defined (DEPRECATED_PUSH_RETURN_ADDRESS) |
28f617b3 | 1689 | #define DEPRECATED_PUSH_RETURN_ADDRESS(pc, sp) (gdbarch_deprecated_push_return_address (current_gdbarch, pc, sp)) |
0f71a2f6 | 1690 | #endif |
0f71a2f6 | 1691 | |
749b82f6 AC |
1692 | #if defined (DEPRECATED_POP_FRAME) |
1693 | /* Legacy for systems yet to multi-arch DEPRECATED_POP_FRAME */ | |
1694 | #if !defined (DEPRECATED_POP_FRAME_P) | |
1695 | #define DEPRECATED_POP_FRAME_P() (1) | |
dedc2a2b AC |
1696 | #endif |
1697 | #endif | |
1698 | ||
1699 | /* Default predicate for non- multi-arch targets. */ | |
749b82f6 AC |
1700 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_POP_FRAME_P) |
1701 | #define DEPRECATED_POP_FRAME_P() (0) | |
dedc2a2b AC |
1702 | #endif |
1703 | ||
749b82f6 AC |
1704 | extern int gdbarch_deprecated_pop_frame_p (struct gdbarch *gdbarch); |
1705 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_POP_FRAME_P) | |
1706 | #error "Non multi-arch definition of DEPRECATED_POP_FRAME" | |
dedc2a2b | 1707 | #endif |
749b82f6 AC |
1708 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_POP_FRAME_P) |
1709 | #define DEPRECATED_POP_FRAME_P() (gdbarch_deprecated_pop_frame_p (current_gdbarch)) | |
dedc2a2b AC |
1710 | #endif |
1711 | ||
1712 | /* Default (function) for non- multi-arch platforms. */ | |
749b82f6 AC |
1713 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_POP_FRAME) |
1714 | #define DEPRECATED_POP_FRAME (internal_error (__FILE__, __LINE__, "DEPRECATED_POP_FRAME"), 0) | |
dedc2a2b AC |
1715 | #endif |
1716 | ||
749b82f6 AC |
1717 | typedef void (gdbarch_deprecated_pop_frame_ftype) (void); |
1718 | extern void gdbarch_deprecated_pop_frame (struct gdbarch *gdbarch); | |
1719 | extern void set_gdbarch_deprecated_pop_frame (struct gdbarch *gdbarch, gdbarch_deprecated_pop_frame_ftype *deprecated_pop_frame); | |
1720 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_POP_FRAME) | |
1721 | #error "Non multi-arch definition of DEPRECATED_POP_FRAME" | |
83905903 | 1722 | #endif |
c25083af | 1723 | #if !defined (DEPRECATED_POP_FRAME) |
749b82f6 | 1724 | #define DEPRECATED_POP_FRAME (gdbarch_deprecated_pop_frame (current_gdbarch)) |
0f71a2f6 | 1725 | #endif |
0f71a2f6 | 1726 | |
4183d812 AC |
1727 | /* NOTE: cagney/2003-03-24: Replaced by PUSH_ARGUMENTS. */ |
1728 | ||
1729 | #if defined (DEPRECATED_STORE_STRUCT_RETURN) | |
1730 | /* Legacy for systems yet to multi-arch DEPRECATED_STORE_STRUCT_RETURN */ | |
1731 | #if !defined (DEPRECATED_STORE_STRUCT_RETURN_P) | |
1732 | #define DEPRECATED_STORE_STRUCT_RETURN_P() (1) | |
1733 | #endif | |
1734 | #endif | |
1735 | ||
1736 | /* Default predicate for non- multi-arch targets. */ | |
1737 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_STORE_STRUCT_RETURN_P) | |
1738 | #define DEPRECATED_STORE_STRUCT_RETURN_P() (0) | |
1739 | #endif | |
1740 | ||
1741 | extern int gdbarch_deprecated_store_struct_return_p (struct gdbarch *gdbarch); | |
1742 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_STORE_STRUCT_RETURN_P) | |
1743 | #error "Non multi-arch definition of DEPRECATED_STORE_STRUCT_RETURN" | |
1744 | #endif | |
1745 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_STORE_STRUCT_RETURN_P) | |
1746 | #define DEPRECATED_STORE_STRUCT_RETURN_P() (gdbarch_deprecated_store_struct_return_p (current_gdbarch)) | |
1747 | #endif | |
1748 | ||
1749 | /* Default (function) for non- multi-arch platforms. */ | |
1750 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_STORE_STRUCT_RETURN) | |
1751 | #define DEPRECATED_STORE_STRUCT_RETURN(addr, sp) (internal_error (__FILE__, __LINE__, "DEPRECATED_STORE_STRUCT_RETURN"), 0) | |
1752 | #endif | |
1753 | ||
1754 | typedef void (gdbarch_deprecated_store_struct_return_ftype) (CORE_ADDR addr, CORE_ADDR sp); | |
1755 | extern void gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch, CORE_ADDR addr, CORE_ADDR sp); | |
1756 | extern void set_gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch, gdbarch_deprecated_store_struct_return_ftype *deprecated_store_struct_return); | |
1757 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_STORE_STRUCT_RETURN) | |
1758 | #error "Non multi-arch definition of DEPRECATED_STORE_STRUCT_RETURN" | |
83905903 | 1759 | #endif |
c25083af | 1760 | #if !defined (DEPRECATED_STORE_STRUCT_RETURN) |
4183d812 | 1761 | #define DEPRECATED_STORE_STRUCT_RETURN(addr, sp) (gdbarch_deprecated_store_struct_return (current_gdbarch, addr, sp)) |
0f71a2f6 | 1762 | #endif |
0f71a2f6 | 1763 | |
ebba8386 AC |
1764 | /* Default (function) for non- multi-arch platforms. */ |
1765 | #if (!GDB_MULTI_ARCH) && !defined (EXTRACT_RETURN_VALUE) | |
1766 | #define EXTRACT_RETURN_VALUE(type, regcache, valbuf) (legacy_extract_return_value (type, regcache, valbuf)) | |
1767 | #endif | |
1768 | ||
1769 | typedef void (gdbarch_extract_return_value_ftype) (struct type *type, struct regcache *regcache, void *valbuf); | |
1770 | extern void gdbarch_extract_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, void *valbuf); | |
1771 | extern void set_gdbarch_extract_return_value (struct gdbarch *gdbarch, gdbarch_extract_return_value_ftype *extract_return_value); | |
1772 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (EXTRACT_RETURN_VALUE) | |
1773 | #error "Non multi-arch definition of EXTRACT_RETURN_VALUE" | |
1774 | #endif | |
c25083af | 1775 | #if !defined (EXTRACT_RETURN_VALUE) |
ebba8386 AC |
1776 | #define EXTRACT_RETURN_VALUE(type, regcache, valbuf) (gdbarch_extract_return_value (current_gdbarch, type, regcache, valbuf)) |
1777 | #endif | |
ebba8386 AC |
1778 | |
1779 | /* Default (function) for non- multi-arch platforms. */ | |
1780 | #if (!GDB_MULTI_ARCH) && !defined (STORE_RETURN_VALUE) | |
1781 | #define STORE_RETURN_VALUE(type, regcache, valbuf) (legacy_store_return_value (type, regcache, valbuf)) | |
1782 | #endif | |
1783 | ||
1784 | typedef void (gdbarch_store_return_value_ftype) (struct type *type, struct regcache *regcache, const void *valbuf); | |
1785 | extern void gdbarch_store_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, const void *valbuf); | |
104c1213 | 1786 | extern void set_gdbarch_store_return_value (struct gdbarch *gdbarch, gdbarch_store_return_value_ftype *store_return_value); |
83905903 AC |
1787 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (STORE_RETURN_VALUE) |
1788 | #error "Non multi-arch definition of STORE_RETURN_VALUE" | |
1789 | #endif | |
c25083af | 1790 | #if !defined (STORE_RETURN_VALUE) |
ebba8386 AC |
1791 | #define STORE_RETURN_VALUE(type, regcache, valbuf) (gdbarch_store_return_value (current_gdbarch, type, regcache, valbuf)) |
1792 | #endif | |
ebba8386 AC |
1793 | |
1794 | typedef void (gdbarch_deprecated_extract_return_value_ftype) (struct type *type, char *regbuf, char *valbuf); | |
1795 | extern void gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, struct type *type, char *regbuf, char *valbuf); | |
1796 | extern void set_gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, gdbarch_deprecated_extract_return_value_ftype *deprecated_extract_return_value); | |
1797 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_EXTRACT_RETURN_VALUE) | |
1798 | #error "Non multi-arch definition of DEPRECATED_EXTRACT_RETURN_VALUE" | |
1799 | #endif | |
c25083af | 1800 | #if !defined (DEPRECATED_EXTRACT_RETURN_VALUE) |
ebba8386 AC |
1801 | #define DEPRECATED_EXTRACT_RETURN_VALUE(type, regbuf, valbuf) (gdbarch_deprecated_extract_return_value (current_gdbarch, type, regbuf, valbuf)) |
1802 | #endif | |
ebba8386 AC |
1803 | |
1804 | typedef void (gdbarch_deprecated_store_return_value_ftype) (struct type *type, char *valbuf); | |
1805 | extern void gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch, struct type *type, char *valbuf); | |
1806 | extern void set_gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch, gdbarch_deprecated_store_return_value_ftype *deprecated_store_return_value); | |
1807 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_STORE_RETURN_VALUE) | |
1808 | #error "Non multi-arch definition of DEPRECATED_STORE_RETURN_VALUE" | |
1809 | #endif | |
c25083af | 1810 | #if !defined (DEPRECATED_STORE_RETURN_VALUE) |
ebba8386 | 1811 | #define DEPRECATED_STORE_RETURN_VALUE(type, valbuf) (gdbarch_deprecated_store_return_value (current_gdbarch, type, valbuf)) |
0f71a2f6 | 1812 | #endif |
0f71a2f6 | 1813 | |
049ee0e4 AC |
1814 | #if defined (EXTRACT_STRUCT_VALUE_ADDRESS) |
1815 | /* Legacy for systems yet to multi-arch EXTRACT_STRUCT_VALUE_ADDRESS */ | |
1816 | #if !defined (EXTRACT_STRUCT_VALUE_ADDRESS_P) | |
1817 | #define EXTRACT_STRUCT_VALUE_ADDRESS_P() (1) | |
1818 | #endif | |
1819 | #endif | |
1820 | ||
1821 | /* Default predicate for non- multi-arch targets. */ | |
1822 | #if (!GDB_MULTI_ARCH) && !defined (EXTRACT_STRUCT_VALUE_ADDRESS_P) | |
1823 | #define EXTRACT_STRUCT_VALUE_ADDRESS_P() (0) | |
1824 | #endif | |
1825 | ||
1826 | extern int gdbarch_extract_struct_value_address_p (struct gdbarch *gdbarch); | |
1827 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (EXTRACT_STRUCT_VALUE_ADDRESS_P) | |
1828 | #error "Non multi-arch definition of EXTRACT_STRUCT_VALUE_ADDRESS" | |
1829 | #endif | |
1830 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (EXTRACT_STRUCT_VALUE_ADDRESS_P) | |
1831 | #define EXTRACT_STRUCT_VALUE_ADDRESS_P() (gdbarch_extract_struct_value_address_p (current_gdbarch)) | |
1832 | #endif | |
1833 | ||
1834 | /* Default (function) for non- multi-arch platforms. */ | |
1835 | #if (!GDB_MULTI_ARCH) && !defined (EXTRACT_STRUCT_VALUE_ADDRESS) | |
1836 | #define EXTRACT_STRUCT_VALUE_ADDRESS(regcache) (internal_error (__FILE__, __LINE__, "EXTRACT_STRUCT_VALUE_ADDRESS"), 0) | |
1837 | #endif | |
1838 | ||
1839 | typedef CORE_ADDR (gdbarch_extract_struct_value_address_ftype) (struct regcache *regcache); | |
1840 | extern CORE_ADDR gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, struct regcache *regcache); | |
1841 | extern void set_gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, gdbarch_extract_struct_value_address_ftype *extract_struct_value_address); | |
1842 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (EXTRACT_STRUCT_VALUE_ADDRESS) | |
1843 | #error "Non multi-arch definition of EXTRACT_STRUCT_VALUE_ADDRESS" | |
1844 | #endif | |
c25083af | 1845 | #if !defined (EXTRACT_STRUCT_VALUE_ADDRESS) |
049ee0e4 AC |
1846 | #define EXTRACT_STRUCT_VALUE_ADDRESS(regcache) (gdbarch_extract_struct_value_address (current_gdbarch, regcache)) |
1847 | #endif | |
049ee0e4 | 1848 | |
26e9b323 AC |
1849 | #if defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS) |
1850 | /* Legacy for systems yet to multi-arch DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS */ | |
1851 | #if !defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P) | |
1852 | #define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P() (1) | |
d6dd581e AC |
1853 | #endif |
1854 | #endif | |
1855 | ||
1856 | /* Default predicate for non- multi-arch targets. */ | |
26e9b323 AC |
1857 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P) |
1858 | #define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P() (0) | |
d6dd581e AC |
1859 | #endif |
1860 | ||
26e9b323 AC |
1861 | extern int gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch *gdbarch); |
1862 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P) | |
1863 | #error "Non multi-arch definition of DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS" | |
83905903 | 1864 | #endif |
26e9b323 AC |
1865 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P) |
1866 | #define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P() (gdbarch_deprecated_extract_struct_value_address_p (current_gdbarch)) | |
d6dd581e AC |
1867 | #endif |
1868 | ||
1869 | /* Default (function) for non- multi-arch platforms. */ | |
26e9b323 AC |
1870 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS) |
1871 | #define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regbuf) (internal_error (__FILE__, __LINE__, "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS"), 0) | |
d6dd581e AC |
1872 | #endif |
1873 | ||
26e9b323 AC |
1874 | typedef CORE_ADDR (gdbarch_deprecated_extract_struct_value_address_ftype) (char *regbuf); |
1875 | extern CORE_ADDR gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch, char *regbuf); | |
1876 | extern void set_gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch, gdbarch_deprecated_extract_struct_value_address_ftype *deprecated_extract_struct_value_address); | |
1877 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS) | |
1878 | #error "Non multi-arch definition of DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS" | |
83905903 | 1879 | #endif |
c25083af | 1880 | #if !defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS) |
26e9b323 | 1881 | #define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regbuf) (gdbarch_deprecated_extract_struct_value_address (current_gdbarch, regbuf)) |
0f71a2f6 | 1882 | #endif |
0f71a2f6 | 1883 | |
56f12751 AC |
1884 | /* Default (function) for non- multi-arch platforms. */ |
1885 | #if (!GDB_MULTI_ARCH) && !defined (USE_STRUCT_CONVENTION) | |
1886 | #define USE_STRUCT_CONVENTION(gcc_p, value_type) (generic_use_struct_convention (gcc_p, value_type)) | |
1887 | #endif | |
1888 | ||
104c1213 JM |
1889 | typedef int (gdbarch_use_struct_convention_ftype) (int gcc_p, struct type *value_type); |
1890 | extern int gdbarch_use_struct_convention (struct gdbarch *gdbarch, int gcc_p, struct type *value_type); | |
1891 | extern void set_gdbarch_use_struct_convention (struct gdbarch *gdbarch, gdbarch_use_struct_convention_ftype *use_struct_convention); | |
83905903 AC |
1892 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (USE_STRUCT_CONVENTION) |
1893 | #error "Non multi-arch definition of USE_STRUCT_CONVENTION" | |
1894 | #endif | |
c25083af | 1895 | #if !defined (USE_STRUCT_CONVENTION) |
0f71a2f6 JM |
1896 | #define USE_STRUCT_CONVENTION(gcc_p, value_type) (gdbarch_use_struct_convention (current_gdbarch, gcc_p, value_type)) |
1897 | #endif | |
0f71a2f6 | 1898 | |
f30ee0bc AC |
1899 | #if defined (DEPRECATED_FRAME_INIT_SAVED_REGS) |
1900 | /* Legacy for systems yet to multi-arch DEPRECATED_FRAME_INIT_SAVED_REGS */ | |
1901 | #if !defined (DEPRECATED_FRAME_INIT_SAVED_REGS_P) | |
1902 | #define DEPRECATED_FRAME_INIT_SAVED_REGS_P() (1) | |
8f871025 AC |
1903 | #endif |
1904 | #endif | |
1905 | ||
1906 | /* Default predicate for non- multi-arch targets. */ | |
f30ee0bc AC |
1907 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_INIT_SAVED_REGS_P) |
1908 | #define DEPRECATED_FRAME_INIT_SAVED_REGS_P() (0) | |
8f871025 AC |
1909 | #endif |
1910 | ||
f30ee0bc AC |
1911 | extern int gdbarch_deprecated_frame_init_saved_regs_p (struct gdbarch *gdbarch); |
1912 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_INIT_SAVED_REGS_P) | |
1913 | #error "Non multi-arch definition of DEPRECATED_FRAME_INIT_SAVED_REGS" | |
8f871025 | 1914 | #endif |
f30ee0bc AC |
1915 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_FRAME_INIT_SAVED_REGS_P) |
1916 | #define DEPRECATED_FRAME_INIT_SAVED_REGS_P() (gdbarch_deprecated_frame_init_saved_regs_p (current_gdbarch)) | |
8f871025 AC |
1917 | #endif |
1918 | ||
1919 | /* Default (function) for non- multi-arch platforms. */ | |
f30ee0bc AC |
1920 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_INIT_SAVED_REGS) |
1921 | #define DEPRECATED_FRAME_INIT_SAVED_REGS(frame) (internal_error (__FILE__, __LINE__, "DEPRECATED_FRAME_INIT_SAVED_REGS"), 0) | |
8f871025 AC |
1922 | #endif |
1923 | ||
f30ee0bc AC |
1924 | typedef void (gdbarch_deprecated_frame_init_saved_regs_ftype) (struct frame_info *frame); |
1925 | extern void gdbarch_deprecated_frame_init_saved_regs (struct gdbarch *gdbarch, struct frame_info *frame); | |
1926 | extern void set_gdbarch_deprecated_frame_init_saved_regs (struct gdbarch *gdbarch, gdbarch_deprecated_frame_init_saved_regs_ftype *deprecated_frame_init_saved_regs); | |
1927 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_INIT_SAVED_REGS) | |
1928 | #error "Non multi-arch definition of DEPRECATED_FRAME_INIT_SAVED_REGS" | |
83905903 | 1929 | #endif |
c25083af | 1930 | #if !defined (DEPRECATED_FRAME_INIT_SAVED_REGS) |
f30ee0bc | 1931 | #define DEPRECATED_FRAME_INIT_SAVED_REGS(frame) (gdbarch_deprecated_frame_init_saved_regs (current_gdbarch, frame)) |
0f71a2f6 | 1932 | #endif |
0f71a2f6 | 1933 | |
e9582e71 AC |
1934 | #if defined (DEPRECATED_INIT_EXTRA_FRAME_INFO) |
1935 | /* Legacy for systems yet to multi-arch DEPRECATED_INIT_EXTRA_FRAME_INFO */ | |
1936 | #if !defined (DEPRECATED_INIT_EXTRA_FRAME_INFO_P) | |
1937 | #define DEPRECATED_INIT_EXTRA_FRAME_INFO_P() (1) | |
5fdff426 AC |
1938 | #endif |
1939 | #endif | |
1940 | ||
1941 | /* Default predicate for non- multi-arch targets. */ | |
e9582e71 AC |
1942 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_INIT_EXTRA_FRAME_INFO_P) |
1943 | #define DEPRECATED_INIT_EXTRA_FRAME_INFO_P() (0) | |
5fdff426 AC |
1944 | #endif |
1945 | ||
e9582e71 AC |
1946 | extern int gdbarch_deprecated_init_extra_frame_info_p (struct gdbarch *gdbarch); |
1947 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_INIT_EXTRA_FRAME_INFO_P) | |
1948 | #error "Non multi-arch definition of DEPRECATED_INIT_EXTRA_FRAME_INFO" | |
5fdff426 | 1949 | #endif |
e9582e71 AC |
1950 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_INIT_EXTRA_FRAME_INFO_P) |
1951 | #define DEPRECATED_INIT_EXTRA_FRAME_INFO_P() (gdbarch_deprecated_init_extra_frame_info_p (current_gdbarch)) | |
5fdff426 AC |
1952 | #endif |
1953 | ||
1954 | /* Default (function) for non- multi-arch platforms. */ | |
e9582e71 AC |
1955 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_INIT_EXTRA_FRAME_INFO) |
1956 | #define DEPRECATED_INIT_EXTRA_FRAME_INFO(fromleaf, frame) (internal_error (__FILE__, __LINE__, "DEPRECATED_INIT_EXTRA_FRAME_INFO"), 0) | |
5fdff426 AC |
1957 | #endif |
1958 | ||
e9582e71 AC |
1959 | typedef void (gdbarch_deprecated_init_extra_frame_info_ftype) (int fromleaf, struct frame_info *frame); |
1960 | extern void gdbarch_deprecated_init_extra_frame_info (struct gdbarch *gdbarch, int fromleaf, struct frame_info *frame); | |
1961 | extern void set_gdbarch_deprecated_init_extra_frame_info (struct gdbarch *gdbarch, gdbarch_deprecated_init_extra_frame_info_ftype *deprecated_init_extra_frame_info); | |
1962 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_INIT_EXTRA_FRAME_INFO) | |
1963 | #error "Non multi-arch definition of DEPRECATED_INIT_EXTRA_FRAME_INFO" | |
83905903 | 1964 | #endif |
c25083af | 1965 | #if !defined (DEPRECATED_INIT_EXTRA_FRAME_INFO) |
e9582e71 | 1966 | #define DEPRECATED_INIT_EXTRA_FRAME_INFO(fromleaf, frame) (gdbarch_deprecated_init_extra_frame_info (current_gdbarch, fromleaf, frame)) |
0f71a2f6 | 1967 | #endif |
0f71a2f6 | 1968 | |
104c1213 JM |
1969 | typedef CORE_ADDR (gdbarch_skip_prologue_ftype) (CORE_ADDR ip); |
1970 | extern CORE_ADDR gdbarch_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR ip); | |
1971 | extern void set_gdbarch_skip_prologue (struct gdbarch *gdbarch, gdbarch_skip_prologue_ftype *skip_prologue); | |
83905903 AC |
1972 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SKIP_PROLOGUE) |
1973 | #error "Non multi-arch definition of SKIP_PROLOGUE" | |
1974 | #endif | |
c25083af | 1975 | #if !defined (SKIP_PROLOGUE) |
0f71a2f6 JM |
1976 | #define SKIP_PROLOGUE(ip) (gdbarch_skip_prologue (current_gdbarch, ip)) |
1977 | #endif | |
0f71a2f6 | 1978 | |
33489c5b | 1979 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 1980 | #if (!GDB_MULTI_ARCH) && !defined (PROLOGUE_FRAMELESS_P) |
33489c5b AC |
1981 | #define PROLOGUE_FRAMELESS_P(ip) (generic_prologue_frameless_p (ip)) |
1982 | #endif | |
1983 | ||
dad41f9a AC |
1984 | typedef int (gdbarch_prologue_frameless_p_ftype) (CORE_ADDR ip); |
1985 | extern int gdbarch_prologue_frameless_p (struct gdbarch *gdbarch, CORE_ADDR ip); | |
1986 | extern void set_gdbarch_prologue_frameless_p (struct gdbarch *gdbarch, gdbarch_prologue_frameless_p_ftype *prologue_frameless_p); | |
83905903 AC |
1987 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (PROLOGUE_FRAMELESS_P) |
1988 | #error "Non multi-arch definition of PROLOGUE_FRAMELESS_P" | |
1989 | #endif | |
c25083af | 1990 | #if !defined (PROLOGUE_FRAMELESS_P) |
dad41f9a AC |
1991 | #define PROLOGUE_FRAMELESS_P(ip) (gdbarch_prologue_frameless_p (current_gdbarch, ip)) |
1992 | #endif | |
1993 | ||
104c1213 JM |
1994 | typedef int (gdbarch_inner_than_ftype) (CORE_ADDR lhs, CORE_ADDR rhs); |
1995 | extern int gdbarch_inner_than (struct gdbarch *gdbarch, CORE_ADDR lhs, CORE_ADDR rhs); | |
1996 | extern void set_gdbarch_inner_than (struct gdbarch *gdbarch, gdbarch_inner_than_ftype *inner_than); | |
83905903 AC |
1997 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (INNER_THAN) |
1998 | #error "Non multi-arch definition of INNER_THAN" | |
1999 | #endif | |
c25083af | 2000 | #if !defined (INNER_THAN) |
0f71a2f6 JM |
2001 | #define INNER_THAN(lhs, rhs) (gdbarch_inner_than (current_gdbarch, lhs, rhs)) |
2002 | #endif | |
0f71a2f6 | 2003 | |
f4f9705a AC |
2004 | typedef const unsigned char * (gdbarch_breakpoint_from_pc_ftype) (CORE_ADDR *pcptr, int *lenptr); |
2005 | extern const unsigned char * gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr); | |
104c1213 | 2006 | extern void set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc); |
83905903 AC |
2007 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (BREAKPOINT_FROM_PC) |
2008 | #error "Non multi-arch definition of BREAKPOINT_FROM_PC" | |
2009 | #endif | |
c25083af | 2010 | #if !defined (BREAKPOINT_FROM_PC) |
0f71a2f6 JM |
2011 | #define BREAKPOINT_FROM_PC(pcptr, lenptr) (gdbarch_breakpoint_from_pc (current_gdbarch, pcptr, lenptr)) |
2012 | #endif | |
33489c5b AC |
2013 | |
2014 | /* Default (function) for non- multi-arch platforms. */ | |
6166d547 | 2015 | #if (!GDB_MULTI_ARCH) && !defined (MEMORY_INSERT_BREAKPOINT) |
33489c5b AC |
2016 | #define MEMORY_INSERT_BREAKPOINT(addr, contents_cache) (default_memory_insert_breakpoint (addr, contents_cache)) |
2017 | #endif | |
0f71a2f6 | 2018 | |
917317f4 JM |
2019 | typedef int (gdbarch_memory_insert_breakpoint_ftype) (CORE_ADDR addr, char *contents_cache); |
2020 | extern int gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, CORE_ADDR addr, char *contents_cache); | |
2021 | extern void set_gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, gdbarch_memory_insert_breakpoint_ftype *memory_insert_breakpoint); | |
83905903 AC |
2022 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (MEMORY_INSERT_BREAKPOINT) |
2023 | #error "Non multi-arch definition of MEMORY_INSERT_BREAKPOINT" | |
2024 | #endif | |
c25083af | 2025 | #if !defined (MEMORY_INSERT_BREAKPOINT) |
917317f4 JM |
2026 | #define MEMORY_INSERT_BREAKPOINT(addr, contents_cache) (gdbarch_memory_insert_breakpoint (current_gdbarch, addr, contents_cache)) |
2027 | #endif | |
33489c5b AC |
2028 | |
2029 | /* Default (function) for non- multi-arch platforms. */ | |
6166d547 | 2030 | #if (!GDB_MULTI_ARCH) && !defined (MEMORY_REMOVE_BREAKPOINT) |
33489c5b AC |
2031 | #define MEMORY_REMOVE_BREAKPOINT(addr, contents_cache) (default_memory_remove_breakpoint (addr, contents_cache)) |
2032 | #endif | |
917317f4 JM |
2033 | |
2034 | typedef int (gdbarch_memory_remove_breakpoint_ftype) (CORE_ADDR addr, char *contents_cache); | |
2035 | extern int gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, CORE_ADDR addr, char *contents_cache); | |
2036 | extern void set_gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint); | |
83905903 AC |
2037 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (MEMORY_REMOVE_BREAKPOINT) |
2038 | #error "Non multi-arch definition of MEMORY_REMOVE_BREAKPOINT" | |
2039 | #endif | |
c25083af | 2040 | #if !defined (MEMORY_REMOVE_BREAKPOINT) |
917317f4 JM |
2041 | #define MEMORY_REMOVE_BREAKPOINT(addr, contents_cache) (gdbarch_memory_remove_breakpoint (current_gdbarch, addr, contents_cache)) |
2042 | #endif | |
917317f4 | 2043 | |
104c1213 JM |
2044 | extern CORE_ADDR gdbarch_decr_pc_after_break (struct gdbarch *gdbarch); |
2045 | extern void set_gdbarch_decr_pc_after_break (struct gdbarch *gdbarch, CORE_ADDR decr_pc_after_break); | |
83905903 AC |
2046 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DECR_PC_AFTER_BREAK) |
2047 | #error "Non multi-arch definition of DECR_PC_AFTER_BREAK" | |
2048 | #endif | |
c25083af | 2049 | #if !defined (DECR_PC_AFTER_BREAK) |
0f71a2f6 JM |
2050 | #define DECR_PC_AFTER_BREAK (gdbarch_decr_pc_after_break (current_gdbarch)) |
2051 | #endif | |
0f71a2f6 | 2052 | |
e02bc4cc DS |
2053 | /* Default (function) for non- multi-arch platforms. */ |
2054 | #if (!GDB_MULTI_ARCH) && !defined (PREPARE_TO_PROCEED) | |
2055 | #define PREPARE_TO_PROCEED(select_it) (default_prepare_to_proceed (select_it)) | |
2056 | #endif | |
2057 | ||
2058 | typedef int (gdbarch_prepare_to_proceed_ftype) (int select_it); | |
2059 | extern int gdbarch_prepare_to_proceed (struct gdbarch *gdbarch, int select_it); | |
2060 | extern void set_gdbarch_prepare_to_proceed (struct gdbarch *gdbarch, gdbarch_prepare_to_proceed_ftype *prepare_to_proceed); | |
83905903 AC |
2061 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (PREPARE_TO_PROCEED) |
2062 | #error "Non multi-arch definition of PREPARE_TO_PROCEED" | |
2063 | #endif | |
c25083af | 2064 | #if !defined (PREPARE_TO_PROCEED) |
e02bc4cc DS |
2065 | #define PREPARE_TO_PROCEED(select_it) (gdbarch_prepare_to_proceed (current_gdbarch, select_it)) |
2066 | #endif | |
e02bc4cc | 2067 | |
104c1213 JM |
2068 | extern CORE_ADDR gdbarch_function_start_offset (struct gdbarch *gdbarch); |
2069 | extern void set_gdbarch_function_start_offset (struct gdbarch *gdbarch, CORE_ADDR function_start_offset); | |
83905903 AC |
2070 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (FUNCTION_START_OFFSET) |
2071 | #error "Non multi-arch definition of FUNCTION_START_OFFSET" | |
2072 | #endif | |
c25083af | 2073 | #if !defined (FUNCTION_START_OFFSET) |
0f71a2f6 JM |
2074 | #define FUNCTION_START_OFFSET (gdbarch_function_start_offset (current_gdbarch)) |
2075 | #endif | |
0f71a2f6 | 2076 | |
f6684c31 AC |
2077 | typedef void (gdbarch_remote_translate_xfer_address_ftype) (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len); |
2078 | extern void gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len); | |
104c1213 | 2079 | extern void set_gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, gdbarch_remote_translate_xfer_address_ftype *remote_translate_xfer_address); |
0f71a2f6 | 2080 | |
104c1213 JM |
2081 | extern CORE_ADDR gdbarch_frame_args_skip (struct gdbarch *gdbarch); |
2082 | extern void set_gdbarch_frame_args_skip (struct gdbarch *gdbarch, CORE_ADDR frame_args_skip); | |
83905903 AC |
2083 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (FRAME_ARGS_SKIP) |
2084 | #error "Non multi-arch definition of FRAME_ARGS_SKIP" | |
2085 | #endif | |
c25083af | 2086 | #if !defined (FRAME_ARGS_SKIP) |
0f71a2f6 JM |
2087 | #define FRAME_ARGS_SKIP (gdbarch_frame_args_skip (current_gdbarch)) |
2088 | #endif | |
0f71a2f6 | 2089 | |
33489c5b | 2090 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 2091 | #if (!GDB_MULTI_ARCH) && !defined (FRAMELESS_FUNCTION_INVOCATION) |
33489c5b AC |
2092 | #define FRAMELESS_FUNCTION_INVOCATION(fi) (generic_frameless_function_invocation_not (fi)) |
2093 | #endif | |
2094 | ||
104c1213 JM |
2095 | typedef int (gdbarch_frameless_function_invocation_ftype) (struct frame_info *fi); |
2096 | extern int gdbarch_frameless_function_invocation (struct gdbarch *gdbarch, struct frame_info *fi); | |
2097 | extern void set_gdbarch_frameless_function_invocation (struct gdbarch *gdbarch, gdbarch_frameless_function_invocation_ftype *frameless_function_invocation); | |
83905903 AC |
2098 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (FRAMELESS_FUNCTION_INVOCATION) |
2099 | #error "Non multi-arch definition of FRAMELESS_FUNCTION_INVOCATION" | |
2100 | #endif | |
c25083af | 2101 | #if !defined (FRAMELESS_FUNCTION_INVOCATION) |
0f71a2f6 JM |
2102 | #define FRAMELESS_FUNCTION_INVOCATION(fi) (gdbarch_frameless_function_invocation (current_gdbarch, fi)) |
2103 | #endif | |
0f71a2f6 | 2104 | |
618ce49f AC |
2105 | #if defined (DEPRECATED_FRAME_CHAIN) |
2106 | /* Legacy for systems yet to multi-arch DEPRECATED_FRAME_CHAIN */ | |
2107 | #if !defined (DEPRECATED_FRAME_CHAIN_P) | |
2108 | #define DEPRECATED_FRAME_CHAIN_P() (1) | |
d62d1979 AC |
2109 | #endif |
2110 | #endif | |
2111 | ||
2112 | /* Default predicate for non- multi-arch targets. */ | |
618ce49f AC |
2113 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_CHAIN_P) |
2114 | #define DEPRECATED_FRAME_CHAIN_P() (0) | |
d62d1979 AC |
2115 | #endif |
2116 | ||
618ce49f AC |
2117 | extern int gdbarch_deprecated_frame_chain_p (struct gdbarch *gdbarch); |
2118 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_CHAIN_P) | |
2119 | #error "Non multi-arch definition of DEPRECATED_FRAME_CHAIN" | |
d62d1979 | 2120 | #endif |
618ce49f AC |
2121 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_FRAME_CHAIN_P) |
2122 | #define DEPRECATED_FRAME_CHAIN_P() (gdbarch_deprecated_frame_chain_p (current_gdbarch)) | |
d62d1979 AC |
2123 | #endif |
2124 | ||
2125 | /* Default (function) for non- multi-arch platforms. */ | |
618ce49f AC |
2126 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_CHAIN) |
2127 | #define DEPRECATED_FRAME_CHAIN(frame) (internal_error (__FILE__, __LINE__, "DEPRECATED_FRAME_CHAIN"), 0) | |
d62d1979 AC |
2128 | #endif |
2129 | ||
618ce49f AC |
2130 | typedef CORE_ADDR (gdbarch_deprecated_frame_chain_ftype) (struct frame_info *frame); |
2131 | extern CORE_ADDR gdbarch_deprecated_frame_chain (struct gdbarch *gdbarch, struct frame_info *frame); | |
2132 | extern void set_gdbarch_deprecated_frame_chain (struct gdbarch *gdbarch, gdbarch_deprecated_frame_chain_ftype *deprecated_frame_chain); | |
2133 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_CHAIN) | |
2134 | #error "Non multi-arch definition of DEPRECATED_FRAME_CHAIN" | |
83905903 | 2135 | #endif |
c25083af | 2136 | #if !defined (DEPRECATED_FRAME_CHAIN) |
618ce49f | 2137 | #define DEPRECATED_FRAME_CHAIN(frame) (gdbarch_deprecated_frame_chain (current_gdbarch, frame)) |
0f71a2f6 | 2138 | #endif |
0f71a2f6 | 2139 | |
618ce49f AC |
2140 | #if defined (DEPRECATED_FRAME_CHAIN_VALID) |
2141 | /* Legacy for systems yet to multi-arch DEPRECATED_FRAME_CHAIN_VALID */ | |
2142 | #if !defined (DEPRECATED_FRAME_CHAIN_VALID_P) | |
2143 | #define DEPRECATED_FRAME_CHAIN_VALID_P() (1) | |
51603483 DJ |
2144 | #endif |
2145 | #endif | |
2146 | ||
2147 | /* Default predicate for non- multi-arch targets. */ | |
618ce49f AC |
2148 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_CHAIN_VALID_P) |
2149 | #define DEPRECATED_FRAME_CHAIN_VALID_P() (0) | |
51603483 DJ |
2150 | #endif |
2151 | ||
618ce49f AC |
2152 | extern int gdbarch_deprecated_frame_chain_valid_p (struct gdbarch *gdbarch); |
2153 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_CHAIN_VALID_P) | |
2154 | #error "Non multi-arch definition of DEPRECATED_FRAME_CHAIN_VALID" | |
51603483 | 2155 | #endif |
618ce49f AC |
2156 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_FRAME_CHAIN_VALID_P) |
2157 | #define DEPRECATED_FRAME_CHAIN_VALID_P() (gdbarch_deprecated_frame_chain_valid_p (current_gdbarch)) | |
51603483 | 2158 | #endif |
7f55af32 AC |
2159 | |
2160 | /* Default (function) for non- multi-arch platforms. */ | |
618ce49f AC |
2161 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_CHAIN_VALID) |
2162 | #define DEPRECATED_FRAME_CHAIN_VALID(chain, thisframe) (internal_error (__FILE__, __LINE__, "DEPRECATED_FRAME_CHAIN_VALID"), 0) | |
7f55af32 | 2163 | #endif |
028c194b | 2164 | |
618ce49f AC |
2165 | typedef int (gdbarch_deprecated_frame_chain_valid_ftype) (CORE_ADDR chain, struct frame_info *thisframe); |
2166 | extern int gdbarch_deprecated_frame_chain_valid (struct gdbarch *gdbarch, CORE_ADDR chain, struct frame_info *thisframe); | |
2167 | extern void set_gdbarch_deprecated_frame_chain_valid (struct gdbarch *gdbarch, gdbarch_deprecated_frame_chain_valid_ftype *deprecated_frame_chain_valid); | |
2168 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_CHAIN_VALID) | |
2169 | #error "Non multi-arch definition of DEPRECATED_FRAME_CHAIN_VALID" | |
83905903 | 2170 | #endif |
c25083af | 2171 | #if !defined (DEPRECATED_FRAME_CHAIN_VALID) |
618ce49f | 2172 | #define DEPRECATED_FRAME_CHAIN_VALID(chain, thisframe) (gdbarch_deprecated_frame_chain_valid (current_gdbarch, chain, thisframe)) |
0f71a2f6 | 2173 | #endif |
0f71a2f6 | 2174 | |
8bedc050 AC |
2175 | /* DEPRECATED_FRAME_SAVED_PC has been replaced by UNWIND_PC. Please |
2176 | note, per UNWIND_PC's doco, that while the two have similar | |
2177 | interfaces they have very different underlying implementations. */ | |
12cc2063 | 2178 | |
8bedc050 AC |
2179 | #if defined (DEPRECATED_FRAME_SAVED_PC) |
2180 | /* Legacy for systems yet to multi-arch DEPRECATED_FRAME_SAVED_PC */ | |
2181 | #if !defined (DEPRECATED_FRAME_SAVED_PC_P) | |
2182 | #define DEPRECATED_FRAME_SAVED_PC_P() (1) | |
d62d1979 AC |
2183 | #endif |
2184 | #endif | |
2185 | ||
2186 | /* Default predicate for non- multi-arch targets. */ | |
8bedc050 AC |
2187 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_SAVED_PC_P) |
2188 | #define DEPRECATED_FRAME_SAVED_PC_P() (0) | |
d62d1979 AC |
2189 | #endif |
2190 | ||
8bedc050 AC |
2191 | extern int gdbarch_deprecated_frame_saved_pc_p (struct gdbarch *gdbarch); |
2192 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_SAVED_PC_P) | |
2193 | #error "Non multi-arch definition of DEPRECATED_FRAME_SAVED_PC" | |
d62d1979 | 2194 | #endif |
8bedc050 AC |
2195 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_FRAME_SAVED_PC_P) |
2196 | #define DEPRECATED_FRAME_SAVED_PC_P() (gdbarch_deprecated_frame_saved_pc_p (current_gdbarch)) | |
d62d1979 AC |
2197 | #endif |
2198 | ||
2199 | /* Default (function) for non- multi-arch platforms. */ | |
8bedc050 AC |
2200 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_FRAME_SAVED_PC) |
2201 | #define DEPRECATED_FRAME_SAVED_PC(fi) (internal_error (__FILE__, __LINE__, "DEPRECATED_FRAME_SAVED_PC"), 0) | |
d62d1979 AC |
2202 | #endif |
2203 | ||
8bedc050 AC |
2204 | typedef CORE_ADDR (gdbarch_deprecated_frame_saved_pc_ftype) (struct frame_info *fi); |
2205 | extern CORE_ADDR gdbarch_deprecated_frame_saved_pc (struct gdbarch *gdbarch, struct frame_info *fi); | |
2206 | extern void set_gdbarch_deprecated_frame_saved_pc (struct gdbarch *gdbarch, gdbarch_deprecated_frame_saved_pc_ftype *deprecated_frame_saved_pc); | |
2207 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_FRAME_SAVED_PC) | |
2208 | #error "Non multi-arch definition of DEPRECATED_FRAME_SAVED_PC" | |
83905903 | 2209 | #endif |
c25083af | 2210 | #if !defined (DEPRECATED_FRAME_SAVED_PC) |
8bedc050 | 2211 | #define DEPRECATED_FRAME_SAVED_PC(fi) (gdbarch_deprecated_frame_saved_pc (current_gdbarch, fi)) |
0f71a2f6 | 2212 | #endif |
0f71a2f6 | 2213 | |
12cc2063 AC |
2214 | extern int gdbarch_unwind_pc_p (struct gdbarch *gdbarch); |
2215 | ||
2216 | typedef CORE_ADDR (gdbarch_unwind_pc_ftype) (struct gdbarch *gdbarch, struct frame_info *next_frame); | |
2217 | extern CORE_ADDR gdbarch_unwind_pc (struct gdbarch *gdbarch, struct frame_info *next_frame); | |
2218 | extern void set_gdbarch_unwind_pc (struct gdbarch *gdbarch, gdbarch_unwind_pc_ftype *unwind_pc); | |
2219 | ||
f4ded5b1 AC |
2220 | /* Default (function) for non- multi-arch platforms. */ |
2221 | #if (!GDB_MULTI_ARCH) && !defined (FRAME_ARGS_ADDRESS) | |
7d6a26a7 | 2222 | #define FRAME_ARGS_ADDRESS(fi) (get_frame_base (fi)) |
f4ded5b1 AC |
2223 | #endif |
2224 | ||
104c1213 JM |
2225 | typedef CORE_ADDR (gdbarch_frame_args_address_ftype) (struct frame_info *fi); |
2226 | extern CORE_ADDR gdbarch_frame_args_address (struct gdbarch *gdbarch, struct frame_info *fi); | |
2227 | extern void set_gdbarch_frame_args_address (struct gdbarch *gdbarch, gdbarch_frame_args_address_ftype *frame_args_address); | |
83905903 AC |
2228 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (FRAME_ARGS_ADDRESS) |
2229 | #error "Non multi-arch definition of FRAME_ARGS_ADDRESS" | |
2230 | #endif | |
c25083af | 2231 | #if !defined (FRAME_ARGS_ADDRESS) |
0f71a2f6 JM |
2232 | #define FRAME_ARGS_ADDRESS(fi) (gdbarch_frame_args_address (current_gdbarch, fi)) |
2233 | #endif | |
0f71a2f6 | 2234 | |
f4ded5b1 AC |
2235 | /* Default (function) for non- multi-arch platforms. */ |
2236 | #if (!GDB_MULTI_ARCH) && !defined (FRAME_LOCALS_ADDRESS) | |
7d6a26a7 | 2237 | #define FRAME_LOCALS_ADDRESS(fi) (get_frame_base (fi)) |
f4ded5b1 AC |
2238 | #endif |
2239 | ||
104c1213 JM |
2240 | typedef CORE_ADDR (gdbarch_frame_locals_address_ftype) (struct frame_info *fi); |
2241 | extern CORE_ADDR gdbarch_frame_locals_address (struct gdbarch *gdbarch, struct frame_info *fi); | |
2242 | extern void set_gdbarch_frame_locals_address (struct gdbarch *gdbarch, gdbarch_frame_locals_address_ftype *frame_locals_address); | |
83905903 AC |
2243 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (FRAME_LOCALS_ADDRESS) |
2244 | #error "Non multi-arch definition of FRAME_LOCALS_ADDRESS" | |
2245 | #endif | |
c25083af | 2246 | #if !defined (FRAME_LOCALS_ADDRESS) |
0f71a2f6 JM |
2247 | #define FRAME_LOCALS_ADDRESS(fi) (gdbarch_frame_locals_address (current_gdbarch, fi)) |
2248 | #endif | |
0f71a2f6 | 2249 | |
6913c89a AC |
2250 | #if defined (DEPRECATED_SAVED_PC_AFTER_CALL) |
2251 | /* Legacy for systems yet to multi-arch DEPRECATED_SAVED_PC_AFTER_CALL */ | |
2252 | #if !defined (DEPRECATED_SAVED_PC_AFTER_CALL_P) | |
2253 | #define DEPRECATED_SAVED_PC_AFTER_CALL_P() (1) | |
4443bd83 AC |
2254 | #endif |
2255 | #endif | |
2256 | ||
2257 | /* Default predicate for non- multi-arch targets. */ | |
6913c89a AC |
2258 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_SAVED_PC_AFTER_CALL_P) |
2259 | #define DEPRECATED_SAVED_PC_AFTER_CALL_P() (0) | |
4443bd83 AC |
2260 | #endif |
2261 | ||
6913c89a AC |
2262 | extern int gdbarch_deprecated_saved_pc_after_call_p (struct gdbarch *gdbarch); |
2263 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_SAVED_PC_AFTER_CALL_P) | |
2264 | #error "Non multi-arch definition of DEPRECATED_SAVED_PC_AFTER_CALL" | |
4443bd83 | 2265 | #endif |
6913c89a AC |
2266 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_SAVED_PC_AFTER_CALL_P) |
2267 | #define DEPRECATED_SAVED_PC_AFTER_CALL_P() (gdbarch_deprecated_saved_pc_after_call_p (current_gdbarch)) | |
4443bd83 AC |
2268 | #endif |
2269 | ||
2270 | /* Default (function) for non- multi-arch platforms. */ | |
6913c89a AC |
2271 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_SAVED_PC_AFTER_CALL) |
2272 | #define DEPRECATED_SAVED_PC_AFTER_CALL(frame) (internal_error (__FILE__, __LINE__, "DEPRECATED_SAVED_PC_AFTER_CALL"), 0) | |
4443bd83 AC |
2273 | #endif |
2274 | ||
6913c89a AC |
2275 | typedef CORE_ADDR (gdbarch_deprecated_saved_pc_after_call_ftype) (struct frame_info *frame); |
2276 | extern CORE_ADDR gdbarch_deprecated_saved_pc_after_call (struct gdbarch *gdbarch, struct frame_info *frame); | |
2277 | extern void set_gdbarch_deprecated_saved_pc_after_call (struct gdbarch *gdbarch, gdbarch_deprecated_saved_pc_after_call_ftype *deprecated_saved_pc_after_call); | |
2278 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_SAVED_PC_AFTER_CALL) | |
2279 | #error "Non multi-arch definition of DEPRECATED_SAVED_PC_AFTER_CALL" | |
83905903 | 2280 | #endif |
c25083af | 2281 | #if !defined (DEPRECATED_SAVED_PC_AFTER_CALL) |
6913c89a | 2282 | #define DEPRECATED_SAVED_PC_AFTER_CALL(frame) (gdbarch_deprecated_saved_pc_after_call (current_gdbarch, frame)) |
0f71a2f6 | 2283 | #endif |
0f71a2f6 | 2284 | |
104c1213 JM |
2285 | typedef int (gdbarch_frame_num_args_ftype) (struct frame_info *frame); |
2286 | extern int gdbarch_frame_num_args (struct gdbarch *gdbarch, struct frame_info *frame); | |
2287 | extern void set_gdbarch_frame_num_args (struct gdbarch *gdbarch, gdbarch_frame_num_args_ftype *frame_num_args); | |
83905903 AC |
2288 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (FRAME_NUM_ARGS) |
2289 | #error "Non multi-arch definition of FRAME_NUM_ARGS" | |
2290 | #endif | |
c25083af | 2291 | #if !defined (FRAME_NUM_ARGS) |
0f71a2f6 JM |
2292 | #define FRAME_NUM_ARGS(frame) (gdbarch_frame_num_args (current_gdbarch, frame)) |
2293 | #endif | |
0f71a2f6 | 2294 | |
2ada493a AC |
2295 | #if defined (STACK_ALIGN) |
2296 | /* Legacy for systems yet to multi-arch STACK_ALIGN */ | |
eee30e78 | 2297 | #if !defined (STACK_ALIGN_P) |
2ada493a AC |
2298 | #define STACK_ALIGN_P() (1) |
2299 | #endif | |
eee30e78 | 2300 | #endif |
2ada493a | 2301 | |
33489c5b | 2302 | /* Default predicate for non- multi-arch targets. */ |
6166d547 | 2303 | #if (!GDB_MULTI_ARCH) && !defined (STACK_ALIGN_P) |
33489c5b AC |
2304 | #define STACK_ALIGN_P() (0) |
2305 | #endif | |
2306 | ||
2ada493a | 2307 | extern int gdbarch_stack_align_p (struct gdbarch *gdbarch); |
83905903 AC |
2308 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (STACK_ALIGN_P) |
2309 | #error "Non multi-arch definition of STACK_ALIGN" | |
2310 | #endif | |
6166d547 | 2311 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (STACK_ALIGN_P) |
2ada493a AC |
2312 | #define STACK_ALIGN_P() (gdbarch_stack_align_p (current_gdbarch)) |
2313 | #endif | |
2314 | ||
33489c5b | 2315 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 2316 | #if (!GDB_MULTI_ARCH) && !defined (STACK_ALIGN) |
8e65ff28 | 2317 | #define STACK_ALIGN(sp) (internal_error (__FILE__, __LINE__, "STACK_ALIGN"), 0) |
33489c5b AC |
2318 | #endif |
2319 | ||
2ada493a AC |
2320 | typedef CORE_ADDR (gdbarch_stack_align_ftype) (CORE_ADDR sp); |
2321 | extern CORE_ADDR gdbarch_stack_align (struct gdbarch *gdbarch, CORE_ADDR sp); | |
2322 | extern void set_gdbarch_stack_align (struct gdbarch *gdbarch, gdbarch_stack_align_ftype *stack_align); | |
83905903 AC |
2323 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (STACK_ALIGN) |
2324 | #error "Non multi-arch definition of STACK_ALIGN" | |
2325 | #endif | |
c25083af | 2326 | #if !defined (STACK_ALIGN) |
2ada493a AC |
2327 | #define STACK_ALIGN(sp) (gdbarch_stack_align (current_gdbarch, sp)) |
2328 | #endif | |
2329 | ||
dc604539 AC |
2330 | extern int gdbarch_frame_align_p (struct gdbarch *gdbarch); |
2331 | ||
2332 | typedef CORE_ADDR (gdbarch_frame_align_ftype) (struct gdbarch *gdbarch, CORE_ADDR address); | |
2333 | extern CORE_ADDR gdbarch_frame_align (struct gdbarch *gdbarch, CORE_ADDR address); | |
2334 | extern void set_gdbarch_frame_align (struct gdbarch *gdbarch, gdbarch_frame_align_ftype *frame_align); | |
2335 | ||
f933a9c5 AC |
2336 | /* NOTE: cagney/2003-03-24: This is better handled by PUSH_ARGUMENTS. */ |
2337 | ||
0a49d05e | 2338 | /* Default (value) for non- multi-arch platforms. */ |
f933a9c5 AC |
2339 | #if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED) |
2340 | #define DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED (0) | |
0a49d05e AC |
2341 | #endif |
2342 | ||
f933a9c5 AC |
2343 | extern int gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch *gdbarch); |
2344 | extern void set_gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch *gdbarch, int deprecated_extra_stack_alignment_needed); | |
2345 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED) | |
2346 | #error "Non multi-arch definition of DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED" | |
83905903 | 2347 | #endif |
c25083af | 2348 | #if !defined (DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED) |
f933a9c5 | 2349 | #define DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED (gdbarch_deprecated_extra_stack_alignment_needed (current_gdbarch)) |
0a49d05e | 2350 | #endif |
0a49d05e | 2351 | |
d03e67c9 AC |
2352 | #if defined (REG_STRUCT_HAS_ADDR) |
2353 | /* Legacy for systems yet to multi-arch REG_STRUCT_HAS_ADDR */ | |
eee30e78 | 2354 | #if !defined (REG_STRUCT_HAS_ADDR_P) |
d03e67c9 AC |
2355 | #define REG_STRUCT_HAS_ADDR_P() (1) |
2356 | #endif | |
eee30e78 | 2357 | #endif |
d03e67c9 | 2358 | |
33489c5b | 2359 | /* Default predicate for non- multi-arch targets. */ |
6166d547 | 2360 | #if (!GDB_MULTI_ARCH) && !defined (REG_STRUCT_HAS_ADDR_P) |
33489c5b AC |
2361 | #define REG_STRUCT_HAS_ADDR_P() (0) |
2362 | #endif | |
2363 | ||
d03e67c9 | 2364 | extern int gdbarch_reg_struct_has_addr_p (struct gdbarch *gdbarch); |
83905903 AC |
2365 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REG_STRUCT_HAS_ADDR_P) |
2366 | #error "Non multi-arch definition of REG_STRUCT_HAS_ADDR" | |
2367 | #endif | |
6166d547 | 2368 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (REG_STRUCT_HAS_ADDR_P) |
d03e67c9 AC |
2369 | #define REG_STRUCT_HAS_ADDR_P() (gdbarch_reg_struct_has_addr_p (current_gdbarch)) |
2370 | #endif | |
2371 | ||
33489c5b | 2372 | /* Default (function) for non- multi-arch platforms. */ |
6166d547 | 2373 | #if (!GDB_MULTI_ARCH) && !defined (REG_STRUCT_HAS_ADDR) |
8e65ff28 | 2374 | #define REG_STRUCT_HAS_ADDR(gcc_p, type) (internal_error (__FILE__, __LINE__, "REG_STRUCT_HAS_ADDR"), 0) |
33489c5b AC |
2375 | #endif |
2376 | ||
d03e67c9 AC |
2377 | typedef int (gdbarch_reg_struct_has_addr_ftype) (int gcc_p, struct type *type); |
2378 | extern int gdbarch_reg_struct_has_addr (struct gdbarch *gdbarch, int gcc_p, struct type *type); | |
2379 | extern void set_gdbarch_reg_struct_has_addr (struct gdbarch *gdbarch, gdbarch_reg_struct_has_addr_ftype *reg_struct_has_addr); | |
83905903 AC |
2380 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REG_STRUCT_HAS_ADDR) |
2381 | #error "Non multi-arch definition of REG_STRUCT_HAS_ADDR" | |
2382 | #endif | |
c25083af | 2383 | #if !defined (REG_STRUCT_HAS_ADDR) |
d03e67c9 AC |
2384 | #define REG_STRUCT_HAS_ADDR(gcc_p, type) (gdbarch_reg_struct_has_addr (current_gdbarch, gcc_p, type)) |
2385 | #endif | |
2386 | ||
a2ce2e56 AC |
2387 | /* FIXME: kettenis/2003-03-08: This should be replaced by a function |
2388 | parametrized with (at least) the regcache. */ | |
2389 | ||
d1e3cf49 AC |
2390 | #if defined (SAVE_DUMMY_FRAME_TOS) |
2391 | /* Legacy for systems yet to multi-arch SAVE_DUMMY_FRAME_TOS */ | |
eee30e78 | 2392 | #if !defined (SAVE_DUMMY_FRAME_TOS_P) |
d1e3cf49 AC |
2393 | #define SAVE_DUMMY_FRAME_TOS_P() (1) |
2394 | #endif | |
eee30e78 | 2395 | #endif |
d1e3cf49 AC |
2396 | |
2397 | /* Default predicate for non- multi-arch targets. */ | |
6166d547 | 2398 | #if (!GDB_MULTI_ARCH) && !defined (SAVE_DUMMY_FRAME_TOS_P) |
d1e3cf49 AC |
2399 | #define SAVE_DUMMY_FRAME_TOS_P() (0) |
2400 | #endif | |
2401 | ||
2402 | extern int gdbarch_save_dummy_frame_tos_p (struct gdbarch *gdbarch); | |
83905903 AC |
2403 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SAVE_DUMMY_FRAME_TOS_P) |
2404 | #error "Non multi-arch definition of SAVE_DUMMY_FRAME_TOS" | |
2405 | #endif | |
6166d547 | 2406 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (SAVE_DUMMY_FRAME_TOS_P) |
d1e3cf49 AC |
2407 | #define SAVE_DUMMY_FRAME_TOS_P() (gdbarch_save_dummy_frame_tos_p (current_gdbarch)) |
2408 | #endif | |
2409 | ||
2410 | /* Default (function) for non- multi-arch platforms. */ | |
6166d547 | 2411 | #if (!GDB_MULTI_ARCH) && !defined (SAVE_DUMMY_FRAME_TOS) |
8e65ff28 | 2412 | #define SAVE_DUMMY_FRAME_TOS(sp) (internal_error (__FILE__, __LINE__, "SAVE_DUMMY_FRAME_TOS"), 0) |
d1e3cf49 AC |
2413 | #endif |
2414 | ||
2415 | typedef void (gdbarch_save_dummy_frame_tos_ftype) (CORE_ADDR sp); | |
2416 | extern void gdbarch_save_dummy_frame_tos (struct gdbarch *gdbarch, CORE_ADDR sp); | |
2417 | extern void set_gdbarch_save_dummy_frame_tos (struct gdbarch *gdbarch, gdbarch_save_dummy_frame_tos_ftype *save_dummy_frame_tos); | |
83905903 AC |
2418 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SAVE_DUMMY_FRAME_TOS) |
2419 | #error "Non multi-arch definition of SAVE_DUMMY_FRAME_TOS" | |
2420 | #endif | |
c25083af | 2421 | #if !defined (SAVE_DUMMY_FRAME_TOS) |
d1e3cf49 AC |
2422 | #define SAVE_DUMMY_FRAME_TOS(sp) (gdbarch_save_dummy_frame_tos (current_gdbarch, sp)) |
2423 | #endif | |
d1e3cf49 | 2424 | |
6314f104 AC |
2425 | extern int gdbarch_unwind_dummy_id_p (struct gdbarch *gdbarch); |
2426 | ||
2427 | typedef struct frame_id (gdbarch_unwind_dummy_id_ftype) (struct gdbarch *gdbarch, struct frame_info *info); | |
2428 | extern struct frame_id gdbarch_unwind_dummy_id (struct gdbarch *gdbarch, struct frame_info *info); | |
2429 | extern void set_gdbarch_unwind_dummy_id (struct gdbarch *gdbarch, gdbarch_unwind_dummy_id_ftype *unwind_dummy_id); | |
2430 | ||
58d5518e ND |
2431 | extern int gdbarch_parm_boundary (struct gdbarch *gdbarch); |
2432 | extern void set_gdbarch_parm_boundary (struct gdbarch *gdbarch, int parm_boundary); | |
83905903 AC |
2433 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (PARM_BOUNDARY) |
2434 | #error "Non multi-arch definition of PARM_BOUNDARY" | |
2435 | #endif | |
c25083af | 2436 | #if !defined (PARM_BOUNDARY) |
58d5518e ND |
2437 | #define PARM_BOUNDARY (gdbarch_parm_boundary (current_gdbarch)) |
2438 | #endif | |
58d5518e | 2439 | |
f0d4cc9e | 2440 | /* Default (value) for non- multi-arch platforms. */ |
6166d547 | 2441 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_FLOAT_FORMAT) |
f0d4cc9e AC |
2442 | #define TARGET_FLOAT_FORMAT (default_float_format (current_gdbarch)) |
2443 | #endif | |
2444 | ||
2445 | extern const struct floatformat * gdbarch_float_format (struct gdbarch *gdbarch); | |
2446 | extern void set_gdbarch_float_format (struct gdbarch *gdbarch, const struct floatformat * float_format); | |
83905903 AC |
2447 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_FLOAT_FORMAT) |
2448 | #error "Non multi-arch definition of TARGET_FLOAT_FORMAT" | |
2449 | #endif | |
c25083af | 2450 | #if !defined (TARGET_FLOAT_FORMAT) |
f0d4cc9e AC |
2451 | #define TARGET_FLOAT_FORMAT (gdbarch_float_format (current_gdbarch)) |
2452 | #endif | |
f0d4cc9e AC |
2453 | |
2454 | /* Default (value) for non- multi-arch platforms. */ | |
6166d547 | 2455 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_DOUBLE_FORMAT) |
f0d4cc9e AC |
2456 | #define TARGET_DOUBLE_FORMAT (default_double_format (current_gdbarch)) |
2457 | #endif | |
2458 | ||
2459 | extern const struct floatformat * gdbarch_double_format (struct gdbarch *gdbarch); | |
2460 | extern void set_gdbarch_double_format (struct gdbarch *gdbarch, const struct floatformat * double_format); | |
83905903 AC |
2461 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_DOUBLE_FORMAT) |
2462 | #error "Non multi-arch definition of TARGET_DOUBLE_FORMAT" | |
2463 | #endif | |
c25083af | 2464 | #if !defined (TARGET_DOUBLE_FORMAT) |
f0d4cc9e AC |
2465 | #define TARGET_DOUBLE_FORMAT (gdbarch_double_format (current_gdbarch)) |
2466 | #endif | |
f0d4cc9e AC |
2467 | |
2468 | /* Default (value) for non- multi-arch platforms. */ | |
6166d547 | 2469 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_LONG_DOUBLE_FORMAT) |
2fa5c1e0 | 2470 | #define TARGET_LONG_DOUBLE_FORMAT (default_double_format (current_gdbarch)) |
f0d4cc9e AC |
2471 | #endif |
2472 | ||
2473 | extern const struct floatformat * gdbarch_long_double_format (struct gdbarch *gdbarch); | |
2474 | extern void set_gdbarch_long_double_format (struct gdbarch *gdbarch, const struct floatformat * long_double_format); | |
83905903 AC |
2475 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_LONG_DOUBLE_FORMAT) |
2476 | #error "Non multi-arch definition of TARGET_LONG_DOUBLE_FORMAT" | |
2477 | #endif | |
c25083af | 2478 | #if !defined (TARGET_LONG_DOUBLE_FORMAT) |
f0d4cc9e AC |
2479 | #define TARGET_LONG_DOUBLE_FORMAT (gdbarch_long_double_format (current_gdbarch)) |
2480 | #endif | |
f0d4cc9e | 2481 | |
f517ea4e PS |
2482 | /* Default (function) for non- multi-arch platforms. */ |
2483 | #if (!GDB_MULTI_ARCH) && !defined (CONVERT_FROM_FUNC_PTR_ADDR) | |
875e1767 | 2484 | #define CONVERT_FROM_FUNC_PTR_ADDR(addr) (core_addr_identity (addr)) |
f517ea4e PS |
2485 | #endif |
2486 | ||
2487 | typedef CORE_ADDR (gdbarch_convert_from_func_ptr_addr_ftype) (CORE_ADDR addr); | |
2488 | extern CORE_ADDR gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, CORE_ADDR addr); | |
2489 | extern void set_gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, gdbarch_convert_from_func_ptr_addr_ftype *convert_from_func_ptr_addr); | |
83905903 AC |
2490 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (CONVERT_FROM_FUNC_PTR_ADDR) |
2491 | #error "Non multi-arch definition of CONVERT_FROM_FUNC_PTR_ADDR" | |
2492 | #endif | |
c25083af | 2493 | #if !defined (CONVERT_FROM_FUNC_PTR_ADDR) |
f517ea4e PS |
2494 | #define CONVERT_FROM_FUNC_PTR_ADDR(addr) (gdbarch_convert_from_func_ptr_addr (current_gdbarch, addr)) |
2495 | #endif | |
f517ea4e | 2496 | |
875e1767 AC |
2497 | /* On some machines there are bits in addresses which are not really |
2498 | part of the address, but are used by the kernel, the hardware, etc. | |
2499 | for special purposes. ADDR_BITS_REMOVE takes out any such bits so | |
2500 | we get a "real" address such as one would find in a symbol table. | |
2501 | This is used only for addresses of instructions, and even then I'm | |
2502 | not sure it's used in all contexts. It exists to deal with there | |
2503 | being a few stray bits in the PC which would mislead us, not as some | |
2504 | sort of generic thing to handle alignment or segmentation (it's | |
2505 | possible it should be in TARGET_READ_PC instead). */ | |
2506 | ||
2507 | /* Default (function) for non- multi-arch platforms. */ | |
2508 | #if (!GDB_MULTI_ARCH) && !defined (ADDR_BITS_REMOVE) | |
2509 | #define ADDR_BITS_REMOVE(addr) (core_addr_identity (addr)) | |
2510 | #endif | |
2511 | ||
2512 | typedef CORE_ADDR (gdbarch_addr_bits_remove_ftype) (CORE_ADDR addr); | |
2513 | extern CORE_ADDR gdbarch_addr_bits_remove (struct gdbarch *gdbarch, CORE_ADDR addr); | |
2514 | extern void set_gdbarch_addr_bits_remove (struct gdbarch *gdbarch, gdbarch_addr_bits_remove_ftype *addr_bits_remove); | |
83905903 AC |
2515 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (ADDR_BITS_REMOVE) |
2516 | #error "Non multi-arch definition of ADDR_BITS_REMOVE" | |
2517 | #endif | |
c25083af | 2518 | #if !defined (ADDR_BITS_REMOVE) |
875e1767 AC |
2519 | #define ADDR_BITS_REMOVE(addr) (gdbarch_addr_bits_remove (current_gdbarch, addr)) |
2520 | #endif | |
875e1767 | 2521 | |
5720643c | 2522 | /* It is not at all clear why SMASH_TEXT_ADDRESS is not folded into |
181c1381 RE |
2523 | ADDR_BITS_REMOVE. */ |
2524 | ||
2525 | /* Default (function) for non- multi-arch platforms. */ | |
2526 | #if (!GDB_MULTI_ARCH) && !defined (SMASH_TEXT_ADDRESS) | |
2527 | #define SMASH_TEXT_ADDRESS(addr) (core_addr_identity (addr)) | |
2528 | #endif | |
2529 | ||
2530 | typedef CORE_ADDR (gdbarch_smash_text_address_ftype) (CORE_ADDR addr); | |
2531 | extern CORE_ADDR gdbarch_smash_text_address (struct gdbarch *gdbarch, CORE_ADDR addr); | |
2532 | extern void set_gdbarch_smash_text_address (struct gdbarch *gdbarch, gdbarch_smash_text_address_ftype *smash_text_address); | |
2533 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SMASH_TEXT_ADDRESS) | |
2534 | #error "Non multi-arch definition of SMASH_TEXT_ADDRESS" | |
2535 | #endif | |
c25083af | 2536 | #if !defined (SMASH_TEXT_ADDRESS) |
181c1381 RE |
2537 | #define SMASH_TEXT_ADDRESS(addr) (gdbarch_smash_text_address (current_gdbarch, addr)) |
2538 | #endif | |
181c1381 | 2539 | |
64c4637f AC |
2540 | /* FIXME/cagney/2001-01-18: This should be split in two. A target method that indicates if |
2541 | the target needs software single step. An ISA method to implement it. | |
2542 | ||
2543 | FIXME/cagney/2001-01-18: This should be replaced with something that inserts breakpoints | |
2544 | using the breakpoint system instead of blatting memory directly (as with rs6000). | |
2545 | ||
2546 | FIXME/cagney/2001-01-18: The logic is backwards. It should be asking if the target can | |
2547 | single step. If not, then implement single step using breakpoints. */ | |
2548 | ||
2549 | #if defined (SOFTWARE_SINGLE_STEP) | |
2550 | /* Legacy for systems yet to multi-arch SOFTWARE_SINGLE_STEP */ | |
2551 | #if !defined (SOFTWARE_SINGLE_STEP_P) | |
2552 | #define SOFTWARE_SINGLE_STEP_P() (1) | |
2553 | #endif | |
2554 | #endif | |
2555 | ||
2556 | /* Default predicate for non- multi-arch targets. */ | |
2557 | #if (!GDB_MULTI_ARCH) && !defined (SOFTWARE_SINGLE_STEP_P) | |
2558 | #define SOFTWARE_SINGLE_STEP_P() (0) | |
2559 | #endif | |
2560 | ||
2561 | extern int gdbarch_software_single_step_p (struct gdbarch *gdbarch); | |
83905903 AC |
2562 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SOFTWARE_SINGLE_STEP_P) |
2563 | #error "Non multi-arch definition of SOFTWARE_SINGLE_STEP" | |
2564 | #endif | |
64c4637f AC |
2565 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (SOFTWARE_SINGLE_STEP_P) |
2566 | #define SOFTWARE_SINGLE_STEP_P() (gdbarch_software_single_step_p (current_gdbarch)) | |
2567 | #endif | |
2568 | ||
2569 | /* Default (function) for non- multi-arch platforms. */ | |
2570 | #if (!GDB_MULTI_ARCH) && !defined (SOFTWARE_SINGLE_STEP) | |
2571 | #define SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p) (internal_error (__FILE__, __LINE__, "SOFTWARE_SINGLE_STEP"), 0) | |
2572 | #endif | |
2573 | ||
2574 | typedef void (gdbarch_software_single_step_ftype) (enum target_signal sig, int insert_breakpoints_p); | |
2575 | extern void gdbarch_software_single_step (struct gdbarch *gdbarch, enum target_signal sig, int insert_breakpoints_p); | |
2576 | extern void set_gdbarch_software_single_step (struct gdbarch *gdbarch, gdbarch_software_single_step_ftype *software_single_step); | |
83905903 AC |
2577 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SOFTWARE_SINGLE_STEP) |
2578 | #error "Non multi-arch definition of SOFTWARE_SINGLE_STEP" | |
2579 | #endif | |
c25083af | 2580 | #if !defined (SOFTWARE_SINGLE_STEP) |
64c4637f AC |
2581 | #define SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p) (gdbarch_software_single_step (current_gdbarch, sig, insert_breakpoints_p)) |
2582 | #endif | |
64c4637f | 2583 | |
2bf0cb65 EZ |
2584 | /* Default (function) for non- multi-arch platforms. */ |
2585 | #if (!GDB_MULTI_ARCH) && !defined (TARGET_PRINT_INSN) | |
2586 | #define TARGET_PRINT_INSN(vma, info) (legacy_print_insn (vma, info)) | |
2587 | #endif | |
2588 | ||
2589 | typedef int (gdbarch_print_insn_ftype) (bfd_vma vma, disassemble_info *info); | |
2590 | extern int gdbarch_print_insn (struct gdbarch *gdbarch, bfd_vma vma, disassemble_info *info); | |
2591 | extern void set_gdbarch_print_insn (struct gdbarch *gdbarch, gdbarch_print_insn_ftype *print_insn); | |
2592 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (TARGET_PRINT_INSN) | |
2593 | #error "Non multi-arch definition of TARGET_PRINT_INSN" | |
2594 | #endif | |
c25083af | 2595 | #if !defined (TARGET_PRINT_INSN) |
2bf0cb65 EZ |
2596 | #define TARGET_PRINT_INSN(vma, info) (gdbarch_print_insn (current_gdbarch, vma, info)) |
2597 | #endif | |
2bf0cb65 | 2598 | |
bdcd319a CV |
2599 | /* Default (function) for non- multi-arch platforms. */ |
2600 | #if (!GDB_MULTI_ARCH) && !defined (SKIP_TRAMPOLINE_CODE) | |
2601 | #define SKIP_TRAMPOLINE_CODE(pc) (generic_skip_trampoline_code (pc)) | |
2602 | #endif | |
2603 | ||
2604 | typedef CORE_ADDR (gdbarch_skip_trampoline_code_ftype) (CORE_ADDR pc); | |
2605 | extern CORE_ADDR gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, CORE_ADDR pc); | |
2606 | extern void set_gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, gdbarch_skip_trampoline_code_ftype *skip_trampoline_code); | |
2607 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SKIP_TRAMPOLINE_CODE) | |
2608 | #error "Non multi-arch definition of SKIP_TRAMPOLINE_CODE" | |
2609 | #endif | |
c25083af | 2610 | #if !defined (SKIP_TRAMPOLINE_CODE) |
bdcd319a CV |
2611 | #define SKIP_TRAMPOLINE_CODE(pc) (gdbarch_skip_trampoline_code (current_gdbarch, pc)) |
2612 | #endif | |
bdcd319a | 2613 | |
68e9cc94 CV |
2614 | /* For SVR4 shared libraries, each call goes through a small piece of |
2615 | trampoline code in the ".plt" section. IN_SOLIB_CALL_TRAMPOLINE evaluates | |
d50355b6 | 2616 | to nonzero if we are currently stopped in one of these. */ |
68e9cc94 CV |
2617 | |
2618 | /* Default (function) for non- multi-arch platforms. */ | |
2619 | #if (!GDB_MULTI_ARCH) && !defined (IN_SOLIB_CALL_TRAMPOLINE) | |
2620 | #define IN_SOLIB_CALL_TRAMPOLINE(pc, name) (generic_in_solib_call_trampoline (pc, name)) | |
2621 | #endif | |
2622 | ||
2623 | typedef int (gdbarch_in_solib_call_trampoline_ftype) (CORE_ADDR pc, char *name); | |
2624 | extern int gdbarch_in_solib_call_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name); | |
2625 | extern void set_gdbarch_in_solib_call_trampoline (struct gdbarch *gdbarch, gdbarch_in_solib_call_trampoline_ftype *in_solib_call_trampoline); | |
2626 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (IN_SOLIB_CALL_TRAMPOLINE) | |
2627 | #error "Non multi-arch definition of IN_SOLIB_CALL_TRAMPOLINE" | |
2628 | #endif | |
c25083af | 2629 | #if !defined (IN_SOLIB_CALL_TRAMPOLINE) |
68e9cc94 CV |
2630 | #define IN_SOLIB_CALL_TRAMPOLINE(pc, name) (gdbarch_in_solib_call_trampoline (current_gdbarch, pc, name)) |
2631 | #endif | |
68e9cc94 | 2632 | |
d50355b6 MS |
2633 | /* Some systems also have trampoline code for returning from shared libs. */ |
2634 | ||
2635 | /* Default (function) for non- multi-arch platforms. */ | |
2636 | #if (!GDB_MULTI_ARCH) && !defined (IN_SOLIB_RETURN_TRAMPOLINE) | |
2637 | #define IN_SOLIB_RETURN_TRAMPOLINE(pc, name) (generic_in_solib_return_trampoline (pc, name)) | |
2638 | #endif | |
2639 | ||
2640 | typedef int (gdbarch_in_solib_return_trampoline_ftype) (CORE_ADDR pc, char *name); | |
2641 | extern int gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name); | |
2642 | extern void set_gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, gdbarch_in_solib_return_trampoline_ftype *in_solib_return_trampoline); | |
2643 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (IN_SOLIB_RETURN_TRAMPOLINE) | |
2644 | #error "Non multi-arch definition of IN_SOLIB_RETURN_TRAMPOLINE" | |
2645 | #endif | |
c25083af | 2646 | #if !defined (IN_SOLIB_RETURN_TRAMPOLINE) |
d50355b6 MS |
2647 | #define IN_SOLIB_RETURN_TRAMPOLINE(pc, name) (gdbarch_in_solib_return_trampoline (current_gdbarch, pc, name)) |
2648 | #endif | |
d50355b6 | 2649 | |
d7bd68ca AC |
2650 | /* Sigtramp is a routine that the kernel calls (which then calls the |
2651 | signal handler). On most machines it is a library routine that is | |
2652 | linked into the executable. | |
2653 | ||
2654 | This macro, given a program counter value and the name of the | |
2655 | function in which that PC resides (which can be null if the name is | |
2656 | not known), returns nonzero if the PC and name show that we are in | |
2657 | sigtramp. | |
2658 | ||
2659 | On most machines just see if the name is sigtramp (and if we have | |
2660 | no name, assume we are not in sigtramp). | |
2661 | ||
2662 | FIXME: cagney/2002-04-21: The function find_pc_partial_function | |
2663 | calls find_pc_sect_partial_function() which calls PC_IN_SIGTRAMP. | |
2664 | This means PC_IN_SIGTRAMP function can't be implemented by doing its | |
2665 | own local NAME lookup. | |
2666 | ||
2667 | FIXME: cagney/2002-04-21: PC_IN_SIGTRAMP is something of a mess. | |
2668 | Some code also depends on SIGTRAMP_START and SIGTRAMP_END but other | |
2669 | does not. */ | |
2670 | ||
2671 | /* Default (function) for non- multi-arch platforms. */ | |
2672 | #if (!GDB_MULTI_ARCH) && !defined (PC_IN_SIGTRAMP) | |
2673 | #define PC_IN_SIGTRAMP(pc, name) (legacy_pc_in_sigtramp (pc, name)) | |
2674 | #endif | |
2675 | ||
2676 | typedef int (gdbarch_pc_in_sigtramp_ftype) (CORE_ADDR pc, char *name); | |
2677 | extern int gdbarch_pc_in_sigtramp (struct gdbarch *gdbarch, CORE_ADDR pc, char *name); | |
2678 | extern void set_gdbarch_pc_in_sigtramp (struct gdbarch *gdbarch, gdbarch_pc_in_sigtramp_ftype *pc_in_sigtramp); | |
2679 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (PC_IN_SIGTRAMP) | |
2680 | #error "Non multi-arch definition of PC_IN_SIGTRAMP" | |
2681 | #endif | |
c25083af | 2682 | #if !defined (PC_IN_SIGTRAMP) |
d7bd68ca AC |
2683 | #define PC_IN_SIGTRAMP(pc, name) (gdbarch_pc_in_sigtramp (current_gdbarch, pc, name)) |
2684 | #endif | |
d7bd68ca | 2685 | |
43156d82 MK |
2686 | #if defined (SIGTRAMP_START) |
2687 | /* Legacy for systems yet to multi-arch SIGTRAMP_START */ | |
2688 | #if !defined (SIGTRAMP_START_P) | |
2689 | #define SIGTRAMP_START_P() (1) | |
2690 | #endif | |
2691 | #endif | |
2692 | ||
2693 | /* Default predicate for non- multi-arch targets. */ | |
2694 | #if (!GDB_MULTI_ARCH) && !defined (SIGTRAMP_START_P) | |
2695 | #define SIGTRAMP_START_P() (0) | |
2696 | #endif | |
2697 | ||
2698 | extern int gdbarch_sigtramp_start_p (struct gdbarch *gdbarch); | |
2699 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SIGTRAMP_START_P) | |
2700 | #error "Non multi-arch definition of SIGTRAMP_START" | |
2701 | #endif | |
2702 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (SIGTRAMP_START_P) | |
2703 | #define SIGTRAMP_START_P() (gdbarch_sigtramp_start_p (current_gdbarch)) | |
2704 | #endif | |
2705 | ||
2706 | /* Default (function) for non- multi-arch platforms. */ | |
2707 | #if (!GDB_MULTI_ARCH) && !defined (SIGTRAMP_START) | |
2708 | #define SIGTRAMP_START(pc) (internal_error (__FILE__, __LINE__, "SIGTRAMP_START"), 0) | |
2709 | #endif | |
2710 | ||
2711 | typedef CORE_ADDR (gdbarch_sigtramp_start_ftype) (CORE_ADDR pc); | |
2712 | extern CORE_ADDR gdbarch_sigtramp_start (struct gdbarch *gdbarch, CORE_ADDR pc); | |
2713 | extern void set_gdbarch_sigtramp_start (struct gdbarch *gdbarch, gdbarch_sigtramp_start_ftype *sigtramp_start); | |
2714 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SIGTRAMP_START) | |
2715 | #error "Non multi-arch definition of SIGTRAMP_START" | |
2716 | #endif | |
c25083af | 2717 | #if !defined (SIGTRAMP_START) |
43156d82 MK |
2718 | #define SIGTRAMP_START(pc) (gdbarch_sigtramp_start (current_gdbarch, pc)) |
2719 | #endif | |
43156d82 | 2720 | |
e76cff22 AC |
2721 | #if defined (SIGTRAMP_END) |
2722 | /* Legacy for systems yet to multi-arch SIGTRAMP_END */ | |
2723 | #if !defined (SIGTRAMP_END_P) | |
2724 | #define SIGTRAMP_END_P() (1) | |
2725 | #endif | |
2726 | #endif | |
2727 | ||
2728 | /* Default predicate for non- multi-arch targets. */ | |
2729 | #if (!GDB_MULTI_ARCH) && !defined (SIGTRAMP_END_P) | |
2730 | #define SIGTRAMP_END_P() (0) | |
2731 | #endif | |
2732 | ||
2733 | extern int gdbarch_sigtramp_end_p (struct gdbarch *gdbarch); | |
2734 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SIGTRAMP_END_P) | |
2735 | #error "Non multi-arch definition of SIGTRAMP_END" | |
2736 | #endif | |
2737 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (SIGTRAMP_END_P) | |
2738 | #define SIGTRAMP_END_P() (gdbarch_sigtramp_end_p (current_gdbarch)) | |
2739 | #endif | |
2740 | ||
2741 | /* Default (function) for non- multi-arch platforms. */ | |
2742 | #if (!GDB_MULTI_ARCH) && !defined (SIGTRAMP_END) | |
2743 | #define SIGTRAMP_END(pc) (internal_error (__FILE__, __LINE__, "SIGTRAMP_END"), 0) | |
2744 | #endif | |
2745 | ||
43156d82 MK |
2746 | typedef CORE_ADDR (gdbarch_sigtramp_end_ftype) (CORE_ADDR pc); |
2747 | extern CORE_ADDR gdbarch_sigtramp_end (struct gdbarch *gdbarch, CORE_ADDR pc); | |
2748 | extern void set_gdbarch_sigtramp_end (struct gdbarch *gdbarch, gdbarch_sigtramp_end_ftype *sigtramp_end); | |
2749 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SIGTRAMP_END) | |
2750 | #error "Non multi-arch definition of SIGTRAMP_END" | |
2751 | #endif | |
c25083af | 2752 | #if !defined (SIGTRAMP_END) |
43156d82 MK |
2753 | #define SIGTRAMP_END(pc) (gdbarch_sigtramp_end (current_gdbarch, pc)) |
2754 | #endif | |
43156d82 | 2755 | |
c12260ac CV |
2756 | /* A target might have problems with watchpoints as soon as the stack |
2757 | frame of the current function has been destroyed. This mostly happens | |
2758 | as the first action in a funtion's epilogue. in_function_epilogue_p() | |
2759 | is defined to return a non-zero value if either the given addr is one | |
2760 | instruction after the stack destroying instruction up to the trailing | |
2761 | return instruction or if we can figure out that the stack frame has | |
2762 | already been invalidated regardless of the value of addr. Targets | |
2763 | which don't suffer from that problem could just let this functionality | |
2764 | untouched. */ | |
2765 | ||
2766 | typedef int (gdbarch_in_function_epilogue_p_ftype) (struct gdbarch *gdbarch, CORE_ADDR addr); | |
2767 | extern int gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, CORE_ADDR addr); | |
2768 | extern void set_gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, gdbarch_in_function_epilogue_p_ftype *in_function_epilogue_p); | |
2769 | ||
552c04a7 TT |
2770 | /* Given a vector of command-line arguments, return a newly allocated |
2771 | string which, when passed to the create_inferior function, will be | |
2772 | parsed (on Unix systems, by the shell) to yield the same vector. | |
2773 | This function should call error() if the argument vector is not | |
2774 | representable for this target or if this target does not support | |
2775 | command-line arguments. | |
2776 | ARGC is the number of elements in the vector. | |
2777 | ARGV is an array of strings, one per argument. */ | |
2778 | ||
2779 | typedef char * (gdbarch_construct_inferior_arguments_ftype) (struct gdbarch *gdbarch, int argc, char **argv); | |
2780 | extern char * gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, int argc, char **argv); | |
2781 | extern void set_gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, gdbarch_construct_inferior_arguments_ftype *construct_inferior_arguments); | |
2782 | ||
b6af0555 JS |
2783 | #if defined (DWARF2_BUILD_FRAME_INFO) |
2784 | /* Legacy for systems yet to multi-arch DWARF2_BUILD_FRAME_INFO */ | |
2785 | #if !defined (DWARF2_BUILD_FRAME_INFO_P) | |
2786 | #define DWARF2_BUILD_FRAME_INFO_P() (1) | |
2787 | #endif | |
2788 | #endif | |
2789 | ||
2790 | /* Default predicate for non- multi-arch targets. */ | |
2791 | #if (!GDB_MULTI_ARCH) && !defined (DWARF2_BUILD_FRAME_INFO_P) | |
2792 | #define DWARF2_BUILD_FRAME_INFO_P() (0) | |
2793 | #endif | |
2794 | ||
2795 | extern int gdbarch_dwarf2_build_frame_info_p (struct gdbarch *gdbarch); | |
2796 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DWARF2_BUILD_FRAME_INFO_P) | |
2797 | #error "Non multi-arch definition of DWARF2_BUILD_FRAME_INFO" | |
2798 | #endif | |
2799 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DWARF2_BUILD_FRAME_INFO_P) | |
2800 | #define DWARF2_BUILD_FRAME_INFO_P() (gdbarch_dwarf2_build_frame_info_p (current_gdbarch)) | |
2801 | #endif | |
2802 | ||
2803 | /* Default (function) for non- multi-arch platforms. */ | |
2804 | #if (!GDB_MULTI_ARCH) && !defined (DWARF2_BUILD_FRAME_INFO) | |
2805 | #define DWARF2_BUILD_FRAME_INFO(objfile) (internal_error (__FILE__, __LINE__, "DWARF2_BUILD_FRAME_INFO"), 0) | |
2806 | #endif | |
2807 | ||
2808 | typedef void (gdbarch_dwarf2_build_frame_info_ftype) (struct objfile *objfile); | |
2809 | extern void gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch, struct objfile *objfile); | |
2810 | extern void set_gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch, gdbarch_dwarf2_build_frame_info_ftype *dwarf2_build_frame_info); | |
2811 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DWARF2_BUILD_FRAME_INFO) | |
2812 | #error "Non multi-arch definition of DWARF2_BUILD_FRAME_INFO" | |
2813 | #endif | |
c25083af | 2814 | #if !defined (DWARF2_BUILD_FRAME_INFO) |
b6af0555 JS |
2815 | #define DWARF2_BUILD_FRAME_INFO(objfile) (gdbarch_dwarf2_build_frame_info (current_gdbarch, objfile)) |
2816 | #endif | |
b6af0555 | 2817 | |
a2cf933a EZ |
2818 | /* Default (function) for non- multi-arch platforms. */ |
2819 | #if (!GDB_MULTI_ARCH) && !defined (ELF_MAKE_MSYMBOL_SPECIAL) | |
2820 | #define ELF_MAKE_MSYMBOL_SPECIAL(sym, msym) (default_elf_make_msymbol_special (sym, msym)) | |
2821 | #endif | |
2822 | ||
2823 | typedef void (gdbarch_elf_make_msymbol_special_ftype) (asymbol *sym, struct minimal_symbol *msym); | |
2824 | extern void gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, asymbol *sym, struct minimal_symbol *msym); | |
2825 | extern void set_gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, gdbarch_elf_make_msymbol_special_ftype *elf_make_msymbol_special); | |
2826 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (ELF_MAKE_MSYMBOL_SPECIAL) | |
2827 | #error "Non multi-arch definition of ELF_MAKE_MSYMBOL_SPECIAL" | |
2828 | #endif | |
c25083af | 2829 | #if !defined (ELF_MAKE_MSYMBOL_SPECIAL) |
a2cf933a EZ |
2830 | #define ELF_MAKE_MSYMBOL_SPECIAL(sym, msym) (gdbarch_elf_make_msymbol_special (current_gdbarch, sym, msym)) |
2831 | #endif | |
a2cf933a EZ |
2832 | |
2833 | /* Default (function) for non- multi-arch platforms. */ | |
2834 | #if (!GDB_MULTI_ARCH) && !defined (COFF_MAKE_MSYMBOL_SPECIAL) | |
2835 | #define COFF_MAKE_MSYMBOL_SPECIAL(val, msym) (default_coff_make_msymbol_special (val, msym)) | |
2836 | #endif | |
2837 | ||
2838 | typedef void (gdbarch_coff_make_msymbol_special_ftype) (int val, struct minimal_symbol *msym); | |
2839 | extern void gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, int val, struct minimal_symbol *msym); | |
2840 | extern void set_gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, gdbarch_coff_make_msymbol_special_ftype *coff_make_msymbol_special); | |
2841 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (COFF_MAKE_MSYMBOL_SPECIAL) | |
2842 | #error "Non multi-arch definition of COFF_MAKE_MSYMBOL_SPECIAL" | |
2843 | #endif | |
c25083af | 2844 | #if !defined (COFF_MAKE_MSYMBOL_SPECIAL) |
a2cf933a EZ |
2845 | #define COFF_MAKE_MSYMBOL_SPECIAL(val, msym) (gdbarch_coff_make_msymbol_special (current_gdbarch, val, msym)) |
2846 | #endif | |
a2cf933a | 2847 | |
5720643c JB |
2848 | /* Default (value) for non- multi-arch platforms. */ |
2849 | #if (!GDB_MULTI_ARCH) && !defined (NAME_OF_MALLOC) | |
2850 | #define NAME_OF_MALLOC ("malloc") | |
2851 | #endif | |
2852 | ||
2853 | extern const char * gdbarch_name_of_malloc (struct gdbarch *gdbarch); | |
2854 | extern void set_gdbarch_name_of_malloc (struct gdbarch *gdbarch, const char * name_of_malloc); | |
2855 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (NAME_OF_MALLOC) | |
2856 | #error "Non multi-arch definition of NAME_OF_MALLOC" | |
2857 | #endif | |
c25083af | 2858 | #if !defined (NAME_OF_MALLOC) |
5720643c JB |
2859 | #define NAME_OF_MALLOC (gdbarch_name_of_malloc (current_gdbarch)) |
2860 | #endif | |
5720643c | 2861 | |
c4ed33b9 AC |
2862 | /* Default (value) for non- multi-arch platforms. */ |
2863 | #if (!GDB_MULTI_ARCH) && !defined (CANNOT_STEP_BREAKPOINT) | |
2864 | #define CANNOT_STEP_BREAKPOINT (0) | |
2865 | #endif | |
2866 | ||
2867 | extern int gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch); | |
2868 | extern void set_gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch, int cannot_step_breakpoint); | |
2869 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (CANNOT_STEP_BREAKPOINT) | |
2870 | #error "Non multi-arch definition of CANNOT_STEP_BREAKPOINT" | |
2871 | #endif | |
c25083af | 2872 | #if !defined (CANNOT_STEP_BREAKPOINT) |
c4ed33b9 AC |
2873 | #define CANNOT_STEP_BREAKPOINT (gdbarch_cannot_step_breakpoint (current_gdbarch)) |
2874 | #endif | |
c4ed33b9 | 2875 | |
f74fa174 MM |
2876 | /* Default (value) for non- multi-arch platforms. */ |
2877 | #if (!GDB_MULTI_ARCH) && !defined (HAVE_NONSTEPPABLE_WATCHPOINT) | |
2878 | #define HAVE_NONSTEPPABLE_WATCHPOINT (0) | |
2879 | #endif | |
2880 | ||
2881 | extern int gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch); | |
2882 | extern void set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch, int have_nonsteppable_watchpoint); | |
2883 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (HAVE_NONSTEPPABLE_WATCHPOINT) | |
2884 | #error "Non multi-arch definition of HAVE_NONSTEPPABLE_WATCHPOINT" | |
2885 | #endif | |
c25083af | 2886 | #if !defined (HAVE_NONSTEPPABLE_WATCHPOINT) |
f74fa174 MM |
2887 | #define HAVE_NONSTEPPABLE_WATCHPOINT (gdbarch_have_nonsteppable_watchpoint (current_gdbarch)) |
2888 | #endif | |
f74fa174 | 2889 | |
8b2dbe47 KB |
2890 | #if defined (ADDRESS_CLASS_TYPE_FLAGS) |
2891 | /* Legacy for systems yet to multi-arch ADDRESS_CLASS_TYPE_FLAGS */ | |
2892 | #if !defined (ADDRESS_CLASS_TYPE_FLAGS_P) | |
2893 | #define ADDRESS_CLASS_TYPE_FLAGS_P() (1) | |
2894 | #endif | |
2895 | #endif | |
2896 | ||
2897 | /* Default predicate for non- multi-arch targets. */ | |
2898 | #if (!GDB_MULTI_ARCH) && !defined (ADDRESS_CLASS_TYPE_FLAGS_P) | |
2899 | #define ADDRESS_CLASS_TYPE_FLAGS_P() (0) | |
2900 | #endif | |
2901 | ||
2902 | extern int gdbarch_address_class_type_flags_p (struct gdbarch *gdbarch); | |
2903 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (ADDRESS_CLASS_TYPE_FLAGS_P) | |
2904 | #error "Non multi-arch definition of ADDRESS_CLASS_TYPE_FLAGS" | |
2905 | #endif | |
2906 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (ADDRESS_CLASS_TYPE_FLAGS_P) | |
2907 | #define ADDRESS_CLASS_TYPE_FLAGS_P() (gdbarch_address_class_type_flags_p (current_gdbarch)) | |
2908 | #endif | |
2909 | ||
2910 | /* Default (function) for non- multi-arch platforms. */ | |
2911 | #if (!GDB_MULTI_ARCH) && !defined (ADDRESS_CLASS_TYPE_FLAGS) | |
2912 | #define ADDRESS_CLASS_TYPE_FLAGS(byte_size, dwarf2_addr_class) (internal_error (__FILE__, __LINE__, "ADDRESS_CLASS_TYPE_FLAGS"), 0) | |
2913 | #endif | |
2914 | ||
2915 | typedef int (gdbarch_address_class_type_flags_ftype) (int byte_size, int dwarf2_addr_class); | |
2916 | extern int gdbarch_address_class_type_flags (struct gdbarch *gdbarch, int byte_size, int dwarf2_addr_class); | |
2917 | extern void set_gdbarch_address_class_type_flags (struct gdbarch *gdbarch, gdbarch_address_class_type_flags_ftype *address_class_type_flags); | |
2918 | #if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (ADDRESS_CLASS_TYPE_FLAGS) | |
2919 | #error "Non multi-arch definition of ADDRESS_CLASS_TYPE_FLAGS" | |
2920 | #endif | |
c25083af | 2921 | #if !defined (ADDRESS_CLASS_TYPE_FLAGS) |
8b2dbe47 KB |
2922 | #define ADDRESS_CLASS_TYPE_FLAGS(byte_size, dwarf2_addr_class) (gdbarch_address_class_type_flags (current_gdbarch, byte_size, dwarf2_addr_class)) |
2923 | #endif | |
8b2dbe47 | 2924 | |
8b2dbe47 | 2925 | extern int gdbarch_address_class_type_flags_to_name_p (struct gdbarch *gdbarch); |
8b2dbe47 | 2926 | |
321432c0 KB |
2927 | typedef const char * (gdbarch_address_class_type_flags_to_name_ftype) (struct gdbarch *gdbarch, int type_flags); |
2928 | extern const char * gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, int type_flags); | |
8b2dbe47 | 2929 | extern void set_gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, gdbarch_address_class_type_flags_to_name_ftype *address_class_type_flags_to_name); |
8b2dbe47 KB |
2930 | |
2931 | extern int gdbarch_address_class_name_to_type_flags_p (struct gdbarch *gdbarch); | |
8b2dbe47 | 2932 | |
321432c0 KB |
2933 | typedef int (gdbarch_address_class_name_to_type_flags_ftype) (struct gdbarch *gdbarch, const char *name, int *type_flags_ptr); |
2934 | extern int gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, const char *name, int *type_flags_ptr); | |
8b2dbe47 | 2935 | extern void set_gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, gdbarch_address_class_name_to_type_flags_ftype *address_class_name_to_type_flags); |
8b2dbe47 | 2936 | |
b59ff9d5 AC |
2937 | /* Is a register in a group */ |
2938 | ||
2939 | typedef int (gdbarch_register_reggroup_p_ftype) (struct gdbarch *gdbarch, int regnum, struct reggroup *reggroup); | |
2940 | extern int gdbarch_register_reggroup_p (struct gdbarch *gdbarch, int regnum, struct reggroup *reggroup); | |
2941 | extern void set_gdbarch_register_reggroup_p (struct gdbarch *gdbarch, gdbarch_register_reggroup_p_ftype *register_reggroup_p); | |
2942 | ||
104c1213 | 2943 | extern struct gdbarch_tdep *gdbarch_tdep (struct gdbarch *gdbarch); |
0f71a2f6 JM |
2944 | |
2945 | ||
2946 | /* Mechanism for co-ordinating the selection of a specific | |
2947 | architecture. | |
2948 | ||
2949 | GDB targets (*-tdep.c) can register an interest in a specific | |
2950 | architecture. Other GDB components can register a need to maintain | |
2951 | per-architecture data. | |
2952 | ||
2953 | The mechanisms below ensures that there is only a loose connection | |
2954 | between the set-architecture command and the various GDB | |
99e7bb18 | 2955 | components. Each component can independently register their need |
0f71a2f6 JM |
2956 | to maintain architecture specific data with gdbarch. |
2957 | ||
2958 | Pragmatics: | |
2959 | ||
2960 | Previously, a single TARGET_ARCHITECTURE_HOOK was provided. It | |
2961 | didn't scale. | |
2962 | ||
2963 | The more traditional mega-struct containing architecture specific | |
2964 | data for all the various GDB components was also considered. Since | |
99e7bb18 | 2965 | GDB is built from a variable number of (fairly independent) |
0f71a2f6 JM |
2966 | components it was determined that the global aproach was not |
2967 | applicable. */ | |
2968 | ||
2969 | ||
2970 | /* Register a new architectural family with GDB. | |
2971 | ||
2972 | Register support for the specified ARCHITECTURE with GDB. When | |
2973 | gdbarch determines that the specified architecture has been | |
2974 | selected, the corresponding INIT function is called. | |
2975 | ||
2976 | -- | |
2977 | ||
2978 | The INIT function takes two parameters: INFO which contains the | |
2979 | information available to gdbarch about the (possibly new) | |
2980 | architecture; ARCHES which is a list of the previously created | |
2981 | ``struct gdbarch'' for this architecture. | |
2982 | ||
0f79675b AC |
2983 | The INFO parameter is, as far as possible, be pre-initialized with |
2984 | information obtained from INFO.ABFD or the previously selected | |
2985 | architecture. | |
2986 | ||
2987 | The ARCHES parameter is a linked list (sorted most recently used) | |
2988 | of all the previously created architures for this architecture | |
2989 | family. The (possibly NULL) ARCHES->gdbarch can used to access | |
2990 | values from the previously selected architecture for this | |
2991 | architecture family. The global ``current_gdbarch'' shall not be | |
2992 | used. | |
0f71a2f6 JM |
2993 | |
2994 | The INIT function shall return any of: NULL - indicating that it | |
ec3d358c | 2995 | doesn't recognize the selected architecture; an existing ``struct |
0f71a2f6 JM |
2996 | gdbarch'' from the ARCHES list - indicating that the new |
2997 | architecture is just a synonym for an earlier architecture (see | |
2998 | gdbarch_list_lookup_by_info()); a newly created ``struct gdbarch'' | |
4b9b3959 AC |
2999 | - that describes the selected architecture (see gdbarch_alloc()). |
3000 | ||
3001 | The DUMP_TDEP function shall print out all target specific values. | |
3002 | Care should be taken to ensure that the function works in both the | |
3003 | multi-arch and non- multi-arch cases. */ | |
0f71a2f6 | 3004 | |
adf40b2e JM |
3005 | struct gdbarch_list |
3006 | { | |
3007 | struct gdbarch *gdbarch; | |
3008 | struct gdbarch_list *next; | |
3009 | }; | |
0f71a2f6 | 3010 | |
adf40b2e JM |
3011 | struct gdbarch_info |
3012 | { | |
adf40b2e JM |
3013 | /* Use default: NULL (ZERO). */ |
3014 | const struct bfd_arch_info *bfd_arch_info; | |
0f71a2f6 | 3015 | |
428721aa | 3016 | /* Use default: BFD_ENDIAN_UNKNOWN (NB: is not ZERO). */ |
adf40b2e | 3017 | int byte_order; |
0f71a2f6 | 3018 | |
adf40b2e JM |
3019 | /* Use default: NULL (ZERO). */ |
3020 | bfd *abfd; | |
0f71a2f6 | 3021 | |
adf40b2e JM |
3022 | /* Use default: NULL (ZERO). */ |
3023 | struct gdbarch_tdep_info *tdep_info; | |
4be87837 DJ |
3024 | |
3025 | /* Use default: GDB_OSABI_UNINITIALIZED (-1). */ | |
3026 | enum gdb_osabi osabi; | |
adf40b2e | 3027 | }; |
0f71a2f6 | 3028 | |
104c1213 | 3029 | typedef struct gdbarch *(gdbarch_init_ftype) (struct gdbarch_info info, struct gdbarch_list *arches); |
4b9b3959 | 3030 | typedef void (gdbarch_dump_tdep_ftype) (struct gdbarch *gdbarch, struct ui_file *file); |
0f71a2f6 | 3031 | |
4b9b3959 | 3032 | /* DEPRECATED - use gdbarch_register() */ |
104c1213 | 3033 | extern void register_gdbarch_init (enum bfd_architecture architecture, gdbarch_init_ftype *); |
0f71a2f6 | 3034 | |
4b9b3959 AC |
3035 | extern void gdbarch_register (enum bfd_architecture architecture, |
3036 | gdbarch_init_ftype *, | |
3037 | gdbarch_dump_tdep_ftype *); | |
3038 | ||
0f71a2f6 | 3039 | |
b4a20239 AC |
3040 | /* Return a freshly allocated, NULL terminated, array of the valid |
3041 | architecture names. Since architectures are registered during the | |
3042 | _initialize phase this function only returns useful information | |
3043 | once initialization has been completed. */ | |
3044 | ||
3045 | extern const char **gdbarch_printable_names (void); | |
3046 | ||
3047 | ||
0f71a2f6 JM |
3048 | /* Helper function. Search the list of ARCHES for a GDBARCH that |
3049 | matches the information provided by INFO. */ | |
3050 | ||
104c1213 | 3051 | extern struct gdbarch_list *gdbarch_list_lookup_by_info (struct gdbarch_list *arches, const struct gdbarch_info *info); |
0f71a2f6 JM |
3052 | |
3053 | ||
3054 | /* Helper function. Create a preliminary ``struct gdbarch''. Perform | |
3055 | basic initialization using values obtained from the INFO andTDEP | |
3056 | parameters. set_gdbarch_*() functions are called to complete the | |
3057 | initialization of the object. */ | |
3058 | ||
104c1213 | 3059 | extern struct gdbarch *gdbarch_alloc (const struct gdbarch_info *info, struct gdbarch_tdep *tdep); |
0f71a2f6 JM |
3060 | |
3061 | ||
4b9b3959 AC |
3062 | /* Helper function. Free a partially-constructed ``struct gdbarch''. |
3063 | It is assumed that the caller freeds the ``struct | |
3064 | gdbarch_tdep''. */ | |
3065 | ||
058f20d5 JB |
3066 | extern void gdbarch_free (struct gdbarch *); |
3067 | ||
3068 | ||
b732d07d | 3069 | /* Helper function. Force an update of the current architecture. |
0f71a2f6 | 3070 | |
b732d07d AC |
3071 | The actual architecture selected is determined by INFO, ``(gdb) set |
3072 | architecture'' et.al., the existing architecture and BFD's default | |
3073 | architecture. INFO should be initialized to zero and then selected | |
3074 | fields should be updated. | |
0f71a2f6 | 3075 | |
16f33e29 AC |
3076 | Returns non-zero if the update succeeds */ |
3077 | ||
3078 | extern int gdbarch_update_p (struct gdbarch_info info); | |
0f71a2f6 JM |
3079 | |
3080 | ||
3081 | ||
3082 | /* Register per-architecture data-pointer. | |
3083 | ||
3084 | Reserve space for a per-architecture data-pointer. An identifier | |
3085 | for the reserved data-pointer is returned. That identifer should | |
95160752 | 3086 | be saved in a local static variable. |
0f71a2f6 | 3087 | |
76860b5f AC |
3088 | The per-architecture data-pointer is either initialized explicitly |
3089 | (set_gdbarch_data()) or implicitly (by INIT() via a call to | |
3090 | gdbarch_data()). FREE() is called to delete either an existing | |
2af496cb | 3091 | data-pointer overridden by set_gdbarch_data() or when the |
76860b5f | 3092 | architecture object is being deleted. |
0f71a2f6 | 3093 | |
95160752 AC |
3094 | When a previously created architecture is re-selected, the |
3095 | per-architecture data-pointer for that previous architecture is | |
76860b5f | 3096 | restored. INIT() is not re-called. |
0f71a2f6 JM |
3097 | |
3098 | Multiple registrarants for any architecture are allowed (and | |
3099 | strongly encouraged). */ | |
3100 | ||
95160752 | 3101 | struct gdbarch_data; |
0f71a2f6 | 3102 | |
95160752 AC |
3103 | typedef void *(gdbarch_data_init_ftype) (struct gdbarch *gdbarch); |
3104 | typedef void (gdbarch_data_free_ftype) (struct gdbarch *gdbarch, | |
3105 | void *pointer); | |
3106 | extern struct gdbarch_data *register_gdbarch_data (gdbarch_data_init_ftype *init, | |
3107 | gdbarch_data_free_ftype *free); | |
3108 | extern void set_gdbarch_data (struct gdbarch *gdbarch, | |
3109 | struct gdbarch_data *data, | |
3110 | void *pointer); | |
0f71a2f6 | 3111 | |
451fbdda | 3112 | extern void *gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *); |
0f71a2f6 JM |
3113 | |
3114 | ||
0f71a2f6 JM |
3115 | /* Register per-architecture memory region. |
3116 | ||
3117 | Provide a memory-region swap mechanism. Per-architecture memory | |
3118 | region are created. These memory regions are swapped whenever the | |
3119 | architecture is changed. For a new architecture, the memory region | |
3120 | is initialized with zero (0) and the INIT function is called. | |
3121 | ||
3122 | Memory regions are swapped / initialized in the order that they are | |
3123 | registered. NULL DATA and/or INIT values can be specified. | |
3124 | ||
3125 | New code should use register_gdbarch_data(). */ | |
3126 | ||
104c1213 JM |
3127 | typedef void (gdbarch_swap_ftype) (void); |
3128 | extern void register_gdbarch_swap (void *data, unsigned long size, gdbarch_swap_ftype *init); | |
e514a9d6 | 3129 | #define REGISTER_GDBARCH_SWAP(VAR) register_gdbarch_swap (&(VAR), sizeof ((VAR)), NULL) |
0f71a2f6 JM |
3130 | |
3131 | ||
3132 | ||
99e7bb18 | 3133 | /* The target-system-dependent byte order is dynamic */ |
c906108c | 3134 | |
adf40b2e | 3135 | extern int target_byte_order; |
c906108c SS |
3136 | #ifndef TARGET_BYTE_ORDER |
3137 | #define TARGET_BYTE_ORDER (target_byte_order + 0) | |
3138 | #endif | |
3139 | ||
adf40b2e | 3140 | extern int target_byte_order_auto; |
c906108c SS |
3141 | #ifndef TARGET_BYTE_ORDER_AUTO |
3142 | #define TARGET_BYTE_ORDER_AUTO (target_byte_order_auto + 0) | |
3143 | #endif | |
3144 | ||
3145 | ||
3146 | ||
99e7bb18 | 3147 | /* The target-system-dependent BFD architecture is dynamic */ |
c906108c | 3148 | |
adf40b2e | 3149 | extern int target_architecture_auto; |
c906108c SS |
3150 | #ifndef TARGET_ARCHITECTURE_AUTO |
3151 | #define TARGET_ARCHITECTURE_AUTO (target_architecture_auto + 0) | |
3152 | #endif | |
3153 | ||
adf40b2e | 3154 | extern const struct bfd_arch_info *target_architecture; |
c906108c SS |
3155 | #ifndef TARGET_ARCHITECTURE |
3156 | #define TARGET_ARCHITECTURE (target_architecture + 0) | |
3157 | #endif | |
3158 | ||
c906108c | 3159 | |
99e7bb18 | 3160 | /* The target-system-dependent disassembler is semi-dynamic */ |
c906108c | 3161 | |
810ecf9f | 3162 | /* Use gdb_disassemble, and gdbarch_print_insn instead. */ |
d7a27068 | 3163 | extern int (*deprecated_tm_print_insn) (bfd_vma, disassemble_info*); |
c906108c | 3164 | |
810ecf9f AC |
3165 | /* Use set_gdbarch_print_insn instead. */ |
3166 | extern disassemble_info deprecated_tm_print_insn_info; | |
c906108c | 3167 | |
99e7bb18 | 3168 | /* Set the dynamic target-system-dependent parameters (architecture, |
c906108c SS |
3169 | byte-order, ...) using information found in the BFD */ |
3170 | ||
104c1213 | 3171 | extern void set_gdbarch_from_file (bfd *); |
c906108c SS |
3172 | |
3173 | ||
e514a9d6 JM |
3174 | /* Initialize the current architecture to the "first" one we find on |
3175 | our list. */ | |
3176 | ||
3177 | extern void initialize_current_architecture (void); | |
3178 | ||
ceaa8edf JB |
3179 | /* For non-multiarched targets, do any initialization of the default |
3180 | gdbarch object necessary after the _initialize_MODULE functions | |
3181 | have run. */ | |
5ae5f592 | 3182 | extern void initialize_non_multiarch (void); |
cce74817 | 3183 | |
c906108c | 3184 | /* gdbarch trace variable */ |
adf40b2e | 3185 | extern int gdbarch_debug; |
c906108c | 3186 | |
4b9b3959 | 3187 | extern void gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file); |
0f71a2f6 | 3188 | |
c906108c | 3189 | #endif |