Fix whitespace snafu in tc-riscv.c
[binutils-gdb.git] / gdb / gdbarch.c
blobea6e4c647b10b9b266ad2dbb0a624b74ee142b5b
1 /* THIS FILE IS GENERATED -*- buffer-read-only: t -*- */
2 /* vi:set ro: */
4 /* Dynamic architecture support for GDB, the GNU debugger.
6 Copyright (C) 1998-2023 Free Software Foundation, Inc.
8 This file is part of GDB.
10 This program is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 3 of the License, or
13 (at your option) any later version.
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program. If not, see <http://www.gnu.org/licenses/>. */
23 /* To regenerate this file, run:
24 ./gdbarch.py
28 /* Maintain the struct gdbarch object. */
30 struct gdbarch
32 /* Has this architecture been fully initialized? */
33 bool initialized_p = false;
35 /* An obstack bound to the lifetime of the architecture. */
36 auto_obstack obstack;
37 /* Registry. */
38 registry<gdbarch> registry_fields;
40 /* basic architectural information. */
41 const struct bfd_arch_info * bfd_arch_info;
42 enum bfd_endian byte_order;
43 enum bfd_endian byte_order_for_code;
44 enum gdb_osabi osabi;
45 const struct target_desc * target_desc;
47 /* target specific vector. */
48 gdbarch_tdep_up tdep;
49 gdbarch_dump_tdep_ftype *dump_tdep = nullptr;
51 int short_bit = 2*TARGET_CHAR_BIT;
52 int int_bit = 4*TARGET_CHAR_BIT;
53 int long_bit = 4*TARGET_CHAR_BIT;
54 int long_long_bit = 2*4*TARGET_CHAR_BIT;
55 int bfloat16_bit = 2*TARGET_CHAR_BIT;
56 const struct floatformat ** bfloat16_format = floatformats_bfloat16;
57 int half_bit = 2*TARGET_CHAR_BIT;
58 const struct floatformat ** half_format = floatformats_ieee_half;
59 int float_bit = 4*TARGET_CHAR_BIT;
60 const struct floatformat ** float_format = floatformats_ieee_single;
61 int double_bit = 8*TARGET_CHAR_BIT;
62 const struct floatformat ** double_format = floatformats_ieee_double;
63 int long_double_bit = 8*TARGET_CHAR_BIT;
64 const struct floatformat ** long_double_format = floatformats_ieee_double;
65 int wchar_bit = 4*TARGET_CHAR_BIT;
66 int wchar_signed = -1;
67 gdbarch_floatformat_for_type_ftype *floatformat_for_type = default_floatformat_for_type;
68 int ptr_bit = 4*TARGET_CHAR_BIT;
69 int addr_bit = 0;
70 int dwarf2_addr_size = 0;
71 int char_signed = -1;
72 gdbarch_read_pc_ftype *read_pc = nullptr;
73 gdbarch_write_pc_ftype *write_pc = nullptr;
74 gdbarch_virtual_frame_pointer_ftype *virtual_frame_pointer = legacy_virtual_frame_pointer;
75 gdbarch_pseudo_register_read_ftype *pseudo_register_read = nullptr;
76 gdbarch_pseudo_register_read_value_ftype *pseudo_register_read_value = nullptr;
77 gdbarch_pseudo_register_write_ftype *pseudo_register_write = nullptr;
78 int num_regs = -1;
79 int num_pseudo_regs = 0;
80 gdbarch_ax_pseudo_register_collect_ftype *ax_pseudo_register_collect = nullptr;
81 gdbarch_ax_pseudo_register_push_stack_ftype *ax_pseudo_register_push_stack = nullptr;
82 gdbarch_report_signal_info_ftype *report_signal_info = nullptr;
83 int sp_regnum = -1;
84 int pc_regnum = -1;
85 int ps_regnum = -1;
86 int fp0_regnum = -1;
87 gdbarch_stab_reg_to_regnum_ftype *stab_reg_to_regnum = no_op_reg_to_regnum;
88 gdbarch_ecoff_reg_to_regnum_ftype *ecoff_reg_to_regnum = no_op_reg_to_regnum;
89 gdbarch_sdb_reg_to_regnum_ftype *sdb_reg_to_regnum = no_op_reg_to_regnum;
90 gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum = no_op_reg_to_regnum;
91 gdbarch_register_name_ftype *register_name = nullptr;
92 gdbarch_register_type_ftype *register_type = nullptr;
93 gdbarch_dummy_id_ftype *dummy_id = default_dummy_id;
94 int deprecated_fp_regnum = -1;
95 gdbarch_push_dummy_call_ftype *push_dummy_call = nullptr;
96 enum call_dummy_location_type call_dummy_location = AT_ENTRY_POINT;
97 gdbarch_push_dummy_code_ftype *push_dummy_code = nullptr;
98 gdbarch_code_of_frame_writable_ftype *code_of_frame_writable = default_code_of_frame_writable;
99 gdbarch_print_registers_info_ftype *print_registers_info = default_print_registers_info;
100 gdbarch_print_float_info_ftype *print_float_info = default_print_float_info;
101 gdbarch_print_vector_info_ftype *print_vector_info = nullptr;
102 gdbarch_register_sim_regno_ftype *register_sim_regno = legacy_register_sim_regno;
103 gdbarch_cannot_fetch_register_ftype *cannot_fetch_register = cannot_register_not;
104 gdbarch_cannot_store_register_ftype *cannot_store_register = cannot_register_not;
105 gdbarch_get_longjmp_target_ftype *get_longjmp_target = nullptr;
106 int believe_pcc_promotion = 0;
107 gdbarch_convert_register_p_ftype *convert_register_p = generic_convert_register_p;
108 gdbarch_register_to_value_ftype *register_to_value = nullptr;
109 gdbarch_value_to_register_ftype *value_to_register = nullptr;
110 gdbarch_value_from_register_ftype *value_from_register = default_value_from_register;
111 gdbarch_pointer_to_address_ftype *pointer_to_address = unsigned_pointer_to_address;
112 gdbarch_address_to_pointer_ftype *address_to_pointer = unsigned_address_to_pointer;
113 gdbarch_integer_to_address_ftype *integer_to_address = nullptr;
114 gdbarch_return_value_ftype *return_value = nullptr;
115 gdbarch_return_value_as_value_ftype *return_value_as_value = default_gdbarch_return_value;
116 gdbarch_get_return_buf_addr_ftype *get_return_buf_addr = default_get_return_buf_addr;
117 gdbarch_dwarf2_omit_typedef_p_ftype *dwarf2_omit_typedef_p = default_dwarf2_omit_typedef_p;
118 gdbarch_update_call_site_pc_ftype *update_call_site_pc = default_update_call_site_pc;
119 gdbarch_return_in_first_hidden_param_p_ftype *return_in_first_hidden_param_p = default_return_in_first_hidden_param_p;
120 gdbarch_skip_prologue_ftype *skip_prologue = nullptr;
121 gdbarch_skip_main_prologue_ftype *skip_main_prologue = nullptr;
122 gdbarch_skip_entrypoint_ftype *skip_entrypoint = nullptr;
123 gdbarch_inner_than_ftype *inner_than = nullptr;
124 gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc = default_breakpoint_from_pc;
125 gdbarch_breakpoint_kind_from_pc_ftype *breakpoint_kind_from_pc = nullptr;
126 gdbarch_sw_breakpoint_from_kind_ftype *sw_breakpoint_from_kind = NULL;
127 gdbarch_breakpoint_kind_from_current_state_ftype *breakpoint_kind_from_current_state = default_breakpoint_kind_from_current_state;
128 gdbarch_adjust_breakpoint_address_ftype *adjust_breakpoint_address = nullptr;
129 gdbarch_memory_insert_breakpoint_ftype *memory_insert_breakpoint = default_memory_insert_breakpoint;
130 gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint = default_memory_remove_breakpoint;
131 CORE_ADDR decr_pc_after_break = 0;
132 CORE_ADDR deprecated_function_start_offset = 0;
133 gdbarch_remote_register_number_ftype *remote_register_number = default_remote_register_number;
134 gdbarch_fetch_tls_load_module_address_ftype *fetch_tls_load_module_address = nullptr;
135 gdbarch_get_thread_local_address_ftype *get_thread_local_address = nullptr;
136 CORE_ADDR frame_args_skip = 0;
137 gdbarch_unwind_pc_ftype *unwind_pc = default_unwind_pc;
138 gdbarch_unwind_sp_ftype *unwind_sp = default_unwind_sp;
139 gdbarch_frame_num_args_ftype *frame_num_args = nullptr;
140 gdbarch_frame_align_ftype *frame_align = nullptr;
141 gdbarch_stabs_argument_has_addr_ftype *stabs_argument_has_addr = default_stabs_argument_has_addr;
142 int frame_red_zone_size = 0;
143 gdbarch_convert_from_func_ptr_addr_ftype *convert_from_func_ptr_addr = convert_from_func_ptr_addr_identity;
144 gdbarch_addr_bits_remove_ftype *addr_bits_remove = core_addr_identity;
145 gdbarch_remove_non_address_bits_ftype *remove_non_address_bits = default_remove_non_address_bits;
146 gdbarch_memtag_to_string_ftype *memtag_to_string = default_memtag_to_string;
147 gdbarch_tagged_address_p_ftype *tagged_address_p = default_tagged_address_p;
148 gdbarch_memtag_matches_p_ftype *memtag_matches_p = default_memtag_matches_p;
149 gdbarch_set_memtags_ftype *set_memtags = default_set_memtags;
150 gdbarch_get_memtag_ftype *get_memtag = default_get_memtag;
151 CORE_ADDR memtag_granule_size = 0;
152 gdbarch_software_single_step_ftype *software_single_step = nullptr;
153 gdbarch_single_step_through_delay_ftype *single_step_through_delay = nullptr;
154 gdbarch_print_insn_ftype *print_insn = default_print_insn;
155 gdbarch_skip_trampoline_code_ftype *skip_trampoline_code = generic_skip_trampoline_code;
156 const struct target_so_ops * so_ops = &solib_target_so_ops;
157 gdbarch_skip_solib_resolver_ftype *skip_solib_resolver = generic_skip_solib_resolver;
158 gdbarch_in_solib_return_trampoline_ftype *in_solib_return_trampoline = generic_in_solib_return_trampoline;
159 gdbarch_in_indirect_branch_thunk_ftype *in_indirect_branch_thunk = default_in_indirect_branch_thunk;
160 gdbarch_stack_frame_destroyed_p_ftype *stack_frame_destroyed_p = generic_stack_frame_destroyed_p;
161 gdbarch_elf_make_msymbol_special_ftype *elf_make_msymbol_special = nullptr;
162 gdbarch_coff_make_msymbol_special_ftype *coff_make_msymbol_special = default_coff_make_msymbol_special;
163 gdbarch_make_symbol_special_ftype *make_symbol_special = default_make_symbol_special;
164 gdbarch_adjust_dwarf2_addr_ftype *adjust_dwarf2_addr = default_adjust_dwarf2_addr;
165 gdbarch_adjust_dwarf2_line_ftype *adjust_dwarf2_line = default_adjust_dwarf2_line;
166 int cannot_step_breakpoint = 0;
167 int have_nonsteppable_watchpoint = 0;
168 gdbarch_address_class_type_flags_ftype *address_class_type_flags = nullptr;
169 gdbarch_address_class_type_flags_to_name_ftype *address_class_type_flags_to_name = nullptr;
170 gdbarch_execute_dwarf_cfa_vendor_op_ftype *execute_dwarf_cfa_vendor_op = default_execute_dwarf_cfa_vendor_op;
171 gdbarch_address_class_name_to_type_flags_ftype *address_class_name_to_type_flags = nullptr;
172 gdbarch_register_reggroup_p_ftype *register_reggroup_p = default_register_reggroup_p;
173 gdbarch_fetch_pointer_argument_ftype *fetch_pointer_argument = nullptr;
174 gdbarch_iterate_over_regset_sections_ftype *iterate_over_regset_sections = nullptr;
175 gdbarch_make_corefile_notes_ftype *make_corefile_notes = nullptr;
176 gdbarch_find_memory_regions_ftype *find_memory_regions = nullptr;
177 gdbarch_create_memtag_section_ftype *create_memtag_section = nullptr;
178 gdbarch_fill_memtag_section_ftype *fill_memtag_section = nullptr;
179 gdbarch_decode_memtag_section_ftype *decode_memtag_section = nullptr;
180 gdbarch_core_xfer_shared_libraries_ftype *core_xfer_shared_libraries = nullptr;
181 gdbarch_core_xfer_shared_libraries_aix_ftype *core_xfer_shared_libraries_aix = nullptr;
182 gdbarch_core_pid_to_str_ftype *core_pid_to_str = nullptr;
183 gdbarch_core_thread_name_ftype *core_thread_name = nullptr;
184 gdbarch_core_xfer_siginfo_ftype *core_xfer_siginfo = nullptr;
185 gdbarch_core_read_x86_xsave_layout_ftype *core_read_x86_xsave_layout = nullptr;
186 const char * gcore_bfd_target = 0;
187 int vtable_function_descriptors = 0;
188 int vbit_in_delta = 0;
189 gdbarch_skip_permanent_breakpoint_ftype *skip_permanent_breakpoint = default_skip_permanent_breakpoint;
190 ULONGEST max_insn_length = 0;
191 gdbarch_displaced_step_copy_insn_ftype *displaced_step_copy_insn = nullptr;
192 gdbarch_displaced_step_hw_singlestep_ftype *displaced_step_hw_singlestep = default_displaced_step_hw_singlestep;
193 gdbarch_displaced_step_fixup_ftype *displaced_step_fixup = NULL;
194 gdbarch_displaced_step_prepare_ftype *displaced_step_prepare = nullptr;
195 gdbarch_displaced_step_finish_ftype *displaced_step_finish = NULL;
196 gdbarch_displaced_step_copy_insn_closure_by_addr_ftype *displaced_step_copy_insn_closure_by_addr = nullptr;
197 gdbarch_displaced_step_restore_all_in_ptid_ftype *displaced_step_restore_all_in_ptid = nullptr;
198 ULONGEST displaced_step_buffer_length = 0;
199 gdbarch_relocate_instruction_ftype *relocate_instruction = NULL;
200 gdbarch_overlay_update_ftype *overlay_update = nullptr;
201 gdbarch_core_read_description_ftype *core_read_description = nullptr;
202 int sofun_address_maybe_missing = 0;
203 gdbarch_process_record_ftype *process_record = nullptr;
204 gdbarch_process_record_signal_ftype *process_record_signal = nullptr;
205 gdbarch_gdb_signal_from_target_ftype *gdb_signal_from_target = nullptr;
206 gdbarch_gdb_signal_to_target_ftype *gdb_signal_to_target = nullptr;
207 gdbarch_get_siginfo_type_ftype *get_siginfo_type = nullptr;
208 gdbarch_record_special_symbol_ftype *record_special_symbol = nullptr;
209 gdbarch_get_syscall_number_ftype *get_syscall_number = nullptr;
210 const char * xml_syscall_file = 0;
211 struct syscalls_info * syscalls_info = 0;
212 const char *const * stap_integer_prefixes = 0;
213 const char *const * stap_integer_suffixes = 0;
214 const char *const * stap_register_prefixes = 0;
215 const char *const * stap_register_suffixes = 0;
216 const char *const * stap_register_indirection_prefixes = 0;
217 const char *const * stap_register_indirection_suffixes = 0;
218 const char * stap_gdb_register_prefix = 0;
219 const char * stap_gdb_register_suffix = 0;
220 gdbarch_stap_is_single_operand_ftype *stap_is_single_operand = nullptr;
221 gdbarch_stap_parse_special_token_ftype *stap_parse_special_token = nullptr;
222 gdbarch_stap_adjust_register_ftype *stap_adjust_register = nullptr;
223 gdbarch_dtrace_parse_probe_argument_ftype *dtrace_parse_probe_argument = nullptr;
224 gdbarch_dtrace_probe_is_enabled_ftype *dtrace_probe_is_enabled = nullptr;
225 gdbarch_dtrace_enable_probe_ftype *dtrace_enable_probe = nullptr;
226 gdbarch_dtrace_disable_probe_ftype *dtrace_disable_probe = nullptr;
227 int has_global_solist = 0;
228 int has_global_breakpoints = 0;
229 gdbarch_has_shared_address_space_ftype *has_shared_address_space = default_has_shared_address_space;
230 gdbarch_fast_tracepoint_valid_at_ftype *fast_tracepoint_valid_at = default_fast_tracepoint_valid_at;
231 gdbarch_guess_tracepoint_registers_ftype *guess_tracepoint_registers = default_guess_tracepoint_registers;
232 gdbarch_auto_charset_ftype *auto_charset = default_auto_charset;
233 gdbarch_auto_wide_charset_ftype *auto_wide_charset = default_auto_wide_charset;
234 const char * solib_symbols_extension = 0;
235 int has_dos_based_file_system = 0;
236 gdbarch_gen_return_address_ftype *gen_return_address = default_gen_return_address;
237 gdbarch_info_proc_ftype *info_proc = nullptr;
238 gdbarch_core_info_proc_ftype *core_info_proc = nullptr;
239 gdbarch_iterate_over_objfiles_in_search_order_ftype *iterate_over_objfiles_in_search_order = default_iterate_over_objfiles_in_search_order;
240 struct ravenscar_arch_ops * ravenscar_ops = NULL;
241 gdbarch_insn_is_call_ftype *insn_is_call = default_insn_is_call;
242 gdbarch_insn_is_ret_ftype *insn_is_ret = default_insn_is_ret;
243 gdbarch_insn_is_jump_ftype *insn_is_jump = default_insn_is_jump;
244 gdbarch_program_breakpoint_here_p_ftype *program_breakpoint_here_p = default_program_breakpoint_here_p;
245 gdbarch_auxv_parse_ftype *auxv_parse = nullptr;
246 gdbarch_print_auxv_entry_ftype *print_auxv_entry = default_print_auxv_entry;
247 gdbarch_vsyscall_range_ftype *vsyscall_range = default_vsyscall_range;
248 gdbarch_infcall_mmap_ftype *infcall_mmap = default_infcall_mmap;
249 gdbarch_infcall_munmap_ftype *infcall_munmap = default_infcall_munmap;
250 gdbarch_gcc_target_options_ftype *gcc_target_options = default_gcc_target_options;
251 gdbarch_gnu_triplet_regexp_ftype *gnu_triplet_regexp = default_gnu_triplet_regexp;
252 gdbarch_addressable_memory_unit_size_ftype *addressable_memory_unit_size = default_addressable_memory_unit_size;
253 const char * disassembler_options_implicit = 0;
254 char ** disassembler_options = 0;
255 const disasm_options_and_args_t * valid_disassembler_options = 0;
256 gdbarch_type_align_ftype *type_align = default_type_align;
257 gdbarch_get_pc_address_flags_ftype *get_pc_address_flags = default_get_pc_address_flags;
258 gdbarch_read_core_file_mappings_ftype *read_core_file_mappings = default_read_core_file_mappings;
259 gdbarch_use_target_description_from_corefile_notes_ftype *use_target_description_from_corefile_notes = default_use_target_description_from_corefile_notes;
262 /* Create a new ``struct gdbarch'' based on information provided by
263 ``struct gdbarch_info''. */
265 struct gdbarch *
266 gdbarch_alloc (const struct gdbarch_info *info,
267 gdbarch_tdep_up tdep)
269 struct gdbarch *gdbarch;
271 gdbarch = new struct gdbarch;
273 gdbarch->tdep = std::move (tdep);
275 gdbarch->bfd_arch_info = info->bfd_arch_info;
276 gdbarch->byte_order = info->byte_order;
277 gdbarch->byte_order_for_code = info->byte_order_for_code;
278 gdbarch->osabi = info->osabi;
279 gdbarch->target_desc = info->target_desc;
281 return gdbarch;
286 /* Ensure that all values in a GDBARCH are reasonable. */
288 static void
289 verify_gdbarch (struct gdbarch *gdbarch)
291 string_file log;
293 /* fundamental */
294 if (gdbarch->byte_order == BFD_ENDIAN_UNKNOWN)
295 log.puts ("\n\tbyte-order");
296 if (gdbarch->bfd_arch_info == NULL)
297 log.puts ("\n\tbfd_arch_info");
298 /* Check those that need to be defined for the given multi-arch level. */
299 /* Skip verify of short_bit, invalid_p == 0 */
300 /* Skip verify of int_bit, invalid_p == 0 */
301 /* Skip verify of long_bit, invalid_p == 0 */
302 /* Skip verify of long_long_bit, invalid_p == 0 */
303 /* Skip verify of bfloat16_bit, invalid_p == 0 */
304 /* Skip verify of bfloat16_format, invalid_p == 0 */
305 /* Skip verify of half_bit, invalid_p == 0 */
306 /* Skip verify of half_format, invalid_p == 0 */
307 /* Skip verify of float_bit, invalid_p == 0 */
308 /* Skip verify of float_format, invalid_p == 0 */
309 /* Skip verify of double_bit, invalid_p == 0 */
310 /* Skip verify of double_format, invalid_p == 0 */
311 /* Skip verify of long_double_bit, invalid_p == 0 */
312 /* Skip verify of long_double_format, invalid_p == 0 */
313 /* Skip verify of wchar_bit, invalid_p == 0 */
314 if (gdbarch->wchar_signed == -1)
315 gdbarch->wchar_signed = 1;
316 /* Skip verify of wchar_signed, invalid_p == 0 */
317 /* Skip verify of floatformat_for_type, invalid_p == 0 */
318 /* Skip verify of ptr_bit, invalid_p == 0 */
319 if (gdbarch->addr_bit == 0)
320 gdbarch->addr_bit = gdbarch_ptr_bit (gdbarch);
321 /* Skip verify of addr_bit, invalid_p == 0 */
322 if (gdbarch->dwarf2_addr_size == 0)
323 gdbarch->dwarf2_addr_size = gdbarch_ptr_bit (gdbarch) / TARGET_CHAR_BIT;
324 /* Skip verify of dwarf2_addr_size, invalid_p == 0 */
325 if (gdbarch->char_signed == -1)
326 gdbarch->char_signed = 1;
327 /* Skip verify of char_signed, invalid_p == 0 */
328 /* Skip verify of read_pc, has predicate. */
329 /* Skip verify of write_pc, has predicate. */
330 /* Skip verify of virtual_frame_pointer, invalid_p == 0 */
331 /* Skip verify of pseudo_register_read, has predicate. */
332 /* Skip verify of pseudo_register_read_value, has predicate. */
333 /* Skip verify of pseudo_register_write, has predicate. */
334 if (gdbarch->num_regs == -1)
335 log.puts ("\n\tnum_regs");
336 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
337 /* Skip verify of ax_pseudo_register_collect, has predicate. */
338 /* Skip verify of ax_pseudo_register_push_stack, has predicate. */
339 /* Skip verify of report_signal_info, has predicate. */
340 /* Skip verify of sp_regnum, invalid_p == 0 */
341 /* Skip verify of pc_regnum, invalid_p == 0 */
342 /* Skip verify of ps_regnum, invalid_p == 0 */
343 /* Skip verify of fp0_regnum, invalid_p == 0 */
344 /* Skip verify of stab_reg_to_regnum, invalid_p == 0 */
345 /* Skip verify of ecoff_reg_to_regnum, invalid_p == 0 */
346 /* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */
347 /* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
348 if (gdbarch->register_name == 0)
349 log.puts ("\n\tregister_name");
350 if (gdbarch->register_type == 0)
351 log.puts ("\n\tregister_type");
352 /* Skip verify of dummy_id, invalid_p == 0 */
353 /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
354 /* Skip verify of push_dummy_call, has predicate. */
355 /* Skip verify of call_dummy_location, invalid_p == 0 */
356 /* Skip verify of push_dummy_code, has predicate. */
357 /* Skip verify of code_of_frame_writable, invalid_p == 0 */
358 /* Skip verify of print_registers_info, invalid_p == 0 */
359 /* Skip verify of print_float_info, invalid_p == 0 */
360 /* Skip verify of print_vector_info, has predicate. */
361 /* Skip verify of register_sim_regno, invalid_p == 0 */
362 /* Skip verify of cannot_fetch_register, invalid_p == 0 */
363 /* Skip verify of cannot_store_register, invalid_p == 0 */
364 /* Skip verify of get_longjmp_target, has predicate. */
365 /* Skip verify of believe_pcc_promotion, invalid_p == 0 */
366 /* Skip verify of convert_register_p, invalid_p == 0 */
367 /* Skip verify of register_to_value, invalid_p == 0 */
368 /* Skip verify of value_to_register, invalid_p == 0 */
369 /* Skip verify of value_from_register, invalid_p == 0 */
370 /* Skip verify of pointer_to_address, invalid_p == 0 */
371 /* Skip verify of address_to_pointer, invalid_p == 0 */
372 /* Skip verify of integer_to_address, has predicate. */
373 /* Skip verify of return_value, invalid_p == 0 */
374 if ((gdbarch->return_value_as_value == default_gdbarch_return_value) == (gdbarch->return_value == nullptr))
375 log.puts ("\n\treturn_value_as_value");
376 /* Skip verify of get_return_buf_addr, invalid_p == 0 */
377 /* Skip verify of dwarf2_omit_typedef_p, invalid_p == 0 */
378 /* Skip verify of update_call_site_pc, invalid_p == 0 */
379 /* Skip verify of return_in_first_hidden_param_p, invalid_p == 0 */
380 if (gdbarch->skip_prologue == 0)
381 log.puts ("\n\tskip_prologue");
382 /* Skip verify of skip_main_prologue, has predicate. */
383 /* Skip verify of skip_entrypoint, has predicate. */
384 if (gdbarch->inner_than == 0)
385 log.puts ("\n\tinner_than");
386 /* Skip verify of breakpoint_from_pc, invalid_p == 0 */
387 if (gdbarch->breakpoint_kind_from_pc == 0)
388 log.puts ("\n\tbreakpoint_kind_from_pc");
389 /* Skip verify of sw_breakpoint_from_kind, invalid_p == 0 */
390 /* Skip verify of breakpoint_kind_from_current_state, invalid_p == 0 */
391 /* Skip verify of adjust_breakpoint_address, has predicate. */
392 /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */
393 /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */
394 /* Skip verify of decr_pc_after_break, invalid_p == 0 */
395 /* Skip verify of deprecated_function_start_offset, invalid_p == 0 */
396 /* Skip verify of remote_register_number, invalid_p == 0 */
397 /* Skip verify of fetch_tls_load_module_address, has predicate. */
398 /* Skip verify of get_thread_local_address, has predicate. */
399 /* Skip verify of frame_args_skip, invalid_p == 0 */
400 /* Skip verify of unwind_pc, invalid_p == 0 */
401 /* Skip verify of unwind_sp, invalid_p == 0 */
402 /* Skip verify of frame_num_args, has predicate. */
403 /* Skip verify of frame_align, has predicate. */
404 /* Skip verify of stabs_argument_has_addr, invalid_p == 0 */
405 /* Skip verify of frame_red_zone_size, invalid_p == 0 */
406 /* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */
407 /* Skip verify of addr_bits_remove, invalid_p == 0 */
408 /* Skip verify of remove_non_address_bits, invalid_p == 0 */
409 /* Skip verify of memtag_to_string, invalid_p == 0 */
410 /* Skip verify of tagged_address_p, invalid_p == 0 */
411 /* Skip verify of memtag_matches_p, invalid_p == 0 */
412 /* Skip verify of set_memtags, invalid_p == 0 */
413 /* Skip verify of get_memtag, invalid_p == 0 */
414 /* Skip verify of memtag_granule_size, invalid_p == 0 */
415 /* Skip verify of software_single_step, has predicate. */
416 /* Skip verify of single_step_through_delay, has predicate. */
417 /* Skip verify of print_insn, invalid_p == 0 */
418 /* Skip verify of skip_trampoline_code, invalid_p == 0 */
419 /* Skip verify of so_ops, invalid_p == 0 */
420 /* Skip verify of skip_solib_resolver, invalid_p == 0 */
421 /* Skip verify of in_solib_return_trampoline, invalid_p == 0 */
422 /* Skip verify of in_indirect_branch_thunk, invalid_p == 0 */
423 /* Skip verify of stack_frame_destroyed_p, invalid_p == 0 */
424 /* Skip verify of elf_make_msymbol_special, has predicate. */
425 /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */
426 /* Skip verify of make_symbol_special, invalid_p == 0 */
427 /* Skip verify of adjust_dwarf2_addr, invalid_p == 0 */
428 /* Skip verify of adjust_dwarf2_line, invalid_p == 0 */
429 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
430 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
431 /* Skip verify of address_class_type_flags, has predicate. */
432 /* Skip verify of address_class_type_flags_to_name, has predicate. */
433 /* Skip verify of execute_dwarf_cfa_vendor_op, invalid_p == 0 */
434 /* Skip verify of address_class_name_to_type_flags, has predicate. */
435 /* Skip verify of register_reggroup_p, invalid_p == 0 */
436 /* Skip verify of fetch_pointer_argument, has predicate. */
437 /* Skip verify of iterate_over_regset_sections, has predicate. */
438 /* Skip verify of make_corefile_notes, has predicate. */
439 /* Skip verify of find_memory_regions, has predicate. */
440 /* Skip verify of create_memtag_section, has predicate. */
441 /* Skip verify of fill_memtag_section, has predicate. */
442 /* Skip verify of decode_memtag_section, has predicate. */
443 /* Skip verify of core_xfer_shared_libraries, has predicate. */
444 /* Skip verify of core_xfer_shared_libraries_aix, has predicate. */
445 /* Skip verify of core_pid_to_str, has predicate. */
446 /* Skip verify of core_thread_name, has predicate. */
447 /* Skip verify of core_xfer_siginfo, has predicate. */
448 /* Skip verify of core_read_x86_xsave_layout, has predicate. */
449 /* Skip verify of gcore_bfd_target, has predicate. */
450 /* Skip verify of vtable_function_descriptors, invalid_p == 0 */
451 /* Skip verify of vbit_in_delta, invalid_p == 0 */
452 /* Skip verify of skip_permanent_breakpoint, invalid_p == 0 */
453 /* Skip verify of max_insn_length, has predicate. */
454 /* Skip verify of displaced_step_copy_insn, has predicate. */
455 /* Skip verify of displaced_step_hw_singlestep, invalid_p == 0 */
456 if ((gdbarch->displaced_step_copy_insn == nullptr) != (gdbarch->displaced_step_fixup == nullptr))
457 log.puts ("\n\tdisplaced_step_fixup");
458 /* Skip verify of displaced_step_prepare, has predicate. */
459 if ((! gdbarch->displaced_step_finish) != (! gdbarch->displaced_step_prepare))
460 log.puts ("\n\tdisplaced_step_finish");
461 /* Skip verify of displaced_step_copy_insn_closure_by_addr, has predicate. */
462 /* Skip verify of displaced_step_restore_all_in_ptid, invalid_p == 0 */
463 if (gdbarch->displaced_step_buffer_length == 0)
464 gdbarch->displaced_step_buffer_length = gdbarch->max_insn_length;
465 if (gdbarch->displaced_step_buffer_length < gdbarch->max_insn_length)
466 log.puts ("\n\tdisplaced_step_buffer_length");
467 /* Skip verify of relocate_instruction, has predicate. */
468 /* Skip verify of overlay_update, has predicate. */
469 /* Skip verify of core_read_description, has predicate. */
470 /* Skip verify of sofun_address_maybe_missing, invalid_p == 0 */
471 /* Skip verify of process_record, has predicate. */
472 /* Skip verify of process_record_signal, has predicate. */
473 /* Skip verify of gdb_signal_from_target, has predicate. */
474 /* Skip verify of gdb_signal_to_target, has predicate. */
475 /* Skip verify of get_siginfo_type, has predicate. */
476 /* Skip verify of record_special_symbol, has predicate. */
477 /* Skip verify of get_syscall_number, has predicate. */
478 /* Skip verify of xml_syscall_file, invalid_p == 0 */
479 /* Skip verify of syscalls_info, invalid_p == 0 */
480 /* Skip verify of stap_integer_prefixes, invalid_p == 0 */
481 /* Skip verify of stap_integer_suffixes, invalid_p == 0 */
482 /* Skip verify of stap_register_prefixes, invalid_p == 0 */
483 /* Skip verify of stap_register_suffixes, invalid_p == 0 */
484 /* Skip verify of stap_register_indirection_prefixes, invalid_p == 0 */
485 /* Skip verify of stap_register_indirection_suffixes, invalid_p == 0 */
486 /* Skip verify of stap_gdb_register_prefix, invalid_p == 0 */
487 /* Skip verify of stap_gdb_register_suffix, invalid_p == 0 */
488 /* Skip verify of stap_is_single_operand, has predicate. */
489 /* Skip verify of stap_parse_special_token, has predicate. */
490 /* Skip verify of stap_adjust_register, has predicate. */
491 /* Skip verify of dtrace_parse_probe_argument, has predicate. */
492 /* Skip verify of dtrace_probe_is_enabled, has predicate. */
493 /* Skip verify of dtrace_enable_probe, has predicate. */
494 /* Skip verify of dtrace_disable_probe, has predicate. */
495 /* Skip verify of has_global_solist, invalid_p == 0 */
496 /* Skip verify of has_global_breakpoints, invalid_p == 0 */
497 /* Skip verify of has_shared_address_space, invalid_p == 0 */
498 /* Skip verify of fast_tracepoint_valid_at, invalid_p == 0 */
499 /* Skip verify of guess_tracepoint_registers, invalid_p == 0 */
500 /* Skip verify of auto_charset, invalid_p == 0 */
501 /* Skip verify of auto_wide_charset, invalid_p == 0 */
502 /* Skip verify of solib_symbols_extension, invalid_p == 0 */
503 /* Skip verify of has_dos_based_file_system, invalid_p == 0 */
504 /* Skip verify of gen_return_address, invalid_p == 0 */
505 /* Skip verify of info_proc, has predicate. */
506 /* Skip verify of core_info_proc, has predicate. */
507 /* Skip verify of iterate_over_objfiles_in_search_order, invalid_p == 0 */
508 /* Skip verify of ravenscar_ops, invalid_p == 0 */
509 /* Skip verify of insn_is_call, invalid_p == 0 */
510 /* Skip verify of insn_is_ret, invalid_p == 0 */
511 /* Skip verify of insn_is_jump, invalid_p == 0 */
512 /* Skip verify of program_breakpoint_here_p, invalid_p == 0 */
513 /* Skip verify of auxv_parse, has predicate. */
514 /* Skip verify of print_auxv_entry, invalid_p == 0 */
515 /* Skip verify of vsyscall_range, invalid_p == 0 */
516 /* Skip verify of infcall_mmap, invalid_p == 0 */
517 /* Skip verify of infcall_munmap, invalid_p == 0 */
518 /* Skip verify of gcc_target_options, invalid_p == 0 */
519 /* Skip verify of gnu_triplet_regexp, invalid_p == 0 */
520 /* Skip verify of addressable_memory_unit_size, invalid_p == 0 */
521 /* Skip verify of disassembler_options_implicit, invalid_p == 0 */
522 /* Skip verify of disassembler_options, invalid_p == 0 */
523 /* Skip verify of valid_disassembler_options, invalid_p == 0 */
524 /* Skip verify of type_align, invalid_p == 0 */
525 /* Skip verify of get_pc_address_flags, invalid_p == 0 */
526 /* Skip verify of read_core_file_mappings, invalid_p == 0 */
527 /* Skip verify of use_target_description_from_corefile_notes, invalid_p == 0 */
528 if (!log.empty ())
529 internal_error (_("verify_gdbarch: the following are invalid ...%s"),
530 log.c_str ());
534 /* Print out the details of the current architecture. */
536 void
537 gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
539 const char *gdb_nm_file = "<not-defined>";
541 #if defined (GDB_NM_FILE)
542 gdb_nm_file = GDB_NM_FILE;
543 #endif
544 gdb_printf (file,
545 "gdbarch_dump: GDB_NM_FILE = %s\n",
546 gdb_nm_file);
547 gdb_printf (file,
548 "gdbarch_dump: bfd_arch_info = %s\n",
549 gdbarch_bfd_arch_info (gdbarch)->printable_name);
550 gdb_printf (file,
551 "gdbarch_dump: byte_order = %s\n",
552 plongest (gdbarch->byte_order));
553 gdb_printf (file,
554 "gdbarch_dump: byte_order_for_code = %s\n",
555 plongest (gdbarch->byte_order_for_code));
556 gdb_printf (file,
557 "gdbarch_dump: osabi = %s\n",
558 plongest (gdbarch->osabi));
559 gdb_printf (file,
560 "gdbarch_dump: target_desc = %s\n",
561 host_address_to_string (gdbarch->target_desc));
562 gdb_printf (file,
563 "gdbarch_dump: short_bit = %s\n",
564 plongest (gdbarch->short_bit));
565 gdb_printf (file,
566 "gdbarch_dump: int_bit = %s\n",
567 plongest (gdbarch->int_bit));
568 gdb_printf (file,
569 "gdbarch_dump: long_bit = %s\n",
570 plongest (gdbarch->long_bit));
571 gdb_printf (file,
572 "gdbarch_dump: long_long_bit = %s\n",
573 plongest (gdbarch->long_long_bit));
574 gdb_printf (file,
575 "gdbarch_dump: bfloat16_bit = %s\n",
576 plongest (gdbarch->bfloat16_bit));
577 gdb_printf (file,
578 "gdbarch_dump: bfloat16_format = %s\n",
579 pformat (gdbarch, gdbarch->bfloat16_format));
580 gdb_printf (file,
581 "gdbarch_dump: half_bit = %s\n",
582 plongest (gdbarch->half_bit));
583 gdb_printf (file,
584 "gdbarch_dump: half_format = %s\n",
585 pformat (gdbarch, gdbarch->half_format));
586 gdb_printf (file,
587 "gdbarch_dump: float_bit = %s\n",
588 plongest (gdbarch->float_bit));
589 gdb_printf (file,
590 "gdbarch_dump: float_format = %s\n",
591 pformat (gdbarch, gdbarch->float_format));
592 gdb_printf (file,
593 "gdbarch_dump: double_bit = %s\n",
594 plongest (gdbarch->double_bit));
595 gdb_printf (file,
596 "gdbarch_dump: double_format = %s\n",
597 pformat (gdbarch, gdbarch->double_format));
598 gdb_printf (file,
599 "gdbarch_dump: long_double_bit = %s\n",
600 plongest (gdbarch->long_double_bit));
601 gdb_printf (file,
602 "gdbarch_dump: long_double_format = %s\n",
603 pformat (gdbarch, gdbarch->long_double_format));
604 gdb_printf (file,
605 "gdbarch_dump: wchar_bit = %s\n",
606 plongest (gdbarch->wchar_bit));
607 gdb_printf (file,
608 "gdbarch_dump: wchar_signed = %s\n",
609 plongest (gdbarch->wchar_signed));
610 gdb_printf (file,
611 "gdbarch_dump: floatformat_for_type = <%s>\n",
612 host_address_to_string (gdbarch->floatformat_for_type));
613 gdb_printf (file,
614 "gdbarch_dump: ptr_bit = %s\n",
615 plongest (gdbarch->ptr_bit));
616 gdb_printf (file,
617 "gdbarch_dump: addr_bit = %s\n",
618 plongest (gdbarch->addr_bit));
619 gdb_printf (file,
620 "gdbarch_dump: dwarf2_addr_size = %s\n",
621 plongest (gdbarch->dwarf2_addr_size));
622 gdb_printf (file,
623 "gdbarch_dump: char_signed = %s\n",
624 plongest (gdbarch->char_signed));
625 gdb_printf (file,
626 "gdbarch_dump: gdbarch_read_pc_p() = %d\n",
627 gdbarch_read_pc_p (gdbarch));
628 gdb_printf (file,
629 "gdbarch_dump: read_pc = <%s>\n",
630 host_address_to_string (gdbarch->read_pc));
631 gdb_printf (file,
632 "gdbarch_dump: gdbarch_write_pc_p() = %d\n",
633 gdbarch_write_pc_p (gdbarch));
634 gdb_printf (file,
635 "gdbarch_dump: write_pc = <%s>\n",
636 host_address_to_string (gdbarch->write_pc));
637 gdb_printf (file,
638 "gdbarch_dump: virtual_frame_pointer = <%s>\n",
639 host_address_to_string (gdbarch->virtual_frame_pointer));
640 gdb_printf (file,
641 "gdbarch_dump: gdbarch_pseudo_register_read_p() = %d\n",
642 gdbarch_pseudo_register_read_p (gdbarch));
643 gdb_printf (file,
644 "gdbarch_dump: pseudo_register_read = <%s>\n",
645 host_address_to_string (gdbarch->pseudo_register_read));
646 gdb_printf (file,
647 "gdbarch_dump: gdbarch_pseudo_register_read_value_p() = %d\n",
648 gdbarch_pseudo_register_read_value_p (gdbarch));
649 gdb_printf (file,
650 "gdbarch_dump: pseudo_register_read_value = <%s>\n",
651 host_address_to_string (gdbarch->pseudo_register_read_value));
652 gdb_printf (file,
653 "gdbarch_dump: gdbarch_pseudo_register_write_p() = %d\n",
654 gdbarch_pseudo_register_write_p (gdbarch));
655 gdb_printf (file,
656 "gdbarch_dump: pseudo_register_write = <%s>\n",
657 host_address_to_string (gdbarch->pseudo_register_write));
658 gdb_printf (file,
659 "gdbarch_dump: num_regs = %s\n",
660 plongest (gdbarch->num_regs));
661 gdb_printf (file,
662 "gdbarch_dump: num_pseudo_regs = %s\n",
663 plongest (gdbarch->num_pseudo_regs));
664 gdb_printf (file,
665 "gdbarch_dump: gdbarch_ax_pseudo_register_collect_p() = %d\n",
666 gdbarch_ax_pseudo_register_collect_p (gdbarch));
667 gdb_printf (file,
668 "gdbarch_dump: ax_pseudo_register_collect = <%s>\n",
669 host_address_to_string (gdbarch->ax_pseudo_register_collect));
670 gdb_printf (file,
671 "gdbarch_dump: gdbarch_ax_pseudo_register_push_stack_p() = %d\n",
672 gdbarch_ax_pseudo_register_push_stack_p (gdbarch));
673 gdb_printf (file,
674 "gdbarch_dump: ax_pseudo_register_push_stack = <%s>\n",
675 host_address_to_string (gdbarch->ax_pseudo_register_push_stack));
676 gdb_printf (file,
677 "gdbarch_dump: gdbarch_report_signal_info_p() = %d\n",
678 gdbarch_report_signal_info_p (gdbarch));
679 gdb_printf (file,
680 "gdbarch_dump: report_signal_info = <%s>\n",
681 host_address_to_string (gdbarch->report_signal_info));
682 gdb_printf (file,
683 "gdbarch_dump: sp_regnum = %s\n",
684 plongest (gdbarch->sp_regnum));
685 gdb_printf (file,
686 "gdbarch_dump: pc_regnum = %s\n",
687 plongest (gdbarch->pc_regnum));
688 gdb_printf (file,
689 "gdbarch_dump: ps_regnum = %s\n",
690 plongest (gdbarch->ps_regnum));
691 gdb_printf (file,
692 "gdbarch_dump: fp0_regnum = %s\n",
693 plongest (gdbarch->fp0_regnum));
694 gdb_printf (file,
695 "gdbarch_dump: stab_reg_to_regnum = <%s>\n",
696 host_address_to_string (gdbarch->stab_reg_to_regnum));
697 gdb_printf (file,
698 "gdbarch_dump: ecoff_reg_to_regnum = <%s>\n",
699 host_address_to_string (gdbarch->ecoff_reg_to_regnum));
700 gdb_printf (file,
701 "gdbarch_dump: sdb_reg_to_regnum = <%s>\n",
702 host_address_to_string (gdbarch->sdb_reg_to_regnum));
703 gdb_printf (file,
704 "gdbarch_dump: dwarf2_reg_to_regnum = <%s>\n",
705 host_address_to_string (gdbarch->dwarf2_reg_to_regnum));
706 gdb_printf (file,
707 "gdbarch_dump: register_name = <%s>\n",
708 host_address_to_string (gdbarch->register_name));
709 gdb_printf (file,
710 "gdbarch_dump: register_type = <%s>\n",
711 host_address_to_string (gdbarch->register_type));
712 gdb_printf (file,
713 "gdbarch_dump: dummy_id = <%s>\n",
714 host_address_to_string (gdbarch->dummy_id));
715 gdb_printf (file,
716 "gdbarch_dump: deprecated_fp_regnum = %s\n",
717 plongest (gdbarch->deprecated_fp_regnum));
718 gdb_printf (file,
719 "gdbarch_dump: gdbarch_push_dummy_call_p() = %d\n",
720 gdbarch_push_dummy_call_p (gdbarch));
721 gdb_printf (file,
722 "gdbarch_dump: push_dummy_call = <%s>\n",
723 host_address_to_string (gdbarch->push_dummy_call));
724 gdb_printf (file,
725 "gdbarch_dump: call_dummy_location = %s\n",
726 plongest (gdbarch->call_dummy_location));
727 gdb_printf (file,
728 "gdbarch_dump: gdbarch_push_dummy_code_p() = %d\n",
729 gdbarch_push_dummy_code_p (gdbarch));
730 gdb_printf (file,
731 "gdbarch_dump: push_dummy_code = <%s>\n",
732 host_address_to_string (gdbarch->push_dummy_code));
733 gdb_printf (file,
734 "gdbarch_dump: code_of_frame_writable = <%s>\n",
735 host_address_to_string (gdbarch->code_of_frame_writable));
736 gdb_printf (file,
737 "gdbarch_dump: print_registers_info = <%s>\n",
738 host_address_to_string (gdbarch->print_registers_info));
739 gdb_printf (file,
740 "gdbarch_dump: print_float_info = <%s>\n",
741 host_address_to_string (gdbarch->print_float_info));
742 gdb_printf (file,
743 "gdbarch_dump: gdbarch_print_vector_info_p() = %d\n",
744 gdbarch_print_vector_info_p (gdbarch));
745 gdb_printf (file,
746 "gdbarch_dump: print_vector_info = <%s>\n",
747 host_address_to_string (gdbarch->print_vector_info));
748 gdb_printf (file,
749 "gdbarch_dump: register_sim_regno = <%s>\n",
750 host_address_to_string (gdbarch->register_sim_regno));
751 gdb_printf (file,
752 "gdbarch_dump: cannot_fetch_register = <%s>\n",
753 host_address_to_string (gdbarch->cannot_fetch_register));
754 gdb_printf (file,
755 "gdbarch_dump: cannot_store_register = <%s>\n",
756 host_address_to_string (gdbarch->cannot_store_register));
757 gdb_printf (file,
758 "gdbarch_dump: gdbarch_get_longjmp_target_p() = %d\n",
759 gdbarch_get_longjmp_target_p (gdbarch));
760 gdb_printf (file,
761 "gdbarch_dump: get_longjmp_target = <%s>\n",
762 host_address_to_string (gdbarch->get_longjmp_target));
763 gdb_printf (file,
764 "gdbarch_dump: believe_pcc_promotion = %s\n",
765 plongest (gdbarch->believe_pcc_promotion));
766 gdb_printf (file,
767 "gdbarch_dump: convert_register_p = <%s>\n",
768 host_address_to_string (gdbarch->convert_register_p));
769 gdb_printf (file,
770 "gdbarch_dump: register_to_value = <%s>\n",
771 host_address_to_string (gdbarch->register_to_value));
772 gdb_printf (file,
773 "gdbarch_dump: value_to_register = <%s>\n",
774 host_address_to_string (gdbarch->value_to_register));
775 gdb_printf (file,
776 "gdbarch_dump: value_from_register = <%s>\n",
777 host_address_to_string (gdbarch->value_from_register));
778 gdb_printf (file,
779 "gdbarch_dump: pointer_to_address = <%s>\n",
780 host_address_to_string (gdbarch->pointer_to_address));
781 gdb_printf (file,
782 "gdbarch_dump: address_to_pointer = <%s>\n",
783 host_address_to_string (gdbarch->address_to_pointer));
784 gdb_printf (file,
785 "gdbarch_dump: gdbarch_integer_to_address_p() = %d\n",
786 gdbarch_integer_to_address_p (gdbarch));
787 gdb_printf (file,
788 "gdbarch_dump: integer_to_address = <%s>\n",
789 host_address_to_string (gdbarch->integer_to_address));
790 gdb_printf (file,
791 "gdbarch_dump: return_value = <%s>\n",
792 host_address_to_string (gdbarch->return_value));
793 gdb_printf (file,
794 "gdbarch_dump: return_value_as_value = <%s>\n",
795 host_address_to_string (gdbarch->return_value_as_value));
796 gdb_printf (file,
797 "gdbarch_dump: get_return_buf_addr = <%s>\n",
798 host_address_to_string (gdbarch->get_return_buf_addr));
799 gdb_printf (file,
800 "gdbarch_dump: dwarf2_omit_typedef_p = <%s>\n",
801 host_address_to_string (gdbarch->dwarf2_omit_typedef_p));
802 gdb_printf (file,
803 "gdbarch_dump: update_call_site_pc = <%s>\n",
804 host_address_to_string (gdbarch->update_call_site_pc));
805 gdb_printf (file,
806 "gdbarch_dump: return_in_first_hidden_param_p = <%s>\n",
807 host_address_to_string (gdbarch->return_in_first_hidden_param_p));
808 gdb_printf (file,
809 "gdbarch_dump: skip_prologue = <%s>\n",
810 host_address_to_string (gdbarch->skip_prologue));
811 gdb_printf (file,
812 "gdbarch_dump: gdbarch_skip_main_prologue_p() = %d\n",
813 gdbarch_skip_main_prologue_p (gdbarch));
814 gdb_printf (file,
815 "gdbarch_dump: skip_main_prologue = <%s>\n",
816 host_address_to_string (gdbarch->skip_main_prologue));
817 gdb_printf (file,
818 "gdbarch_dump: gdbarch_skip_entrypoint_p() = %d\n",
819 gdbarch_skip_entrypoint_p (gdbarch));
820 gdb_printf (file,
821 "gdbarch_dump: skip_entrypoint = <%s>\n",
822 host_address_to_string (gdbarch->skip_entrypoint));
823 gdb_printf (file,
824 "gdbarch_dump: inner_than = <%s>\n",
825 host_address_to_string (gdbarch->inner_than));
826 gdb_printf (file,
827 "gdbarch_dump: breakpoint_from_pc = <%s>\n",
828 host_address_to_string (gdbarch->breakpoint_from_pc));
829 gdb_printf (file,
830 "gdbarch_dump: breakpoint_kind_from_pc = <%s>\n",
831 host_address_to_string (gdbarch->breakpoint_kind_from_pc));
832 gdb_printf (file,
833 "gdbarch_dump: sw_breakpoint_from_kind = <%s>\n",
834 host_address_to_string (gdbarch->sw_breakpoint_from_kind));
835 gdb_printf (file,
836 "gdbarch_dump: breakpoint_kind_from_current_state = <%s>\n",
837 host_address_to_string (gdbarch->breakpoint_kind_from_current_state));
838 gdb_printf (file,
839 "gdbarch_dump: gdbarch_adjust_breakpoint_address_p() = %d\n",
840 gdbarch_adjust_breakpoint_address_p (gdbarch));
841 gdb_printf (file,
842 "gdbarch_dump: adjust_breakpoint_address = <%s>\n",
843 host_address_to_string (gdbarch->adjust_breakpoint_address));
844 gdb_printf (file,
845 "gdbarch_dump: memory_insert_breakpoint = <%s>\n",
846 host_address_to_string (gdbarch->memory_insert_breakpoint));
847 gdb_printf (file,
848 "gdbarch_dump: memory_remove_breakpoint = <%s>\n",
849 host_address_to_string (gdbarch->memory_remove_breakpoint));
850 gdb_printf (file,
851 "gdbarch_dump: decr_pc_after_break = %s\n",
852 core_addr_to_string_nz (gdbarch->decr_pc_after_break));
853 gdb_printf (file,
854 "gdbarch_dump: deprecated_function_start_offset = %s\n",
855 core_addr_to_string_nz (gdbarch->deprecated_function_start_offset));
856 gdb_printf (file,
857 "gdbarch_dump: remote_register_number = <%s>\n",
858 host_address_to_string (gdbarch->remote_register_number));
859 gdb_printf (file,
860 "gdbarch_dump: gdbarch_fetch_tls_load_module_address_p() = %d\n",
861 gdbarch_fetch_tls_load_module_address_p (gdbarch));
862 gdb_printf (file,
863 "gdbarch_dump: fetch_tls_load_module_address = <%s>\n",
864 host_address_to_string (gdbarch->fetch_tls_load_module_address));
865 gdb_printf (file,
866 "gdbarch_dump: gdbarch_get_thread_local_address_p() = %d\n",
867 gdbarch_get_thread_local_address_p (gdbarch));
868 gdb_printf (file,
869 "gdbarch_dump: get_thread_local_address = <%s>\n",
870 host_address_to_string (gdbarch->get_thread_local_address));
871 gdb_printf (file,
872 "gdbarch_dump: frame_args_skip = %s\n",
873 core_addr_to_string_nz (gdbarch->frame_args_skip));
874 gdb_printf (file,
875 "gdbarch_dump: unwind_pc = <%s>\n",
876 host_address_to_string (gdbarch->unwind_pc));
877 gdb_printf (file,
878 "gdbarch_dump: unwind_sp = <%s>\n",
879 host_address_to_string (gdbarch->unwind_sp));
880 gdb_printf (file,
881 "gdbarch_dump: gdbarch_frame_num_args_p() = %d\n",
882 gdbarch_frame_num_args_p (gdbarch));
883 gdb_printf (file,
884 "gdbarch_dump: frame_num_args = <%s>\n",
885 host_address_to_string (gdbarch->frame_num_args));
886 gdb_printf (file,
887 "gdbarch_dump: gdbarch_frame_align_p() = %d\n",
888 gdbarch_frame_align_p (gdbarch));
889 gdb_printf (file,
890 "gdbarch_dump: frame_align = <%s>\n",
891 host_address_to_string (gdbarch->frame_align));
892 gdb_printf (file,
893 "gdbarch_dump: stabs_argument_has_addr = <%s>\n",
894 host_address_to_string (gdbarch->stabs_argument_has_addr));
895 gdb_printf (file,
896 "gdbarch_dump: frame_red_zone_size = %s\n",
897 plongest (gdbarch->frame_red_zone_size));
898 gdb_printf (file,
899 "gdbarch_dump: convert_from_func_ptr_addr = <%s>\n",
900 host_address_to_string (gdbarch->convert_from_func_ptr_addr));
901 gdb_printf (file,
902 "gdbarch_dump: addr_bits_remove = <%s>\n",
903 host_address_to_string (gdbarch->addr_bits_remove));
904 gdb_printf (file,
905 "gdbarch_dump: remove_non_address_bits = <%s>\n",
906 host_address_to_string (gdbarch->remove_non_address_bits));
907 gdb_printf (file,
908 "gdbarch_dump: memtag_to_string = <%s>\n",
909 host_address_to_string (gdbarch->memtag_to_string));
910 gdb_printf (file,
911 "gdbarch_dump: tagged_address_p = <%s>\n",
912 host_address_to_string (gdbarch->tagged_address_p));
913 gdb_printf (file,
914 "gdbarch_dump: memtag_matches_p = <%s>\n",
915 host_address_to_string (gdbarch->memtag_matches_p));
916 gdb_printf (file,
917 "gdbarch_dump: set_memtags = <%s>\n",
918 host_address_to_string (gdbarch->set_memtags));
919 gdb_printf (file,
920 "gdbarch_dump: get_memtag = <%s>\n",
921 host_address_to_string (gdbarch->get_memtag));
922 gdb_printf (file,
923 "gdbarch_dump: memtag_granule_size = %s\n",
924 core_addr_to_string_nz (gdbarch->memtag_granule_size));
925 gdb_printf (file,
926 "gdbarch_dump: gdbarch_software_single_step_p() = %d\n",
927 gdbarch_software_single_step_p (gdbarch));
928 gdb_printf (file,
929 "gdbarch_dump: software_single_step = <%s>\n",
930 host_address_to_string (gdbarch->software_single_step));
931 gdb_printf (file,
932 "gdbarch_dump: gdbarch_single_step_through_delay_p() = %d\n",
933 gdbarch_single_step_through_delay_p (gdbarch));
934 gdb_printf (file,
935 "gdbarch_dump: single_step_through_delay = <%s>\n",
936 host_address_to_string (gdbarch->single_step_through_delay));
937 gdb_printf (file,
938 "gdbarch_dump: print_insn = <%s>\n",
939 host_address_to_string (gdbarch->print_insn));
940 gdb_printf (file,
941 "gdbarch_dump: skip_trampoline_code = <%s>\n",
942 host_address_to_string (gdbarch->skip_trampoline_code));
943 gdb_printf (file,
944 "gdbarch_dump: so_ops = %s\n",
945 host_address_to_string (gdbarch->so_ops));
946 gdb_printf (file,
947 "gdbarch_dump: skip_solib_resolver = <%s>\n",
948 host_address_to_string (gdbarch->skip_solib_resolver));
949 gdb_printf (file,
950 "gdbarch_dump: in_solib_return_trampoline = <%s>\n",
951 host_address_to_string (gdbarch->in_solib_return_trampoline));
952 gdb_printf (file,
953 "gdbarch_dump: in_indirect_branch_thunk = <%s>\n",
954 host_address_to_string (gdbarch->in_indirect_branch_thunk));
955 gdb_printf (file,
956 "gdbarch_dump: stack_frame_destroyed_p = <%s>\n",
957 host_address_to_string (gdbarch->stack_frame_destroyed_p));
958 gdb_printf (file,
959 "gdbarch_dump: gdbarch_elf_make_msymbol_special_p() = %d\n",
960 gdbarch_elf_make_msymbol_special_p (gdbarch));
961 gdb_printf (file,
962 "gdbarch_dump: elf_make_msymbol_special = <%s>\n",
963 host_address_to_string (gdbarch->elf_make_msymbol_special));
964 gdb_printf (file,
965 "gdbarch_dump: coff_make_msymbol_special = <%s>\n",
966 host_address_to_string (gdbarch->coff_make_msymbol_special));
967 gdb_printf (file,
968 "gdbarch_dump: make_symbol_special = <%s>\n",
969 host_address_to_string (gdbarch->make_symbol_special));
970 gdb_printf (file,
971 "gdbarch_dump: adjust_dwarf2_addr = <%s>\n",
972 host_address_to_string (gdbarch->adjust_dwarf2_addr));
973 gdb_printf (file,
974 "gdbarch_dump: adjust_dwarf2_line = <%s>\n",
975 host_address_to_string (gdbarch->adjust_dwarf2_line));
976 gdb_printf (file,
977 "gdbarch_dump: cannot_step_breakpoint = %s\n",
978 plongest (gdbarch->cannot_step_breakpoint));
979 gdb_printf (file,
980 "gdbarch_dump: have_nonsteppable_watchpoint = %s\n",
981 plongest (gdbarch->have_nonsteppable_watchpoint));
982 gdb_printf (file,
983 "gdbarch_dump: gdbarch_address_class_type_flags_p() = %d\n",
984 gdbarch_address_class_type_flags_p (gdbarch));
985 gdb_printf (file,
986 "gdbarch_dump: address_class_type_flags = <%s>\n",
987 host_address_to_string (gdbarch->address_class_type_flags));
988 gdb_printf (file,
989 "gdbarch_dump: gdbarch_address_class_type_flags_to_name_p() = %d\n",
990 gdbarch_address_class_type_flags_to_name_p (gdbarch));
991 gdb_printf (file,
992 "gdbarch_dump: address_class_type_flags_to_name = <%s>\n",
993 host_address_to_string (gdbarch->address_class_type_flags_to_name));
994 gdb_printf (file,
995 "gdbarch_dump: execute_dwarf_cfa_vendor_op = <%s>\n",
996 host_address_to_string (gdbarch->execute_dwarf_cfa_vendor_op));
997 gdb_printf (file,
998 "gdbarch_dump: gdbarch_address_class_name_to_type_flags_p() = %d\n",
999 gdbarch_address_class_name_to_type_flags_p (gdbarch));
1000 gdb_printf (file,
1001 "gdbarch_dump: address_class_name_to_type_flags = <%s>\n",
1002 host_address_to_string (gdbarch->address_class_name_to_type_flags));
1003 gdb_printf (file,
1004 "gdbarch_dump: register_reggroup_p = <%s>\n",
1005 host_address_to_string (gdbarch->register_reggroup_p));
1006 gdb_printf (file,
1007 "gdbarch_dump: gdbarch_fetch_pointer_argument_p() = %d\n",
1008 gdbarch_fetch_pointer_argument_p (gdbarch));
1009 gdb_printf (file,
1010 "gdbarch_dump: fetch_pointer_argument = <%s>\n",
1011 host_address_to_string (gdbarch->fetch_pointer_argument));
1012 gdb_printf (file,
1013 "gdbarch_dump: gdbarch_iterate_over_regset_sections_p() = %d\n",
1014 gdbarch_iterate_over_regset_sections_p (gdbarch));
1015 gdb_printf (file,
1016 "gdbarch_dump: iterate_over_regset_sections = <%s>\n",
1017 host_address_to_string (gdbarch->iterate_over_regset_sections));
1018 gdb_printf (file,
1019 "gdbarch_dump: gdbarch_make_corefile_notes_p() = %d\n",
1020 gdbarch_make_corefile_notes_p (gdbarch));
1021 gdb_printf (file,
1022 "gdbarch_dump: make_corefile_notes = <%s>\n",
1023 host_address_to_string (gdbarch->make_corefile_notes));
1024 gdb_printf (file,
1025 "gdbarch_dump: gdbarch_find_memory_regions_p() = %d\n",
1026 gdbarch_find_memory_regions_p (gdbarch));
1027 gdb_printf (file,
1028 "gdbarch_dump: find_memory_regions = <%s>\n",
1029 host_address_to_string (gdbarch->find_memory_regions));
1030 gdb_printf (file,
1031 "gdbarch_dump: gdbarch_create_memtag_section_p() = %d\n",
1032 gdbarch_create_memtag_section_p (gdbarch));
1033 gdb_printf (file,
1034 "gdbarch_dump: create_memtag_section = <%s>\n",
1035 host_address_to_string (gdbarch->create_memtag_section));
1036 gdb_printf (file,
1037 "gdbarch_dump: gdbarch_fill_memtag_section_p() = %d\n",
1038 gdbarch_fill_memtag_section_p (gdbarch));
1039 gdb_printf (file,
1040 "gdbarch_dump: fill_memtag_section = <%s>\n",
1041 host_address_to_string (gdbarch->fill_memtag_section));
1042 gdb_printf (file,
1043 "gdbarch_dump: gdbarch_decode_memtag_section_p() = %d\n",
1044 gdbarch_decode_memtag_section_p (gdbarch));
1045 gdb_printf (file,
1046 "gdbarch_dump: decode_memtag_section = <%s>\n",
1047 host_address_to_string (gdbarch->decode_memtag_section));
1048 gdb_printf (file,
1049 "gdbarch_dump: gdbarch_core_xfer_shared_libraries_p() = %d\n",
1050 gdbarch_core_xfer_shared_libraries_p (gdbarch));
1051 gdb_printf (file,
1052 "gdbarch_dump: core_xfer_shared_libraries = <%s>\n",
1053 host_address_to_string (gdbarch->core_xfer_shared_libraries));
1054 gdb_printf (file,
1055 "gdbarch_dump: gdbarch_core_xfer_shared_libraries_aix_p() = %d\n",
1056 gdbarch_core_xfer_shared_libraries_aix_p (gdbarch));
1057 gdb_printf (file,
1058 "gdbarch_dump: core_xfer_shared_libraries_aix = <%s>\n",
1059 host_address_to_string (gdbarch->core_xfer_shared_libraries_aix));
1060 gdb_printf (file,
1061 "gdbarch_dump: gdbarch_core_pid_to_str_p() = %d\n",
1062 gdbarch_core_pid_to_str_p (gdbarch));
1063 gdb_printf (file,
1064 "gdbarch_dump: core_pid_to_str = <%s>\n",
1065 host_address_to_string (gdbarch->core_pid_to_str));
1066 gdb_printf (file,
1067 "gdbarch_dump: gdbarch_core_thread_name_p() = %d\n",
1068 gdbarch_core_thread_name_p (gdbarch));
1069 gdb_printf (file,
1070 "gdbarch_dump: core_thread_name = <%s>\n",
1071 host_address_to_string (gdbarch->core_thread_name));
1072 gdb_printf (file,
1073 "gdbarch_dump: gdbarch_core_xfer_siginfo_p() = %d\n",
1074 gdbarch_core_xfer_siginfo_p (gdbarch));
1075 gdb_printf (file,
1076 "gdbarch_dump: core_xfer_siginfo = <%s>\n",
1077 host_address_to_string (gdbarch->core_xfer_siginfo));
1078 gdb_printf (file,
1079 "gdbarch_dump: gdbarch_core_read_x86_xsave_layout_p() = %d\n",
1080 gdbarch_core_read_x86_xsave_layout_p (gdbarch));
1081 gdb_printf (file,
1082 "gdbarch_dump: core_read_x86_xsave_layout = <%s>\n",
1083 host_address_to_string (gdbarch->core_read_x86_xsave_layout));
1084 gdb_printf (file,
1085 "gdbarch_dump: gdbarch_gcore_bfd_target_p() = %d\n",
1086 gdbarch_gcore_bfd_target_p (gdbarch));
1087 gdb_printf (file,
1088 "gdbarch_dump: gcore_bfd_target = %s\n",
1089 pstring (gdbarch->gcore_bfd_target));
1090 gdb_printf (file,
1091 "gdbarch_dump: vtable_function_descriptors = %s\n",
1092 plongest (gdbarch->vtable_function_descriptors));
1093 gdb_printf (file,
1094 "gdbarch_dump: vbit_in_delta = %s\n",
1095 plongest (gdbarch->vbit_in_delta));
1096 gdb_printf (file,
1097 "gdbarch_dump: skip_permanent_breakpoint = <%s>\n",
1098 host_address_to_string (gdbarch->skip_permanent_breakpoint));
1099 gdb_printf (file,
1100 "gdbarch_dump: gdbarch_max_insn_length_p() = %d\n",
1101 gdbarch_max_insn_length_p (gdbarch));
1102 gdb_printf (file,
1103 "gdbarch_dump: max_insn_length = %s\n",
1104 plongest (gdbarch->max_insn_length));
1105 gdb_printf (file,
1106 "gdbarch_dump: gdbarch_displaced_step_copy_insn_p() = %d\n",
1107 gdbarch_displaced_step_copy_insn_p (gdbarch));
1108 gdb_printf (file,
1109 "gdbarch_dump: displaced_step_copy_insn = <%s>\n",
1110 host_address_to_string (gdbarch->displaced_step_copy_insn));
1111 gdb_printf (file,
1112 "gdbarch_dump: displaced_step_hw_singlestep = <%s>\n",
1113 host_address_to_string (gdbarch->displaced_step_hw_singlestep));
1114 gdb_printf (file,
1115 "gdbarch_dump: displaced_step_fixup = <%s>\n",
1116 host_address_to_string (gdbarch->displaced_step_fixup));
1117 gdb_printf (file,
1118 "gdbarch_dump: gdbarch_displaced_step_prepare_p() = %d\n",
1119 gdbarch_displaced_step_prepare_p (gdbarch));
1120 gdb_printf (file,
1121 "gdbarch_dump: displaced_step_prepare = <%s>\n",
1122 host_address_to_string (gdbarch->displaced_step_prepare));
1123 gdb_printf (file,
1124 "gdbarch_dump: displaced_step_finish = <%s>\n",
1125 host_address_to_string (gdbarch->displaced_step_finish));
1126 gdb_printf (file,
1127 "gdbarch_dump: gdbarch_displaced_step_copy_insn_closure_by_addr_p() = %d\n",
1128 gdbarch_displaced_step_copy_insn_closure_by_addr_p (gdbarch));
1129 gdb_printf (file,
1130 "gdbarch_dump: displaced_step_copy_insn_closure_by_addr = <%s>\n",
1131 host_address_to_string (gdbarch->displaced_step_copy_insn_closure_by_addr));
1132 gdb_printf (file,
1133 "gdbarch_dump: displaced_step_restore_all_in_ptid = <%s>\n",
1134 host_address_to_string (gdbarch->displaced_step_restore_all_in_ptid));
1135 gdb_printf (file,
1136 "gdbarch_dump: displaced_step_buffer_length = %s\n",
1137 plongest (gdbarch->displaced_step_buffer_length));
1138 gdb_printf (file,
1139 "gdbarch_dump: gdbarch_relocate_instruction_p() = %d\n",
1140 gdbarch_relocate_instruction_p (gdbarch));
1141 gdb_printf (file,
1142 "gdbarch_dump: relocate_instruction = <%s>\n",
1143 host_address_to_string (gdbarch->relocate_instruction));
1144 gdb_printf (file,
1145 "gdbarch_dump: gdbarch_overlay_update_p() = %d\n",
1146 gdbarch_overlay_update_p (gdbarch));
1147 gdb_printf (file,
1148 "gdbarch_dump: overlay_update = <%s>\n",
1149 host_address_to_string (gdbarch->overlay_update));
1150 gdb_printf (file,
1151 "gdbarch_dump: gdbarch_core_read_description_p() = %d\n",
1152 gdbarch_core_read_description_p (gdbarch));
1153 gdb_printf (file,
1154 "gdbarch_dump: core_read_description = <%s>\n",
1155 host_address_to_string (gdbarch->core_read_description));
1156 gdb_printf (file,
1157 "gdbarch_dump: sofun_address_maybe_missing = %s\n",
1158 plongest (gdbarch->sofun_address_maybe_missing));
1159 gdb_printf (file,
1160 "gdbarch_dump: gdbarch_process_record_p() = %d\n",
1161 gdbarch_process_record_p (gdbarch));
1162 gdb_printf (file,
1163 "gdbarch_dump: process_record = <%s>\n",
1164 host_address_to_string (gdbarch->process_record));
1165 gdb_printf (file,
1166 "gdbarch_dump: gdbarch_process_record_signal_p() = %d\n",
1167 gdbarch_process_record_signal_p (gdbarch));
1168 gdb_printf (file,
1169 "gdbarch_dump: process_record_signal = <%s>\n",
1170 host_address_to_string (gdbarch->process_record_signal));
1171 gdb_printf (file,
1172 "gdbarch_dump: gdbarch_gdb_signal_from_target_p() = %d\n",
1173 gdbarch_gdb_signal_from_target_p (gdbarch));
1174 gdb_printf (file,
1175 "gdbarch_dump: gdb_signal_from_target = <%s>\n",
1176 host_address_to_string (gdbarch->gdb_signal_from_target));
1177 gdb_printf (file,
1178 "gdbarch_dump: gdbarch_gdb_signal_to_target_p() = %d\n",
1179 gdbarch_gdb_signal_to_target_p (gdbarch));
1180 gdb_printf (file,
1181 "gdbarch_dump: gdb_signal_to_target = <%s>\n",
1182 host_address_to_string (gdbarch->gdb_signal_to_target));
1183 gdb_printf (file,
1184 "gdbarch_dump: gdbarch_get_siginfo_type_p() = %d\n",
1185 gdbarch_get_siginfo_type_p (gdbarch));
1186 gdb_printf (file,
1187 "gdbarch_dump: get_siginfo_type = <%s>\n",
1188 host_address_to_string (gdbarch->get_siginfo_type));
1189 gdb_printf (file,
1190 "gdbarch_dump: gdbarch_record_special_symbol_p() = %d\n",
1191 gdbarch_record_special_symbol_p (gdbarch));
1192 gdb_printf (file,
1193 "gdbarch_dump: record_special_symbol = <%s>\n",
1194 host_address_to_string (gdbarch->record_special_symbol));
1195 gdb_printf (file,
1196 "gdbarch_dump: gdbarch_get_syscall_number_p() = %d\n",
1197 gdbarch_get_syscall_number_p (gdbarch));
1198 gdb_printf (file,
1199 "gdbarch_dump: get_syscall_number = <%s>\n",
1200 host_address_to_string (gdbarch->get_syscall_number));
1201 gdb_printf (file,
1202 "gdbarch_dump: xml_syscall_file = %s\n",
1203 pstring (gdbarch->xml_syscall_file));
1204 gdb_printf (file,
1205 "gdbarch_dump: syscalls_info = %s\n",
1206 host_address_to_string (gdbarch->syscalls_info));
1207 gdb_printf (file,
1208 "gdbarch_dump: stap_integer_prefixes = %s\n",
1209 pstring_list (gdbarch->stap_integer_prefixes));
1210 gdb_printf (file,
1211 "gdbarch_dump: stap_integer_suffixes = %s\n",
1212 pstring_list (gdbarch->stap_integer_suffixes));
1213 gdb_printf (file,
1214 "gdbarch_dump: stap_register_prefixes = %s\n",
1215 pstring_list (gdbarch->stap_register_prefixes));
1216 gdb_printf (file,
1217 "gdbarch_dump: stap_register_suffixes = %s\n",
1218 pstring_list (gdbarch->stap_register_suffixes));
1219 gdb_printf (file,
1220 "gdbarch_dump: stap_register_indirection_prefixes = %s\n",
1221 pstring_list (gdbarch->stap_register_indirection_prefixes));
1222 gdb_printf (file,
1223 "gdbarch_dump: stap_register_indirection_suffixes = %s\n",
1224 pstring_list (gdbarch->stap_register_indirection_suffixes));
1225 gdb_printf (file,
1226 "gdbarch_dump: stap_gdb_register_prefix = %s\n",
1227 pstring (gdbarch->stap_gdb_register_prefix));
1228 gdb_printf (file,
1229 "gdbarch_dump: stap_gdb_register_suffix = %s\n",
1230 pstring (gdbarch->stap_gdb_register_suffix));
1231 gdb_printf (file,
1232 "gdbarch_dump: gdbarch_stap_is_single_operand_p() = %d\n",
1233 gdbarch_stap_is_single_operand_p (gdbarch));
1234 gdb_printf (file,
1235 "gdbarch_dump: stap_is_single_operand = <%s>\n",
1236 host_address_to_string (gdbarch->stap_is_single_operand));
1237 gdb_printf (file,
1238 "gdbarch_dump: gdbarch_stap_parse_special_token_p() = %d\n",
1239 gdbarch_stap_parse_special_token_p (gdbarch));
1240 gdb_printf (file,
1241 "gdbarch_dump: stap_parse_special_token = <%s>\n",
1242 host_address_to_string (gdbarch->stap_parse_special_token));
1243 gdb_printf (file,
1244 "gdbarch_dump: gdbarch_stap_adjust_register_p() = %d\n",
1245 gdbarch_stap_adjust_register_p (gdbarch));
1246 gdb_printf (file,
1247 "gdbarch_dump: stap_adjust_register = <%s>\n",
1248 host_address_to_string (gdbarch->stap_adjust_register));
1249 gdb_printf (file,
1250 "gdbarch_dump: gdbarch_dtrace_parse_probe_argument_p() = %d\n",
1251 gdbarch_dtrace_parse_probe_argument_p (gdbarch));
1252 gdb_printf (file,
1253 "gdbarch_dump: dtrace_parse_probe_argument = <%s>\n",
1254 host_address_to_string (gdbarch->dtrace_parse_probe_argument));
1255 gdb_printf (file,
1256 "gdbarch_dump: gdbarch_dtrace_probe_is_enabled_p() = %d\n",
1257 gdbarch_dtrace_probe_is_enabled_p (gdbarch));
1258 gdb_printf (file,
1259 "gdbarch_dump: dtrace_probe_is_enabled = <%s>\n",
1260 host_address_to_string (gdbarch->dtrace_probe_is_enabled));
1261 gdb_printf (file,
1262 "gdbarch_dump: gdbarch_dtrace_enable_probe_p() = %d\n",
1263 gdbarch_dtrace_enable_probe_p (gdbarch));
1264 gdb_printf (file,
1265 "gdbarch_dump: dtrace_enable_probe = <%s>\n",
1266 host_address_to_string (gdbarch->dtrace_enable_probe));
1267 gdb_printf (file,
1268 "gdbarch_dump: gdbarch_dtrace_disable_probe_p() = %d\n",
1269 gdbarch_dtrace_disable_probe_p (gdbarch));
1270 gdb_printf (file,
1271 "gdbarch_dump: dtrace_disable_probe = <%s>\n",
1272 host_address_to_string (gdbarch->dtrace_disable_probe));
1273 gdb_printf (file,
1274 "gdbarch_dump: has_global_solist = %s\n",
1275 plongest (gdbarch->has_global_solist));
1276 gdb_printf (file,
1277 "gdbarch_dump: has_global_breakpoints = %s\n",
1278 plongest (gdbarch->has_global_breakpoints));
1279 gdb_printf (file,
1280 "gdbarch_dump: has_shared_address_space = <%s>\n",
1281 host_address_to_string (gdbarch->has_shared_address_space));
1282 gdb_printf (file,
1283 "gdbarch_dump: fast_tracepoint_valid_at = <%s>\n",
1284 host_address_to_string (gdbarch->fast_tracepoint_valid_at));
1285 gdb_printf (file,
1286 "gdbarch_dump: guess_tracepoint_registers = <%s>\n",
1287 host_address_to_string (gdbarch->guess_tracepoint_registers));
1288 gdb_printf (file,
1289 "gdbarch_dump: auto_charset = <%s>\n",
1290 host_address_to_string (gdbarch->auto_charset));
1291 gdb_printf (file,
1292 "gdbarch_dump: auto_wide_charset = <%s>\n",
1293 host_address_to_string (gdbarch->auto_wide_charset));
1294 gdb_printf (file,
1295 "gdbarch_dump: solib_symbols_extension = %s\n",
1296 pstring (gdbarch->solib_symbols_extension));
1297 gdb_printf (file,
1298 "gdbarch_dump: has_dos_based_file_system = %s\n",
1299 plongest (gdbarch->has_dos_based_file_system));
1300 gdb_printf (file,
1301 "gdbarch_dump: gen_return_address = <%s>\n",
1302 host_address_to_string (gdbarch->gen_return_address));
1303 gdb_printf (file,
1304 "gdbarch_dump: gdbarch_info_proc_p() = %d\n",
1305 gdbarch_info_proc_p (gdbarch));
1306 gdb_printf (file,
1307 "gdbarch_dump: info_proc = <%s>\n",
1308 host_address_to_string (gdbarch->info_proc));
1309 gdb_printf (file,
1310 "gdbarch_dump: gdbarch_core_info_proc_p() = %d\n",
1311 gdbarch_core_info_proc_p (gdbarch));
1312 gdb_printf (file,
1313 "gdbarch_dump: core_info_proc = <%s>\n",
1314 host_address_to_string (gdbarch->core_info_proc));
1315 gdb_printf (file,
1316 "gdbarch_dump: iterate_over_objfiles_in_search_order = <%s>\n",
1317 host_address_to_string (gdbarch->iterate_over_objfiles_in_search_order));
1318 gdb_printf (file,
1319 "gdbarch_dump: ravenscar_ops = %s\n",
1320 host_address_to_string (gdbarch->ravenscar_ops));
1321 gdb_printf (file,
1322 "gdbarch_dump: insn_is_call = <%s>\n",
1323 host_address_to_string (gdbarch->insn_is_call));
1324 gdb_printf (file,
1325 "gdbarch_dump: insn_is_ret = <%s>\n",
1326 host_address_to_string (gdbarch->insn_is_ret));
1327 gdb_printf (file,
1328 "gdbarch_dump: insn_is_jump = <%s>\n",
1329 host_address_to_string (gdbarch->insn_is_jump));
1330 gdb_printf (file,
1331 "gdbarch_dump: program_breakpoint_here_p = <%s>\n",
1332 host_address_to_string (gdbarch->program_breakpoint_here_p));
1333 gdb_printf (file,
1334 "gdbarch_dump: gdbarch_auxv_parse_p() = %d\n",
1335 gdbarch_auxv_parse_p (gdbarch));
1336 gdb_printf (file,
1337 "gdbarch_dump: auxv_parse = <%s>\n",
1338 host_address_to_string (gdbarch->auxv_parse));
1339 gdb_printf (file,
1340 "gdbarch_dump: print_auxv_entry = <%s>\n",
1341 host_address_to_string (gdbarch->print_auxv_entry));
1342 gdb_printf (file,
1343 "gdbarch_dump: vsyscall_range = <%s>\n",
1344 host_address_to_string (gdbarch->vsyscall_range));
1345 gdb_printf (file,
1346 "gdbarch_dump: infcall_mmap = <%s>\n",
1347 host_address_to_string (gdbarch->infcall_mmap));
1348 gdb_printf (file,
1349 "gdbarch_dump: infcall_munmap = <%s>\n",
1350 host_address_to_string (gdbarch->infcall_munmap));
1351 gdb_printf (file,
1352 "gdbarch_dump: gcc_target_options = <%s>\n",
1353 host_address_to_string (gdbarch->gcc_target_options));
1354 gdb_printf (file,
1355 "gdbarch_dump: gnu_triplet_regexp = <%s>\n",
1356 host_address_to_string (gdbarch->gnu_triplet_regexp));
1357 gdb_printf (file,
1358 "gdbarch_dump: addressable_memory_unit_size = <%s>\n",
1359 host_address_to_string (gdbarch->addressable_memory_unit_size));
1360 gdb_printf (file,
1361 "gdbarch_dump: disassembler_options_implicit = %s\n",
1362 pstring (gdbarch->disassembler_options_implicit));
1363 gdb_printf (file,
1364 "gdbarch_dump: disassembler_options = %s\n",
1365 pstring_ptr (gdbarch->disassembler_options));
1366 gdb_printf (file,
1367 "gdbarch_dump: valid_disassembler_options = %s\n",
1368 host_address_to_string (gdbarch->valid_disassembler_options));
1369 gdb_printf (file,
1370 "gdbarch_dump: type_align = <%s>\n",
1371 host_address_to_string (gdbarch->type_align));
1372 gdb_printf (file,
1373 "gdbarch_dump: get_pc_address_flags = <%s>\n",
1374 host_address_to_string (gdbarch->get_pc_address_flags));
1375 gdb_printf (file,
1376 "gdbarch_dump: read_core_file_mappings = <%s>\n",
1377 host_address_to_string (gdbarch->read_core_file_mappings));
1378 gdb_printf (file,
1379 "gdbarch_dump: use_target_description_from_corefile_notes = <%s>\n",
1380 host_address_to_string (gdbarch->use_target_description_from_corefile_notes));
1381 if (gdbarch->dump_tdep != NULL)
1382 gdbarch->dump_tdep (gdbarch, file);
1386 const struct bfd_arch_info *
1387 gdbarch_bfd_arch_info (struct gdbarch *gdbarch)
1389 gdb_assert (gdbarch != NULL);
1390 if (gdbarch_debug >= 2)
1391 gdb_printf (gdb_stdlog, "gdbarch_bfd_arch_info called\n");
1392 return gdbarch->bfd_arch_info;
1395 enum bfd_endian
1396 gdbarch_byte_order (struct gdbarch *gdbarch)
1398 gdb_assert (gdbarch != NULL);
1399 if (gdbarch_debug >= 2)
1400 gdb_printf (gdb_stdlog, "gdbarch_byte_order called\n");
1401 return gdbarch->byte_order;
1404 enum bfd_endian
1405 gdbarch_byte_order_for_code (struct gdbarch *gdbarch)
1407 gdb_assert (gdbarch != NULL);
1408 if (gdbarch_debug >= 2)
1409 gdb_printf (gdb_stdlog, "gdbarch_byte_order_for_code called\n");
1410 return gdbarch->byte_order_for_code;
1413 enum gdb_osabi
1414 gdbarch_osabi (struct gdbarch *gdbarch)
1416 gdb_assert (gdbarch != NULL);
1417 if (gdbarch_debug >= 2)
1418 gdb_printf (gdb_stdlog, "gdbarch_osabi called\n");
1419 return gdbarch->osabi;
1422 const struct target_desc *
1423 gdbarch_target_desc (struct gdbarch *gdbarch)
1425 gdb_assert (gdbarch != NULL);
1426 if (gdbarch_debug >= 2)
1427 gdb_printf (gdb_stdlog, "gdbarch_target_desc called\n");
1428 return gdbarch->target_desc;
1432 gdbarch_short_bit (struct gdbarch *gdbarch)
1434 gdb_assert (gdbarch != NULL);
1435 /* Skip verify of short_bit, invalid_p == 0 */
1436 if (gdbarch_debug >= 2)
1437 gdb_printf (gdb_stdlog, "gdbarch_short_bit called\n");
1438 return gdbarch->short_bit;
1441 void
1442 set_gdbarch_short_bit (struct gdbarch *gdbarch,
1443 int short_bit)
1445 gdbarch->short_bit = short_bit;
1449 gdbarch_int_bit (struct gdbarch *gdbarch)
1451 gdb_assert (gdbarch != NULL);
1452 /* Skip verify of int_bit, invalid_p == 0 */
1453 if (gdbarch_debug >= 2)
1454 gdb_printf (gdb_stdlog, "gdbarch_int_bit called\n");
1455 return gdbarch->int_bit;
1458 void
1459 set_gdbarch_int_bit (struct gdbarch *gdbarch,
1460 int int_bit)
1462 gdbarch->int_bit = int_bit;
1466 gdbarch_long_bit (struct gdbarch *gdbarch)
1468 gdb_assert (gdbarch != NULL);
1469 /* Skip verify of long_bit, invalid_p == 0 */
1470 if (gdbarch_debug >= 2)
1471 gdb_printf (gdb_stdlog, "gdbarch_long_bit called\n");
1472 return gdbarch->long_bit;
1475 void
1476 set_gdbarch_long_bit (struct gdbarch *gdbarch,
1477 int long_bit)
1479 gdbarch->long_bit = long_bit;
1483 gdbarch_long_long_bit (struct gdbarch *gdbarch)
1485 gdb_assert (gdbarch != NULL);
1486 /* Skip verify of long_long_bit, invalid_p == 0 */
1487 if (gdbarch_debug >= 2)
1488 gdb_printf (gdb_stdlog, "gdbarch_long_long_bit called\n");
1489 return gdbarch->long_long_bit;
1492 void
1493 set_gdbarch_long_long_bit (struct gdbarch *gdbarch,
1494 int long_long_bit)
1496 gdbarch->long_long_bit = long_long_bit;
1500 gdbarch_bfloat16_bit (struct gdbarch *gdbarch)
1502 gdb_assert (gdbarch != NULL);
1503 /* Skip verify of bfloat16_bit, invalid_p == 0 */
1504 if (gdbarch_debug >= 2)
1505 gdb_printf (gdb_stdlog, "gdbarch_bfloat16_bit called\n");
1506 return gdbarch->bfloat16_bit;
1509 void
1510 set_gdbarch_bfloat16_bit (struct gdbarch *gdbarch,
1511 int bfloat16_bit)
1513 gdbarch->bfloat16_bit = bfloat16_bit;
1516 const struct floatformat **
1517 gdbarch_bfloat16_format (struct gdbarch *gdbarch)
1519 gdb_assert (gdbarch != NULL);
1520 /* Skip verify of bfloat16_format, invalid_p == 0 */
1521 if (gdbarch_debug >= 2)
1522 gdb_printf (gdb_stdlog, "gdbarch_bfloat16_format called\n");
1523 return gdbarch->bfloat16_format;
1526 void
1527 set_gdbarch_bfloat16_format (struct gdbarch *gdbarch,
1528 const struct floatformat ** bfloat16_format)
1530 gdbarch->bfloat16_format = bfloat16_format;
1534 gdbarch_half_bit (struct gdbarch *gdbarch)
1536 gdb_assert (gdbarch != NULL);
1537 /* Skip verify of half_bit, invalid_p == 0 */
1538 if (gdbarch_debug >= 2)
1539 gdb_printf (gdb_stdlog, "gdbarch_half_bit called\n");
1540 return gdbarch->half_bit;
1543 void
1544 set_gdbarch_half_bit (struct gdbarch *gdbarch,
1545 int half_bit)
1547 gdbarch->half_bit = half_bit;
1550 const struct floatformat **
1551 gdbarch_half_format (struct gdbarch *gdbarch)
1553 gdb_assert (gdbarch != NULL);
1554 /* Skip verify of half_format, invalid_p == 0 */
1555 if (gdbarch_debug >= 2)
1556 gdb_printf (gdb_stdlog, "gdbarch_half_format called\n");
1557 return gdbarch->half_format;
1560 void
1561 set_gdbarch_half_format (struct gdbarch *gdbarch,
1562 const struct floatformat ** half_format)
1564 gdbarch->half_format = half_format;
1568 gdbarch_float_bit (struct gdbarch *gdbarch)
1570 gdb_assert (gdbarch != NULL);
1571 /* Skip verify of float_bit, invalid_p == 0 */
1572 if (gdbarch_debug >= 2)
1573 gdb_printf (gdb_stdlog, "gdbarch_float_bit called\n");
1574 return gdbarch->float_bit;
1577 void
1578 set_gdbarch_float_bit (struct gdbarch *gdbarch,
1579 int float_bit)
1581 gdbarch->float_bit = float_bit;
1584 const struct floatformat **
1585 gdbarch_float_format (struct gdbarch *gdbarch)
1587 gdb_assert (gdbarch != NULL);
1588 /* Skip verify of float_format, invalid_p == 0 */
1589 if (gdbarch_debug >= 2)
1590 gdb_printf (gdb_stdlog, "gdbarch_float_format called\n");
1591 return gdbarch->float_format;
1594 void
1595 set_gdbarch_float_format (struct gdbarch *gdbarch,
1596 const struct floatformat ** float_format)
1598 gdbarch->float_format = float_format;
1602 gdbarch_double_bit (struct gdbarch *gdbarch)
1604 gdb_assert (gdbarch != NULL);
1605 /* Skip verify of double_bit, invalid_p == 0 */
1606 if (gdbarch_debug >= 2)
1607 gdb_printf (gdb_stdlog, "gdbarch_double_bit called\n");
1608 return gdbarch->double_bit;
1611 void
1612 set_gdbarch_double_bit (struct gdbarch *gdbarch,
1613 int double_bit)
1615 gdbarch->double_bit = double_bit;
1618 const struct floatformat **
1619 gdbarch_double_format (struct gdbarch *gdbarch)
1621 gdb_assert (gdbarch != NULL);
1622 /* Skip verify of double_format, invalid_p == 0 */
1623 if (gdbarch_debug >= 2)
1624 gdb_printf (gdb_stdlog, "gdbarch_double_format called\n");
1625 return gdbarch->double_format;
1628 void
1629 set_gdbarch_double_format (struct gdbarch *gdbarch,
1630 const struct floatformat ** double_format)
1632 gdbarch->double_format = double_format;
1636 gdbarch_long_double_bit (struct gdbarch *gdbarch)
1638 gdb_assert (gdbarch != NULL);
1639 /* Skip verify of long_double_bit, invalid_p == 0 */
1640 if (gdbarch_debug >= 2)
1641 gdb_printf (gdb_stdlog, "gdbarch_long_double_bit called\n");
1642 return gdbarch->long_double_bit;
1645 void
1646 set_gdbarch_long_double_bit (struct gdbarch *gdbarch,
1647 int long_double_bit)
1649 gdbarch->long_double_bit = long_double_bit;
1652 const struct floatformat **
1653 gdbarch_long_double_format (struct gdbarch *gdbarch)
1655 gdb_assert (gdbarch != NULL);
1656 /* Skip verify of long_double_format, invalid_p == 0 */
1657 if (gdbarch_debug >= 2)
1658 gdb_printf (gdb_stdlog, "gdbarch_long_double_format called\n");
1659 return gdbarch->long_double_format;
1662 void
1663 set_gdbarch_long_double_format (struct gdbarch *gdbarch,
1664 const struct floatformat ** long_double_format)
1666 gdbarch->long_double_format = long_double_format;
1670 gdbarch_wchar_bit (struct gdbarch *gdbarch)
1672 gdb_assert (gdbarch != NULL);
1673 /* Skip verify of wchar_bit, invalid_p == 0 */
1674 if (gdbarch_debug >= 2)
1675 gdb_printf (gdb_stdlog, "gdbarch_wchar_bit called\n");
1676 return gdbarch->wchar_bit;
1679 void
1680 set_gdbarch_wchar_bit (struct gdbarch *gdbarch,
1681 int wchar_bit)
1683 gdbarch->wchar_bit = wchar_bit;
1687 gdbarch_wchar_signed (struct gdbarch *gdbarch)
1689 gdb_assert (gdbarch != NULL);
1690 /* Check variable changed from its initial value. */
1691 gdb_assert (gdbarch->wchar_signed != -1);
1692 if (gdbarch_debug >= 2)
1693 gdb_printf (gdb_stdlog, "gdbarch_wchar_signed called\n");
1694 return gdbarch->wchar_signed;
1697 void
1698 set_gdbarch_wchar_signed (struct gdbarch *gdbarch,
1699 int wchar_signed)
1701 gdbarch->wchar_signed = wchar_signed;
1704 const struct floatformat **
1705 gdbarch_floatformat_for_type (struct gdbarch *gdbarch, const char *name, int length)
1707 gdb_assert (gdbarch != NULL);
1708 gdb_assert (gdbarch->floatformat_for_type != NULL);
1709 if (gdbarch_debug >= 2)
1710 gdb_printf (gdb_stdlog, "gdbarch_floatformat_for_type called\n");
1711 return gdbarch->floatformat_for_type (gdbarch, name, length);
1714 void
1715 set_gdbarch_floatformat_for_type (struct gdbarch *gdbarch,
1716 gdbarch_floatformat_for_type_ftype floatformat_for_type)
1718 gdbarch->floatformat_for_type = floatformat_for_type;
1722 gdbarch_ptr_bit (struct gdbarch *gdbarch)
1724 gdb_assert (gdbarch != NULL);
1725 /* Skip verify of ptr_bit, invalid_p == 0 */
1726 if (gdbarch_debug >= 2)
1727 gdb_printf (gdb_stdlog, "gdbarch_ptr_bit called\n");
1728 return gdbarch->ptr_bit;
1731 void
1732 set_gdbarch_ptr_bit (struct gdbarch *gdbarch,
1733 int ptr_bit)
1735 gdbarch->ptr_bit = ptr_bit;
1739 gdbarch_addr_bit (struct gdbarch *gdbarch)
1741 gdb_assert (gdbarch != NULL);
1742 /* Check variable changed from its initial value. */
1743 gdb_assert (gdbarch->addr_bit != 0);
1744 if (gdbarch_debug >= 2)
1745 gdb_printf (gdb_stdlog, "gdbarch_addr_bit called\n");
1746 return gdbarch->addr_bit;
1749 void
1750 set_gdbarch_addr_bit (struct gdbarch *gdbarch,
1751 int addr_bit)
1753 gdbarch->addr_bit = addr_bit;
1757 gdbarch_dwarf2_addr_size (struct gdbarch *gdbarch)
1759 gdb_assert (gdbarch != NULL);
1760 /* Check variable changed from its initial value. */
1761 gdb_assert (gdbarch->dwarf2_addr_size != 0);
1762 if (gdbarch_debug >= 2)
1763 gdb_printf (gdb_stdlog, "gdbarch_dwarf2_addr_size called\n");
1764 return gdbarch->dwarf2_addr_size;
1767 void
1768 set_gdbarch_dwarf2_addr_size (struct gdbarch *gdbarch,
1769 int dwarf2_addr_size)
1771 gdbarch->dwarf2_addr_size = dwarf2_addr_size;
1775 gdbarch_char_signed (struct gdbarch *gdbarch)
1777 gdb_assert (gdbarch != NULL);
1778 /* Check variable changed from its initial value. */
1779 gdb_assert (gdbarch->char_signed != -1);
1780 if (gdbarch_debug >= 2)
1781 gdb_printf (gdb_stdlog, "gdbarch_char_signed called\n");
1782 return gdbarch->char_signed;
1785 void
1786 set_gdbarch_char_signed (struct gdbarch *gdbarch,
1787 int char_signed)
1789 gdbarch->char_signed = char_signed;
1792 bool
1793 gdbarch_read_pc_p (struct gdbarch *gdbarch)
1795 gdb_assert (gdbarch != NULL);
1796 return gdbarch->read_pc != NULL;
1799 CORE_ADDR
1800 gdbarch_read_pc (struct gdbarch *gdbarch, readable_regcache *regcache)
1802 gdb_assert (gdbarch != NULL);
1803 gdb_assert (gdbarch->read_pc != NULL);
1804 if (gdbarch_debug >= 2)
1805 gdb_printf (gdb_stdlog, "gdbarch_read_pc called\n");
1806 return gdbarch->read_pc (regcache);
1809 void
1810 set_gdbarch_read_pc (struct gdbarch *gdbarch,
1811 gdbarch_read_pc_ftype read_pc)
1813 gdbarch->read_pc = read_pc;
1816 bool
1817 gdbarch_write_pc_p (struct gdbarch *gdbarch)
1819 gdb_assert (gdbarch != NULL);
1820 return gdbarch->write_pc != NULL;
1823 void
1824 gdbarch_write_pc (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR val)
1826 gdb_assert (gdbarch != NULL);
1827 gdb_assert (gdbarch->write_pc != NULL);
1828 if (gdbarch_debug >= 2)
1829 gdb_printf (gdb_stdlog, "gdbarch_write_pc called\n");
1830 gdbarch->write_pc (regcache, val);
1833 void
1834 set_gdbarch_write_pc (struct gdbarch *gdbarch,
1835 gdbarch_write_pc_ftype write_pc)
1837 gdbarch->write_pc = write_pc;
1840 void
1841 gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset)
1843 gdb_assert (gdbarch != NULL);
1844 gdb_assert (gdbarch->virtual_frame_pointer != NULL);
1845 if (gdbarch_debug >= 2)
1846 gdb_printf (gdb_stdlog, "gdbarch_virtual_frame_pointer called\n");
1847 gdbarch->virtual_frame_pointer (gdbarch, pc, frame_regnum, frame_offset);
1850 void
1851 set_gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch,
1852 gdbarch_virtual_frame_pointer_ftype virtual_frame_pointer)
1854 gdbarch->virtual_frame_pointer = virtual_frame_pointer;
1857 bool
1858 gdbarch_pseudo_register_read_p (struct gdbarch *gdbarch)
1860 gdb_assert (gdbarch != NULL);
1861 return gdbarch->pseudo_register_read != NULL;
1864 enum register_status
1865 gdbarch_pseudo_register_read (struct gdbarch *gdbarch, readable_regcache *regcache, int cookednum, gdb_byte *buf)
1867 gdb_assert (gdbarch != NULL);
1868 gdb_assert (gdbarch->pseudo_register_read != NULL);
1869 if (gdbarch_debug >= 2)
1870 gdb_printf (gdb_stdlog, "gdbarch_pseudo_register_read called\n");
1871 return gdbarch->pseudo_register_read (gdbarch, regcache, cookednum, buf);
1874 void
1875 set_gdbarch_pseudo_register_read (struct gdbarch *gdbarch,
1876 gdbarch_pseudo_register_read_ftype pseudo_register_read)
1878 gdbarch->pseudo_register_read = pseudo_register_read;
1881 bool
1882 gdbarch_pseudo_register_read_value_p (struct gdbarch *gdbarch)
1884 gdb_assert (gdbarch != NULL);
1885 return gdbarch->pseudo_register_read_value != NULL;
1888 struct value *
1889 gdbarch_pseudo_register_read_value (struct gdbarch *gdbarch, readable_regcache *regcache, int cookednum)
1891 gdb_assert (gdbarch != NULL);
1892 gdb_assert (gdbarch->pseudo_register_read_value != NULL);
1893 if (gdbarch_debug >= 2)
1894 gdb_printf (gdb_stdlog, "gdbarch_pseudo_register_read_value called\n");
1895 return gdbarch->pseudo_register_read_value (gdbarch, regcache, cookednum);
1898 void
1899 set_gdbarch_pseudo_register_read_value (struct gdbarch *gdbarch,
1900 gdbarch_pseudo_register_read_value_ftype pseudo_register_read_value)
1902 gdbarch->pseudo_register_read_value = pseudo_register_read_value;
1905 bool
1906 gdbarch_pseudo_register_write_p (struct gdbarch *gdbarch)
1908 gdb_assert (gdbarch != NULL);
1909 return gdbarch->pseudo_register_write != NULL;
1912 void
1913 gdbarch_pseudo_register_write (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, const gdb_byte *buf)
1915 gdb_assert (gdbarch != NULL);
1916 gdb_assert (gdbarch->pseudo_register_write != NULL);
1917 if (gdbarch_debug >= 2)
1918 gdb_printf (gdb_stdlog, "gdbarch_pseudo_register_write called\n");
1919 gdbarch->pseudo_register_write (gdbarch, regcache, cookednum, buf);
1922 void
1923 set_gdbarch_pseudo_register_write (struct gdbarch *gdbarch,
1924 gdbarch_pseudo_register_write_ftype pseudo_register_write)
1926 gdbarch->pseudo_register_write = pseudo_register_write;
1930 gdbarch_num_regs (struct gdbarch *gdbarch)
1932 gdb_assert (gdbarch != NULL);
1933 /* Check variable changed from its initial value. */
1934 gdb_assert (gdbarch->num_regs != -1);
1935 if (gdbarch_debug >= 2)
1936 gdb_printf (gdb_stdlog, "gdbarch_num_regs called\n");
1937 return gdbarch->num_regs;
1940 void
1941 set_gdbarch_num_regs (struct gdbarch *gdbarch,
1942 int num_regs)
1944 gdbarch->num_regs = num_regs;
1948 gdbarch_num_pseudo_regs (struct gdbarch *gdbarch)
1950 gdb_assert (gdbarch != NULL);
1951 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
1952 if (gdbarch_debug >= 2)
1953 gdb_printf (gdb_stdlog, "gdbarch_num_pseudo_regs called\n");
1954 return gdbarch->num_pseudo_regs;
1957 void
1958 set_gdbarch_num_pseudo_regs (struct gdbarch *gdbarch,
1959 int num_pseudo_regs)
1961 gdbarch->num_pseudo_regs = num_pseudo_regs;
1964 bool
1965 gdbarch_ax_pseudo_register_collect_p (struct gdbarch *gdbarch)
1967 gdb_assert (gdbarch != NULL);
1968 return gdbarch->ax_pseudo_register_collect != NULL;
1972 gdbarch_ax_pseudo_register_collect (struct gdbarch *gdbarch, struct agent_expr *ax, int reg)
1974 gdb_assert (gdbarch != NULL);
1975 gdb_assert (gdbarch->ax_pseudo_register_collect != NULL);
1976 if (gdbarch_debug >= 2)
1977 gdb_printf (gdb_stdlog, "gdbarch_ax_pseudo_register_collect called\n");
1978 return gdbarch->ax_pseudo_register_collect (gdbarch, ax, reg);
1981 void
1982 set_gdbarch_ax_pseudo_register_collect (struct gdbarch *gdbarch,
1983 gdbarch_ax_pseudo_register_collect_ftype ax_pseudo_register_collect)
1985 gdbarch->ax_pseudo_register_collect = ax_pseudo_register_collect;
1988 bool
1989 gdbarch_ax_pseudo_register_push_stack_p (struct gdbarch *gdbarch)
1991 gdb_assert (gdbarch != NULL);
1992 return gdbarch->ax_pseudo_register_push_stack != NULL;
1996 gdbarch_ax_pseudo_register_push_stack (struct gdbarch *gdbarch, struct agent_expr *ax, int reg)
1998 gdb_assert (gdbarch != NULL);
1999 gdb_assert (gdbarch->ax_pseudo_register_push_stack != NULL);
2000 if (gdbarch_debug >= 2)
2001 gdb_printf (gdb_stdlog, "gdbarch_ax_pseudo_register_push_stack called\n");
2002 return gdbarch->ax_pseudo_register_push_stack (gdbarch, ax, reg);
2005 void
2006 set_gdbarch_ax_pseudo_register_push_stack (struct gdbarch *gdbarch,
2007 gdbarch_ax_pseudo_register_push_stack_ftype ax_pseudo_register_push_stack)
2009 gdbarch->ax_pseudo_register_push_stack = ax_pseudo_register_push_stack;
2012 bool
2013 gdbarch_report_signal_info_p (struct gdbarch *gdbarch)
2015 gdb_assert (gdbarch != NULL);
2016 return gdbarch->report_signal_info != NULL;
2019 void
2020 gdbarch_report_signal_info (struct gdbarch *gdbarch, struct ui_out *uiout, enum gdb_signal siggnal)
2022 gdb_assert (gdbarch != NULL);
2023 gdb_assert (gdbarch->report_signal_info != NULL);
2024 if (gdbarch_debug >= 2)
2025 gdb_printf (gdb_stdlog, "gdbarch_report_signal_info called\n");
2026 gdbarch->report_signal_info (gdbarch, uiout, siggnal);
2029 void
2030 set_gdbarch_report_signal_info (struct gdbarch *gdbarch,
2031 gdbarch_report_signal_info_ftype report_signal_info)
2033 gdbarch->report_signal_info = report_signal_info;
2037 gdbarch_sp_regnum (struct gdbarch *gdbarch)
2039 gdb_assert (gdbarch != NULL);
2040 /* Skip verify of sp_regnum, invalid_p == 0 */
2041 if (gdbarch_debug >= 2)
2042 gdb_printf (gdb_stdlog, "gdbarch_sp_regnum called\n");
2043 return gdbarch->sp_regnum;
2046 void
2047 set_gdbarch_sp_regnum (struct gdbarch *gdbarch,
2048 int sp_regnum)
2050 gdbarch->sp_regnum = sp_regnum;
2054 gdbarch_pc_regnum (struct gdbarch *gdbarch)
2056 gdb_assert (gdbarch != NULL);
2057 /* Skip verify of pc_regnum, invalid_p == 0 */
2058 if (gdbarch_debug >= 2)
2059 gdb_printf (gdb_stdlog, "gdbarch_pc_regnum called\n");
2060 return gdbarch->pc_regnum;
2063 void
2064 set_gdbarch_pc_regnum (struct gdbarch *gdbarch,
2065 int pc_regnum)
2067 gdbarch->pc_regnum = pc_regnum;
2071 gdbarch_ps_regnum (struct gdbarch *gdbarch)
2073 gdb_assert (gdbarch != NULL);
2074 /* Skip verify of ps_regnum, invalid_p == 0 */
2075 if (gdbarch_debug >= 2)
2076 gdb_printf (gdb_stdlog, "gdbarch_ps_regnum called\n");
2077 return gdbarch->ps_regnum;
2080 void
2081 set_gdbarch_ps_regnum (struct gdbarch *gdbarch,
2082 int ps_regnum)
2084 gdbarch->ps_regnum = ps_regnum;
2088 gdbarch_fp0_regnum (struct gdbarch *gdbarch)
2090 gdb_assert (gdbarch != NULL);
2091 /* Skip verify of fp0_regnum, invalid_p == 0 */
2092 if (gdbarch_debug >= 2)
2093 gdb_printf (gdb_stdlog, "gdbarch_fp0_regnum called\n");
2094 return gdbarch->fp0_regnum;
2097 void
2098 set_gdbarch_fp0_regnum (struct gdbarch *gdbarch,
2099 int fp0_regnum)
2101 gdbarch->fp0_regnum = fp0_regnum;
2105 gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, int stab_regnr)
2107 gdb_assert (gdbarch != NULL);
2108 gdb_assert (gdbarch->stab_reg_to_regnum != NULL);
2109 if (gdbarch_debug >= 2)
2110 gdb_printf (gdb_stdlog, "gdbarch_stab_reg_to_regnum called\n");
2111 return gdbarch->stab_reg_to_regnum (gdbarch, stab_regnr);
2114 void
2115 set_gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch,
2116 gdbarch_stab_reg_to_regnum_ftype stab_reg_to_regnum)
2118 gdbarch->stab_reg_to_regnum = stab_reg_to_regnum;
2122 gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, int ecoff_regnr)
2124 gdb_assert (gdbarch != NULL);
2125 gdb_assert (gdbarch->ecoff_reg_to_regnum != NULL);
2126 if (gdbarch_debug >= 2)
2127 gdb_printf (gdb_stdlog, "gdbarch_ecoff_reg_to_regnum called\n");
2128 return gdbarch->ecoff_reg_to_regnum (gdbarch, ecoff_regnr);
2131 void
2132 set_gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch,
2133 gdbarch_ecoff_reg_to_regnum_ftype ecoff_reg_to_regnum)
2135 gdbarch->ecoff_reg_to_regnum = ecoff_reg_to_regnum;
2139 gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, int sdb_regnr)
2141 gdb_assert (gdbarch != NULL);
2142 gdb_assert (gdbarch->sdb_reg_to_regnum != NULL);
2143 if (gdbarch_debug >= 2)
2144 gdb_printf (gdb_stdlog, "gdbarch_sdb_reg_to_regnum called\n");
2145 return gdbarch->sdb_reg_to_regnum (gdbarch, sdb_regnr);
2148 void
2149 set_gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch,
2150 gdbarch_sdb_reg_to_regnum_ftype sdb_reg_to_regnum)
2152 gdbarch->sdb_reg_to_regnum = sdb_reg_to_regnum;
2156 gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, int dwarf2_regnr)
2158 gdb_assert (gdbarch != NULL);
2159 gdb_assert (gdbarch->dwarf2_reg_to_regnum != NULL);
2160 if (gdbarch_debug >= 2)
2161 gdb_printf (gdb_stdlog, "gdbarch_dwarf2_reg_to_regnum called\n");
2162 return gdbarch->dwarf2_reg_to_regnum (gdbarch, dwarf2_regnr);
2165 void
2166 set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch,
2167 gdbarch_dwarf2_reg_to_regnum_ftype dwarf2_reg_to_regnum)
2169 gdbarch->dwarf2_reg_to_regnum = dwarf2_reg_to_regnum;
2172 const char *
2173 gdbarch_register_name (struct gdbarch *gdbarch, int regnr)
2175 gdb_assert (gdbarch != NULL);
2176 gdb_assert (gdbarch->register_name != NULL);
2177 gdb_assert (regnr >= 0);
2178 gdb_assert (regnr < gdbarch_num_cooked_regs (gdbarch));
2179 if (gdbarch_debug >= 2)
2180 gdb_printf (gdb_stdlog, "gdbarch_register_name called\n");
2181 auto result = gdbarch->register_name (gdbarch, regnr);
2182 gdb_assert (result != nullptr);
2183 return result;
2186 void
2187 set_gdbarch_register_name (struct gdbarch *gdbarch,
2188 gdbarch_register_name_ftype register_name)
2190 gdbarch->register_name = register_name;
2193 struct type *
2194 gdbarch_register_type (struct gdbarch *gdbarch, int reg_nr)
2196 gdb_assert (gdbarch != NULL);
2197 gdb_assert (gdbarch->register_type != NULL);
2198 if (gdbarch_debug >= 2)
2199 gdb_printf (gdb_stdlog, "gdbarch_register_type called\n");
2200 return gdbarch->register_type (gdbarch, reg_nr);
2203 void
2204 set_gdbarch_register_type (struct gdbarch *gdbarch,
2205 gdbarch_register_type_ftype register_type)
2207 gdbarch->register_type = register_type;
2210 struct frame_id
2211 gdbarch_dummy_id (struct gdbarch *gdbarch, frame_info_ptr this_frame)
2213 gdb_assert (gdbarch != NULL);
2214 gdb_assert (gdbarch->dummy_id != NULL);
2215 if (gdbarch_debug >= 2)
2216 gdb_printf (gdb_stdlog, "gdbarch_dummy_id called\n");
2217 return gdbarch->dummy_id (gdbarch, this_frame);
2220 void
2221 set_gdbarch_dummy_id (struct gdbarch *gdbarch,
2222 gdbarch_dummy_id_ftype dummy_id)
2224 gdbarch->dummy_id = dummy_id;
2228 gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch)
2230 gdb_assert (gdbarch != NULL);
2231 /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
2232 if (gdbarch_debug >= 2)
2233 gdb_printf (gdb_stdlog, "gdbarch_deprecated_fp_regnum called\n");
2234 return gdbarch->deprecated_fp_regnum;
2237 void
2238 set_gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch,
2239 int deprecated_fp_regnum)
2241 gdbarch->deprecated_fp_regnum = deprecated_fp_regnum;
2244 bool
2245 gdbarch_push_dummy_call_p (struct gdbarch *gdbarch)
2247 gdb_assert (gdbarch != NULL);
2248 return gdbarch->push_dummy_call != NULL;
2251 CORE_ADDR
2252 gdbarch_push_dummy_call (struct gdbarch *gdbarch, struct value *function, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, function_call_return_method return_method, CORE_ADDR struct_addr)
2254 gdb_assert (gdbarch != NULL);
2255 gdb_assert (gdbarch->push_dummy_call != NULL);
2256 if (gdbarch_debug >= 2)
2257 gdb_printf (gdb_stdlog, "gdbarch_push_dummy_call called\n");
2258 return gdbarch->push_dummy_call (gdbarch, function, regcache, bp_addr, nargs, args, sp, return_method, struct_addr);
2261 void
2262 set_gdbarch_push_dummy_call (struct gdbarch *gdbarch,
2263 gdbarch_push_dummy_call_ftype push_dummy_call)
2265 gdbarch->push_dummy_call = push_dummy_call;
2268 enum call_dummy_location_type
2269 gdbarch_call_dummy_location (struct gdbarch *gdbarch)
2271 gdb_assert (gdbarch != NULL);
2272 /* Skip verify of call_dummy_location, invalid_p == 0 */
2273 if (gdbarch_debug >= 2)
2274 gdb_printf (gdb_stdlog, "gdbarch_call_dummy_location called\n");
2275 return gdbarch->call_dummy_location;
2278 void
2279 set_gdbarch_call_dummy_location (struct gdbarch *gdbarch,
2280 enum call_dummy_location_type call_dummy_location)
2282 gdbarch->call_dummy_location = call_dummy_location;
2285 bool
2286 gdbarch_push_dummy_code_p (struct gdbarch *gdbarch)
2288 gdb_assert (gdbarch != NULL);
2289 return gdbarch->push_dummy_code != NULL;
2292 CORE_ADDR
2293 gdbarch_push_dummy_code (struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr, struct regcache *regcache)
2295 gdb_assert (gdbarch != NULL);
2296 gdb_assert (gdbarch->push_dummy_code != NULL);
2297 if (gdbarch_debug >= 2)
2298 gdb_printf (gdb_stdlog, "gdbarch_push_dummy_code called\n");
2299 return gdbarch->push_dummy_code (gdbarch, sp, funaddr, args, nargs, value_type, real_pc, bp_addr, regcache);
2302 void
2303 set_gdbarch_push_dummy_code (struct gdbarch *gdbarch,
2304 gdbarch_push_dummy_code_ftype push_dummy_code)
2306 gdbarch->push_dummy_code = push_dummy_code;
2310 gdbarch_code_of_frame_writable (struct gdbarch *gdbarch, frame_info_ptr frame)
2312 gdb_assert (gdbarch != NULL);
2313 gdb_assert (gdbarch->code_of_frame_writable != NULL);
2314 if (gdbarch_debug >= 2)
2315 gdb_printf (gdb_stdlog, "gdbarch_code_of_frame_writable called\n");
2316 return gdbarch->code_of_frame_writable (gdbarch, frame);
2319 void
2320 set_gdbarch_code_of_frame_writable (struct gdbarch *gdbarch,
2321 gdbarch_code_of_frame_writable_ftype code_of_frame_writable)
2323 gdbarch->code_of_frame_writable = code_of_frame_writable;
2326 void
2327 gdbarch_print_registers_info (struct gdbarch *gdbarch, struct ui_file *file, frame_info_ptr frame, int regnum, int all)
2329 gdb_assert (gdbarch != NULL);
2330 gdb_assert (gdbarch->print_registers_info != NULL);
2331 if (gdbarch_debug >= 2)
2332 gdb_printf (gdb_stdlog, "gdbarch_print_registers_info called\n");
2333 gdbarch->print_registers_info (gdbarch, file, frame, regnum, all);
2336 void
2337 set_gdbarch_print_registers_info (struct gdbarch *gdbarch,
2338 gdbarch_print_registers_info_ftype print_registers_info)
2340 gdbarch->print_registers_info = print_registers_info;
2343 void
2344 gdbarch_print_float_info (struct gdbarch *gdbarch, struct ui_file *file, frame_info_ptr frame, const char *args)
2346 gdb_assert (gdbarch != NULL);
2347 gdb_assert (gdbarch->print_float_info != NULL);
2348 if (gdbarch_debug >= 2)
2349 gdb_printf (gdb_stdlog, "gdbarch_print_float_info called\n");
2350 gdbarch->print_float_info (gdbarch, file, frame, args);
2353 void
2354 set_gdbarch_print_float_info (struct gdbarch *gdbarch,
2355 gdbarch_print_float_info_ftype print_float_info)
2357 gdbarch->print_float_info = print_float_info;
2360 bool
2361 gdbarch_print_vector_info_p (struct gdbarch *gdbarch)
2363 gdb_assert (gdbarch != NULL);
2364 return gdbarch->print_vector_info != NULL;
2367 void
2368 gdbarch_print_vector_info (struct gdbarch *gdbarch, struct ui_file *file, frame_info_ptr frame, const char *args)
2370 gdb_assert (gdbarch != NULL);
2371 gdb_assert (gdbarch->print_vector_info != NULL);
2372 if (gdbarch_debug >= 2)
2373 gdb_printf (gdb_stdlog, "gdbarch_print_vector_info called\n");
2374 gdbarch->print_vector_info (gdbarch, file, frame, args);
2377 void
2378 set_gdbarch_print_vector_info (struct gdbarch *gdbarch,
2379 gdbarch_print_vector_info_ftype print_vector_info)
2381 gdbarch->print_vector_info = print_vector_info;
2385 gdbarch_register_sim_regno (struct gdbarch *gdbarch, int reg_nr)
2387 gdb_assert (gdbarch != NULL);
2388 gdb_assert (gdbarch->register_sim_regno != NULL);
2389 if (gdbarch_debug >= 2)
2390 gdb_printf (gdb_stdlog, "gdbarch_register_sim_regno called\n");
2391 return gdbarch->register_sim_regno (gdbarch, reg_nr);
2394 void
2395 set_gdbarch_register_sim_regno (struct gdbarch *gdbarch,
2396 gdbarch_register_sim_regno_ftype register_sim_regno)
2398 gdbarch->register_sim_regno = register_sim_regno;
2402 gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, int regnum)
2404 gdb_assert (gdbarch != NULL);
2405 gdb_assert (gdbarch->cannot_fetch_register != NULL);
2406 if (gdbarch_debug >= 2)
2407 gdb_printf (gdb_stdlog, "gdbarch_cannot_fetch_register called\n");
2408 return gdbarch->cannot_fetch_register (gdbarch, regnum);
2411 void
2412 set_gdbarch_cannot_fetch_register (struct gdbarch *gdbarch,
2413 gdbarch_cannot_fetch_register_ftype cannot_fetch_register)
2415 gdbarch->cannot_fetch_register = cannot_fetch_register;
2419 gdbarch_cannot_store_register (struct gdbarch *gdbarch, int regnum)
2421 gdb_assert (gdbarch != NULL);
2422 gdb_assert (gdbarch->cannot_store_register != NULL);
2423 if (gdbarch_debug >= 2)
2424 gdb_printf (gdb_stdlog, "gdbarch_cannot_store_register called\n");
2425 return gdbarch->cannot_store_register (gdbarch, regnum);
2428 void
2429 set_gdbarch_cannot_store_register (struct gdbarch *gdbarch,
2430 gdbarch_cannot_store_register_ftype cannot_store_register)
2432 gdbarch->cannot_store_register = cannot_store_register;
2435 bool
2436 gdbarch_get_longjmp_target_p (struct gdbarch *gdbarch)
2438 gdb_assert (gdbarch != NULL);
2439 return gdbarch->get_longjmp_target != NULL;
2443 gdbarch_get_longjmp_target (struct gdbarch *gdbarch, frame_info_ptr frame, CORE_ADDR *pc)
2445 gdb_assert (gdbarch != NULL);
2446 gdb_assert (gdbarch->get_longjmp_target != NULL);
2447 if (gdbarch_debug >= 2)
2448 gdb_printf (gdb_stdlog, "gdbarch_get_longjmp_target called\n");
2449 return gdbarch->get_longjmp_target (frame, pc);
2452 void
2453 set_gdbarch_get_longjmp_target (struct gdbarch *gdbarch,
2454 gdbarch_get_longjmp_target_ftype get_longjmp_target)
2456 gdbarch->get_longjmp_target = get_longjmp_target;
2460 gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch)
2462 gdb_assert (gdbarch != NULL);
2463 /* Skip verify of believe_pcc_promotion, invalid_p == 0 */
2464 if (gdbarch_debug >= 2)
2465 gdb_printf (gdb_stdlog, "gdbarch_believe_pcc_promotion called\n");
2466 return gdbarch->believe_pcc_promotion;
2469 void
2470 set_gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch,
2471 int believe_pcc_promotion)
2473 gdbarch->believe_pcc_promotion = believe_pcc_promotion;
2477 gdbarch_convert_register_p (struct gdbarch *gdbarch, int regnum, struct type *type)
2479 gdb_assert (gdbarch != NULL);
2480 gdb_assert (gdbarch->convert_register_p != NULL);
2481 if (gdbarch_debug >= 2)
2482 gdb_printf (gdb_stdlog, "gdbarch_convert_register_p called\n");
2483 return gdbarch->convert_register_p (gdbarch, regnum, type);
2486 void
2487 set_gdbarch_convert_register_p (struct gdbarch *gdbarch,
2488 gdbarch_convert_register_p_ftype convert_register_p)
2490 gdbarch->convert_register_p = convert_register_p;
2494 gdbarch_register_to_value (struct gdbarch *gdbarch, frame_info_ptr frame, int regnum, struct type *type, gdb_byte *buf, int *optimizedp, int *unavailablep)
2496 gdb_assert (gdbarch != NULL);
2497 gdb_assert (gdbarch->register_to_value != NULL);
2498 if (gdbarch_debug >= 2)
2499 gdb_printf (gdb_stdlog, "gdbarch_register_to_value called\n");
2500 return gdbarch->register_to_value (frame, regnum, type, buf, optimizedp, unavailablep);
2503 void
2504 set_gdbarch_register_to_value (struct gdbarch *gdbarch,
2505 gdbarch_register_to_value_ftype register_to_value)
2507 gdbarch->register_to_value = register_to_value;
2510 void
2511 gdbarch_value_to_register (struct gdbarch *gdbarch, frame_info_ptr frame, int regnum, struct type *type, const gdb_byte *buf)
2513 gdb_assert (gdbarch != NULL);
2514 gdb_assert (gdbarch->value_to_register != NULL);
2515 if (gdbarch_debug >= 2)
2516 gdb_printf (gdb_stdlog, "gdbarch_value_to_register called\n");
2517 gdbarch->value_to_register (frame, regnum, type, buf);
2520 void
2521 set_gdbarch_value_to_register (struct gdbarch *gdbarch,
2522 gdbarch_value_to_register_ftype value_to_register)
2524 gdbarch->value_to_register = value_to_register;
2527 struct value *
2528 gdbarch_value_from_register (struct gdbarch *gdbarch, struct type *type, int regnum, struct frame_id frame_id)
2530 gdb_assert (gdbarch != NULL);
2531 gdb_assert (gdbarch->value_from_register != NULL);
2532 if (gdbarch_debug >= 2)
2533 gdb_printf (gdb_stdlog, "gdbarch_value_from_register called\n");
2534 return gdbarch->value_from_register (gdbarch, type, regnum, frame_id);
2537 void
2538 set_gdbarch_value_from_register (struct gdbarch *gdbarch,
2539 gdbarch_value_from_register_ftype value_from_register)
2541 gdbarch->value_from_register = value_from_register;
2544 CORE_ADDR
2545 gdbarch_pointer_to_address (struct gdbarch *gdbarch, struct type *type, const gdb_byte *buf)
2547 gdb_assert (gdbarch != NULL);
2548 gdb_assert (gdbarch->pointer_to_address != NULL);
2549 if (gdbarch_debug >= 2)
2550 gdb_printf (gdb_stdlog, "gdbarch_pointer_to_address called\n");
2551 return gdbarch->pointer_to_address (gdbarch, type, buf);
2554 void
2555 set_gdbarch_pointer_to_address (struct gdbarch *gdbarch,
2556 gdbarch_pointer_to_address_ftype pointer_to_address)
2558 gdbarch->pointer_to_address = pointer_to_address;
2561 void
2562 gdbarch_address_to_pointer (struct gdbarch *gdbarch, struct type *type, gdb_byte *buf, CORE_ADDR addr)
2564 gdb_assert (gdbarch != NULL);
2565 gdb_assert (gdbarch->address_to_pointer != NULL);
2566 if (gdbarch_debug >= 2)
2567 gdb_printf (gdb_stdlog, "gdbarch_address_to_pointer called\n");
2568 gdbarch->address_to_pointer (gdbarch, type, buf, addr);
2571 void
2572 set_gdbarch_address_to_pointer (struct gdbarch *gdbarch,
2573 gdbarch_address_to_pointer_ftype address_to_pointer)
2575 gdbarch->address_to_pointer = address_to_pointer;
2578 bool
2579 gdbarch_integer_to_address_p (struct gdbarch *gdbarch)
2581 gdb_assert (gdbarch != NULL);
2582 return gdbarch->integer_to_address != NULL;
2585 CORE_ADDR
2586 gdbarch_integer_to_address (struct gdbarch *gdbarch, struct type *type, const gdb_byte *buf)
2588 gdb_assert (gdbarch != NULL);
2589 gdb_assert (gdbarch->integer_to_address != NULL);
2590 if (gdbarch_debug >= 2)
2591 gdb_printf (gdb_stdlog, "gdbarch_integer_to_address called\n");
2592 return gdbarch->integer_to_address (gdbarch, type, buf);
2595 void
2596 set_gdbarch_integer_to_address (struct gdbarch *gdbarch,
2597 gdbarch_integer_to_address_ftype integer_to_address)
2599 gdbarch->integer_to_address = integer_to_address;
2602 void
2603 set_gdbarch_return_value (struct gdbarch *gdbarch,
2604 gdbarch_return_value_ftype return_value)
2606 gdbarch->return_value = return_value;
2609 enum return_value_convention
2610 gdbarch_return_value_as_value (struct gdbarch *gdbarch, struct value *function, struct type *valtype, struct regcache *regcache, struct value **read_value, const gdb_byte *writebuf)
2612 gdb_assert (gdbarch != NULL);
2613 gdb_assert (gdbarch->return_value_as_value != NULL);
2614 if (gdbarch_debug >= 2)
2615 gdb_printf (gdb_stdlog, "gdbarch_return_value_as_value called\n");
2616 return gdbarch->return_value_as_value (gdbarch, function, valtype, regcache, read_value, writebuf);
2619 void
2620 set_gdbarch_return_value_as_value (struct gdbarch *gdbarch,
2621 gdbarch_return_value_as_value_ftype return_value_as_value)
2623 gdbarch->return_value_as_value = return_value_as_value;
2626 CORE_ADDR
2627 gdbarch_get_return_buf_addr (struct gdbarch *gdbarch, struct type *val_type, frame_info_ptr cur_frame)
2629 gdb_assert (gdbarch != NULL);
2630 gdb_assert (gdbarch->get_return_buf_addr != NULL);
2631 if (gdbarch_debug >= 2)
2632 gdb_printf (gdb_stdlog, "gdbarch_get_return_buf_addr called\n");
2633 return gdbarch->get_return_buf_addr (val_type, cur_frame);
2636 void
2637 set_gdbarch_get_return_buf_addr (struct gdbarch *gdbarch,
2638 gdbarch_get_return_buf_addr_ftype get_return_buf_addr)
2640 gdbarch->get_return_buf_addr = get_return_buf_addr;
2643 bool
2644 gdbarch_dwarf2_omit_typedef_p (struct gdbarch *gdbarch, struct type *target_type, const char *producer, const char *name)
2646 gdb_assert (gdbarch != NULL);
2647 gdb_assert (gdbarch->dwarf2_omit_typedef_p != NULL);
2648 if (gdbarch_debug >= 2)
2649 gdb_printf (gdb_stdlog, "gdbarch_dwarf2_omit_typedef_p called\n");
2650 return gdbarch->dwarf2_omit_typedef_p (target_type, producer, name);
2653 void
2654 set_gdbarch_dwarf2_omit_typedef_p (struct gdbarch *gdbarch,
2655 gdbarch_dwarf2_omit_typedef_p_ftype dwarf2_omit_typedef_p)
2657 gdbarch->dwarf2_omit_typedef_p = dwarf2_omit_typedef_p;
2660 CORE_ADDR
2661 gdbarch_update_call_site_pc (struct gdbarch *gdbarch, CORE_ADDR pc)
2663 gdb_assert (gdbarch != NULL);
2664 gdb_assert (gdbarch->update_call_site_pc != NULL);
2665 if (gdbarch_debug >= 2)
2666 gdb_printf (gdb_stdlog, "gdbarch_update_call_site_pc called\n");
2667 return gdbarch->update_call_site_pc (gdbarch, pc);
2670 void
2671 set_gdbarch_update_call_site_pc (struct gdbarch *gdbarch,
2672 gdbarch_update_call_site_pc_ftype update_call_site_pc)
2674 gdbarch->update_call_site_pc = update_call_site_pc;
2678 gdbarch_return_in_first_hidden_param_p (struct gdbarch *gdbarch, struct type *type)
2680 gdb_assert (gdbarch != NULL);
2681 gdb_assert (gdbarch->return_in_first_hidden_param_p != NULL);
2682 if (gdbarch_debug >= 2)
2683 gdb_printf (gdb_stdlog, "gdbarch_return_in_first_hidden_param_p called\n");
2684 return gdbarch->return_in_first_hidden_param_p (gdbarch, type);
2687 void
2688 set_gdbarch_return_in_first_hidden_param_p (struct gdbarch *gdbarch,
2689 gdbarch_return_in_first_hidden_param_p_ftype return_in_first_hidden_param_p)
2691 gdbarch->return_in_first_hidden_param_p = return_in_first_hidden_param_p;
2694 CORE_ADDR
2695 gdbarch_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR ip)
2697 gdb_assert (gdbarch != NULL);
2698 gdb_assert (gdbarch->skip_prologue != NULL);
2699 if (gdbarch_debug >= 2)
2700 gdb_printf (gdb_stdlog, "gdbarch_skip_prologue called\n");
2701 return gdbarch->skip_prologue (gdbarch, ip);
2704 void
2705 set_gdbarch_skip_prologue (struct gdbarch *gdbarch,
2706 gdbarch_skip_prologue_ftype skip_prologue)
2708 gdbarch->skip_prologue = skip_prologue;
2711 bool
2712 gdbarch_skip_main_prologue_p (struct gdbarch *gdbarch)
2714 gdb_assert (gdbarch != NULL);
2715 return gdbarch->skip_main_prologue != NULL;
2718 CORE_ADDR
2719 gdbarch_skip_main_prologue (struct gdbarch *gdbarch, CORE_ADDR ip)
2721 gdb_assert (gdbarch != NULL);
2722 gdb_assert (gdbarch->skip_main_prologue != NULL);
2723 if (gdbarch_debug >= 2)
2724 gdb_printf (gdb_stdlog, "gdbarch_skip_main_prologue called\n");
2725 return gdbarch->skip_main_prologue (gdbarch, ip);
2728 void
2729 set_gdbarch_skip_main_prologue (struct gdbarch *gdbarch,
2730 gdbarch_skip_main_prologue_ftype skip_main_prologue)
2732 gdbarch->skip_main_prologue = skip_main_prologue;
2735 bool
2736 gdbarch_skip_entrypoint_p (struct gdbarch *gdbarch)
2738 gdb_assert (gdbarch != NULL);
2739 return gdbarch->skip_entrypoint != NULL;
2742 CORE_ADDR
2743 gdbarch_skip_entrypoint (struct gdbarch *gdbarch, CORE_ADDR ip)
2745 gdb_assert (gdbarch != NULL);
2746 gdb_assert (gdbarch->skip_entrypoint != NULL);
2747 if (gdbarch_debug >= 2)
2748 gdb_printf (gdb_stdlog, "gdbarch_skip_entrypoint called\n");
2749 return gdbarch->skip_entrypoint (gdbarch, ip);
2752 void
2753 set_gdbarch_skip_entrypoint (struct gdbarch *gdbarch,
2754 gdbarch_skip_entrypoint_ftype skip_entrypoint)
2756 gdbarch->skip_entrypoint = skip_entrypoint;
2760 gdbarch_inner_than (struct gdbarch *gdbarch, CORE_ADDR lhs, CORE_ADDR rhs)
2762 gdb_assert (gdbarch != NULL);
2763 gdb_assert (gdbarch->inner_than != NULL);
2764 if (gdbarch_debug >= 2)
2765 gdb_printf (gdb_stdlog, "gdbarch_inner_than called\n");
2766 return gdbarch->inner_than (lhs, rhs);
2769 void
2770 set_gdbarch_inner_than (struct gdbarch *gdbarch,
2771 gdbarch_inner_than_ftype inner_than)
2773 gdbarch->inner_than = inner_than;
2776 const gdb_byte *
2777 gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr)
2779 gdb_assert (gdbarch != NULL);
2780 gdb_assert (gdbarch->breakpoint_from_pc != NULL);
2781 if (gdbarch_debug >= 2)
2782 gdb_printf (gdb_stdlog, "gdbarch_breakpoint_from_pc called\n");
2783 return gdbarch->breakpoint_from_pc (gdbarch, pcptr, lenptr);
2786 void
2787 set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch,
2788 gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc)
2790 gdbarch->breakpoint_from_pc = breakpoint_from_pc;
2794 gdbarch_breakpoint_kind_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr)
2796 gdb_assert (gdbarch != NULL);
2797 gdb_assert (gdbarch->breakpoint_kind_from_pc != NULL);
2798 if (gdbarch_debug >= 2)
2799 gdb_printf (gdb_stdlog, "gdbarch_breakpoint_kind_from_pc called\n");
2800 return gdbarch->breakpoint_kind_from_pc (gdbarch, pcptr);
2803 void
2804 set_gdbarch_breakpoint_kind_from_pc (struct gdbarch *gdbarch,
2805 gdbarch_breakpoint_kind_from_pc_ftype breakpoint_kind_from_pc)
2807 gdbarch->breakpoint_kind_from_pc = breakpoint_kind_from_pc;
2810 const gdb_byte *
2811 gdbarch_sw_breakpoint_from_kind (struct gdbarch *gdbarch, int kind, int *size)
2813 gdb_assert (gdbarch != NULL);
2814 gdb_assert (gdbarch->sw_breakpoint_from_kind != NULL);
2815 if (gdbarch_debug >= 2)
2816 gdb_printf (gdb_stdlog, "gdbarch_sw_breakpoint_from_kind called\n");
2817 return gdbarch->sw_breakpoint_from_kind (gdbarch, kind, size);
2820 void
2821 set_gdbarch_sw_breakpoint_from_kind (struct gdbarch *gdbarch,
2822 gdbarch_sw_breakpoint_from_kind_ftype sw_breakpoint_from_kind)
2824 gdbarch->sw_breakpoint_from_kind = sw_breakpoint_from_kind;
2828 gdbarch_breakpoint_kind_from_current_state (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR *pcptr)
2830 gdb_assert (gdbarch != NULL);
2831 gdb_assert (gdbarch->breakpoint_kind_from_current_state != NULL);
2832 if (gdbarch_debug >= 2)
2833 gdb_printf (gdb_stdlog, "gdbarch_breakpoint_kind_from_current_state called\n");
2834 return gdbarch->breakpoint_kind_from_current_state (gdbarch, regcache, pcptr);
2837 void
2838 set_gdbarch_breakpoint_kind_from_current_state (struct gdbarch *gdbarch,
2839 gdbarch_breakpoint_kind_from_current_state_ftype breakpoint_kind_from_current_state)
2841 gdbarch->breakpoint_kind_from_current_state = breakpoint_kind_from_current_state;
2844 bool
2845 gdbarch_adjust_breakpoint_address_p (struct gdbarch *gdbarch)
2847 gdb_assert (gdbarch != NULL);
2848 return gdbarch->adjust_breakpoint_address != NULL;
2851 CORE_ADDR
2852 gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch, CORE_ADDR bpaddr)
2854 gdb_assert (gdbarch != NULL);
2855 gdb_assert (gdbarch->adjust_breakpoint_address != NULL);
2856 if (gdbarch_debug >= 2)
2857 gdb_printf (gdb_stdlog, "gdbarch_adjust_breakpoint_address called\n");
2858 return gdbarch->adjust_breakpoint_address (gdbarch, bpaddr);
2861 void
2862 set_gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch,
2863 gdbarch_adjust_breakpoint_address_ftype adjust_breakpoint_address)
2865 gdbarch->adjust_breakpoint_address = adjust_breakpoint_address;
2869 gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt)
2871 gdb_assert (gdbarch != NULL);
2872 gdb_assert (gdbarch->memory_insert_breakpoint != NULL);
2873 if (gdbarch_debug >= 2)
2874 gdb_printf (gdb_stdlog, "gdbarch_memory_insert_breakpoint called\n");
2875 return gdbarch->memory_insert_breakpoint (gdbarch, bp_tgt);
2878 void
2879 set_gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch,
2880 gdbarch_memory_insert_breakpoint_ftype memory_insert_breakpoint)
2882 gdbarch->memory_insert_breakpoint = memory_insert_breakpoint;
2886 gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt)
2888 gdb_assert (gdbarch != NULL);
2889 gdb_assert (gdbarch->memory_remove_breakpoint != NULL);
2890 if (gdbarch_debug >= 2)
2891 gdb_printf (gdb_stdlog, "gdbarch_memory_remove_breakpoint called\n");
2892 return gdbarch->memory_remove_breakpoint (gdbarch, bp_tgt);
2895 void
2896 set_gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch,
2897 gdbarch_memory_remove_breakpoint_ftype memory_remove_breakpoint)
2899 gdbarch->memory_remove_breakpoint = memory_remove_breakpoint;
2902 CORE_ADDR
2903 gdbarch_decr_pc_after_break (struct gdbarch *gdbarch)
2905 gdb_assert (gdbarch != NULL);
2906 /* Skip verify of decr_pc_after_break, invalid_p == 0 */
2907 if (gdbarch_debug >= 2)
2908 gdb_printf (gdb_stdlog, "gdbarch_decr_pc_after_break called\n");
2909 return gdbarch->decr_pc_after_break;
2912 void
2913 set_gdbarch_decr_pc_after_break (struct gdbarch *gdbarch,
2914 CORE_ADDR decr_pc_after_break)
2916 gdbarch->decr_pc_after_break = decr_pc_after_break;
2919 CORE_ADDR
2920 gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarch)
2922 gdb_assert (gdbarch != NULL);
2923 /* Skip verify of deprecated_function_start_offset, invalid_p == 0 */
2924 if (gdbarch_debug >= 2)
2925 gdb_printf (gdb_stdlog, "gdbarch_deprecated_function_start_offset called\n");
2926 return gdbarch->deprecated_function_start_offset;
2929 void
2930 set_gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarch,
2931 CORE_ADDR deprecated_function_start_offset)
2933 gdbarch->deprecated_function_start_offset = deprecated_function_start_offset;
2937 gdbarch_remote_register_number (struct gdbarch *gdbarch, int regno)
2939 gdb_assert (gdbarch != NULL);
2940 gdb_assert (gdbarch->remote_register_number != NULL);
2941 if (gdbarch_debug >= 2)
2942 gdb_printf (gdb_stdlog, "gdbarch_remote_register_number called\n");
2943 return gdbarch->remote_register_number (gdbarch, regno);
2946 void
2947 set_gdbarch_remote_register_number (struct gdbarch *gdbarch,
2948 gdbarch_remote_register_number_ftype remote_register_number)
2950 gdbarch->remote_register_number = remote_register_number;
2953 bool
2954 gdbarch_fetch_tls_load_module_address_p (struct gdbarch *gdbarch)
2956 gdb_assert (gdbarch != NULL);
2957 return gdbarch->fetch_tls_load_module_address != NULL;
2960 CORE_ADDR
2961 gdbarch_fetch_tls_load_module_address (struct gdbarch *gdbarch, struct objfile *objfile)
2963 gdb_assert (gdbarch != NULL);
2964 gdb_assert (gdbarch->fetch_tls_load_module_address != NULL);
2965 if (gdbarch_debug >= 2)
2966 gdb_printf (gdb_stdlog, "gdbarch_fetch_tls_load_module_address called\n");
2967 return gdbarch->fetch_tls_load_module_address (objfile);
2970 void
2971 set_gdbarch_fetch_tls_load_module_address (struct gdbarch *gdbarch,
2972 gdbarch_fetch_tls_load_module_address_ftype fetch_tls_load_module_address)
2974 gdbarch->fetch_tls_load_module_address = fetch_tls_load_module_address;
2977 bool
2978 gdbarch_get_thread_local_address_p (struct gdbarch *gdbarch)
2980 gdb_assert (gdbarch != NULL);
2981 return gdbarch->get_thread_local_address != NULL;
2984 CORE_ADDR
2985 gdbarch_get_thread_local_address (struct gdbarch *gdbarch, ptid_t ptid, CORE_ADDR lm_addr, CORE_ADDR offset)
2987 gdb_assert (gdbarch != NULL);
2988 gdb_assert (gdbarch->get_thread_local_address != NULL);
2989 if (gdbarch_debug >= 2)
2990 gdb_printf (gdb_stdlog, "gdbarch_get_thread_local_address called\n");
2991 return gdbarch->get_thread_local_address (gdbarch, ptid, lm_addr, offset);
2994 void
2995 set_gdbarch_get_thread_local_address (struct gdbarch *gdbarch,
2996 gdbarch_get_thread_local_address_ftype get_thread_local_address)
2998 gdbarch->get_thread_local_address = get_thread_local_address;
3001 CORE_ADDR
3002 gdbarch_frame_args_skip (struct gdbarch *gdbarch)
3004 gdb_assert (gdbarch != NULL);
3005 /* Skip verify of frame_args_skip, invalid_p == 0 */
3006 if (gdbarch_debug >= 2)
3007 gdb_printf (gdb_stdlog, "gdbarch_frame_args_skip called\n");
3008 return gdbarch->frame_args_skip;
3011 void
3012 set_gdbarch_frame_args_skip (struct gdbarch *gdbarch,
3013 CORE_ADDR frame_args_skip)
3015 gdbarch->frame_args_skip = frame_args_skip;
3018 CORE_ADDR
3019 gdbarch_unwind_pc (struct gdbarch *gdbarch, frame_info_ptr next_frame)
3021 gdb_assert (gdbarch != NULL);
3022 gdb_assert (gdbarch->unwind_pc != NULL);
3023 if (gdbarch_debug >= 2)
3024 gdb_printf (gdb_stdlog, "gdbarch_unwind_pc called\n");
3025 return gdbarch->unwind_pc (gdbarch, next_frame);
3028 void
3029 set_gdbarch_unwind_pc (struct gdbarch *gdbarch,
3030 gdbarch_unwind_pc_ftype unwind_pc)
3032 gdbarch->unwind_pc = unwind_pc;
3035 CORE_ADDR
3036 gdbarch_unwind_sp (struct gdbarch *gdbarch, frame_info_ptr next_frame)
3038 gdb_assert (gdbarch != NULL);
3039 gdb_assert (gdbarch->unwind_sp != NULL);
3040 if (gdbarch_debug >= 2)
3041 gdb_printf (gdb_stdlog, "gdbarch_unwind_sp called\n");
3042 return gdbarch->unwind_sp (gdbarch, next_frame);
3045 void
3046 set_gdbarch_unwind_sp (struct gdbarch *gdbarch,
3047 gdbarch_unwind_sp_ftype unwind_sp)
3049 gdbarch->unwind_sp = unwind_sp;
3052 bool
3053 gdbarch_frame_num_args_p (struct gdbarch *gdbarch)
3055 gdb_assert (gdbarch != NULL);
3056 return gdbarch->frame_num_args != NULL;
3060 gdbarch_frame_num_args (struct gdbarch *gdbarch, frame_info_ptr frame)
3062 gdb_assert (gdbarch != NULL);
3063 gdb_assert (gdbarch->frame_num_args != NULL);
3064 if (gdbarch_debug >= 2)
3065 gdb_printf (gdb_stdlog, "gdbarch_frame_num_args called\n");
3066 return gdbarch->frame_num_args (frame);
3069 void
3070 set_gdbarch_frame_num_args (struct gdbarch *gdbarch,
3071 gdbarch_frame_num_args_ftype frame_num_args)
3073 gdbarch->frame_num_args = frame_num_args;
3076 bool
3077 gdbarch_frame_align_p (struct gdbarch *gdbarch)
3079 gdb_assert (gdbarch != NULL);
3080 return gdbarch->frame_align != NULL;
3083 CORE_ADDR
3084 gdbarch_frame_align (struct gdbarch *gdbarch, CORE_ADDR address)
3086 gdb_assert (gdbarch != NULL);
3087 gdb_assert (gdbarch->frame_align != NULL);
3088 if (gdbarch_debug >= 2)
3089 gdb_printf (gdb_stdlog, "gdbarch_frame_align called\n");
3090 return gdbarch->frame_align (gdbarch, address);
3093 void
3094 set_gdbarch_frame_align (struct gdbarch *gdbarch,
3095 gdbarch_frame_align_ftype frame_align)
3097 gdbarch->frame_align = frame_align;
3101 gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch, struct type *type)
3103 gdb_assert (gdbarch != NULL);
3104 gdb_assert (gdbarch->stabs_argument_has_addr != NULL);
3105 if (gdbarch_debug >= 2)
3106 gdb_printf (gdb_stdlog, "gdbarch_stabs_argument_has_addr called\n");
3107 return gdbarch->stabs_argument_has_addr (gdbarch, type);
3110 void
3111 set_gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch,
3112 gdbarch_stabs_argument_has_addr_ftype stabs_argument_has_addr)
3114 gdbarch->stabs_argument_has_addr = stabs_argument_has_addr;
3118 gdbarch_frame_red_zone_size (struct gdbarch *gdbarch)
3120 gdb_assert (gdbarch != NULL);
3121 /* Skip verify of frame_red_zone_size, invalid_p == 0 */
3122 if (gdbarch_debug >= 2)
3123 gdb_printf (gdb_stdlog, "gdbarch_frame_red_zone_size called\n");
3124 return gdbarch->frame_red_zone_size;
3127 void
3128 set_gdbarch_frame_red_zone_size (struct gdbarch *gdbarch,
3129 int frame_red_zone_size)
3131 gdbarch->frame_red_zone_size = frame_red_zone_size;
3134 CORE_ADDR
3135 gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, CORE_ADDR addr, struct target_ops *targ)
3137 gdb_assert (gdbarch != NULL);
3138 gdb_assert (gdbarch->convert_from_func_ptr_addr != NULL);
3139 if (gdbarch_debug >= 2)
3140 gdb_printf (gdb_stdlog, "gdbarch_convert_from_func_ptr_addr called\n");
3141 return gdbarch->convert_from_func_ptr_addr (gdbarch, addr, targ);
3144 void
3145 set_gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch,
3146 gdbarch_convert_from_func_ptr_addr_ftype convert_from_func_ptr_addr)
3148 gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr;
3151 CORE_ADDR
3152 gdbarch_addr_bits_remove (struct gdbarch *gdbarch, CORE_ADDR addr)
3154 gdb_assert (gdbarch != NULL);
3155 gdb_assert (gdbarch->addr_bits_remove != NULL);
3156 if (gdbarch_debug >= 2)
3157 gdb_printf (gdb_stdlog, "gdbarch_addr_bits_remove called\n");
3158 return gdbarch->addr_bits_remove (gdbarch, addr);
3161 void
3162 set_gdbarch_addr_bits_remove (struct gdbarch *gdbarch,
3163 gdbarch_addr_bits_remove_ftype addr_bits_remove)
3165 gdbarch->addr_bits_remove = addr_bits_remove;
3168 CORE_ADDR
3169 gdbarch_remove_non_address_bits (struct gdbarch *gdbarch, CORE_ADDR pointer)
3171 gdb_assert (gdbarch != NULL);
3172 gdb_assert (gdbarch->remove_non_address_bits != NULL);
3173 if (gdbarch_debug >= 2)
3174 gdb_printf (gdb_stdlog, "gdbarch_remove_non_address_bits called\n");
3175 return gdbarch->remove_non_address_bits (gdbarch, pointer);
3178 void
3179 set_gdbarch_remove_non_address_bits (struct gdbarch *gdbarch,
3180 gdbarch_remove_non_address_bits_ftype remove_non_address_bits)
3182 gdbarch->remove_non_address_bits = remove_non_address_bits;
3185 std::string
3186 gdbarch_memtag_to_string (struct gdbarch *gdbarch, struct value *tag)
3188 gdb_assert (gdbarch != NULL);
3189 gdb_assert (gdbarch->memtag_to_string != NULL);
3190 if (gdbarch_debug >= 2)
3191 gdb_printf (gdb_stdlog, "gdbarch_memtag_to_string called\n");
3192 return gdbarch->memtag_to_string (gdbarch, tag);
3195 void
3196 set_gdbarch_memtag_to_string (struct gdbarch *gdbarch,
3197 gdbarch_memtag_to_string_ftype memtag_to_string)
3199 gdbarch->memtag_to_string = memtag_to_string;
3202 bool
3203 gdbarch_tagged_address_p (struct gdbarch *gdbarch, struct value *address)
3205 gdb_assert (gdbarch != NULL);
3206 gdb_assert (gdbarch->tagged_address_p != NULL);
3207 if (gdbarch_debug >= 2)
3208 gdb_printf (gdb_stdlog, "gdbarch_tagged_address_p called\n");
3209 return gdbarch->tagged_address_p (gdbarch, address);
3212 void
3213 set_gdbarch_tagged_address_p (struct gdbarch *gdbarch,
3214 gdbarch_tagged_address_p_ftype tagged_address_p)
3216 gdbarch->tagged_address_p = tagged_address_p;
3219 bool
3220 gdbarch_memtag_matches_p (struct gdbarch *gdbarch, struct value *address)
3222 gdb_assert (gdbarch != NULL);
3223 gdb_assert (gdbarch->memtag_matches_p != NULL);
3224 if (gdbarch_debug >= 2)
3225 gdb_printf (gdb_stdlog, "gdbarch_memtag_matches_p called\n");
3226 return gdbarch->memtag_matches_p (gdbarch, address);
3229 void
3230 set_gdbarch_memtag_matches_p (struct gdbarch *gdbarch,
3231 gdbarch_memtag_matches_p_ftype memtag_matches_p)
3233 gdbarch->memtag_matches_p = memtag_matches_p;
3236 bool
3237 gdbarch_set_memtags (struct gdbarch *gdbarch, struct value *address, size_t length, const gdb::byte_vector &tags, memtag_type tag_type)
3239 gdb_assert (gdbarch != NULL);
3240 gdb_assert (gdbarch->set_memtags != NULL);
3241 if (gdbarch_debug >= 2)
3242 gdb_printf (gdb_stdlog, "gdbarch_set_memtags called\n");
3243 return gdbarch->set_memtags (gdbarch, address, length, tags, tag_type);
3246 void
3247 set_gdbarch_set_memtags (struct gdbarch *gdbarch,
3248 gdbarch_set_memtags_ftype set_memtags)
3250 gdbarch->set_memtags = set_memtags;
3253 struct value *
3254 gdbarch_get_memtag (struct gdbarch *gdbarch, struct value *address, memtag_type tag_type)
3256 gdb_assert (gdbarch != NULL);
3257 gdb_assert (gdbarch->get_memtag != NULL);
3258 if (gdbarch_debug >= 2)
3259 gdb_printf (gdb_stdlog, "gdbarch_get_memtag called\n");
3260 return gdbarch->get_memtag (gdbarch, address, tag_type);
3263 void
3264 set_gdbarch_get_memtag (struct gdbarch *gdbarch,
3265 gdbarch_get_memtag_ftype get_memtag)
3267 gdbarch->get_memtag = get_memtag;
3270 CORE_ADDR
3271 gdbarch_memtag_granule_size (struct gdbarch *gdbarch)
3273 gdb_assert (gdbarch != NULL);
3274 /* Skip verify of memtag_granule_size, invalid_p == 0 */
3275 if (gdbarch_debug >= 2)
3276 gdb_printf (gdb_stdlog, "gdbarch_memtag_granule_size called\n");
3277 return gdbarch->memtag_granule_size;
3280 void
3281 set_gdbarch_memtag_granule_size (struct gdbarch *gdbarch,
3282 CORE_ADDR memtag_granule_size)
3284 gdbarch->memtag_granule_size = memtag_granule_size;
3287 bool
3288 gdbarch_software_single_step_p (struct gdbarch *gdbarch)
3290 gdb_assert (gdbarch != NULL);
3291 return gdbarch->software_single_step != NULL;
3294 std::vector<CORE_ADDR>
3295 gdbarch_software_single_step (struct gdbarch *gdbarch, struct regcache *regcache)
3297 gdb_assert (gdbarch != NULL);
3298 gdb_assert (gdbarch->software_single_step != NULL);
3299 if (gdbarch_debug >= 2)
3300 gdb_printf (gdb_stdlog, "gdbarch_software_single_step called\n");
3301 return gdbarch->software_single_step (regcache);
3304 void
3305 set_gdbarch_software_single_step (struct gdbarch *gdbarch,
3306 gdbarch_software_single_step_ftype software_single_step)
3308 gdbarch->software_single_step = software_single_step;
3311 bool
3312 gdbarch_single_step_through_delay_p (struct gdbarch *gdbarch)
3314 gdb_assert (gdbarch != NULL);
3315 return gdbarch->single_step_through_delay != NULL;
3319 gdbarch_single_step_through_delay (struct gdbarch *gdbarch, frame_info_ptr frame)
3321 gdb_assert (gdbarch != NULL);
3322 gdb_assert (gdbarch->single_step_through_delay != NULL);
3323 if (gdbarch_debug >= 2)
3324 gdb_printf (gdb_stdlog, "gdbarch_single_step_through_delay called\n");
3325 return gdbarch->single_step_through_delay (gdbarch, frame);
3328 void
3329 set_gdbarch_single_step_through_delay (struct gdbarch *gdbarch,
3330 gdbarch_single_step_through_delay_ftype single_step_through_delay)
3332 gdbarch->single_step_through_delay = single_step_through_delay;
3336 gdbarch_print_insn (struct gdbarch *gdbarch, bfd_vma vma, struct disassemble_info *info)
3338 gdb_assert (gdbarch != NULL);
3339 gdb_assert (gdbarch->print_insn != NULL);
3340 if (gdbarch_debug >= 2)
3341 gdb_printf (gdb_stdlog, "gdbarch_print_insn called\n");
3342 return gdbarch->print_insn (vma, info);
3345 void
3346 set_gdbarch_print_insn (struct gdbarch *gdbarch,
3347 gdbarch_print_insn_ftype print_insn)
3349 gdbarch->print_insn = print_insn;
3352 CORE_ADDR
3353 gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, frame_info_ptr frame, CORE_ADDR pc)
3355 gdb_assert (gdbarch != NULL);
3356 gdb_assert (gdbarch->skip_trampoline_code != NULL);
3357 if (gdbarch_debug >= 2)
3358 gdb_printf (gdb_stdlog, "gdbarch_skip_trampoline_code called\n");
3359 return gdbarch->skip_trampoline_code (frame, pc);
3362 void
3363 set_gdbarch_skip_trampoline_code (struct gdbarch *gdbarch,
3364 gdbarch_skip_trampoline_code_ftype skip_trampoline_code)
3366 gdbarch->skip_trampoline_code = skip_trampoline_code;
3369 const struct target_so_ops *
3370 gdbarch_so_ops (struct gdbarch *gdbarch)
3372 gdb_assert (gdbarch != NULL);
3373 /* Skip verify of so_ops, invalid_p == 0 */
3374 if (gdbarch_debug >= 2)
3375 gdb_printf (gdb_stdlog, "gdbarch_so_ops called\n");
3376 return gdbarch->so_ops;
3379 void
3380 set_gdbarch_so_ops (struct gdbarch *gdbarch,
3381 const struct target_so_ops * so_ops)
3383 gdbarch->so_ops = so_ops;
3386 CORE_ADDR
3387 gdbarch_skip_solib_resolver (struct gdbarch *gdbarch, CORE_ADDR pc)
3389 gdb_assert (gdbarch != NULL);
3390 gdb_assert (gdbarch->skip_solib_resolver != NULL);
3391 if (gdbarch_debug >= 2)
3392 gdb_printf (gdb_stdlog, "gdbarch_skip_solib_resolver called\n");
3393 return gdbarch->skip_solib_resolver (gdbarch, pc);
3396 void
3397 set_gdbarch_skip_solib_resolver (struct gdbarch *gdbarch,
3398 gdbarch_skip_solib_resolver_ftype skip_solib_resolver)
3400 gdbarch->skip_solib_resolver = skip_solib_resolver;
3404 gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, const char *name)
3406 gdb_assert (gdbarch != NULL);
3407 gdb_assert (gdbarch->in_solib_return_trampoline != NULL);
3408 if (gdbarch_debug >= 2)
3409 gdb_printf (gdb_stdlog, "gdbarch_in_solib_return_trampoline called\n");
3410 return gdbarch->in_solib_return_trampoline (gdbarch, pc, name);
3413 void
3414 set_gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch,
3415 gdbarch_in_solib_return_trampoline_ftype in_solib_return_trampoline)
3417 gdbarch->in_solib_return_trampoline = in_solib_return_trampoline;
3420 bool
3421 gdbarch_in_indirect_branch_thunk (struct gdbarch *gdbarch, CORE_ADDR pc)
3423 gdb_assert (gdbarch != NULL);
3424 gdb_assert (gdbarch->in_indirect_branch_thunk != NULL);
3425 if (gdbarch_debug >= 2)
3426 gdb_printf (gdb_stdlog, "gdbarch_in_indirect_branch_thunk called\n");
3427 return gdbarch->in_indirect_branch_thunk (gdbarch, pc);
3430 void
3431 set_gdbarch_in_indirect_branch_thunk (struct gdbarch *gdbarch,
3432 gdbarch_in_indirect_branch_thunk_ftype in_indirect_branch_thunk)
3434 gdbarch->in_indirect_branch_thunk = in_indirect_branch_thunk;
3438 gdbarch_stack_frame_destroyed_p (struct gdbarch *gdbarch, CORE_ADDR addr)
3440 gdb_assert (gdbarch != NULL);
3441 gdb_assert (gdbarch->stack_frame_destroyed_p != NULL);
3442 if (gdbarch_debug >= 2)
3443 gdb_printf (gdb_stdlog, "gdbarch_stack_frame_destroyed_p called\n");
3444 return gdbarch->stack_frame_destroyed_p (gdbarch, addr);
3447 void
3448 set_gdbarch_stack_frame_destroyed_p (struct gdbarch *gdbarch,
3449 gdbarch_stack_frame_destroyed_p_ftype stack_frame_destroyed_p)
3451 gdbarch->stack_frame_destroyed_p = stack_frame_destroyed_p;
3454 bool
3455 gdbarch_elf_make_msymbol_special_p (struct gdbarch *gdbarch)
3457 gdb_assert (gdbarch != NULL);
3458 return gdbarch->elf_make_msymbol_special != NULL;
3461 void
3462 gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, asymbol *sym, struct minimal_symbol *msym)
3464 gdb_assert (gdbarch != NULL);
3465 gdb_assert (gdbarch->elf_make_msymbol_special != NULL);
3466 if (gdbarch_debug >= 2)
3467 gdb_printf (gdb_stdlog, "gdbarch_elf_make_msymbol_special called\n");
3468 gdbarch->elf_make_msymbol_special (sym, msym);
3471 void
3472 set_gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch,
3473 gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special)
3475 gdbarch->elf_make_msymbol_special = elf_make_msymbol_special;
3478 void
3479 gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, int val, struct minimal_symbol *msym)
3481 gdb_assert (gdbarch != NULL);
3482 gdb_assert (gdbarch->coff_make_msymbol_special != NULL);
3483 if (gdbarch_debug >= 2)
3484 gdb_printf (gdb_stdlog, "gdbarch_coff_make_msymbol_special called\n");
3485 gdbarch->coff_make_msymbol_special (val, msym);
3488 void
3489 set_gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch,
3490 gdbarch_coff_make_msymbol_special_ftype coff_make_msymbol_special)
3492 gdbarch->coff_make_msymbol_special = coff_make_msymbol_special;
3495 void
3496 gdbarch_make_symbol_special (struct gdbarch *gdbarch, struct symbol *sym, struct objfile *objfile)
3498 gdb_assert (gdbarch != NULL);
3499 gdb_assert (gdbarch->make_symbol_special != NULL);
3500 if (gdbarch_debug >= 2)
3501 gdb_printf (gdb_stdlog, "gdbarch_make_symbol_special called\n");
3502 gdbarch->make_symbol_special (sym, objfile);
3505 void
3506 set_gdbarch_make_symbol_special (struct gdbarch *gdbarch,
3507 gdbarch_make_symbol_special_ftype make_symbol_special)
3509 gdbarch->make_symbol_special = make_symbol_special;
3512 CORE_ADDR
3513 gdbarch_adjust_dwarf2_addr (struct gdbarch *gdbarch, CORE_ADDR pc)
3515 gdb_assert (gdbarch != NULL);
3516 gdb_assert (gdbarch->adjust_dwarf2_addr != NULL);
3517 if (gdbarch_debug >= 2)
3518 gdb_printf (gdb_stdlog, "gdbarch_adjust_dwarf2_addr called\n");
3519 return gdbarch->adjust_dwarf2_addr (pc);
3522 void
3523 set_gdbarch_adjust_dwarf2_addr (struct gdbarch *gdbarch,
3524 gdbarch_adjust_dwarf2_addr_ftype adjust_dwarf2_addr)
3526 gdbarch->adjust_dwarf2_addr = adjust_dwarf2_addr;
3529 CORE_ADDR
3530 gdbarch_adjust_dwarf2_line (struct gdbarch *gdbarch, CORE_ADDR addr, int rel)
3532 gdb_assert (gdbarch != NULL);
3533 gdb_assert (gdbarch->adjust_dwarf2_line != NULL);
3534 if (gdbarch_debug >= 2)
3535 gdb_printf (gdb_stdlog, "gdbarch_adjust_dwarf2_line called\n");
3536 return gdbarch->adjust_dwarf2_line (addr, rel);
3539 void
3540 set_gdbarch_adjust_dwarf2_line (struct gdbarch *gdbarch,
3541 gdbarch_adjust_dwarf2_line_ftype adjust_dwarf2_line)
3543 gdbarch->adjust_dwarf2_line = adjust_dwarf2_line;
3547 gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch)
3549 gdb_assert (gdbarch != NULL);
3550 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
3551 if (gdbarch_debug >= 2)
3552 gdb_printf (gdb_stdlog, "gdbarch_cannot_step_breakpoint called\n");
3553 return gdbarch->cannot_step_breakpoint;
3556 void
3557 set_gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch,
3558 int cannot_step_breakpoint)
3560 gdbarch->cannot_step_breakpoint = cannot_step_breakpoint;
3564 gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch)
3566 gdb_assert (gdbarch != NULL);
3567 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
3568 if (gdbarch_debug >= 2)
3569 gdb_printf (gdb_stdlog, "gdbarch_have_nonsteppable_watchpoint called\n");
3570 return gdbarch->have_nonsteppable_watchpoint;
3573 void
3574 set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch,
3575 int have_nonsteppable_watchpoint)
3577 gdbarch->have_nonsteppable_watchpoint = have_nonsteppable_watchpoint;
3580 bool
3581 gdbarch_address_class_type_flags_p (struct gdbarch *gdbarch)
3583 gdb_assert (gdbarch != NULL);
3584 return gdbarch->address_class_type_flags != NULL;
3587 type_instance_flags
3588 gdbarch_address_class_type_flags (struct gdbarch *gdbarch, int byte_size, int dwarf2_addr_class)
3590 gdb_assert (gdbarch != NULL);
3591 gdb_assert (gdbarch->address_class_type_flags != NULL);
3592 if (gdbarch_debug >= 2)
3593 gdb_printf (gdb_stdlog, "gdbarch_address_class_type_flags called\n");
3594 return gdbarch->address_class_type_flags (byte_size, dwarf2_addr_class);
3597 void
3598 set_gdbarch_address_class_type_flags (struct gdbarch *gdbarch,
3599 gdbarch_address_class_type_flags_ftype address_class_type_flags)
3601 gdbarch->address_class_type_flags = address_class_type_flags;
3604 bool
3605 gdbarch_address_class_type_flags_to_name_p (struct gdbarch *gdbarch)
3607 gdb_assert (gdbarch != NULL);
3608 return gdbarch->address_class_type_flags_to_name != NULL;
3611 const char *
3612 gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, type_instance_flags type_flags)
3614 gdb_assert (gdbarch != NULL);
3615 gdb_assert (gdbarch->address_class_type_flags_to_name != NULL);
3616 if (gdbarch_debug >= 2)
3617 gdb_printf (gdb_stdlog, "gdbarch_address_class_type_flags_to_name called\n");
3618 return gdbarch->address_class_type_flags_to_name (gdbarch, type_flags);
3621 void
3622 set_gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch,
3623 gdbarch_address_class_type_flags_to_name_ftype address_class_type_flags_to_name)
3625 gdbarch->address_class_type_flags_to_name = address_class_type_flags_to_name;
3628 bool
3629 gdbarch_execute_dwarf_cfa_vendor_op (struct gdbarch *gdbarch, gdb_byte op, struct dwarf2_frame_state *fs)
3631 gdb_assert (gdbarch != NULL);
3632 gdb_assert (gdbarch->execute_dwarf_cfa_vendor_op != NULL);
3633 if (gdbarch_debug >= 2)
3634 gdb_printf (gdb_stdlog, "gdbarch_execute_dwarf_cfa_vendor_op called\n");
3635 return gdbarch->execute_dwarf_cfa_vendor_op (gdbarch, op, fs);
3638 void
3639 set_gdbarch_execute_dwarf_cfa_vendor_op (struct gdbarch *gdbarch,
3640 gdbarch_execute_dwarf_cfa_vendor_op_ftype execute_dwarf_cfa_vendor_op)
3642 gdbarch->execute_dwarf_cfa_vendor_op = execute_dwarf_cfa_vendor_op;
3645 bool
3646 gdbarch_address_class_name_to_type_flags_p (struct gdbarch *gdbarch)
3648 gdb_assert (gdbarch != NULL);
3649 return gdbarch->address_class_name_to_type_flags != NULL;
3652 bool
3653 gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, const char *name, type_instance_flags *type_flags_ptr)
3655 gdb_assert (gdbarch != NULL);
3656 gdb_assert (gdbarch->address_class_name_to_type_flags != NULL);
3657 if (gdbarch_debug >= 2)
3658 gdb_printf (gdb_stdlog, "gdbarch_address_class_name_to_type_flags called\n");
3659 return gdbarch->address_class_name_to_type_flags (gdbarch, name, type_flags_ptr);
3662 void
3663 set_gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch,
3664 gdbarch_address_class_name_to_type_flags_ftype address_class_name_to_type_flags)
3666 gdbarch->address_class_name_to_type_flags = address_class_name_to_type_flags;
3670 gdbarch_register_reggroup_p (struct gdbarch *gdbarch, int regnum, const struct reggroup *reggroup)
3672 gdb_assert (gdbarch != NULL);
3673 gdb_assert (gdbarch->register_reggroup_p != NULL);
3674 if (gdbarch_debug >= 2)
3675 gdb_printf (gdb_stdlog, "gdbarch_register_reggroup_p called\n");
3676 return gdbarch->register_reggroup_p (gdbarch, regnum, reggroup);
3679 void
3680 set_gdbarch_register_reggroup_p (struct gdbarch *gdbarch,
3681 gdbarch_register_reggroup_p_ftype register_reggroup_p)
3683 gdbarch->register_reggroup_p = register_reggroup_p;
3686 bool
3687 gdbarch_fetch_pointer_argument_p (struct gdbarch *gdbarch)
3689 gdb_assert (gdbarch != NULL);
3690 return gdbarch->fetch_pointer_argument != NULL;
3693 CORE_ADDR
3694 gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch, frame_info_ptr frame, int argi, struct type *type)
3696 gdb_assert (gdbarch != NULL);
3697 gdb_assert (gdbarch->fetch_pointer_argument != NULL);
3698 if (gdbarch_debug >= 2)
3699 gdb_printf (gdb_stdlog, "gdbarch_fetch_pointer_argument called\n");
3700 return gdbarch->fetch_pointer_argument (frame, argi, type);
3703 void
3704 set_gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch,
3705 gdbarch_fetch_pointer_argument_ftype fetch_pointer_argument)
3707 gdbarch->fetch_pointer_argument = fetch_pointer_argument;
3710 bool
3711 gdbarch_iterate_over_regset_sections_p (struct gdbarch *gdbarch)
3713 gdb_assert (gdbarch != NULL);
3714 return gdbarch->iterate_over_regset_sections != NULL;
3717 void
3718 gdbarch_iterate_over_regset_sections (struct gdbarch *gdbarch, iterate_over_regset_sections_cb *cb, void *cb_data, const struct regcache *regcache)
3720 gdb_assert (gdbarch != NULL);
3721 gdb_assert (gdbarch->iterate_over_regset_sections != NULL);
3722 if (gdbarch_debug >= 2)
3723 gdb_printf (gdb_stdlog, "gdbarch_iterate_over_regset_sections called\n");
3724 gdbarch->iterate_over_regset_sections (gdbarch, cb, cb_data, regcache);
3727 void
3728 set_gdbarch_iterate_over_regset_sections (struct gdbarch *gdbarch,
3729 gdbarch_iterate_over_regset_sections_ftype iterate_over_regset_sections)
3731 gdbarch->iterate_over_regset_sections = iterate_over_regset_sections;
3734 bool
3735 gdbarch_make_corefile_notes_p (struct gdbarch *gdbarch)
3737 gdb_assert (gdbarch != NULL);
3738 return gdbarch->make_corefile_notes != NULL;
3741 gdb::unique_xmalloc_ptr<char>
3742 gdbarch_make_corefile_notes (struct gdbarch *gdbarch, bfd *obfd, int *note_size)
3744 gdb_assert (gdbarch != NULL);
3745 gdb_assert (gdbarch->make_corefile_notes != NULL);
3746 if (gdbarch_debug >= 2)
3747 gdb_printf (gdb_stdlog, "gdbarch_make_corefile_notes called\n");
3748 return gdbarch->make_corefile_notes (gdbarch, obfd, note_size);
3751 void
3752 set_gdbarch_make_corefile_notes (struct gdbarch *gdbarch,
3753 gdbarch_make_corefile_notes_ftype make_corefile_notes)
3755 gdbarch->make_corefile_notes = make_corefile_notes;
3758 bool
3759 gdbarch_find_memory_regions_p (struct gdbarch *gdbarch)
3761 gdb_assert (gdbarch != NULL);
3762 return gdbarch->find_memory_regions != NULL;
3766 gdbarch_find_memory_regions (struct gdbarch *gdbarch, find_memory_region_ftype func, void *data)
3768 gdb_assert (gdbarch != NULL);
3769 gdb_assert (gdbarch->find_memory_regions != NULL);
3770 if (gdbarch_debug >= 2)
3771 gdb_printf (gdb_stdlog, "gdbarch_find_memory_regions called\n");
3772 return gdbarch->find_memory_regions (gdbarch, func, data);
3775 void
3776 set_gdbarch_find_memory_regions (struct gdbarch *gdbarch,
3777 gdbarch_find_memory_regions_ftype find_memory_regions)
3779 gdbarch->find_memory_regions = find_memory_regions;
3782 bool
3783 gdbarch_create_memtag_section_p (struct gdbarch *gdbarch)
3785 gdb_assert (gdbarch != NULL);
3786 return gdbarch->create_memtag_section != NULL;
3789 asection *
3790 gdbarch_create_memtag_section (struct gdbarch *gdbarch, bfd *obfd, CORE_ADDR address, size_t size)
3792 gdb_assert (gdbarch != NULL);
3793 gdb_assert (gdbarch->create_memtag_section != NULL);
3794 if (gdbarch_debug >= 2)
3795 gdb_printf (gdb_stdlog, "gdbarch_create_memtag_section called\n");
3796 return gdbarch->create_memtag_section (gdbarch, obfd, address, size);
3799 void
3800 set_gdbarch_create_memtag_section (struct gdbarch *gdbarch,
3801 gdbarch_create_memtag_section_ftype create_memtag_section)
3803 gdbarch->create_memtag_section = create_memtag_section;
3806 bool
3807 gdbarch_fill_memtag_section_p (struct gdbarch *gdbarch)
3809 gdb_assert (gdbarch != NULL);
3810 return gdbarch->fill_memtag_section != NULL;
3813 bool
3814 gdbarch_fill_memtag_section (struct gdbarch *gdbarch, asection *osec)
3816 gdb_assert (gdbarch != NULL);
3817 gdb_assert (gdbarch->fill_memtag_section != NULL);
3818 if (gdbarch_debug >= 2)
3819 gdb_printf (gdb_stdlog, "gdbarch_fill_memtag_section called\n");
3820 return gdbarch->fill_memtag_section (gdbarch, osec);
3823 void
3824 set_gdbarch_fill_memtag_section (struct gdbarch *gdbarch,
3825 gdbarch_fill_memtag_section_ftype fill_memtag_section)
3827 gdbarch->fill_memtag_section = fill_memtag_section;
3830 bool
3831 gdbarch_decode_memtag_section_p (struct gdbarch *gdbarch)
3833 gdb_assert (gdbarch != NULL);
3834 return gdbarch->decode_memtag_section != NULL;
3837 gdb::byte_vector
3838 gdbarch_decode_memtag_section (struct gdbarch *gdbarch, bfd_section *section, int type, CORE_ADDR address, size_t length)
3840 gdb_assert (gdbarch != NULL);
3841 gdb_assert (gdbarch->decode_memtag_section != NULL);
3842 if (gdbarch_debug >= 2)
3843 gdb_printf (gdb_stdlog, "gdbarch_decode_memtag_section called\n");
3844 return gdbarch->decode_memtag_section (gdbarch, section, type, address, length);
3847 void
3848 set_gdbarch_decode_memtag_section (struct gdbarch *gdbarch,
3849 gdbarch_decode_memtag_section_ftype decode_memtag_section)
3851 gdbarch->decode_memtag_section = decode_memtag_section;
3854 bool
3855 gdbarch_core_xfer_shared_libraries_p (struct gdbarch *gdbarch)
3857 gdb_assert (gdbarch != NULL);
3858 return gdbarch->core_xfer_shared_libraries != NULL;
3861 ULONGEST
3862 gdbarch_core_xfer_shared_libraries (struct gdbarch *gdbarch, gdb_byte *readbuf, ULONGEST offset, ULONGEST len)
3864 gdb_assert (gdbarch != NULL);
3865 gdb_assert (gdbarch->core_xfer_shared_libraries != NULL);
3866 if (gdbarch_debug >= 2)
3867 gdb_printf (gdb_stdlog, "gdbarch_core_xfer_shared_libraries called\n");
3868 return gdbarch->core_xfer_shared_libraries (gdbarch, readbuf, offset, len);
3871 void
3872 set_gdbarch_core_xfer_shared_libraries (struct gdbarch *gdbarch,
3873 gdbarch_core_xfer_shared_libraries_ftype core_xfer_shared_libraries)
3875 gdbarch->core_xfer_shared_libraries = core_xfer_shared_libraries;
3878 bool
3879 gdbarch_core_xfer_shared_libraries_aix_p (struct gdbarch *gdbarch)
3881 gdb_assert (gdbarch != NULL);
3882 return gdbarch->core_xfer_shared_libraries_aix != NULL;
3885 ULONGEST
3886 gdbarch_core_xfer_shared_libraries_aix (struct gdbarch *gdbarch, gdb_byte *readbuf, ULONGEST offset, ULONGEST len)
3888 gdb_assert (gdbarch != NULL);
3889 gdb_assert (gdbarch->core_xfer_shared_libraries_aix != NULL);
3890 if (gdbarch_debug >= 2)
3891 gdb_printf (gdb_stdlog, "gdbarch_core_xfer_shared_libraries_aix called\n");
3892 return gdbarch->core_xfer_shared_libraries_aix (gdbarch, readbuf, offset, len);
3895 void
3896 set_gdbarch_core_xfer_shared_libraries_aix (struct gdbarch *gdbarch,
3897 gdbarch_core_xfer_shared_libraries_aix_ftype core_xfer_shared_libraries_aix)
3899 gdbarch->core_xfer_shared_libraries_aix = core_xfer_shared_libraries_aix;
3902 bool
3903 gdbarch_core_pid_to_str_p (struct gdbarch *gdbarch)
3905 gdb_assert (gdbarch != NULL);
3906 return gdbarch->core_pid_to_str != NULL;
3909 std::string
3910 gdbarch_core_pid_to_str (struct gdbarch *gdbarch, ptid_t ptid)
3912 gdb_assert (gdbarch != NULL);
3913 gdb_assert (gdbarch->core_pid_to_str != NULL);
3914 if (gdbarch_debug >= 2)
3915 gdb_printf (gdb_stdlog, "gdbarch_core_pid_to_str called\n");
3916 return gdbarch->core_pid_to_str (gdbarch, ptid);
3919 void
3920 set_gdbarch_core_pid_to_str (struct gdbarch *gdbarch,
3921 gdbarch_core_pid_to_str_ftype core_pid_to_str)
3923 gdbarch->core_pid_to_str = core_pid_to_str;
3926 bool
3927 gdbarch_core_thread_name_p (struct gdbarch *gdbarch)
3929 gdb_assert (gdbarch != NULL);
3930 return gdbarch->core_thread_name != NULL;
3933 const char *
3934 gdbarch_core_thread_name (struct gdbarch *gdbarch, struct thread_info *thr)
3936 gdb_assert (gdbarch != NULL);
3937 gdb_assert (gdbarch->core_thread_name != NULL);
3938 if (gdbarch_debug >= 2)
3939 gdb_printf (gdb_stdlog, "gdbarch_core_thread_name called\n");
3940 return gdbarch->core_thread_name (gdbarch, thr);
3943 void
3944 set_gdbarch_core_thread_name (struct gdbarch *gdbarch,
3945 gdbarch_core_thread_name_ftype core_thread_name)
3947 gdbarch->core_thread_name = core_thread_name;
3950 bool
3951 gdbarch_core_xfer_siginfo_p (struct gdbarch *gdbarch)
3953 gdb_assert (gdbarch != NULL);
3954 return gdbarch->core_xfer_siginfo != NULL;
3957 LONGEST
3958 gdbarch_core_xfer_siginfo (struct gdbarch *gdbarch, gdb_byte *readbuf, ULONGEST offset, ULONGEST len)
3960 gdb_assert (gdbarch != NULL);
3961 gdb_assert (gdbarch->core_xfer_siginfo != NULL);
3962 if (gdbarch_debug >= 2)
3963 gdb_printf (gdb_stdlog, "gdbarch_core_xfer_siginfo called\n");
3964 return gdbarch->core_xfer_siginfo (gdbarch, readbuf, offset, len);
3967 void
3968 set_gdbarch_core_xfer_siginfo (struct gdbarch *gdbarch,
3969 gdbarch_core_xfer_siginfo_ftype core_xfer_siginfo)
3971 gdbarch->core_xfer_siginfo = core_xfer_siginfo;
3974 bool
3975 gdbarch_core_read_x86_xsave_layout_p (struct gdbarch *gdbarch)
3977 gdb_assert (gdbarch != NULL);
3978 return gdbarch->core_read_x86_xsave_layout != NULL;
3981 bool
3982 gdbarch_core_read_x86_xsave_layout (struct gdbarch *gdbarch, x86_xsave_layout &xsave_layout)
3984 gdb_assert (gdbarch != NULL);
3985 gdb_assert (gdbarch->core_read_x86_xsave_layout != NULL);
3986 if (gdbarch_debug >= 2)
3987 gdb_printf (gdb_stdlog, "gdbarch_core_read_x86_xsave_layout called\n");
3988 return gdbarch->core_read_x86_xsave_layout (gdbarch, xsave_layout);
3991 void
3992 set_gdbarch_core_read_x86_xsave_layout (struct gdbarch *gdbarch,
3993 gdbarch_core_read_x86_xsave_layout_ftype core_read_x86_xsave_layout)
3995 gdbarch->core_read_x86_xsave_layout = core_read_x86_xsave_layout;
3998 bool
3999 gdbarch_gcore_bfd_target_p (struct gdbarch *gdbarch)
4001 gdb_assert (gdbarch != NULL);
4002 return gdbarch->gcore_bfd_target != NULL;
4005 const char *
4006 gdbarch_gcore_bfd_target (struct gdbarch *gdbarch)
4008 gdb_assert (gdbarch != NULL);
4009 /* Check predicate was used. */
4010 gdb_assert (gdbarch_gcore_bfd_target_p (gdbarch));
4011 if (gdbarch_debug >= 2)
4012 gdb_printf (gdb_stdlog, "gdbarch_gcore_bfd_target called\n");
4013 return gdbarch->gcore_bfd_target;
4016 void
4017 set_gdbarch_gcore_bfd_target (struct gdbarch *gdbarch,
4018 const char * gcore_bfd_target)
4020 gdbarch->gcore_bfd_target = gcore_bfd_target;
4024 gdbarch_vtable_function_descriptors (struct gdbarch *gdbarch)
4026 gdb_assert (gdbarch != NULL);
4027 /* Skip verify of vtable_function_descriptors, invalid_p == 0 */
4028 if (gdbarch_debug >= 2)
4029 gdb_printf (gdb_stdlog, "gdbarch_vtable_function_descriptors called\n");
4030 return gdbarch->vtable_function_descriptors;
4033 void
4034 set_gdbarch_vtable_function_descriptors (struct gdbarch *gdbarch,
4035 int vtable_function_descriptors)
4037 gdbarch->vtable_function_descriptors = vtable_function_descriptors;
4041 gdbarch_vbit_in_delta (struct gdbarch *gdbarch)
4043 gdb_assert (gdbarch != NULL);
4044 /* Skip verify of vbit_in_delta, invalid_p == 0 */
4045 if (gdbarch_debug >= 2)
4046 gdb_printf (gdb_stdlog, "gdbarch_vbit_in_delta called\n");
4047 return gdbarch->vbit_in_delta;
4050 void
4051 set_gdbarch_vbit_in_delta (struct gdbarch *gdbarch,
4052 int vbit_in_delta)
4054 gdbarch->vbit_in_delta = vbit_in_delta;
4057 void
4058 gdbarch_skip_permanent_breakpoint (struct gdbarch *gdbarch, struct regcache *regcache)
4060 gdb_assert (gdbarch != NULL);
4061 gdb_assert (gdbarch->skip_permanent_breakpoint != NULL);
4062 if (gdbarch_debug >= 2)
4063 gdb_printf (gdb_stdlog, "gdbarch_skip_permanent_breakpoint called\n");
4064 gdbarch->skip_permanent_breakpoint (regcache);
4067 void
4068 set_gdbarch_skip_permanent_breakpoint (struct gdbarch *gdbarch,
4069 gdbarch_skip_permanent_breakpoint_ftype skip_permanent_breakpoint)
4071 gdbarch->skip_permanent_breakpoint = skip_permanent_breakpoint;
4074 bool
4075 gdbarch_max_insn_length_p (struct gdbarch *gdbarch)
4077 gdb_assert (gdbarch != NULL);
4078 return gdbarch->max_insn_length != 0;
4081 ULONGEST
4082 gdbarch_max_insn_length (struct gdbarch *gdbarch)
4084 gdb_assert (gdbarch != NULL);
4085 /* Check predicate was used. */
4086 gdb_assert (gdbarch_max_insn_length_p (gdbarch));
4087 if (gdbarch_debug >= 2)
4088 gdb_printf (gdb_stdlog, "gdbarch_max_insn_length called\n");
4089 return gdbarch->max_insn_length;
4092 void
4093 set_gdbarch_max_insn_length (struct gdbarch *gdbarch,
4094 ULONGEST max_insn_length)
4096 gdbarch->max_insn_length = max_insn_length;
4099 bool
4100 gdbarch_displaced_step_copy_insn_p (struct gdbarch *gdbarch)
4102 gdb_assert (gdbarch != NULL);
4103 return gdbarch->displaced_step_copy_insn != NULL;
4106 displaced_step_copy_insn_closure_up
4107 gdbarch_displaced_step_copy_insn (struct gdbarch *gdbarch, CORE_ADDR from, CORE_ADDR to, struct regcache *regs)
4109 gdb_assert (gdbarch != NULL);
4110 gdb_assert (gdbarch->displaced_step_copy_insn != NULL);
4111 if (gdbarch_debug >= 2)
4112 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_copy_insn called\n");
4113 return gdbarch->displaced_step_copy_insn (gdbarch, from, to, regs);
4116 void
4117 set_gdbarch_displaced_step_copy_insn (struct gdbarch *gdbarch,
4118 gdbarch_displaced_step_copy_insn_ftype displaced_step_copy_insn)
4120 gdbarch->displaced_step_copy_insn = displaced_step_copy_insn;
4123 bool
4124 gdbarch_displaced_step_hw_singlestep (struct gdbarch *gdbarch)
4126 gdb_assert (gdbarch != NULL);
4127 gdb_assert (gdbarch->displaced_step_hw_singlestep != NULL);
4128 if (gdbarch_debug >= 2)
4129 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_hw_singlestep called\n");
4130 return gdbarch->displaced_step_hw_singlestep (gdbarch);
4133 void
4134 set_gdbarch_displaced_step_hw_singlestep (struct gdbarch *gdbarch,
4135 gdbarch_displaced_step_hw_singlestep_ftype displaced_step_hw_singlestep)
4137 gdbarch->displaced_step_hw_singlestep = displaced_step_hw_singlestep;
4140 void
4141 gdbarch_displaced_step_fixup (struct gdbarch *gdbarch, struct displaced_step_copy_insn_closure *closure, CORE_ADDR from, CORE_ADDR to, struct regcache *regs, bool completed_p)
4143 gdb_assert (gdbarch != NULL);
4144 gdb_assert (gdbarch->displaced_step_fixup != NULL);
4145 if (gdbarch_debug >= 2)
4146 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_fixup called\n");
4147 gdbarch->displaced_step_fixup (gdbarch, closure, from, to, regs, completed_p);
4150 void
4151 set_gdbarch_displaced_step_fixup (struct gdbarch *gdbarch,
4152 gdbarch_displaced_step_fixup_ftype displaced_step_fixup)
4154 gdbarch->displaced_step_fixup = displaced_step_fixup;
4157 bool
4158 gdbarch_displaced_step_prepare_p (struct gdbarch *gdbarch)
4160 gdb_assert (gdbarch != NULL);
4161 return gdbarch->displaced_step_prepare != NULL;
4164 displaced_step_prepare_status
4165 gdbarch_displaced_step_prepare (struct gdbarch *gdbarch, thread_info *thread, CORE_ADDR &displaced_pc)
4167 gdb_assert (gdbarch != NULL);
4168 gdb_assert (gdbarch->displaced_step_prepare != NULL);
4169 if (gdbarch_debug >= 2)
4170 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_prepare called\n");
4171 return gdbarch->displaced_step_prepare (gdbarch, thread, displaced_pc);
4174 void
4175 set_gdbarch_displaced_step_prepare (struct gdbarch *gdbarch,
4176 gdbarch_displaced_step_prepare_ftype displaced_step_prepare)
4178 gdbarch->displaced_step_prepare = displaced_step_prepare;
4181 displaced_step_finish_status
4182 gdbarch_displaced_step_finish (struct gdbarch *gdbarch, thread_info *thread, const target_waitstatus &ws)
4184 gdb_assert (gdbarch != NULL);
4185 gdb_assert (gdbarch->displaced_step_finish != NULL);
4186 if (gdbarch_debug >= 2)
4187 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_finish called\n");
4188 return gdbarch->displaced_step_finish (gdbarch, thread, ws);
4191 void
4192 set_gdbarch_displaced_step_finish (struct gdbarch *gdbarch,
4193 gdbarch_displaced_step_finish_ftype displaced_step_finish)
4195 gdbarch->displaced_step_finish = displaced_step_finish;
4198 bool
4199 gdbarch_displaced_step_copy_insn_closure_by_addr_p (struct gdbarch *gdbarch)
4201 gdb_assert (gdbarch != NULL);
4202 return gdbarch->displaced_step_copy_insn_closure_by_addr != NULL;
4205 const displaced_step_copy_insn_closure *
4206 gdbarch_displaced_step_copy_insn_closure_by_addr (struct gdbarch *gdbarch, inferior *inf, CORE_ADDR addr)
4208 gdb_assert (gdbarch != NULL);
4209 gdb_assert (gdbarch->displaced_step_copy_insn_closure_by_addr != NULL);
4210 if (gdbarch_debug >= 2)
4211 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_copy_insn_closure_by_addr called\n");
4212 return gdbarch->displaced_step_copy_insn_closure_by_addr (inf, addr);
4215 void
4216 set_gdbarch_displaced_step_copy_insn_closure_by_addr (struct gdbarch *gdbarch,
4217 gdbarch_displaced_step_copy_insn_closure_by_addr_ftype displaced_step_copy_insn_closure_by_addr)
4219 gdbarch->displaced_step_copy_insn_closure_by_addr = displaced_step_copy_insn_closure_by_addr;
4222 void
4223 gdbarch_displaced_step_restore_all_in_ptid (struct gdbarch *gdbarch, inferior *parent_inf, ptid_t child_ptid)
4225 gdb_assert (gdbarch != NULL);
4226 gdb_assert (gdbarch->displaced_step_restore_all_in_ptid != NULL);
4227 if (gdbarch_debug >= 2)
4228 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_restore_all_in_ptid called\n");
4229 gdbarch->displaced_step_restore_all_in_ptid (parent_inf, child_ptid);
4232 void
4233 set_gdbarch_displaced_step_restore_all_in_ptid (struct gdbarch *gdbarch,
4234 gdbarch_displaced_step_restore_all_in_ptid_ftype displaced_step_restore_all_in_ptid)
4236 gdbarch->displaced_step_restore_all_in_ptid = displaced_step_restore_all_in_ptid;
4239 ULONGEST
4240 gdbarch_displaced_step_buffer_length (struct gdbarch *gdbarch)
4242 gdb_assert (gdbarch != NULL);
4243 /* Check variable is valid. */
4244 gdb_assert (!(gdbarch->displaced_step_buffer_length < gdbarch->max_insn_length));
4245 if (gdbarch_debug >= 2)
4246 gdb_printf (gdb_stdlog, "gdbarch_displaced_step_buffer_length called\n");
4247 return gdbarch->displaced_step_buffer_length;
4250 void
4251 set_gdbarch_displaced_step_buffer_length (struct gdbarch *gdbarch,
4252 ULONGEST displaced_step_buffer_length)
4254 gdbarch->displaced_step_buffer_length = displaced_step_buffer_length;
4257 bool
4258 gdbarch_relocate_instruction_p (struct gdbarch *gdbarch)
4260 gdb_assert (gdbarch != NULL);
4261 return gdbarch->relocate_instruction != NULL;
4264 void
4265 gdbarch_relocate_instruction (struct gdbarch *gdbarch, CORE_ADDR *to, CORE_ADDR from)
4267 gdb_assert (gdbarch != NULL);
4268 gdb_assert (gdbarch->relocate_instruction != NULL);
4269 /* Do not check predicate: gdbarch->relocate_instruction != NULL, allow call. */
4270 if (gdbarch_debug >= 2)
4271 gdb_printf (gdb_stdlog, "gdbarch_relocate_instruction called\n");
4272 gdbarch->relocate_instruction (gdbarch, to, from);
4275 void
4276 set_gdbarch_relocate_instruction (struct gdbarch *gdbarch,
4277 gdbarch_relocate_instruction_ftype relocate_instruction)
4279 gdbarch->relocate_instruction = relocate_instruction;
4282 bool
4283 gdbarch_overlay_update_p (struct gdbarch *gdbarch)
4285 gdb_assert (gdbarch != NULL);
4286 return gdbarch->overlay_update != NULL;
4289 void
4290 gdbarch_overlay_update (struct gdbarch *gdbarch, struct obj_section *osect)
4292 gdb_assert (gdbarch != NULL);
4293 gdb_assert (gdbarch->overlay_update != NULL);
4294 if (gdbarch_debug >= 2)
4295 gdb_printf (gdb_stdlog, "gdbarch_overlay_update called\n");
4296 gdbarch->overlay_update (osect);
4299 void
4300 set_gdbarch_overlay_update (struct gdbarch *gdbarch,
4301 gdbarch_overlay_update_ftype overlay_update)
4303 gdbarch->overlay_update = overlay_update;
4306 bool
4307 gdbarch_core_read_description_p (struct gdbarch *gdbarch)
4309 gdb_assert (gdbarch != NULL);
4310 return gdbarch->core_read_description != NULL;
4313 const struct target_desc *
4314 gdbarch_core_read_description (struct gdbarch *gdbarch, struct target_ops *target, bfd *abfd)
4316 gdb_assert (gdbarch != NULL);
4317 gdb_assert (gdbarch->core_read_description != NULL);
4318 if (gdbarch_debug >= 2)
4319 gdb_printf (gdb_stdlog, "gdbarch_core_read_description called\n");
4320 return gdbarch->core_read_description (gdbarch, target, abfd);
4323 void
4324 set_gdbarch_core_read_description (struct gdbarch *gdbarch,
4325 gdbarch_core_read_description_ftype core_read_description)
4327 gdbarch->core_read_description = core_read_description;
4331 gdbarch_sofun_address_maybe_missing (struct gdbarch *gdbarch)
4333 gdb_assert (gdbarch != NULL);
4334 /* Skip verify of sofun_address_maybe_missing, invalid_p == 0 */
4335 if (gdbarch_debug >= 2)
4336 gdb_printf (gdb_stdlog, "gdbarch_sofun_address_maybe_missing called\n");
4337 return gdbarch->sofun_address_maybe_missing;
4340 void
4341 set_gdbarch_sofun_address_maybe_missing (struct gdbarch *gdbarch,
4342 int sofun_address_maybe_missing)
4344 gdbarch->sofun_address_maybe_missing = sofun_address_maybe_missing;
4347 bool
4348 gdbarch_process_record_p (struct gdbarch *gdbarch)
4350 gdb_assert (gdbarch != NULL);
4351 return gdbarch->process_record != NULL;
4355 gdbarch_process_record (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR addr)
4357 gdb_assert (gdbarch != NULL);
4358 gdb_assert (gdbarch->process_record != NULL);
4359 if (gdbarch_debug >= 2)
4360 gdb_printf (gdb_stdlog, "gdbarch_process_record called\n");
4361 return gdbarch->process_record (gdbarch, regcache, addr);
4364 void
4365 set_gdbarch_process_record (struct gdbarch *gdbarch,
4366 gdbarch_process_record_ftype process_record)
4368 gdbarch->process_record = process_record;
4371 bool
4372 gdbarch_process_record_signal_p (struct gdbarch *gdbarch)
4374 gdb_assert (gdbarch != NULL);
4375 return gdbarch->process_record_signal != NULL;
4379 gdbarch_process_record_signal (struct gdbarch *gdbarch, struct regcache *regcache, enum gdb_signal signal)
4381 gdb_assert (gdbarch != NULL);
4382 gdb_assert (gdbarch->process_record_signal != NULL);
4383 if (gdbarch_debug >= 2)
4384 gdb_printf (gdb_stdlog, "gdbarch_process_record_signal called\n");
4385 return gdbarch->process_record_signal (gdbarch, regcache, signal);
4388 void
4389 set_gdbarch_process_record_signal (struct gdbarch *gdbarch,
4390 gdbarch_process_record_signal_ftype process_record_signal)
4392 gdbarch->process_record_signal = process_record_signal;
4395 bool
4396 gdbarch_gdb_signal_from_target_p (struct gdbarch *gdbarch)
4398 gdb_assert (gdbarch != NULL);
4399 return gdbarch->gdb_signal_from_target != NULL;
4402 enum gdb_signal
4403 gdbarch_gdb_signal_from_target (struct gdbarch *gdbarch, int signo)
4405 gdb_assert (gdbarch != NULL);
4406 gdb_assert (gdbarch->gdb_signal_from_target != NULL);
4407 if (gdbarch_debug >= 2)
4408 gdb_printf (gdb_stdlog, "gdbarch_gdb_signal_from_target called\n");
4409 return gdbarch->gdb_signal_from_target (gdbarch, signo);
4412 void
4413 set_gdbarch_gdb_signal_from_target (struct gdbarch *gdbarch,
4414 gdbarch_gdb_signal_from_target_ftype gdb_signal_from_target)
4416 gdbarch->gdb_signal_from_target = gdb_signal_from_target;
4419 bool
4420 gdbarch_gdb_signal_to_target_p (struct gdbarch *gdbarch)
4422 gdb_assert (gdbarch != NULL);
4423 return gdbarch->gdb_signal_to_target != NULL;
4427 gdbarch_gdb_signal_to_target (struct gdbarch *gdbarch, enum gdb_signal signal)
4429 gdb_assert (gdbarch != NULL);
4430 gdb_assert (gdbarch->gdb_signal_to_target != NULL);
4431 if (gdbarch_debug >= 2)
4432 gdb_printf (gdb_stdlog, "gdbarch_gdb_signal_to_target called\n");
4433 return gdbarch->gdb_signal_to_target (gdbarch, signal);
4436 void
4437 set_gdbarch_gdb_signal_to_target (struct gdbarch *gdbarch,
4438 gdbarch_gdb_signal_to_target_ftype gdb_signal_to_target)
4440 gdbarch->gdb_signal_to_target = gdb_signal_to_target;
4443 bool
4444 gdbarch_get_siginfo_type_p (struct gdbarch *gdbarch)
4446 gdb_assert (gdbarch != NULL);
4447 return gdbarch->get_siginfo_type != NULL;
4450 struct type *
4451 gdbarch_get_siginfo_type (struct gdbarch *gdbarch)
4453 gdb_assert (gdbarch != NULL);
4454 gdb_assert (gdbarch->get_siginfo_type != NULL);
4455 if (gdbarch_debug >= 2)
4456 gdb_printf (gdb_stdlog, "gdbarch_get_siginfo_type called\n");
4457 return gdbarch->get_siginfo_type (gdbarch);
4460 void
4461 set_gdbarch_get_siginfo_type (struct gdbarch *gdbarch,
4462 gdbarch_get_siginfo_type_ftype get_siginfo_type)
4464 gdbarch->get_siginfo_type = get_siginfo_type;
4467 bool
4468 gdbarch_record_special_symbol_p (struct gdbarch *gdbarch)
4470 gdb_assert (gdbarch != NULL);
4471 return gdbarch->record_special_symbol != NULL;
4474 void
4475 gdbarch_record_special_symbol (struct gdbarch *gdbarch, struct objfile *objfile, asymbol *sym)
4477 gdb_assert (gdbarch != NULL);
4478 gdb_assert (gdbarch->record_special_symbol != NULL);
4479 if (gdbarch_debug >= 2)
4480 gdb_printf (gdb_stdlog, "gdbarch_record_special_symbol called\n");
4481 gdbarch->record_special_symbol (gdbarch, objfile, sym);
4484 void
4485 set_gdbarch_record_special_symbol (struct gdbarch *gdbarch,
4486 gdbarch_record_special_symbol_ftype record_special_symbol)
4488 gdbarch->record_special_symbol = record_special_symbol;
4491 bool
4492 gdbarch_get_syscall_number_p (struct gdbarch *gdbarch)
4494 gdb_assert (gdbarch != NULL);
4495 return gdbarch->get_syscall_number != NULL;
4498 LONGEST
4499 gdbarch_get_syscall_number (struct gdbarch *gdbarch, thread_info *thread)
4501 gdb_assert (gdbarch != NULL);
4502 gdb_assert (gdbarch->get_syscall_number != NULL);
4503 if (gdbarch_debug >= 2)
4504 gdb_printf (gdb_stdlog, "gdbarch_get_syscall_number called\n");
4505 return gdbarch->get_syscall_number (gdbarch, thread);
4508 void
4509 set_gdbarch_get_syscall_number (struct gdbarch *gdbarch,
4510 gdbarch_get_syscall_number_ftype get_syscall_number)
4512 gdbarch->get_syscall_number = get_syscall_number;
4515 const char *
4516 gdbarch_xml_syscall_file (struct gdbarch *gdbarch)
4518 gdb_assert (gdbarch != NULL);
4519 /* Skip verify of xml_syscall_file, invalid_p == 0 */
4520 if (gdbarch_debug >= 2)
4521 gdb_printf (gdb_stdlog, "gdbarch_xml_syscall_file called\n");
4522 return gdbarch->xml_syscall_file;
4525 void
4526 set_gdbarch_xml_syscall_file (struct gdbarch *gdbarch,
4527 const char * xml_syscall_file)
4529 gdbarch->xml_syscall_file = xml_syscall_file;
4532 struct syscalls_info *
4533 gdbarch_syscalls_info (struct gdbarch *gdbarch)
4535 gdb_assert (gdbarch != NULL);
4536 /* Skip verify of syscalls_info, invalid_p == 0 */
4537 if (gdbarch_debug >= 2)
4538 gdb_printf (gdb_stdlog, "gdbarch_syscalls_info called\n");
4539 return gdbarch->syscalls_info;
4542 void
4543 set_gdbarch_syscalls_info (struct gdbarch *gdbarch,
4544 struct syscalls_info * syscalls_info)
4546 gdbarch->syscalls_info = syscalls_info;
4549 const char *const *
4550 gdbarch_stap_integer_prefixes (struct gdbarch *gdbarch)
4552 gdb_assert (gdbarch != NULL);
4553 /* Skip verify of stap_integer_prefixes, invalid_p == 0 */
4554 if (gdbarch_debug >= 2)
4555 gdb_printf (gdb_stdlog, "gdbarch_stap_integer_prefixes called\n");
4556 return gdbarch->stap_integer_prefixes;
4559 void
4560 set_gdbarch_stap_integer_prefixes (struct gdbarch *gdbarch,
4561 const char *const * stap_integer_prefixes)
4563 gdbarch->stap_integer_prefixes = stap_integer_prefixes;
4566 const char *const *
4567 gdbarch_stap_integer_suffixes (struct gdbarch *gdbarch)
4569 gdb_assert (gdbarch != NULL);
4570 /* Skip verify of stap_integer_suffixes, invalid_p == 0 */
4571 if (gdbarch_debug >= 2)
4572 gdb_printf (gdb_stdlog, "gdbarch_stap_integer_suffixes called\n");
4573 return gdbarch->stap_integer_suffixes;
4576 void
4577 set_gdbarch_stap_integer_suffixes (struct gdbarch *gdbarch,
4578 const char *const * stap_integer_suffixes)
4580 gdbarch->stap_integer_suffixes = stap_integer_suffixes;
4583 const char *const *
4584 gdbarch_stap_register_prefixes (struct gdbarch *gdbarch)
4586 gdb_assert (gdbarch != NULL);
4587 /* Skip verify of stap_register_prefixes, invalid_p == 0 */
4588 if (gdbarch_debug >= 2)
4589 gdb_printf (gdb_stdlog, "gdbarch_stap_register_prefixes called\n");
4590 return gdbarch->stap_register_prefixes;
4593 void
4594 set_gdbarch_stap_register_prefixes (struct gdbarch *gdbarch,
4595 const char *const * stap_register_prefixes)
4597 gdbarch->stap_register_prefixes = stap_register_prefixes;
4600 const char *const *
4601 gdbarch_stap_register_suffixes (struct gdbarch *gdbarch)
4603 gdb_assert (gdbarch != NULL);
4604 /* Skip verify of stap_register_suffixes, invalid_p == 0 */
4605 if (gdbarch_debug >= 2)
4606 gdb_printf (gdb_stdlog, "gdbarch_stap_register_suffixes called\n");
4607 return gdbarch->stap_register_suffixes;
4610 void
4611 set_gdbarch_stap_register_suffixes (struct gdbarch *gdbarch,
4612 const char *const * stap_register_suffixes)
4614 gdbarch->stap_register_suffixes = stap_register_suffixes;
4617 const char *const *
4618 gdbarch_stap_register_indirection_prefixes (struct gdbarch *gdbarch)
4620 gdb_assert (gdbarch != NULL);
4621 /* Skip verify of stap_register_indirection_prefixes, invalid_p == 0 */
4622 if (gdbarch_debug >= 2)
4623 gdb_printf (gdb_stdlog, "gdbarch_stap_register_indirection_prefixes called\n");
4624 return gdbarch->stap_register_indirection_prefixes;
4627 void
4628 set_gdbarch_stap_register_indirection_prefixes (struct gdbarch *gdbarch,
4629 const char *const * stap_register_indirection_prefixes)
4631 gdbarch->stap_register_indirection_prefixes = stap_register_indirection_prefixes;
4634 const char *const *
4635 gdbarch_stap_register_indirection_suffixes (struct gdbarch *gdbarch)
4637 gdb_assert (gdbarch != NULL);
4638 /* Skip verify of stap_register_indirection_suffixes, invalid_p == 0 */
4639 if (gdbarch_debug >= 2)
4640 gdb_printf (gdb_stdlog, "gdbarch_stap_register_indirection_suffixes called\n");
4641 return gdbarch->stap_register_indirection_suffixes;
4644 void
4645 set_gdbarch_stap_register_indirection_suffixes (struct gdbarch *gdbarch,
4646 const char *const * stap_register_indirection_suffixes)
4648 gdbarch->stap_register_indirection_suffixes = stap_register_indirection_suffixes;
4651 const char *
4652 gdbarch_stap_gdb_register_prefix (struct gdbarch *gdbarch)
4654 gdb_assert (gdbarch != NULL);
4655 /* Skip verify of stap_gdb_register_prefix, invalid_p == 0 */
4656 if (gdbarch_debug >= 2)
4657 gdb_printf (gdb_stdlog, "gdbarch_stap_gdb_register_prefix called\n");
4658 return gdbarch->stap_gdb_register_prefix;
4661 void
4662 set_gdbarch_stap_gdb_register_prefix (struct gdbarch *gdbarch,
4663 const char * stap_gdb_register_prefix)
4665 gdbarch->stap_gdb_register_prefix = stap_gdb_register_prefix;
4668 const char *
4669 gdbarch_stap_gdb_register_suffix (struct gdbarch *gdbarch)
4671 gdb_assert (gdbarch != NULL);
4672 /* Skip verify of stap_gdb_register_suffix, invalid_p == 0 */
4673 if (gdbarch_debug >= 2)
4674 gdb_printf (gdb_stdlog, "gdbarch_stap_gdb_register_suffix called\n");
4675 return gdbarch->stap_gdb_register_suffix;
4678 void
4679 set_gdbarch_stap_gdb_register_suffix (struct gdbarch *gdbarch,
4680 const char * stap_gdb_register_suffix)
4682 gdbarch->stap_gdb_register_suffix = stap_gdb_register_suffix;
4685 bool
4686 gdbarch_stap_is_single_operand_p (struct gdbarch *gdbarch)
4688 gdb_assert (gdbarch != NULL);
4689 return gdbarch->stap_is_single_operand != NULL;
4693 gdbarch_stap_is_single_operand (struct gdbarch *gdbarch, const char *s)
4695 gdb_assert (gdbarch != NULL);
4696 gdb_assert (gdbarch->stap_is_single_operand != NULL);
4697 if (gdbarch_debug >= 2)
4698 gdb_printf (gdb_stdlog, "gdbarch_stap_is_single_operand called\n");
4699 return gdbarch->stap_is_single_operand (gdbarch, s);
4702 void
4703 set_gdbarch_stap_is_single_operand (struct gdbarch *gdbarch,
4704 gdbarch_stap_is_single_operand_ftype stap_is_single_operand)
4706 gdbarch->stap_is_single_operand = stap_is_single_operand;
4709 bool
4710 gdbarch_stap_parse_special_token_p (struct gdbarch *gdbarch)
4712 gdb_assert (gdbarch != NULL);
4713 return gdbarch->stap_parse_special_token != NULL;
4716 expr::operation_up
4717 gdbarch_stap_parse_special_token (struct gdbarch *gdbarch, struct stap_parse_info *p)
4719 gdb_assert (gdbarch != NULL);
4720 gdb_assert (gdbarch->stap_parse_special_token != NULL);
4721 if (gdbarch_debug >= 2)
4722 gdb_printf (gdb_stdlog, "gdbarch_stap_parse_special_token called\n");
4723 return gdbarch->stap_parse_special_token (gdbarch, p);
4726 void
4727 set_gdbarch_stap_parse_special_token (struct gdbarch *gdbarch,
4728 gdbarch_stap_parse_special_token_ftype stap_parse_special_token)
4730 gdbarch->stap_parse_special_token = stap_parse_special_token;
4733 bool
4734 gdbarch_stap_adjust_register_p (struct gdbarch *gdbarch)
4736 gdb_assert (gdbarch != NULL);
4737 return gdbarch->stap_adjust_register != NULL;
4740 std::string
4741 gdbarch_stap_adjust_register (struct gdbarch *gdbarch, struct stap_parse_info *p, const std::string &regname, int regnum)
4743 gdb_assert (gdbarch != NULL);
4744 gdb_assert (gdbarch->stap_adjust_register != NULL);
4745 if (gdbarch_debug >= 2)
4746 gdb_printf (gdb_stdlog, "gdbarch_stap_adjust_register called\n");
4747 return gdbarch->stap_adjust_register (gdbarch, p, regname, regnum);
4750 void
4751 set_gdbarch_stap_adjust_register (struct gdbarch *gdbarch,
4752 gdbarch_stap_adjust_register_ftype stap_adjust_register)
4754 gdbarch->stap_adjust_register = stap_adjust_register;
4757 bool
4758 gdbarch_dtrace_parse_probe_argument_p (struct gdbarch *gdbarch)
4760 gdb_assert (gdbarch != NULL);
4761 return gdbarch->dtrace_parse_probe_argument != NULL;
4764 expr::operation_up
4765 gdbarch_dtrace_parse_probe_argument (struct gdbarch *gdbarch, int narg)
4767 gdb_assert (gdbarch != NULL);
4768 gdb_assert (gdbarch->dtrace_parse_probe_argument != NULL);
4769 if (gdbarch_debug >= 2)
4770 gdb_printf (gdb_stdlog, "gdbarch_dtrace_parse_probe_argument called\n");
4771 return gdbarch->dtrace_parse_probe_argument (gdbarch, narg);
4774 void
4775 set_gdbarch_dtrace_parse_probe_argument (struct gdbarch *gdbarch,
4776 gdbarch_dtrace_parse_probe_argument_ftype dtrace_parse_probe_argument)
4778 gdbarch->dtrace_parse_probe_argument = dtrace_parse_probe_argument;
4781 bool
4782 gdbarch_dtrace_probe_is_enabled_p (struct gdbarch *gdbarch)
4784 gdb_assert (gdbarch != NULL);
4785 return gdbarch->dtrace_probe_is_enabled != NULL;
4789 gdbarch_dtrace_probe_is_enabled (struct gdbarch *gdbarch, CORE_ADDR addr)
4791 gdb_assert (gdbarch != NULL);
4792 gdb_assert (gdbarch->dtrace_probe_is_enabled != NULL);
4793 if (gdbarch_debug >= 2)
4794 gdb_printf (gdb_stdlog, "gdbarch_dtrace_probe_is_enabled called\n");
4795 return gdbarch->dtrace_probe_is_enabled (gdbarch, addr);
4798 void
4799 set_gdbarch_dtrace_probe_is_enabled (struct gdbarch *gdbarch,
4800 gdbarch_dtrace_probe_is_enabled_ftype dtrace_probe_is_enabled)
4802 gdbarch->dtrace_probe_is_enabled = dtrace_probe_is_enabled;
4805 bool
4806 gdbarch_dtrace_enable_probe_p (struct gdbarch *gdbarch)
4808 gdb_assert (gdbarch != NULL);
4809 return gdbarch->dtrace_enable_probe != NULL;
4812 void
4813 gdbarch_dtrace_enable_probe (struct gdbarch *gdbarch, CORE_ADDR addr)
4815 gdb_assert (gdbarch != NULL);
4816 gdb_assert (gdbarch->dtrace_enable_probe != NULL);
4817 if (gdbarch_debug >= 2)
4818 gdb_printf (gdb_stdlog, "gdbarch_dtrace_enable_probe called\n");
4819 gdbarch->dtrace_enable_probe (gdbarch, addr);
4822 void
4823 set_gdbarch_dtrace_enable_probe (struct gdbarch *gdbarch,
4824 gdbarch_dtrace_enable_probe_ftype dtrace_enable_probe)
4826 gdbarch->dtrace_enable_probe = dtrace_enable_probe;
4829 bool
4830 gdbarch_dtrace_disable_probe_p (struct gdbarch *gdbarch)
4832 gdb_assert (gdbarch != NULL);
4833 return gdbarch->dtrace_disable_probe != NULL;
4836 void
4837 gdbarch_dtrace_disable_probe (struct gdbarch *gdbarch, CORE_ADDR addr)
4839 gdb_assert (gdbarch != NULL);
4840 gdb_assert (gdbarch->dtrace_disable_probe != NULL);
4841 if (gdbarch_debug >= 2)
4842 gdb_printf (gdb_stdlog, "gdbarch_dtrace_disable_probe called\n");
4843 gdbarch->dtrace_disable_probe (gdbarch, addr);
4846 void
4847 set_gdbarch_dtrace_disable_probe (struct gdbarch *gdbarch,
4848 gdbarch_dtrace_disable_probe_ftype dtrace_disable_probe)
4850 gdbarch->dtrace_disable_probe = dtrace_disable_probe;
4854 gdbarch_has_global_solist (struct gdbarch *gdbarch)
4856 gdb_assert (gdbarch != NULL);
4857 /* Skip verify of has_global_solist, invalid_p == 0 */
4858 if (gdbarch_debug >= 2)
4859 gdb_printf (gdb_stdlog, "gdbarch_has_global_solist called\n");
4860 return gdbarch->has_global_solist;
4863 void
4864 set_gdbarch_has_global_solist (struct gdbarch *gdbarch,
4865 int has_global_solist)
4867 gdbarch->has_global_solist = has_global_solist;
4871 gdbarch_has_global_breakpoints (struct gdbarch *gdbarch)
4873 gdb_assert (gdbarch != NULL);
4874 /* Skip verify of has_global_breakpoints, invalid_p == 0 */
4875 if (gdbarch_debug >= 2)
4876 gdb_printf (gdb_stdlog, "gdbarch_has_global_breakpoints called\n");
4877 return gdbarch->has_global_breakpoints;
4880 void
4881 set_gdbarch_has_global_breakpoints (struct gdbarch *gdbarch,
4882 int has_global_breakpoints)
4884 gdbarch->has_global_breakpoints = has_global_breakpoints;
4888 gdbarch_has_shared_address_space (struct gdbarch *gdbarch)
4890 gdb_assert (gdbarch != NULL);
4891 gdb_assert (gdbarch->has_shared_address_space != NULL);
4892 if (gdbarch_debug >= 2)
4893 gdb_printf (gdb_stdlog, "gdbarch_has_shared_address_space called\n");
4894 return gdbarch->has_shared_address_space (gdbarch);
4897 void
4898 set_gdbarch_has_shared_address_space (struct gdbarch *gdbarch,
4899 gdbarch_has_shared_address_space_ftype has_shared_address_space)
4901 gdbarch->has_shared_address_space = has_shared_address_space;
4905 gdbarch_fast_tracepoint_valid_at (struct gdbarch *gdbarch, CORE_ADDR addr, std::string *msg)
4907 gdb_assert (gdbarch != NULL);
4908 gdb_assert (gdbarch->fast_tracepoint_valid_at != NULL);
4909 if (gdbarch_debug >= 2)
4910 gdb_printf (gdb_stdlog, "gdbarch_fast_tracepoint_valid_at called\n");
4911 return gdbarch->fast_tracepoint_valid_at (gdbarch, addr, msg);
4914 void
4915 set_gdbarch_fast_tracepoint_valid_at (struct gdbarch *gdbarch,
4916 gdbarch_fast_tracepoint_valid_at_ftype fast_tracepoint_valid_at)
4918 gdbarch->fast_tracepoint_valid_at = fast_tracepoint_valid_at;
4921 void
4922 gdbarch_guess_tracepoint_registers (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR addr)
4924 gdb_assert (gdbarch != NULL);
4925 gdb_assert (gdbarch->guess_tracepoint_registers != NULL);
4926 if (gdbarch_debug >= 2)
4927 gdb_printf (gdb_stdlog, "gdbarch_guess_tracepoint_registers called\n");
4928 gdbarch->guess_tracepoint_registers (gdbarch, regcache, addr);
4931 void
4932 set_gdbarch_guess_tracepoint_registers (struct gdbarch *gdbarch,
4933 gdbarch_guess_tracepoint_registers_ftype guess_tracepoint_registers)
4935 gdbarch->guess_tracepoint_registers = guess_tracepoint_registers;
4938 const char *
4939 gdbarch_auto_charset (struct gdbarch *gdbarch)
4941 gdb_assert (gdbarch != NULL);
4942 gdb_assert (gdbarch->auto_charset != NULL);
4943 if (gdbarch_debug >= 2)
4944 gdb_printf (gdb_stdlog, "gdbarch_auto_charset called\n");
4945 return gdbarch->auto_charset ();
4948 void
4949 set_gdbarch_auto_charset (struct gdbarch *gdbarch,
4950 gdbarch_auto_charset_ftype auto_charset)
4952 gdbarch->auto_charset = auto_charset;
4955 const char *
4956 gdbarch_auto_wide_charset (struct gdbarch *gdbarch)
4958 gdb_assert (gdbarch != NULL);
4959 gdb_assert (gdbarch->auto_wide_charset != NULL);
4960 if (gdbarch_debug >= 2)
4961 gdb_printf (gdb_stdlog, "gdbarch_auto_wide_charset called\n");
4962 return gdbarch->auto_wide_charset ();
4965 void
4966 set_gdbarch_auto_wide_charset (struct gdbarch *gdbarch,
4967 gdbarch_auto_wide_charset_ftype auto_wide_charset)
4969 gdbarch->auto_wide_charset = auto_wide_charset;
4972 const char *
4973 gdbarch_solib_symbols_extension (struct gdbarch *gdbarch)
4975 gdb_assert (gdbarch != NULL);
4976 /* Skip verify of solib_symbols_extension, invalid_p == 0 */
4977 if (gdbarch_debug >= 2)
4978 gdb_printf (gdb_stdlog, "gdbarch_solib_symbols_extension called\n");
4979 return gdbarch->solib_symbols_extension;
4982 void
4983 set_gdbarch_solib_symbols_extension (struct gdbarch *gdbarch,
4984 const char * solib_symbols_extension)
4986 gdbarch->solib_symbols_extension = solib_symbols_extension;
4990 gdbarch_has_dos_based_file_system (struct gdbarch *gdbarch)
4992 gdb_assert (gdbarch != NULL);
4993 /* Skip verify of has_dos_based_file_system, invalid_p == 0 */
4994 if (gdbarch_debug >= 2)
4995 gdb_printf (gdb_stdlog, "gdbarch_has_dos_based_file_system called\n");
4996 return gdbarch->has_dos_based_file_system;
4999 void
5000 set_gdbarch_has_dos_based_file_system (struct gdbarch *gdbarch,
5001 int has_dos_based_file_system)
5003 gdbarch->has_dos_based_file_system = has_dos_based_file_system;
5006 void
5007 gdbarch_gen_return_address (struct gdbarch *gdbarch, struct agent_expr *ax, struct axs_value *value, CORE_ADDR scope)
5009 gdb_assert (gdbarch != NULL);
5010 gdb_assert (gdbarch->gen_return_address != NULL);
5011 if (gdbarch_debug >= 2)
5012 gdb_printf (gdb_stdlog, "gdbarch_gen_return_address called\n");
5013 gdbarch->gen_return_address (gdbarch, ax, value, scope);
5016 void
5017 set_gdbarch_gen_return_address (struct gdbarch *gdbarch,
5018 gdbarch_gen_return_address_ftype gen_return_address)
5020 gdbarch->gen_return_address = gen_return_address;
5023 bool
5024 gdbarch_info_proc_p (struct gdbarch *gdbarch)
5026 gdb_assert (gdbarch != NULL);
5027 return gdbarch->info_proc != NULL;
5030 void
5031 gdbarch_info_proc (struct gdbarch *gdbarch, const char *args, enum info_proc_what what)
5033 gdb_assert (gdbarch != NULL);
5034 gdb_assert (gdbarch->info_proc != NULL);
5035 if (gdbarch_debug >= 2)
5036 gdb_printf (gdb_stdlog, "gdbarch_info_proc called\n");
5037 gdbarch->info_proc (gdbarch, args, what);
5040 void
5041 set_gdbarch_info_proc (struct gdbarch *gdbarch,
5042 gdbarch_info_proc_ftype info_proc)
5044 gdbarch->info_proc = info_proc;
5047 bool
5048 gdbarch_core_info_proc_p (struct gdbarch *gdbarch)
5050 gdb_assert (gdbarch != NULL);
5051 return gdbarch->core_info_proc != NULL;
5054 void
5055 gdbarch_core_info_proc (struct gdbarch *gdbarch, const char *args, enum info_proc_what what)
5057 gdb_assert (gdbarch != NULL);
5058 gdb_assert (gdbarch->core_info_proc != NULL);
5059 if (gdbarch_debug >= 2)
5060 gdb_printf (gdb_stdlog, "gdbarch_core_info_proc called\n");
5061 gdbarch->core_info_proc (gdbarch, args, what);
5064 void
5065 set_gdbarch_core_info_proc (struct gdbarch *gdbarch,
5066 gdbarch_core_info_proc_ftype core_info_proc)
5068 gdbarch->core_info_proc = core_info_proc;
5071 void
5072 gdbarch_iterate_over_objfiles_in_search_order (struct gdbarch *gdbarch, iterate_over_objfiles_in_search_order_cb_ftype cb, struct objfile *current_objfile)
5074 gdb_assert (gdbarch != NULL);
5075 gdb_assert (gdbarch->iterate_over_objfiles_in_search_order != NULL);
5076 if (gdbarch_debug >= 2)
5077 gdb_printf (gdb_stdlog, "gdbarch_iterate_over_objfiles_in_search_order called\n");
5078 gdbarch->iterate_over_objfiles_in_search_order (gdbarch, cb, current_objfile);
5081 void
5082 set_gdbarch_iterate_over_objfiles_in_search_order (struct gdbarch *gdbarch,
5083 gdbarch_iterate_over_objfiles_in_search_order_ftype iterate_over_objfiles_in_search_order)
5085 gdbarch->iterate_over_objfiles_in_search_order = iterate_over_objfiles_in_search_order;
5088 struct ravenscar_arch_ops *
5089 gdbarch_ravenscar_ops (struct gdbarch *gdbarch)
5091 gdb_assert (gdbarch != NULL);
5092 /* Skip verify of ravenscar_ops, invalid_p == 0 */
5093 if (gdbarch_debug >= 2)
5094 gdb_printf (gdb_stdlog, "gdbarch_ravenscar_ops called\n");
5095 return gdbarch->ravenscar_ops;
5098 void
5099 set_gdbarch_ravenscar_ops (struct gdbarch *gdbarch,
5100 struct ravenscar_arch_ops * ravenscar_ops)
5102 gdbarch->ravenscar_ops = ravenscar_ops;
5106 gdbarch_insn_is_call (struct gdbarch *gdbarch, CORE_ADDR addr)
5108 gdb_assert (gdbarch != NULL);
5109 gdb_assert (gdbarch->insn_is_call != NULL);
5110 if (gdbarch_debug >= 2)
5111 gdb_printf (gdb_stdlog, "gdbarch_insn_is_call called\n");
5112 return gdbarch->insn_is_call (gdbarch, addr);
5115 void
5116 set_gdbarch_insn_is_call (struct gdbarch *gdbarch,
5117 gdbarch_insn_is_call_ftype insn_is_call)
5119 gdbarch->insn_is_call = insn_is_call;
5123 gdbarch_insn_is_ret (struct gdbarch *gdbarch, CORE_ADDR addr)
5125 gdb_assert (gdbarch != NULL);
5126 gdb_assert (gdbarch->insn_is_ret != NULL);
5127 if (gdbarch_debug >= 2)
5128 gdb_printf (gdb_stdlog, "gdbarch_insn_is_ret called\n");
5129 return gdbarch->insn_is_ret (gdbarch, addr);
5132 void
5133 set_gdbarch_insn_is_ret (struct gdbarch *gdbarch,
5134 gdbarch_insn_is_ret_ftype insn_is_ret)
5136 gdbarch->insn_is_ret = insn_is_ret;
5140 gdbarch_insn_is_jump (struct gdbarch *gdbarch, CORE_ADDR addr)
5142 gdb_assert (gdbarch != NULL);
5143 gdb_assert (gdbarch->insn_is_jump != NULL);
5144 if (gdbarch_debug >= 2)
5145 gdb_printf (gdb_stdlog, "gdbarch_insn_is_jump called\n");
5146 return gdbarch->insn_is_jump (gdbarch, addr);
5149 void
5150 set_gdbarch_insn_is_jump (struct gdbarch *gdbarch,
5151 gdbarch_insn_is_jump_ftype insn_is_jump)
5153 gdbarch->insn_is_jump = insn_is_jump;
5156 bool
5157 gdbarch_program_breakpoint_here_p (struct gdbarch *gdbarch, CORE_ADDR address)
5159 gdb_assert (gdbarch != NULL);
5160 gdb_assert (gdbarch->program_breakpoint_here_p != NULL);
5161 if (gdbarch_debug >= 2)
5162 gdb_printf (gdb_stdlog, "gdbarch_program_breakpoint_here_p called\n");
5163 return gdbarch->program_breakpoint_here_p (gdbarch, address);
5166 void
5167 set_gdbarch_program_breakpoint_here_p (struct gdbarch *gdbarch,
5168 gdbarch_program_breakpoint_here_p_ftype program_breakpoint_here_p)
5170 gdbarch->program_breakpoint_here_p = program_breakpoint_here_p;
5173 bool
5174 gdbarch_auxv_parse_p (struct gdbarch *gdbarch)
5176 gdb_assert (gdbarch != NULL);
5177 return gdbarch->auxv_parse != NULL;
5181 gdbarch_auxv_parse (struct gdbarch *gdbarch, const gdb_byte **readptr, const gdb_byte *endptr, CORE_ADDR *typep, CORE_ADDR *valp)
5183 gdb_assert (gdbarch != NULL);
5184 gdb_assert (gdbarch->auxv_parse != NULL);
5185 if (gdbarch_debug >= 2)
5186 gdb_printf (gdb_stdlog, "gdbarch_auxv_parse called\n");
5187 return gdbarch->auxv_parse (gdbarch, readptr, endptr, typep, valp);
5190 void
5191 set_gdbarch_auxv_parse (struct gdbarch *gdbarch,
5192 gdbarch_auxv_parse_ftype auxv_parse)
5194 gdbarch->auxv_parse = auxv_parse;
5197 void
5198 gdbarch_print_auxv_entry (struct gdbarch *gdbarch, struct ui_file *file, CORE_ADDR type, CORE_ADDR val)
5200 gdb_assert (gdbarch != NULL);
5201 gdb_assert (gdbarch->print_auxv_entry != NULL);
5202 if (gdbarch_debug >= 2)
5203 gdb_printf (gdb_stdlog, "gdbarch_print_auxv_entry called\n");
5204 gdbarch->print_auxv_entry (gdbarch, file, type, val);
5207 void
5208 set_gdbarch_print_auxv_entry (struct gdbarch *gdbarch,
5209 gdbarch_print_auxv_entry_ftype print_auxv_entry)
5211 gdbarch->print_auxv_entry = print_auxv_entry;
5215 gdbarch_vsyscall_range (struct gdbarch *gdbarch, struct mem_range *range)
5217 gdb_assert (gdbarch != NULL);
5218 gdb_assert (gdbarch->vsyscall_range != NULL);
5219 if (gdbarch_debug >= 2)
5220 gdb_printf (gdb_stdlog, "gdbarch_vsyscall_range called\n");
5221 return gdbarch->vsyscall_range (gdbarch, range);
5224 void
5225 set_gdbarch_vsyscall_range (struct gdbarch *gdbarch,
5226 gdbarch_vsyscall_range_ftype vsyscall_range)
5228 gdbarch->vsyscall_range = vsyscall_range;
5231 CORE_ADDR
5232 gdbarch_infcall_mmap (struct gdbarch *gdbarch, CORE_ADDR size, unsigned prot)
5234 gdb_assert (gdbarch != NULL);
5235 gdb_assert (gdbarch->infcall_mmap != NULL);
5236 if (gdbarch_debug >= 2)
5237 gdb_printf (gdb_stdlog, "gdbarch_infcall_mmap called\n");
5238 return gdbarch->infcall_mmap (size, prot);
5241 void
5242 set_gdbarch_infcall_mmap (struct gdbarch *gdbarch,
5243 gdbarch_infcall_mmap_ftype infcall_mmap)
5245 gdbarch->infcall_mmap = infcall_mmap;
5248 void
5249 gdbarch_infcall_munmap (struct gdbarch *gdbarch, CORE_ADDR addr, CORE_ADDR size)
5251 gdb_assert (gdbarch != NULL);
5252 gdb_assert (gdbarch->infcall_munmap != NULL);
5253 if (gdbarch_debug >= 2)
5254 gdb_printf (gdb_stdlog, "gdbarch_infcall_munmap called\n");
5255 gdbarch->infcall_munmap (addr, size);
5258 void
5259 set_gdbarch_infcall_munmap (struct gdbarch *gdbarch,
5260 gdbarch_infcall_munmap_ftype infcall_munmap)
5262 gdbarch->infcall_munmap = infcall_munmap;
5265 std::string
5266 gdbarch_gcc_target_options (struct gdbarch *gdbarch)
5268 gdb_assert (gdbarch != NULL);
5269 gdb_assert (gdbarch->gcc_target_options != NULL);
5270 if (gdbarch_debug >= 2)
5271 gdb_printf (gdb_stdlog, "gdbarch_gcc_target_options called\n");
5272 return gdbarch->gcc_target_options (gdbarch);
5275 void
5276 set_gdbarch_gcc_target_options (struct gdbarch *gdbarch,
5277 gdbarch_gcc_target_options_ftype gcc_target_options)
5279 gdbarch->gcc_target_options = gcc_target_options;
5282 const char *
5283 gdbarch_gnu_triplet_regexp (struct gdbarch *gdbarch)
5285 gdb_assert (gdbarch != NULL);
5286 gdb_assert (gdbarch->gnu_triplet_regexp != NULL);
5287 if (gdbarch_debug >= 2)
5288 gdb_printf (gdb_stdlog, "gdbarch_gnu_triplet_regexp called\n");
5289 return gdbarch->gnu_triplet_regexp (gdbarch);
5292 void
5293 set_gdbarch_gnu_triplet_regexp (struct gdbarch *gdbarch,
5294 gdbarch_gnu_triplet_regexp_ftype gnu_triplet_regexp)
5296 gdbarch->gnu_triplet_regexp = gnu_triplet_regexp;
5300 gdbarch_addressable_memory_unit_size (struct gdbarch *gdbarch)
5302 gdb_assert (gdbarch != NULL);
5303 gdb_assert (gdbarch->addressable_memory_unit_size != NULL);
5304 if (gdbarch_debug >= 2)
5305 gdb_printf (gdb_stdlog, "gdbarch_addressable_memory_unit_size called\n");
5306 return gdbarch->addressable_memory_unit_size (gdbarch);
5309 void
5310 set_gdbarch_addressable_memory_unit_size (struct gdbarch *gdbarch,
5311 gdbarch_addressable_memory_unit_size_ftype addressable_memory_unit_size)
5313 gdbarch->addressable_memory_unit_size = addressable_memory_unit_size;
5316 const char *
5317 gdbarch_disassembler_options_implicit (struct gdbarch *gdbarch)
5319 gdb_assert (gdbarch != NULL);
5320 /* Skip verify of disassembler_options_implicit, invalid_p == 0 */
5321 if (gdbarch_debug >= 2)
5322 gdb_printf (gdb_stdlog, "gdbarch_disassembler_options_implicit called\n");
5323 return gdbarch->disassembler_options_implicit;
5326 void
5327 set_gdbarch_disassembler_options_implicit (struct gdbarch *gdbarch,
5328 const char * disassembler_options_implicit)
5330 gdbarch->disassembler_options_implicit = disassembler_options_implicit;
5333 char **
5334 gdbarch_disassembler_options (struct gdbarch *gdbarch)
5336 gdb_assert (gdbarch != NULL);
5337 /* Skip verify of disassembler_options, invalid_p == 0 */
5338 if (gdbarch_debug >= 2)
5339 gdb_printf (gdb_stdlog, "gdbarch_disassembler_options called\n");
5340 return gdbarch->disassembler_options;
5343 void
5344 set_gdbarch_disassembler_options (struct gdbarch *gdbarch,
5345 char ** disassembler_options)
5347 gdbarch->disassembler_options = disassembler_options;
5350 const disasm_options_and_args_t *
5351 gdbarch_valid_disassembler_options (struct gdbarch *gdbarch)
5353 gdb_assert (gdbarch != NULL);
5354 /* Skip verify of valid_disassembler_options, invalid_p == 0 */
5355 if (gdbarch_debug >= 2)
5356 gdb_printf (gdb_stdlog, "gdbarch_valid_disassembler_options called\n");
5357 return gdbarch->valid_disassembler_options;
5360 void
5361 set_gdbarch_valid_disassembler_options (struct gdbarch *gdbarch,
5362 const disasm_options_and_args_t * valid_disassembler_options)
5364 gdbarch->valid_disassembler_options = valid_disassembler_options;
5367 ULONGEST
5368 gdbarch_type_align (struct gdbarch *gdbarch, struct type *type)
5370 gdb_assert (gdbarch != NULL);
5371 gdb_assert (gdbarch->type_align != NULL);
5372 if (gdbarch_debug >= 2)
5373 gdb_printf (gdb_stdlog, "gdbarch_type_align called\n");
5374 return gdbarch->type_align (gdbarch, type);
5377 void
5378 set_gdbarch_type_align (struct gdbarch *gdbarch,
5379 gdbarch_type_align_ftype type_align)
5381 gdbarch->type_align = type_align;
5384 std::string
5385 gdbarch_get_pc_address_flags (struct gdbarch *gdbarch, frame_info_ptr frame, CORE_ADDR pc)
5387 gdb_assert (gdbarch != NULL);
5388 gdb_assert (gdbarch->get_pc_address_flags != NULL);
5389 if (gdbarch_debug >= 2)
5390 gdb_printf (gdb_stdlog, "gdbarch_get_pc_address_flags called\n");
5391 return gdbarch->get_pc_address_flags (frame, pc);
5394 void
5395 set_gdbarch_get_pc_address_flags (struct gdbarch *gdbarch,
5396 gdbarch_get_pc_address_flags_ftype get_pc_address_flags)
5398 gdbarch->get_pc_address_flags = get_pc_address_flags;
5401 void
5402 gdbarch_read_core_file_mappings (struct gdbarch *gdbarch, struct bfd *cbfd, read_core_file_mappings_pre_loop_ftype pre_loop_cb, read_core_file_mappings_loop_ftype loop_cb)
5404 gdb_assert (gdbarch != NULL);
5405 gdb_assert (gdbarch->read_core_file_mappings != NULL);
5406 if (gdbarch_debug >= 2)
5407 gdb_printf (gdb_stdlog, "gdbarch_read_core_file_mappings called\n");
5408 gdbarch->read_core_file_mappings (gdbarch, cbfd, pre_loop_cb, loop_cb);
5411 void
5412 set_gdbarch_read_core_file_mappings (struct gdbarch *gdbarch,
5413 gdbarch_read_core_file_mappings_ftype read_core_file_mappings)
5415 gdbarch->read_core_file_mappings = read_core_file_mappings;
5418 bool
5419 gdbarch_use_target_description_from_corefile_notes (struct gdbarch *gdbarch, struct bfd *corefile_bfd)
5421 gdb_assert (gdbarch != NULL);
5422 gdb_assert (gdbarch->use_target_description_from_corefile_notes != NULL);
5423 if (gdbarch_debug >= 2)
5424 gdb_printf (gdb_stdlog, "gdbarch_use_target_description_from_corefile_notes called\n");
5425 return gdbarch->use_target_description_from_corefile_notes (gdbarch, corefile_bfd);
5428 void
5429 set_gdbarch_use_target_description_from_corefile_notes (struct gdbarch *gdbarch,
5430 gdbarch_use_target_description_from_corefile_notes_ftype use_target_description_from_corefile_notes)
5432 gdbarch->use_target_description_from_corefile_notes = use_target_description_from_corefile_notes;