4 * i386-tdep.c (i386_16_byte_align_p): Skip static fields.
9 * dwarf2/frame.c (find_comp_unit, set_comp_unit): Reverse use of
10 dwarf2_frame_bfd_data and dwarf2_frame_objfile_data.
14 * arch/riscv.c: Include 'rv32e-xregs.c'.
15 (riscv_create_target_description): Update to handle rv32e.
16 * arch/riscv.h (struct riscv_gdbarch_features) <embedded>: New
18 <operator==>: Update to account for new field.
20 * features/Makefile (FEATURE_XMLFILES): Add riscv/rv32e-xregs.xml.
21 * features/riscv/rv32e-xregs.c: Generated.
22 * features/riscv/rv32e-xregs.xml: New file.
23 * riscv-tdep.c (riscv_debug_breakpoints): Move from later in the
25 (riscv_debug_infcall): Likewise.
26 (riscv_debug_unwinder): Likewise.
27 (riscv_debug_gdbarch): Likewise.
28 (enum riscv_register_required_status): Delete.
29 (struct riscv_register_feature): Add constructor, delete default
30 constructor, copy, and assign constructors.
31 (struct riscv_register_feature::register_info) <required>: Delete.
32 <check>: Update comment and arguments.
33 (struct riscv_register_feature) <name>: Change to member function.
34 <prefer_first_name>: Delete.
35 <tdesc_feature>: New member function.
36 <registers>: Rename to...
37 <m_registers>: ...this.
38 <m_feature_name>: New member variable.
39 (riscv_register_feature::register_info::check): Update arguments.
40 (riscv_xreg_feature): Rewrite as class, create a single static
41 instance of the class.
42 (riscv_freg_feature): Likewise.
43 (riscv_virtual_feature): Likewise.
44 (riscv_csr_feature): Likewise.
45 (riscv_create_csr_aliases): Has become a member function inside
46 riscv_csr_feature class.
47 (riscv_abi_embedded): New function definition.
48 (riscv_register_name): Adjust to use new feature objects.
49 (struct riscv_call_info) <riscv_call_info>: Check for rv32e abi,
50 and adjust available argument registers.
51 (riscv_features_from_gdbarch_info): Check for EF_RISCV_RVE flag.
52 (riscv_check_tdesc_feature): Delete.
53 (riscv_tdesc_unknown_reg): Adjust to use new feature objects.
54 (riscv_gdbarch_init): Delete target description checking code, and
55 instead call to the new feature objects to perform the checks.
56 Reorder handling of no abi information case, allows small code
58 (_initialize_riscv_tdep): Remove call, this is now done in the
59 riscv_csr_feature constructor.
60 * riscv-tdep.h (riscv_abi_embedded): Declare.
64 * riscv-tdep.c (riscv_create_csr_aliases): Remove use of
69 * riscv-tdep.c (riscv_is_unknown_csr): New function,
70 implementation moved from riscv_register_reggroup_p.
71 (riscv_register_reggroup_p): Update group handling for unknown
76 * dwarf2/read.c (dwz_search_other_debugdirs): New function.
77 (dwarf2_get_dwz_file): Convert 'filename' to a
78 std::string. Use dwz_search_other_debugdirs to search for DWZ
79 files in the debug-file-directories provided by the user as well.
83 * parse.c (expr_builder::expr_builder): Initialize expout.
84 (expr_builder::release): Use expression::resize.
85 (expression::expression, expression::~expression)
86 (expression::resize): New methods.
87 (write_exp_elt): Use expression::resize.
88 (prefixify_expression): Update.
89 (increase_expout_size): Use expression::resize.
90 * expression.h (struct expression): Add constructor, destructor.
92 (expression_up): Change type.
95 * ppc-linux-nat.c: (PPC_DEBUG_FEATURE_DATA_BP_ARCH_31): New define.
96 (region_ok_for_hw_watchpoint): Check if 2nd DAWR is avaliable before
102 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add and handle
103 is_reference parameter.
104 (dwarf2_evaluate_property): Update dwarf2_locexpr_baton_eval call.
108 * rust-lang.c (rust_op_name): Remove.
109 (exp_descriptor_rust): Update.
110 * parser-defs.h (op_name_standard): Don't declare.
111 (struct exp_descriptor) <op_name>: Remove.
112 * parse.c (exp_descriptor_standard): Update.
113 * opencl-lang.c (exp_descriptor_opencl): Update.
114 * m2-lang.c (m2_language::exp_descriptor_modula2): Update.
115 * f-lang.c (op_name_f): Remove.
116 (f_language::exp_descriptor_tab): Update.
117 * expression.h (op_name): Update.
118 * expprint.c (op_name): Rewrite.
119 (op_name_standard): Remove.
120 (dump_raw_expression, dump_subexp): Update.
121 * c-lang.c (exp_descriptor_c): Update.
122 * ax-gdb.c (gen_expr): Update.
123 * ada-lang.c (ada_op_name): Remove.
124 (ada_exp_descriptor): Update.
128 * eval.c (init_array_element): Remove.
129 (evaluate_subexp_standard) <OP_ARRAY>: Remove "index_pc".
134 * tui/tui-layout.c (tui_apply_current_layout): Don't delete the
135 static locator win info.
139 * acincludde.m4 (GDB_AC_CHECK_BFD): Include string.h in the test
144 * printcmd.c (skip_over_slash_fmt): Reorder code to ensure in_fmt
145 is always initialized.
148 * MAINTAINERS (Write After Approval): Add myself.
152 * features/aarch64-fpu.c (create_feature_aarch64_fpu): Regenerate.
153 * features/aarch64-fpu.xml: Add named FPCR and FPSR register bit-fields.
157 * eval.c (evaluate_subexp_standard): Remove unnecessary
162 * d-lang.c: Include parser-defs.h.
163 * rust-lang.c: Include parser-defs.h.
164 * c-lang.h: Do not include parser-defs.h.
168 * regcache.h (struct cached_reg): Remove typedef.
172 * README: Fix the URL of the MPFR library.
176 * README: Document the --with-libgmp-prefix configure option.
180 * NEWS: Add entry documenting support for DWARF-based fixed
185 * NEWS: Document that building GDB now requires GMP.
189 * typeprint.c (print_type_scalar): Add handling of
190 TYPE_CODE_FIXED_POINT.
194 * valarith.c (fixed_point_binop): Replace the
195 INIT_VAL_WITH_FIXED_POINT_VAL macro by a lambda. Update all
200 * gdbtypes.h (struct type) <fixed_point_scaling_factor>: New method,
201 replacing fixed_point_scaling_factor. All callers updated
202 throughout this project.
203 (fixed_point_scaling_factor): Delete declaration.
204 * gdbtypes.c (type::fixed_point_scaling_factor): Replaces
205 fixed_point_scaling_factor. Adjust implementation accordingly.
209 * gdbtypes.h (struct type) <fixed_point_type_base_type> New method,
210 replacing the fixed_point_type_base_type function. All callers
211 updated throughout this project.
212 (fixed_point_type_base_type): Remove declaration.
213 * gdbtypes.c (type::fixed_point_type_base_type): Replaces
214 fixed_point_type_base_type. Adjust implementation accordingly.
218 * gdbtypes.h (struct type) <fixed_point_info, set_fixed_point_info>:
220 (INIT_FIXED_POINT_SPECIFIC): Adjust.
221 (TYPE_FIXED_POINT_INFO): Delete macro.
222 (allocate_fixed_point_type_info): Change return type to void.
223 * gdbtypes.c (copy_type_recursive): Replace the use of
224 TYPE_FIXED_POINT_INFO by a call to the fixed_point_info method.
225 (fixed_point_scaling_factor): Likewise.
226 (allocate_fixed_point_type_info): Change return type to void.
227 Adjust implementation accordingly.
228 * dwarf2/read.c (finish_fixed_point_type): Replace the use of
229 TYPE_FIXED_POINT_INFO by a call to the fixed_point_info method.
233 * gmp-utils.h (gdb_mpz::read): Change buf and len parameters
234 into one single gdb::array_view parameter.
235 (gdb_mpz::write): Likewise.
236 (gdb_mpq::read_fixed_point, gdb_mpq::write_fixed_point): Likewise.
237 * gmp-utils.c (gdb_mpz::read): Change buf and len parameters
238 into one single gdb::array_view parameter.
239 Adjust implementation accordingly.
240 (gdb_mpz::write): Likewise.
241 (gdb_mpq::read_fixed_point, gdb_mpq::write_fixed_point): Likewise.
242 * unittests/gmp-utils-selftests.c: Adapt following changes above.
243 * valarith.c, valops.c, valprint.c, value.c: Likewise.
247 * gmp-utils.h (gmp_string_printf): Rename from gmp_string_asprintf.
248 Change return type to std::string. Update all callers.
249 * gmp-utils.c (gmp_string_printf): Likewise.
253 * unittests/gmp-utils-selftests.c (write_fp_test): Use mpq_set_si
254 instead of mpq_set_ui to initialize our GMP rational.
258 * debuginfod-support.c (debuginfod_source_query)
259 (debuginfod_debuginfo_query): Only set DESTNAME if successful.
263 * breakpoint.c (watchpoint_exp_is_const): Return bool.
267 * unittests/gmp-utils-selftests.c (gdb_mpz_read_all_from_small):
269 (gdb_mpz_write_all_from_small): Likewise.
273 * dwarf2/read.c (finish_fixed_point_type): Use std::abs instead
278 * ctfread.c (elfctf_build_psymtabs): Use ctf_dict_open, not
279 ctf_arc_open_by_name.
283 * ctfread.c: Change uses of ctf_file_t to ctf_dict_t.
284 (ctf_fp_info::~ctf_fp_info): Call ctf_dict_close, not ctf_file_close.
288 * language.c (language_arch_info::lookup_primitive_type): Use
289 gdb::function_view instead of gdb::function.
290 (template language_lookup_primitive_type): Rename to ...
291 (language_lookup_primitive_type_1): ... this, and make static.
292 (language_lookup_primitive_type(const struct language_defn *,
293 struct gdbarch *, const char *): Make non-template.
294 (language_lookup_primitive_type(const struct language_defn *,
295 struct gdbarch *, std::function<bool (struct type *)>): Make
296 non-template and use gdb::function_view.
297 * language.h (language_arch_info::lookup_primitive_type): Use
298 gdb::function_view instead of std::function.
299 (language_lookup_primitive_type): No longer template.
300 * opencl-lang.c (lookup_opencl_vector_type): 'filter' is now a
301 lambda instead of a std::function.
306 * s390-tdep.c (s390_process_record): Fix recording of STOC, STOCG,
311 * f-lang.c (fortran_value_subarray): Use plongest/pulongest.
315 * gdbarch.sh (read_core_file_mappings): Remove `other` parameter
316 in `loop_cb` parameter.
317 * gdbarch.c: Re-generate.
318 * gdbarch.h: Re-generate.
319 * arch-utils.c (default_read_core_file_mappings): Remove `other`
321 * arch-utils.h (default_read_core_file_mappings): Likewise.
322 * corelow.c (core_target::build_file_mappings): Likewise.
323 * linux-tdep.c (linux_read_core_file_mappings): Likewise.
324 (linux_core_info_proc_mappings): Likewise.
328 * Makefile.in (HFILES_NO_SRCDIR): Add f-array-walker.h.
329 * NEWS: Mention new options.
330 * f-array-walker.h: New file.
331 * f-lang.c: Include 'gdbcmd.h' and 'f-array-walker.h'.
332 (repack_array_slices): New static global.
333 (show_repack_array_slices): New function.
334 (fortran_array_slicing_debug): New static global.
335 (show_fortran_array_slicing_debug): New function.
336 (value_f90_subarray): Delete.
337 (skip_undetermined_arglist): Delete.
338 (class fortran_array_repacker_base_impl): New class.
339 (class fortran_lazy_array_repacker_impl): New class.
340 (class fortran_array_repacker_impl): New class.
341 (fortran_value_subarray): Complete rewrite.
342 (set_fortran_list): New static global.
343 (show_fortran_list): Likewise.
344 (_initialize_f_language): Register new commands.
345 (fortran_adjust_dynamic_array_base_address_hack): New function.
346 * f-lang.h (fortran_adjust_dynamic_array_base_address_hack):
348 * f-valprint.c: Include 'f-array-walker.h'.
349 (class fortran_array_printer_impl): New class.
350 (f77_print_array_1): Delete.
351 (f77_print_array): Delete.
352 (fortran_print_array): New.
353 (f_value_print_inner): Update to call fortran_print_array.
354 * gdbtypes.c: Include 'f-lang.h'.
355 (resolve_dynamic_type_internal): Call
356 fortran_adjust_dynamic_array_base_address_hack.
360 * breakpoint.c (struct watch_options): New struct.
361 (watch_option_defs): New static global.
362 (make_watch_options_def_group): New function.
363 (watch_maybe_just_location): Convert option parsing.
364 (watch_command_completer): New function.
365 (_initialize_breakpoint): Build help text using options mechanism.
369 * breakpoint.c (update_watchpoint): Pass 'false' not '0'.
370 (watch_command_1): Update parameter types. Convert locals to
372 (watch_command_wrapper): Change parameter type.
373 (watch_maybe_just_location): Change locals to bool.
374 (rwatch_command_wrapper): Update parameter type.
375 (awatch_command_wrapper): Update parameter type.
376 * breakpoint.h (watch_command_wrapper): Change parameter type.
377 (rwatch_command_wrapper): Update parameter type.
378 (awatch_command_wrapper): Update parameter type.
379 * eval.c (fetch_subexp_value): Change parameter type.
380 * ppc-linux-nat.c (ppc_linux_nat_target::check_condition): Pass
382 * value.h (fetch_subexp_value): Change parameter type in
387 * printcmd.c (skip_over_slash_fmt): Make use of skip_to_space and
392 * linux-tdep.c (dump_note_entry_p): Return true instead of
397 * debuginfod-support.c (debuginfod_source_query)
398 (debuginfod_debuginfo_query): Also do early exit if
399 "(getenv (DEBUGINFOD_URLS_ENV_VAR))[0] == '\0'".
403 * gdbtypes.c (update_static_array_size): Fix -Werror=bool-compare
408 * gdbtypes.h (get_array_bounds): Return bool, adjust some
409 callers. Move doc here.
410 * gdbtypes.c (get_array_bounds): Return bool
414 * arc-linux-tdep.c (arc_linux_sw_breakpoint_from_kind): Add an
416 * arc-tdep.c (arc_breakpoint_kind_from_pc): Likewise.
417 * disasm-selftests.c (print_one_insn_test): Fall throough from ARC
422 * printcmd.c: Include 'safe-ctype.c'.
423 (skip_over_slash_fmt): New function.
424 (print_command_completer): Call skip_over_slash_fmt.
425 (display_and_x_command_completer): New function.
426 (_initialize_printcmd): Add command completion for 'x' and
431 * frame.c (get_prev_frame): Move get_frame_id call from here ...
432 (get_prev_frame_always_1): ... to here.
433 * inline-frame.c (inline_frame_this_id): Mention
434 get_prev_frame_always_1 in comment.
438 * valarith.c (fixed_point_binop): Add BINOP_EQUAL and BINOP_LESS
440 (value_less): Add fixed-point handling.
444 * eval.c (binop_promote): Add fixed-point type handling.
445 * valarith.c (fixed_point_binop): New function.
446 (scalar_binop): Add fixed-point type handling.
447 (value_neg): Add fixed-point type handling.
448 * valops.c (value_cast_to_fixed_point): New function.
449 (value_cast): Add fixed-point type handling.
453 * ada-typeprint.c (ada_print_type): Add handing of fixed-point
455 * c-typeprint.c (c_type_print_varspec_prefix)
456 (c_type_print_varspec_suffix, c_type_print_base_1): Add
457 TYPE_CODE_FIXED_POINT handling.
458 * p-typeprint.c (pascal_type_print_varspec_prefix)
459 (pascal_type_print_varspec_suffix): Likewise.
460 * typeprint.c (print_type_fixed_point): New function.
461 * typeprint.h (print_type_fixed_point): Add declaration.
465 * printcmd.c (print_scalar_formatted): Add fixed-point type
466 handling when options->format is set.
470 * ada-valprint.c (ada_value_print_1): Add fixed-point type handling.
471 * dwarf2/read.c (get_dwarf2_rational_constant)
472 (get_dwarf2_unsigned_rational_constant, finish_fixed_point_type)
473 (has_zero_over_zero_small_attribute): New functions.
474 read_base_type, set_die_type): Add fixed-point type handling.
475 * gdb-gdb.py.in: Add fixed-point type handling.
476 * gdbtypes.c: #include "gmp-utils.h".
477 (create_range_type, set_type_code): Add fixed-point type handling.
478 (init_fixed_point_type): New function.
479 (is_integral_type, is_scalar_type): Add fixed-point type handling.
480 (print_fixed_point_type_info): New function.
481 (recursive_dump_type, copy_type_recursive): Add fixed-point type
483 (fixed_point_type_storage): New typedef.
484 (fixed_point_objfile_key): New static global.
485 (allocate_fixed_point_type_info, is_fixed_point_type): New functions.
486 (fixed_point_type_base_type, fixed_point_scaling_factor): New
488 * gdbtypes.h: #include "gmp-utils.h".
489 (enum type_code) <TYPE_SPECIFIC_FIXED_POINT>: New enum.
490 (union type_specific) <fixed_point_info>: New field.
491 (struct fixed_point_type_info): New struct.
492 (INIT_FIXED_POINT_SPECIFIC, TYPE_FIXED_POINT_INFO): New macros.
493 (init_fixed_point_type, is_fixed_point_type)
494 (fixed_point_type_base_type, fixed_point_scaling_factor)
495 (allocate_fixed_point_type_info): Add declarations.
496 * valprint.c (generic_val_print_fixed_point): New function.
497 (generic_value_print): Add fixed-point type handling.
498 * value.c (value_as_address, unpack_long): Add fixed-point type
503 * utils.h (uinteger_pow): Add declaration.
504 * utils.c (uinteger_pow): Moved here (without changes)...
505 * valarith.c (uinteger_pow): ... from here.
509 * gmp-utils.h, gmp-utils.c: New file.
510 * unittests/gmp-utils-selftests.c: New file.
511 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
512 unittests/gmp-utils-selftests.c.
513 (COMMON_SFILES) Add gmp-utils.c.
514 (HFILES_NO_SRCDIR): Add gmp-utils.h.
518 * configure.ac: Generate an error if a usable GMP library
520 * configure: Regenerate.
524 * configure.ac: Add support for --with-libgmp-prefix.
525 * Makefile.in (LIBGMP): New variable.
526 (CLIBS): Include $(LIBGMP).
527 * configure, config.in: Regenerate
532 * f-exp.y (COMPLETE): New token.
533 (exp): Two new rules for tab-completion.
534 (saw_name_at_eof): New static global.
535 (last_was_structop): Likewise.
536 (yylex): Set new variables, and return COMPLETE token at the end
537 of the input stream in some cases.
541 * infrun.c (fetch_inferior_event): Use "bool" for should_stop.
545 * opencl-lang.c (opencl_component_ref): Make "comps" const.
549 * arm-tdep.c (class arm_instruction_reader) <read>: Fix comment.
553 * c-lang.c (convert_ucn, convert_octal, convert_hex)
554 (convert_escape, parse_one_string): Constify.
558 https://bugzilla.redhat.com/show_bug.cgi?id=1553086
559 * elfread.c (elf_symfile_segments): Omit "Loadable section ...
560 outside of ELF segments" warning for debugin
565 * elfread.c (elf_symfile_segments): Output a BFD file name
566 for the "Loadable section ... outside of ELF segments" warning.
571 * arm-tdep.c (class arm_instruction_reader): New.
572 (target_arm_instruction_reader): New.
573 (arm_analyze_prologue): Add instruction reader parameter and use
574 it. Use arm_expand_immediate.
575 (class target_arm_instruction_reader): Adjust.
576 (arm_skip_prologue): Adjust.
577 (arm_expand_immediate): New.
578 (arm_scan_prologue): Adjust.
579 (arm_analyze_prologue_test): New.
580 (class test_arm_instruction_reader): New.
584 * f-lang.c (fortran_argument_convert): Add declaration. Add
585 header comment, taken from f-lang.h. Make static.
586 * f-lang.h (f77_get_dynamic_array_length): Delete declaration.
587 (fortran_argument_convert): Delete declaration.
591 * ada-exp.y (find_primitive_type): Make parameter const.
592 * ada-lang.c (enum ada_primitive_types): Delete.
593 (ada_language::language_arch_info): Update.
594 * c-lang.c (enum c_primitive_types): Delete.
595 (c_language_arch_info): Update.
596 (enum cplus_primitive_types): Delete.
597 (cplus_language::language_arch_info): Update.
598 * d-lang.c (enum d_primitive_types): Delete.
599 (d_language::language_arch_info): Update.
600 * f-lang.c (enum f_primitive_types): Delete.
601 (f_language::language_arch_info): Update.
602 * go-lang.c (enum go_primitive_types): Delete.
603 (go_language::language_arch_info): Update.
604 * language.c (auto_or_unknown_language::language_arch_info):
606 (language_gdbarch_post_init): Use obstack_new, use array indexing.
607 (language_string_char_type): Add header comment, call function in
609 (language_bool_type): Likewise
610 (language_arch_info::bool_type): Define.
611 (language_lookup_primitive_type_1): Delete.
612 (language_lookup_primitive_type): Rewrite as a templated function
613 to call function in language_arch_info, then instantiate twice.
614 (language_arch_info::type_and_symbol::alloc_type_symbol): Define.
615 (language_arch_info::lookup_primitive_type_and_symbol): Define.
616 (language_arch_info::lookup_primitive_type): Define twice with
617 different signatures.
618 (language_arch_info::lookup_primitive_type_as_symbol): Define.
619 (language_lookup_primitive_type_as_symbol): Rewrite to call a
620 member function in language_arch_info.
621 * language.h (language_arch_info): Complete rewrite.
622 (language_lookup_primitive_type): Make templated.
623 * m2-lang.c (enum m2_primitive_types): Delete.
624 (m2_language::language_arch_info): Update.
625 * opencl-lang.c (OCL_P_TYPE): Delete.
626 (enum opencl_primitive_types): Delete.
627 (opencl_type_data): Delete.
628 (builtin_opencl_type): Delete.
629 (lookup_opencl_vector_type): Update.
630 (opencl_language::language_arch_info): Update, lots of content
632 (build_opencl_types): ...here. This function is now deleted.
633 (_initialize_opencl_language): Delete.
634 * p-lang.c (enum pascal_primitive_types): Delete.
635 (pascal_language::language_arch_info): Update.
636 * rust-lang.c (enum rust_primitive_types): Delete.
637 (rust_language::language_arch_info): Update.
641 * dwarf2/read.c (dw2_do_instantiate_symtab): Fix call to
646 * dwarf2/read.c (dw2_do_instantiate_symtab): Fix typo in
651 * dwarf2/read.c (dwarf_read_debug_printf,
652 dwarf_read_debug_printf_v): New macros, use throughout the file.
656 * arc-linux-tdep.c (collect_register): Populate "eret" by
657 "pc" value from the regcache when asked for "pc" value.
662 * symtab.c (find_symbol_at_address): Search symtabs if no psymtabs
667 * features/Makefile (XMLTOC): Add rx.xml.
668 (FEATURE_XMLFILES): Remove rx.xml.
669 (FEATURE_CFILES rule): Pass '-single-feature' flag.
670 * features/rx.c: Regenerate.
671 * features/rx.xml: Wrap in `target` tags, and reindent.
672 * target-descriptions.c (struct maint_print_c_tdesc_options): New
674 (maint_print_c_tdesc_opt_def): New typedef.
675 (maint_print_c_tdesc_opt_defs): New static global.
676 (make_maint_print_c_tdesc_options_def_group): New function.
677 (maint_print_c_tdesc_cmd): Make use of command line flags, only
678 print single feature C file for target descriptions containing a
680 (maint_print_c_tdesc_cmd_completer): New function.
681 (_initialize_target_descriptions): Update call to register command
682 completer, and include command line flag in help text.
686 * riscv-tdep.c (riscv_dwarf_reg_to_regnum): Decode DWARF CSR
688 * riscv-tdep.h (RISCV_DWARF_FIRST_CSR, RISCV_DWARF_LAST_CSR): New
693 * value.h (internalvar_name): Update.
694 * value.c (internalvar_name): Make return type const.
698 * ax-gdb.c (gen_struct_elt_for_reference, gen_namespace_elt)
699 (gen_maybe_namespace_elt, gen_aggregate_elt_ref, gen_expr): Use
704 * objc-lang.h (value_nsstring): Update.
705 * objc-lang.c (value_nsstring): Make "ptr" const.
709 * expprint.c (print_subexp_funcall): Increment expression position
710 after reading argument count.
711 * f-lang.c (print_subexp_f): Skip over opcode before calling
713 (dump_subexp_body_f): Likewise.
718 * configure: Regenerate.
719 * configure.ac: Check for python modules ctypes instead of
724 * macroexp.c (struct macro_buffer): Split in two classes. Add
726 (struct shared_macro_buffer): New, factored out from struct
728 (struct growable_macro_buffer): New, factored out from struct
730 (set_token, get_comment, get_identifier, get_pp_number)
731 (get_character_constant, get_string_literal, get_punctuator)
732 (get_next_token_for_substitution): Constify parameters.
733 (substitute_args): Constify locals.
737 * dwarf2/read.c (read_cutu_die_from_dwo)
738 (cutu_reader::cutu_reader, cutu_reader::cutu_reader)
739 (build_type_psymtabs_1): Update.
740 * dwarf2/abbrev.h (struct abbrev_table): Remove objfile
742 * dwarf2/abbrev.c (abbrev_table::read): Remove objfile parameter.
743 Don't read section. Add assert.
747 * ada-typeprint.c (ada_print_type): Handle __XVL fields.
751 * ada-typeprint.c (ada_print_type): Handle __T types.
755 * dwarf2/read.c (add_partial_symbol, process_die):
756 Handle DW_TAG_array_type.
757 (is_type_tag_for_partial): Add "lang" parameter.
758 (load_partial_dies, new_symbol): Handle DW_TAG_array_type.
762 * ada-lang.c (ada_value_slice_from_ptr): Use bit size.
766 * dwarf2/read.c (read_array_type): Only apply stride to innermost
771 * gdbtypes.c (update_static_array_size): Handle bit stride.
775 * ada-lang.c (ada_value_struct_elt): Resolve dynamic type.
779 * ada-lang.c (ada_is_any_packed_array_type): New function.
780 (ada_evaluate_subexp) <case TERNOP_SLICE>: Use it.
784 * dwarf2/read.c (recognize_bound_expression)
785 (quirk_ada_thick_pointer): New functions.
786 (read_array_type): Call quirk_ada_thick_pointer.
787 (set_die_type): Add "skip_data_location" parameter.
788 (quirk_ada_thick_pointer): New function.
789 (process_structure_scope): Call quirk_ada_thick_pointer.
790 * ada-lang.c (ada_is_unconstrained_packed_array_type)
791 (decode_packed_array_bitsize): Handle thick pointers without
793 (ada_is_gnat_encoded_packed_array_type): Rename from
794 ada_is_packed_array_type.
795 (ada_is_constrained_packed_array_type): Update.
796 * ada-valprint.c (ada_val_print_gnat_array): Remove.
797 (ada_value_print_1): Use ada_get_decoded_value.
801 * ada-lang.c (recursively_update_array_bitsize): New function.
802 (decode_constrained_packed_array_type): Call it.
806 * ada-lang.c (to_fixed_array_type): Error if
807 decode_constrained_packed_array_type returns NULL.
811 * dwarf2/leb.h (read_3_bytes): Use bfd_get_24.
815 * Makefile.in (ALL_64_TARGET_OBS): Add amd64-ravenscar-thread.o.
816 (ALLDEPFILES): Add amd64-ravenscar-thread.c.
817 (HFILES_NO_SRCDIR): Add amd64-ravenscar-thread.h.
818 * amd64-ravenscar-thread.c: New file.
819 * amd64-ravenscar-thread.h: New file.
820 * amd64-tdep.c (amd64_init_abi): Register ravenscar ops.
821 * configure.tgt (amd64_tobjs): Add ravenscar objects.
825 * main.c (execute_cmdargs): New function.
826 (captured_main_1): Make use of execute_cmdargs.
830 * NEWS: Mention changes to config file search path.
835 * python/python.c: Consolidate two HAVE_PYTHON blocks.
836 (python_GdbModuleDef): Move earlier. Now static.
837 (do_start_initialization): Consolidate some IS_PY3K blocks.
841 * aarch64-linux-tdep.c: Fix indentation.
842 * aarch64-ravenscar-thread.c: Fix indentation.
843 * aarch64-tdep.c: Fix indentation.
844 * aarch64-tdep.h: Fix indentation.
845 * ada-lang.c: Fix indentation.
846 * ada-lang.h: Fix indentation.
847 * ada-tasks.c: Fix indentation.
848 * ada-typeprint.c: Fix indentation.
849 * ada-valprint.c: Fix indentation.
850 * ada-varobj.c: Fix indentation.
851 * addrmap.c: Fix indentation.
852 * addrmap.h: Fix indentation.
853 * agent.c: Fix indentation.
854 * aix-thread.c: Fix indentation.
855 * alpha-bsd-nat.c: Fix indentation.
856 * alpha-linux-tdep.c: Fix indentation.
857 * alpha-mdebug-tdep.c: Fix indentation.
858 * alpha-nbsd-tdep.c: Fix indentation.
859 * alpha-obsd-tdep.c: Fix indentation.
860 * alpha-tdep.c: Fix indentation.
861 * amd64-bsd-nat.c: Fix indentation.
862 * amd64-darwin-tdep.c: Fix indentation.
863 * amd64-linux-nat.c: Fix indentation.
864 * amd64-linux-tdep.c: Fix indentation.
865 * amd64-nat.c: Fix indentation.
866 * amd64-obsd-tdep.c: Fix indentation.
867 * amd64-tdep.c: Fix indentation.
868 * amd64-windows-tdep.c: Fix indentation.
869 * annotate.c: Fix indentation.
870 * arc-tdep.c: Fix indentation.
871 * arch-utils.c: Fix indentation.
872 * arch/arm-get-next-pcs.c: Fix indentation.
873 * arch/arm.c: Fix indentation.
874 * arm-linux-nat.c: Fix indentation.
875 * arm-linux-tdep.c: Fix indentation.
876 * arm-nbsd-tdep.c: Fix indentation.
877 * arm-pikeos-tdep.c: Fix indentation.
878 * arm-tdep.c: Fix indentation.
879 * arm-tdep.h: Fix indentation.
880 * arm-wince-tdep.c: Fix indentation.
881 * auto-load.c: Fix indentation.
882 * auxv.c: Fix indentation.
883 * avr-tdep.c: Fix indentation.
884 * ax-gdb.c: Fix indentation.
885 * ax-general.c: Fix indentation.
886 * bfin-linux-tdep.c: Fix indentation.
887 * block.c: Fix indentation.
888 * block.h: Fix indentation.
889 * blockframe.c: Fix indentation.
890 * bpf-tdep.c: Fix indentation.
891 * break-catch-sig.c: Fix indentation.
892 * break-catch-syscall.c: Fix indentation.
893 * break-catch-throw.c: Fix indentation.
894 * breakpoint.c: Fix indentation.
895 * breakpoint.h: Fix indentation.
896 * bsd-uthread.c: Fix indentation.
897 * btrace.c: Fix indentation.
898 * build-id.c: Fix indentation.
899 * buildsym-legacy.h: Fix indentation.
900 * buildsym.c: Fix indentation.
901 * c-typeprint.c: Fix indentation.
902 * c-valprint.c: Fix indentation.
903 * c-varobj.c: Fix indentation.
904 * charset.c: Fix indentation.
905 * cli/cli-cmds.c: Fix indentation.
906 * cli/cli-decode.c: Fix indentation.
907 * cli/cli-decode.h: Fix indentation.
908 * cli/cli-script.c: Fix indentation.
909 * cli/cli-setshow.c: Fix indentation.
910 * coff-pe-read.c: Fix indentation.
911 * coffread.c: Fix indentation.
912 * compile/compile-cplus-types.c: Fix indentation.
913 * compile/compile-object-load.c: Fix indentation.
914 * compile/compile-object-run.c: Fix indentation.
915 * completer.c: Fix indentation.
916 * corefile.c: Fix indentation.
917 * corelow.c: Fix indentation.
918 * cp-abi.h: Fix indentation.
919 * cp-namespace.c: Fix indentation.
920 * cp-support.c: Fix indentation.
921 * cp-valprint.c: Fix indentation.
922 * cris-linux-tdep.c: Fix indentation.
923 * cris-tdep.c: Fix indentation.
924 * darwin-nat-info.c: Fix indentation.
925 * darwin-nat.c: Fix indentation.
926 * darwin-nat.h: Fix indentation.
927 * dbxread.c: Fix indentation.
928 * dcache.c: Fix indentation.
929 * disasm.c: Fix indentation.
930 * dtrace-probe.c: Fix indentation.
931 * dwarf2/abbrev.c: Fix indentation.
932 * dwarf2/attribute.c: Fix indentation.
933 * dwarf2/expr.c: Fix indentation.
934 * dwarf2/frame.c: Fix indentation.
935 * dwarf2/index-cache.c: Fix indentation.
936 * dwarf2/index-write.c: Fix indentation.
937 * dwarf2/line-header.c: Fix indentation.
938 * dwarf2/loc.c: Fix indentation.
939 * dwarf2/macro.c: Fix indentation.
940 * dwarf2/read.c: Fix indentation.
941 * dwarf2/read.h: Fix indentation.
942 * elfread.c: Fix indentation.
943 * eval.c: Fix indentation.
944 * event-top.c: Fix indentation.
945 * exec.c: Fix indentation.
946 * exec.h: Fix indentation.
947 * expprint.c: Fix indentation.
948 * f-lang.c: Fix indentation.
949 * f-typeprint.c: Fix indentation.
950 * f-valprint.c: Fix indentation.
951 * fbsd-nat.c: Fix indentation.
952 * fbsd-tdep.c: Fix indentation.
953 * findvar.c: Fix indentation.
954 * fork-child.c: Fix indentation.
955 * frame-unwind.c: Fix indentation.
956 * frame-unwind.h: Fix indentation.
957 * frame.c: Fix indentation.
958 * frv-linux-tdep.c: Fix indentation.
959 * frv-tdep.c: Fix indentation.
960 * frv-tdep.h: Fix indentation.
961 * ft32-tdep.c: Fix indentation.
962 * gcore.c: Fix indentation.
963 * gdb_bfd.c: Fix indentation.
964 * gdbarch.sh: Fix indentation.
965 * gdbarch.c: Re-generate
966 * gdbarch.h: Re-generate.
967 * gdbcore.h: Fix indentation.
968 * gdbthread.h: Fix indentation.
969 * gdbtypes.c: Fix indentation.
970 * gdbtypes.h: Fix indentation.
971 * glibc-tdep.c: Fix indentation.
972 * gnu-nat.c: Fix indentation.
973 * gnu-nat.h: Fix indentation.
974 * gnu-v2-abi.c: Fix indentation.
975 * gnu-v3-abi.c: Fix indentation.
976 * go32-nat.c: Fix indentation.
977 * guile/guile-internal.h: Fix indentation.
978 * guile/scm-cmd.c: Fix indentation.
979 * guile/scm-frame.c: Fix indentation.
980 * guile/scm-iterator.c: Fix indentation.
981 * guile/scm-math.c: Fix indentation.
982 * guile/scm-ports.c: Fix indentation.
983 * guile/scm-pretty-print.c: Fix indentation.
984 * guile/scm-value.c: Fix indentation.
985 * h8300-tdep.c: Fix indentation.
986 * hppa-linux-nat.c: Fix indentation.
987 * hppa-linux-tdep.c: Fix indentation.
988 * hppa-nbsd-nat.c: Fix indentation.
989 * hppa-nbsd-tdep.c: Fix indentation.
990 * hppa-obsd-nat.c: Fix indentation.
991 * hppa-tdep.c: Fix indentation.
992 * hppa-tdep.h: Fix indentation.
993 * i386-bsd-nat.c: Fix indentation.
994 * i386-darwin-nat.c: Fix indentation.
995 * i386-darwin-tdep.c: Fix indentation.
996 * i386-dicos-tdep.c: Fix indentation.
997 * i386-gnu-nat.c: Fix indentation.
998 * i386-linux-nat.c: Fix indentation.
999 * i386-linux-tdep.c: Fix indentation.
1000 * i386-nto-tdep.c: Fix indentation.
1001 * i386-obsd-tdep.c: Fix indentation.
1002 * i386-sol2-nat.c: Fix indentation.
1003 * i386-tdep.c: Fix indentation.
1004 * i386-tdep.h: Fix indentation.
1005 * i386-windows-tdep.c: Fix indentation.
1006 * i387-tdep.c: Fix indentation.
1007 * i387-tdep.h: Fix indentation.
1008 * ia64-libunwind-tdep.c: Fix indentation.
1009 * ia64-libunwind-tdep.h: Fix indentation.
1010 * ia64-linux-nat.c: Fix indentation.
1011 * ia64-linux-tdep.c: Fix indentation.
1012 * ia64-tdep.c: Fix indentation.
1013 * ia64-tdep.h: Fix indentation.
1014 * ia64-vms-tdep.c: Fix indentation.
1015 * infcall.c: Fix indentation.
1016 * infcmd.c: Fix indentation.
1017 * inferior.c: Fix indentation.
1018 * infrun.c: Fix indentation.
1019 * iq2000-tdep.c: Fix indentation.
1020 * language.c: Fix indentation.
1021 * linespec.c: Fix indentation.
1022 * linux-fork.c: Fix indentation.
1023 * linux-nat.c: Fix indentation.
1024 * linux-tdep.c: Fix indentation.
1025 * linux-thread-db.c: Fix indentation.
1026 * lm32-tdep.c: Fix indentation.
1027 * m2-lang.c: Fix indentation.
1028 * m2-typeprint.c: Fix indentation.
1029 * m2-valprint.c: Fix indentation.
1030 * m32c-tdep.c: Fix indentation.
1031 * m32r-linux-tdep.c: Fix indentation.
1032 * m32r-tdep.c: Fix indentation.
1033 * m68hc11-tdep.c: Fix indentation.
1034 * m68k-bsd-nat.c: Fix indentation.
1035 * m68k-linux-nat.c: Fix indentation.
1036 * m68k-linux-tdep.c: Fix indentation.
1037 * m68k-tdep.c: Fix indentation.
1038 * machoread.c: Fix indentation.
1039 * macrocmd.c: Fix indentation.
1040 * macroexp.c: Fix indentation.
1041 * macroscope.c: Fix indentation.
1042 * macrotab.c: Fix indentation.
1043 * macrotab.h: Fix indentation.
1044 * main.c: Fix indentation.
1045 * mdebugread.c: Fix indentation.
1046 * mep-tdep.c: Fix indentation.
1047 * mi/mi-cmd-catch.c: Fix indentation.
1048 * mi/mi-cmd-disas.c: Fix indentation.
1049 * mi/mi-cmd-env.c: Fix indentation.
1050 * mi/mi-cmd-stack.c: Fix indentation.
1051 * mi/mi-cmd-var.c: Fix indentation.
1052 * mi/mi-cmds.c: Fix indentation.
1053 * mi/mi-main.c: Fix indentation.
1054 * mi/mi-parse.c: Fix indentation.
1055 * microblaze-tdep.c: Fix indentation.
1056 * minidebug.c: Fix indentation.
1057 * minsyms.c: Fix indentation.
1058 * mips-linux-nat.c: Fix indentation.
1059 * mips-linux-tdep.c: Fix indentation.
1060 * mips-nbsd-tdep.c: Fix indentation.
1061 * mips-tdep.c: Fix indentation.
1062 * mn10300-linux-tdep.c: Fix indentation.
1063 * mn10300-tdep.c: Fix indentation.
1064 * moxie-tdep.c: Fix indentation.
1065 * msp430-tdep.c: Fix indentation.
1066 * namespace.h: Fix indentation.
1067 * nat/fork-inferior.c: Fix indentation.
1068 * nat/gdb_ptrace.h: Fix indentation.
1069 * nat/linux-namespaces.c: Fix indentation.
1070 * nat/linux-osdata.c: Fix indentation.
1071 * nat/netbsd-nat.c: Fix indentation.
1072 * nat/x86-dregs.c: Fix indentation.
1073 * nbsd-nat.c: Fix indentation.
1074 * nbsd-tdep.c: Fix indentation.
1075 * nios2-linux-tdep.c: Fix indentation.
1076 * nios2-tdep.c: Fix indentation.
1077 * nto-procfs.c: Fix indentation.
1078 * nto-tdep.c: Fix indentation.
1079 * objfiles.c: Fix indentation.
1080 * objfiles.h: Fix indentation.
1081 * opencl-lang.c: Fix indentation.
1082 * or1k-tdep.c: Fix indentation.
1083 * osabi.c: Fix indentation.
1084 * osabi.h: Fix indentation.
1085 * osdata.c: Fix indentation.
1086 * p-lang.c: Fix indentation.
1087 * p-typeprint.c: Fix indentation.
1088 * p-valprint.c: Fix indentation.
1089 * parse.c: Fix indentation.
1090 * ppc-linux-nat.c: Fix indentation.
1091 * ppc-linux-tdep.c: Fix indentation.
1092 * ppc-nbsd-nat.c: Fix indentation.
1093 * ppc-nbsd-tdep.c: Fix indentation.
1094 * ppc-obsd-nat.c: Fix indentation.
1095 * ppc-ravenscar-thread.c: Fix indentation.
1096 * ppc-sysv-tdep.c: Fix indentation.
1097 * ppc64-tdep.c: Fix indentation.
1098 * printcmd.c: Fix indentation.
1099 * proc-api.c: Fix indentation.
1100 * producer.c: Fix indentation.
1101 * producer.h: Fix indentation.
1102 * prologue-value.c: Fix indentation.
1103 * prologue-value.h: Fix indentation.
1104 * psymtab.c: Fix indentation.
1105 * python/py-arch.c: Fix indentation.
1106 * python/py-bpevent.c: Fix indentation.
1107 * python/py-event.c: Fix indentation.
1108 * python/py-event.h: Fix indentation.
1109 * python/py-finishbreakpoint.c: Fix indentation.
1110 * python/py-frame.c: Fix indentation.
1111 * python/py-framefilter.c: Fix indentation.
1112 * python/py-inferior.c: Fix indentation.
1113 * python/py-infthread.c: Fix indentation.
1114 * python/py-objfile.c: Fix indentation.
1115 * python/py-prettyprint.c: Fix indentation.
1116 * python/py-registers.c: Fix indentation.
1117 * python/py-signalevent.c: Fix indentation.
1118 * python/py-stopevent.c: Fix indentation.
1119 * python/py-stopevent.h: Fix indentation.
1120 * python/py-threadevent.c: Fix indentation.
1121 * python/py-tui.c: Fix indentation.
1122 * python/py-unwind.c: Fix indentation.
1123 * python/py-value.c: Fix indentation.
1124 * python/py-xmethods.c: Fix indentation.
1125 * python/python-internal.h: Fix indentation.
1126 * python/python.c: Fix indentation.
1127 * ravenscar-thread.c: Fix indentation.
1128 * record-btrace.c: Fix indentation.
1129 * record-full.c: Fix indentation.
1130 * record.c: Fix indentation.
1131 * reggroups.c: Fix indentation.
1132 * regset.h: Fix indentation.
1133 * remote-fileio.c: Fix indentation.
1134 * remote.c: Fix indentation.
1135 * reverse.c: Fix indentation.
1136 * riscv-linux-tdep.c: Fix indentation.
1137 * riscv-ravenscar-thread.c: Fix indentation.
1138 * riscv-tdep.c: Fix indentation.
1139 * rl78-tdep.c: Fix indentation.
1140 * rs6000-aix-tdep.c: Fix indentation.
1141 * rs6000-lynx178-tdep.c: Fix indentation.
1142 * rs6000-nat.c: Fix indentation.
1143 * rs6000-tdep.c: Fix indentation.
1144 * rust-lang.c: Fix indentation.
1145 * rx-tdep.c: Fix indentation.
1146 * s12z-tdep.c: Fix indentation.
1147 * s390-linux-tdep.c: Fix indentation.
1148 * score-tdep.c: Fix indentation.
1149 * ser-base.c: Fix indentation.
1150 * ser-mingw.c: Fix indentation.
1151 * ser-uds.c: Fix indentation.
1152 * ser-unix.c: Fix indentation.
1153 * serial.c: Fix indentation.
1154 * sh-linux-tdep.c: Fix indentation.
1155 * sh-nbsd-tdep.c: Fix indentation.
1156 * sh-tdep.c: Fix indentation.
1157 * skip.c: Fix indentation.
1158 * sol-thread.c: Fix indentation.
1159 * solib-aix.c: Fix indentation.
1160 * solib-darwin.c: Fix indentation.
1161 * solib-frv.c: Fix indentation.
1162 * solib-svr4.c: Fix indentation.
1163 * solib.c: Fix indentation.
1164 * source.c: Fix indentation.
1165 * sparc-linux-tdep.c: Fix indentation.
1166 * sparc-nbsd-tdep.c: Fix indentation.
1167 * sparc-obsd-tdep.c: Fix indentation.
1168 * sparc-ravenscar-thread.c: Fix indentation.
1169 * sparc-tdep.c: Fix indentation.
1170 * sparc64-linux-tdep.c: Fix indentation.
1171 * sparc64-nbsd-tdep.c: Fix indentation.
1172 * sparc64-obsd-tdep.c: Fix indentation.
1173 * sparc64-tdep.c: Fix indentation.
1174 * stabsread.c: Fix indentation.
1175 * stack.c: Fix indentation.
1176 * stap-probe.c: Fix indentation.
1177 * stubs/ia64vms-stub.c: Fix indentation.
1178 * stubs/m32r-stub.c: Fix indentation.
1179 * stubs/m68k-stub.c: Fix indentation.
1180 * stubs/sh-stub.c: Fix indentation.
1181 * stubs/sparc-stub.c: Fix indentation.
1182 * symfile-mem.c: Fix indentation.
1183 * symfile.c: Fix indentation.
1184 * symfile.h: Fix indentation.
1185 * symmisc.c: Fix indentation.
1186 * symtab.c: Fix indentation.
1187 * symtab.h: Fix indentation.
1188 * target-float.c: Fix indentation.
1189 * target.c: Fix indentation.
1190 * target.h: Fix indentation.
1191 * tic6x-tdep.c: Fix indentation.
1192 * tilegx-linux-tdep.c: Fix indentation.
1193 * tilegx-tdep.c: Fix indentation.
1194 * top.c: Fix indentation.
1195 * tracefile-tfile.c: Fix indentation.
1196 * tracepoint.c: Fix indentation.
1197 * tui/tui-disasm.c: Fix indentation.
1198 * tui/tui-io.c: Fix indentation.
1199 * tui/tui-regs.c: Fix indentation.
1200 * tui/tui-stack.c: Fix indentation.
1201 * tui/tui-win.c: Fix indentation.
1202 * tui/tui-winsource.c: Fix indentation.
1203 * tui/tui.c: Fix indentation.
1204 * typeprint.c: Fix indentation.
1205 * ui-out.h: Fix indentation.
1206 * unittests/copy_bitwise-selftests.c: Fix indentation.
1207 * unittests/memory-map-selftests.c: Fix indentation.
1208 * utils.c: Fix indentation.
1209 * v850-tdep.c: Fix indentation.
1210 * valarith.c: Fix indentation.
1211 * valops.c: Fix indentation.
1212 * valprint.c: Fix indentation.
1213 * valprint.h: Fix indentation.
1214 * value.c: Fix indentation.
1215 * value.h: Fix indentation.
1216 * varobj.c: Fix indentation.
1217 * vax-tdep.c: Fix indentation.
1218 * windows-nat.c: Fix indentation.
1219 * windows-tdep.c: Fix indentation.
1220 * xcoffread.c: Fix indentation.
1221 * xml-syscall.c: Fix indentation.
1222 * xml-tdesc.c: Fix indentation.
1223 * xstormy16-tdep.c: Fix indentation.
1224 * xtensa-config.c: Fix indentation.
1225 * xtensa-linux-nat.c: Fix indentation.
1226 * xtensa-linux-tdep.c: Fix indentation.
1227 * xtensa-tdep.c: Fix indentation.
1232 * riscv-tdep.c (riscv_frame_cache): Read the frame base register
1233 as an unsigned value.
1237 * dbxread.c (dbx_end_psymtab): Update.
1238 * dwarf2/read.c (process_psymtab_comp_unit_reader)
1239 (build_type_psymtabs_reader): Update.
1240 * xcoffread.c (xcoff_end_psymtab): Update.
1241 * ctfread.c (scan_partial_symbols): Update.
1242 * psymtab.c (sort_pst_symbols): Remove.
1243 (partial_symtab::end): Rename from end_psymtab_common. Inline
1245 * psympriv.h (struct partial_symtab) <end>: New method.
1246 (end_psymtab_common): Don't declare.
1250 * symmisc.c (count_psyms): New function.
1251 (print_objfile_statistics): Use it.
1252 * psymtab.c (append_psymbol_to_list): Remove.
1253 (partial_symtab::add_psymbol): Inline append_psymbol_to_list.
1254 * objfiles.h (struct objstats) <n_psyms>: Remove.
1258 * dbxread.c (dbx_end_psymtab): Update.
1259 * dwarf2/read.c (process_psymtab_comp_unit_reader): Update.
1260 (build_type_psymtabs_reader): Update.
1261 * xcoffread.c (xcoff_end_psymtab): Update.
1262 * ctfread.c (scan_partial_symbols): Update.
1263 * psympriv.h (end_psymtab_common): Update.
1264 * psymtab.c (end_psymtab_common): Remove objfile parameter.
1265 (sort_pst_symbols): Likewise.
1269 * dbxread.c (dbx_symfile_read): Update.
1270 * dwarf2/read.c (dwarf2_build_psymtabs): Update.
1271 * xcoffread.c (xcoff_initial_scan): Update.
1272 * psympriv.h (init_psymbol_list): Don't declare.
1273 * psymtab.c (init_psymbol_list): Remove.
1277 * ada-lang.c (gnat_encoded_fixed_point_type_info): Renames
1278 gnat_encoded_fixed_type_info. Update all callers.
1282 * ada-lang.c (cast_from_gnat_encoded_fixed_point_type): Split
1287 * ada-lang.c (cast_from_gnat_encoded_fixed_point_type): Renames
1288 cast_from_fixed. Update all callers.
1289 (cast_to_gnat_encoded_fixed_point_type): Renames cast_to_fixed.
1291 (gnat_encoded_fixed_point_scaling_factor): Renames ada_scaling_factor.
1293 * ada-lang.h (gnat_encoded_fixed_point_scaling_factor): Renames
1295 * ada-typeprint.c: Replace call to ada_scaling_factor by call
1296 to print_gnat_encoded_fixed_point_type.
1297 * ada-valprint.c: Likewise.
1301 * infrun.h (infrun_debug_printf): Add check of debug_infrun flag.
1302 (debug_prefixed_printf): Add check of debug_displaced flag.
1303 * linux-nat.c (linux_nat_debug_printf): Add check of
1304 debug_linux_nat flag.
1308 * infrun.c (infrun_debug_printf_1): Remove.
1309 (displaced_debug_printf_1): Remove.
1310 (stop_all_threads): Use debug_prefixed_printf.
1311 * infrun.h (infrun_debug_printf_1): Remove.
1312 (infrun_debug_printf): Use debug_prefixed_printf.
1313 (displaced_debug_printf_1): Remove.
1314 (displaced_debug_printf): Use debug_prefixed_printf.
1315 * linux-nat.c (linux_nat_debug_printf_1): Remove.
1316 (linux_nat_debug_printf): Use debug_prefixed_printf.
1320 * configure: Re-generate.
1321 * sanitize.m4: Replace AC_TRY_LINK with AC_LINK_IFELSE +
1326 * configure: Re-generate.
1330 * configure: Re-generate.
1334 * configure: Re-generate.
1338 * configure: Re-generate.
1342 * acinclude.m4: Modernize.
1343 * configure: Re-generate.
1347 * configure.ac: Modernize.
1348 * configure: Re-generate.
1352 * acinclude.m4 (AM_PROG_CC_STDC): Remove.
1353 * configure: Re-generate.
1354 * configure.ac: Remove AM_PROG_CC_STDC.
1358 * configure.ac: Use AC_CANONICAL_{BUILD,HOST,TARGET} instead of
1359 AC_CANONICAL_SYSTEM.
1360 * configure: Re-generate.
1364 * infrun.h (displaced_debug_printf): New macro. Replace
1365 displaced debug prints throughout to use it.
1366 (displaced_debug_printf_1): New declaration.
1367 (displaced_step_dump_bytes): Return string, remove ui_file
1368 parameter, update all callers.
1369 * infrun.c (displaced_debug_printf_1): New function.
1370 (displaced_step_dump_bytes): Return string, remove ui_file
1375 * rs6000-tdep.c (rs6000_dwarf2_reg_to_regnum): Return -1 for
1379 * Makefile.in (stamp-init): Depend on config.status.
1383 * infrun.c (fetch_inferior_event): Temporarily disable pagination.
1387 * thread.c (lookup_selected_frame): Move ...
1388 * frame.c (lookup_selected_frame): ... here.
1392 * blockframe.c (block_innermost_frame): Use get_selected_frame.
1394 (scoped_restore_selected_frame::scoped_restore_selected_frame):
1395 Use save_selected_frame. Save language as well.
1396 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
1397 Use restore_selected_frame, and restore language as well.
1398 (selected_frame_id, selected_frame_level): New.
1399 (selected_frame): Update comments.
1400 (save_selected_frame, restore_selected_frame): New.
1401 (get_selected_frame): Use lookup_selected_frame.
1402 (get_selected_frame_if_set): Delete.
1403 (select_frame): Record selected_frame_level and selected_frame_id.
1404 * frame.h (scoped_restore_selected_frame) <m_level, m_lang>: New
1406 (get_selected_frame): Make 'message' parameter optional.
1407 (get_selected_frame_if_set): Delete declaration.
1408 (select_frame): Update comments.
1409 (save_selected_frame, restore_selected_frame)
1410 (lookup_selected_frame): Declare.
1411 * gdbthread.h (scoped_restore_current_thread) <m_lang>: New field.
1412 * infrun.c (struct infcall_control_state) <selected_frame_level>:
1414 (save_infcall_control_state): Use save_selected_frame.
1415 (restore_selected_frame): Delete.
1416 (restore_infcall_control_state): Use restore_selected_frame.
1417 * stack.c (select_frame_command_core, frame_command_core): Use
1419 * thread.c (restore_selected_frame): Rename to ...
1420 (lookup_selected_frame): ... this and make extern. Select the
1421 current frame if the frame level is -1.
1422 (scoped_restore_current_thread::restore): Also restore the
1424 (scoped_restore_current_thread::~scoped_restore_current_thread):
1426 (scoped_restore_current_thread::scoped_restore_current_thread):
1427 Save the language as well. Use save_selected_frame.
1431 * gdbarch.sh (displaced_step_hw_singlestep): Adjust
1433 * gdbarch.h: Re-generate.
1437 * gdbarch.sh (displaced_step_hw_singlestep): Remove closure
1439 * aarch64-tdep.c (aarch64_displaced_step_hw_singlestep):
1441 * aarch64-tdep.h (aarch64_displaced_step_hw_singlestep):
1443 * arch-utils.c (default_displaced_step_hw_singlestep):
1445 * arch-utils.h (default_displaced_step_hw_singlestep):
1447 * rs6000-tdep.c (ppc_displaced_step_hw_singlestep):
1449 * s390-tdep.c (s390_displaced_step_hw_singlestep):
1451 * gdbarch.c: Re-generate.
1452 * gdbarch.h: Re-generate.
1453 * infrun.c (resume_1): Adjust.
1457 * progspace.c (program_space::~program_space): Don't call
1462 * exec.c (exec_target::close): Don't change current program
1467 * symfile.c (add_symbol_file_command): Update.
1468 * exec.c (program_space::add_target_sections): Rename.
1469 * symfile-mem.c (symbol_file_add_from_memory): Update.
1470 * progspace.h (struct program_space) <add_target_sections>:
1471 Declare new overload.
1472 * exec.h (add_target_sections_of_objfile): Don't declare.
1476 * solib.c (solib_map_sections): Update.
1477 * exec.c (program_space::add_target_sections): Now a method.
1478 (exec_file_attach): Update.
1479 * exec.h (add_target_sections): Don't declare.
1480 * progspace.h (struct program_space) <add_target_sections>:
1485 * progspace.h (struct program_space) <remove_target_sections>:
1487 * exec.c (program_space::remove_target_sections): Now a method.
1488 * exec.h (remove_target_sections): Don't declare.
1492 * inferior.c (delete_inferior): Update.
1493 * progspace.c (program_space::empty): Rename from
1494 program_space_empty_p. Return bool.
1495 * progspace.h (struct program_space) <empty>: New method.
1496 (program_space_empty_p): Don't declare.
1500 * progspace.c (program_space::~program_space): Don't call
1501 clear_program_space_solib_cache.
1502 (program_space::clear_solib_cache): Rename from
1504 * solib.c (handle_solib_event): Update.
1505 * progspace.h (struct program_space) <clear_solib_cache>: New
1507 (clear_program_space_solib_cache): Don't declare.
1511 * windows-tdep.c (windows_solib_create_inferior_hook): Update.
1512 * target.c (info_target_command): Update.
1513 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1514 (symbol_file_clear, reread_symbols): Update.
1515 * symfile-mem.c (add_symbol_file_from_memory_command): Update.
1516 * stabsread.c (scan_file_globals): Update.
1517 * solib.c (update_solib_list): Update.
1518 * solib-svr4.c (elf_locate_base, open_symbol_file_object)
1519 (svr4_fetch_objfile_link_map, enable_break)
1520 (svr4_relocate_main_executable)
1521 (svr4_iterate_over_objfiles_in_search_order): Update.
1522 * solib-frv.c (lm_base, enable_break)
1523 (frv_relocate_main_executable): Update.
1524 (main_got, frv_fdpic_find_canonical_descriptor): Update.
1525 (frv_fetch_objfile_link_map): Update.
1526 * solib-dsbt.c (lm_base, dsbt_relocate_main_executable): Update.
1527 * solib-darwin.c (darwin_solib_create_inferior_hook): Update.
1528 * solib-aix.c (solib_aix_solib_create_inferior_hook): Update.
1529 * remote.c (remote_target::get_offsets): Update.
1530 (remote_target::start_remote)
1531 (extended_remote_target::post_attach): Update.
1532 * objfiles.c (entry_point_address_query): Update.
1533 * nto-procfs.c (nto_procfs_target::create_inferior): Update.
1534 * minsyms.c (get_symbol_leading_char): Update.
1535 * frame.c (inside_main_func): Update.
1536 * progspace.h (symfile_objfile): Remove macro.
1540 * exec.c (exec_file_attach): Update.
1541 * progspace.c (program_space::exec_close): Update.
1542 * progspace.h (struct program_space) <ebfd>: Now a
1544 <set_exec_bfd>: Change argument type.
1549 * windows-tdep.c (windows_solib_create_inferior_hook): Update.
1550 * symfile.c (reread_symbols): Update.
1551 * symfile-mem.c (add_symbol_file_from_memory_command)
1552 (add_vsyscall_page): Update.
1553 * source-cache.c (source_cache::get_plain_source_lines): Update.
1554 * solib-svr4.c (find_program_interpreter, elf_locate_base)
1555 (svr4_current_sos_direct, svr4_exec_displacement)
1556 (svr4_relocate_main_executable): Update.
1557 (svr4_iterate_over_objfiles_in_search_order): Update.
1558 * solib-frv.c (enable_break2, enable_break): Update.
1559 * solib-dsbt.c (lm_base, enable_break): Update.
1560 * solib-darwin.c (find_program_interpreter)
1561 (darwin_solib_create_inferior_hook): Update.
1562 * sol-thread.c (rw_common, ps_pdmodel): Update.
1563 * rs6000-nat.c (rs6000_nat_target::create_inferior): Update.
1564 * remote.c (compare_sections_command)
1565 (remote_target::trace_set_readonly_regions): Update.
1566 * remote-sim.c (get_sim_inferior_data)
1567 (gdbsim_target::create_inferior, gdbsim_target::create_inferior): Update.
1568 (gdbsim_target_open, gdbsim_target::files_info): Update.
1569 * exec.h (exec_bfd): Remove macro.
1570 * progspace.c (initialize_progspace): Update.
1571 * proc-service.c (ps_addr_to_core_addr, core_addr_to_ps_addr):
1573 * nto-procfs.c (nto_procfs_target::post_attach)
1574 (nto_procfs_target::create_inferior): Update.
1575 * maint.c (maintenance_info_sections): Update.
1576 * linux-thread-db.c (thread_db_target::get_thread_local_address):
1578 * infcmd.c (post_create_inferior): Update.
1579 * gcore.c (default_gcore_arch, default_gcore_target): Update.
1580 (objfile_find_memory_regions): Update.
1581 * exec.c (validate_exec_file, exec_file_attach)
1582 (exec_read_partial_read_only, print_section_info): Update.
1583 * corelow.c (core_target_open): Update.
1584 * corefile.c (reopen_exec_file, validate_files): Update.
1585 * arm-tdep.c (gdb_print_insn_arm): Update.
1586 * arch-utils.c (gdbarch_update_p, default_print_insn): Update.
1587 * progspace.h (struct program_space) <exec_bfd, set_exec_bfd>: New
1592 * progspace.h (current_target_sections): Remove macro.
1593 * solib-svr4.c (scan_dyntag): Update.
1594 * solib-dsbt.c (scan_dyntag): Update.
1595 * exec.c (exec_target::close): Update.
1596 (add_target_sections, add_target_sections_of_objfile)
1597 (remove_target_sections, exec_target::get_section_table)
1598 (exec_target::files_info, set_section_command)
1599 (exec_set_section_address, exec_target::has_memory)
1600 (exec_target::has_memory): Update.
1604 * source-cache.c (source_cache::get_plain_source_lines): Use
1605 current_program_space.
1606 * corefile.c (reopen_exec_file): Use current_program_space.
1607 * exec.c (exec_file_attach): Use current_program_space.
1608 * exec.h (exec_bfd_mtime): Remove.
1612 * gcore.c (default_gcore_mach): Remove.
1613 (create_gcore_bfd): Update.
1617 * progspace.c (program_space::exec_close): New method, from
1618 exec_close in exec.c.
1619 * exec.c (exec_close): Move to progspace.c.
1620 (exec_target::close, exec_file_attach): Update.
1621 * progspace.h (struct program_space) <exec_close>: Declare
1626 * progspace.h (struct program_space) <exec_filename>: Rename from
1627 pspace_exec_filename. Now a unique_xmalloc_ptr.
1628 * inferior.c (print_selected_inferior): Update.
1629 (print_inferior): Update.
1630 * mi/mi-main.c (print_one_inferior): Update.
1631 * exec.h (exec_filename): Remove macro.
1632 * corefile.c (get_exec_file): Update.
1633 * exec.c (exec_close): Update.
1634 (exec_file_attach): Update.
1635 * progspace.c (clone_program_space): Update.
1636 (print_program_space): Update.
1640 * target-section.h (struct target_section): Add constructor.
1641 * exec.c (build_section_table, add_target_sections_of_objfile):
1643 * corelow.c (core_target::build_file_mappings): Update.
1648 * inferior.c (detach_inferior_command): Restore the current thread.
1649 (kill_inferior_command): Ditto.
1654 * symtab.c (find_pc_sect_compunit_symtab): In case there's an address
1655 map, check it in the "best match" loop.
1659 * m32c-tdep.c: Remove unused includes.
1663 * xtensa-tdep.c: Remove includes.
1667 * breakpoint.c (struct condition_command_opts): New struct.
1668 (condition_command_option_defs): New static global.
1669 (make_condition_command_options_def_group): New function.
1670 (condition_completer): Update to consider the '-force' flag.
1671 (condition_command): Use gdb::option for the '-force' flag.
1675 * symtab.c (find_pc_sect_compunit_symtab): Include STATIC_BLOCK
1676 symbols in section check.
1680 * symtab.c (find_pc_sect_compunit_symtab): Use early continue.
1684 * breakpoint.h (set_breakpoint_condition): Add a new bool parameter.
1685 * breakpoint.c: Update the help text of the 'condition' and 'break'
1687 (set_breakpoint_condition): Take a new bool parameter
1688 to control whether condition definition should be forced even when
1689 the condition expression is invalid in all of the current locations.
1690 (condition_command): Update the call to 'set_breakpoint_condition'.
1691 (find_condition_and_thread): Take the "-force-condition" flag into
1693 * linespec.c (linespec_keywords): Add "-force-condition" as an
1695 (FORCE_KEYWORD_INDEX): New #define.
1696 (linespec_lexer_lex_keyword): Update to consider "-force-condition"
1698 * ada-lang.c (create_ada_exception_catchpoint): Ditto.
1699 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x): Ditto.
1700 * python/py-breakpoint.c (bppy_set_condition): Ditto.
1701 * NEWS: Mention the changes to the 'break' and 'condition' commands.
1705 * breakpoint.h (class bp_location) <disabled_by_cond>: New field.
1706 * breakpoint.c (set_breakpoint_location_condition): New function.
1707 (set_breakpoint_condition): Disable a breakpoint location if parsing
1708 the condition string gives an error.
1709 (should_be_inserted): Update to consider the 'disabled_by_cond' field.
1710 (build_target_condition_list): Ditto.
1711 (build_target_command_list): Ditto.
1712 (build_bpstat_chain): Ditto.
1713 (print_one_breakpoint_location): Ditto.
1714 (print_one_breakpoint): Ditto.
1715 (breakpoint_1): Ditto.
1716 (bp_location::bp_location): Ditto.
1717 (locations_are_equal): Ditto.
1718 (update_breakpoint_locations): Ditto.
1719 (enable_disable_bp_num_loc): Ditto.
1720 (init_breakpoint_sal): Use set_breakpoint_location_condition.
1721 (find_condition_and_thread_for_sals): New static function.
1722 (create_breakpoint): Call find_condition_and_thread_for_sals.
1723 (location_to_sals): Call find_condition_and_thread_for_sals instead
1724 of find_condition_and_thread.
1728 * dwarf2/read.c (process_full_comp_unit): Call
1729 dwarf2_find_base_address.
1733 * gdbtypes.c (create_range_type): Revert previous patch. Add
1738 * nat/linux-waitpid.c: Include "gdbsupport/eintr.h".
1739 (my_waitpid): Use gdb::handle_eintr.
1743 * acinclude.m4: Update ptrace.m4 path.
1744 * ptrace.m4: Moved to gdbsupport.
1748 * symfile-mem.c (add_vsyscall_page): Use inferior parameter
1749 instead of target_gdbarch.
1753 * jit.c (jit_reader_load_command): Pass current inferior.
1754 (jit_inferior_init): Change parameter type to inferior, use it.
1755 (jit_inferior_created): Remove.
1756 (jit_inferior_created_hook): Pass inferior parameter down.
1757 (_initialize_jit): Use jit_inferior_created_hook instead of
1758 jit_inferior_created.
1759 * jit.h (jit_inferior_created_hook): Add inferior parameter.
1760 * infrun.c (follow_exec): Pass inferior to
1761 jit_inferior_created_hook.
1765 * linux-thread-db.c (check_pid_namespace_match): Add inferior
1766 parameter and use it.
1767 (thread_db_inferior_created): Pass inferior argument.
1771 * aix-thread.c (aix_thread_inferior_created): Add inferior
1773 * bsd-uthread.c (bsd_uthread_inferior_created): Likewise.
1774 * dummy-frame.c (cleanup_dummy_frames): Likewise.
1775 * jit.c (jit_inferior_created): Likewise.
1776 * linux-thread-db.c (thread_db_inferior_created): Likewise.
1777 * m68k-linux-tdep.c (m68k_linux_inferior_created): Likewise.
1778 * observable.h (inferior_created): Likewise.
1779 * ravenscar-thread.c (ravenscar_inferior_created): Likewise.
1780 * symfile-mem.c (add_vsyscall_page): Likewise.
1781 * infcmd.c (post_create_inferior): Pass inferior argument.
1789 * ada-typeprint.c (ada_print_type): Remove superfluous second call
1790 to ada_check_typedef.
1794 * f-exp.y (f_parse): Rename to...
1795 (f_language::parser): ...this.
1796 * f-lang.c (f_get_encoding): Rename to...
1797 (f_language::get_encoding): ...this.
1798 (f_op_print_tab): Rename to...
1799 (f_language::op_print_tab): ...this.
1800 (exp_descriptor_f): Rename to...
1801 (f_language::exp_descriptor_tab): ...this.
1802 (class f_language): Moved to f-lang.h.
1803 (f_language::language_arch_info): New function, moved out of class
1805 (f_language::search_name_hash): Likewise.
1806 (f_language::lookup_symbol_nonlocal): Likewise.
1807 (f_language::get_symbol_name_matcher_inner): Likewise.
1808 * f-lang.h: Add 'valprint.h' include.
1809 (class f_language): Moved here from f-lang.c.
1810 * f-typeprint.c (f_type_print_args): Delete commented out
1812 (f_print_typedef): Rename to...
1813 (f_language::print_typedef): ...this.
1814 (f_print_type): Rename to...
1815 (f_language::print_type): ...this.
1816 (f_type_print_varspec_prefix): Delete declaration and rename to...
1817 (f_language::f_type_print_varspec_prefix): ...this.
1818 (f_type_print_varspec_suffix): Delete declaration and rename to...
1819 (f_language::f_type_print_varspec_suffix): ...this.
1820 (f_type_print_base): Delete declaration and rename to...
1821 (f_language::f_type_print_base): ...this.
1822 * f-valprint.c (f_value_print_inner): Rename to...
1823 (f_language::value_print_inner): ...this.
1824 * parse.c: Delete 'f-lang.h' include.
1828 * language.h (language_defn::print_type): Add variable names in
1829 declaration, and update header comment.
1833 * ada-lang.c (ada_language::demangle): Rename to...
1834 (ada_language::demangle_symbol): ...this.
1835 * c-lang.c (cplus_language::demangle): Rename to...
1836 (cplus_language::demangle_symbol): ...this.
1837 * d-lang.c (d_language::demangle): Rename to...
1838 (d_language::demangle_symbol): ...this.
1839 * f-lang.c (f_language::demangle): Rename to...
1840 (f_language::demangle_symbol): ...this.
1841 * go-lang.c (go_language::demangle): Rename to...
1842 (go_language::demangle_symbol): ...this.
1843 * language.c (language_demangle): Update call to demangle_symbol.
1844 (auto_or_unknown_language::demangle): Rename to...
1845 (auto_or_unknown_language::demangle_symbol): ...this.
1846 * language.h (language_defn::demangle): Rename to...
1847 (language_defn::demangle_symbol): ...this.
1848 * objc-lang.c (objc_language::demangle): Rename to...
1849 (objc_language::demangle_symbol): ...this.
1850 * rust-lang.c (rust_language::demangle): Rename to...
1851 (rust_language::demangle_symbol): ...this.
1855 * language.h (LA_ITERATE_OVER_SYMBOLS): Delete.
1856 (iterate_over_file_blocks): Replace use of macro with the macros
1861 * language.h (LA_PRINT_ARRAY_INDEX): Delete.
1862 * valprint.c (maybe_print_array_index): Replace use of macro with
1863 the macros definition.
1867 * ada-lang.c (ada_language::print_array_index): Call value_print
1869 * language.c (language_defn::print_array_index): Likewise.
1870 * language.h (LA_VALUE_PRINT): Delete.
1871 * valprint.c (value_print): Call value_print on the
1872 current_language directly.
1876 * language.h (LA_PRINT_TYPEDEF): Delete.
1877 * typeprint.c (typedef_print): Call print_typedef directly on the
1878 current_language object.
1882 * m2-exp.y (m2_parse): Rename to...
1883 (m2_language::parser): ...this. Update function signature.
1884 * m2-lang.c (m2_printchar): Renamed to m2_language::printchar.
1885 (m2_op_print): Rename to...
1886 (m2_language::op_print_tab): ...this, and make const.
1887 (exp_descriptor_modula2): Rename to...
1888 (m2_language::exp_descriptor_modula2): ...this.
1889 (class m2_language): Move to m2-lang.h.
1890 (m2_language::language_arch_info): New function, moved out of
1892 (m2_language::printchar): New function, body from m2_printchar.
1893 (m2_language::printstr): New function, moved out of class
1895 (m2_language::emitchar): Likewise.
1896 * m2-lang.h (m2_parse): Delete declaration.
1897 (m2_print_typedef): Delete declaration.
1898 (m2_value_print_inner): Delete declaration.
1899 (class m2_language): Class declaration moved from m2-lang.c,
1900 larger functions are left in m2-lang.c.
1901 * m2-typeprint.c (m2_print_typedef): Rename to...
1902 (m2_language::print_typedef): ...this, and update function
1904 * m2-valprint.c (m2_value_print_inner): Rename to...
1905 (m2_language::value_print_inner): ...this, replace use of
1906 LA_PRINT_STRING with a direct call to printstr member function,
1907 and update recursive call.
1911 * language.c (default_is_string_type_p): Delete, implementation
1912 moved into auto_or_unknown_language::is_string_type_p.
1913 (unk_op_print_tab): Moved into
1914 auto_or_unknown_language::opcode_print_table.
1915 (unknown_language_arch_info): Delete, implementation moved into
1916 auto_or_unknown_language::language_arch_info.
1917 (class auto_or_unknown_language): New class, member functions
1918 copied from unknown_language class, with some updates.
1919 (class unknown_language): Most member functions moved into
1920 auto_or_unknown_language class. Inherit from
1921 auto_or_unknown_language class.
1922 (class auto_language): Inherit from auto_or_unknown_language.
1923 Delete most member functions.
1927 * stabsread.c (read_member_functions): Remove gdb_assert.
1931 * gdbtypes.c (init_complex_type): Check target type name.
1935 * target-debug.h (target_debug_print_struct_target_ops_p):
1937 (target_debug_print_async_callback_ftype_p): Remove.
1938 (target_debug_print_struct_trace_state_variable_p): Remove.
1939 (target_debug_print_struct_traceframe_info_p): Remove.
1940 (target_debug_print_VEC__btrace_block_s__pp): Remove.
1941 (target_debug_print_enum_btrace_format): Remove.
1942 (target_debug_print_enum_info_proc_what): Remove.
1943 (target_debug_print_thread_info_pp): Remove.
1947 * target.h (struct target_ops) <make_corefile_notes>:
1948 Change return type to unique pointer.
1949 * target.c (dummy_make_corefile_notes): Likewise.
1950 * exec.c (struct exec_target) <make_corefile_notes>:
1952 (exec_target::make_corefile_notes): Likewise.
1953 * procfs.c (class procfs_target) <make_corefile_notes>:
1955 (procfs_do_thread_registers): Adjust to unique pointer.
1956 (struct procfs_corefile_thread_data): Add constructor.
1957 <note_data>: Change type to unique pointer.
1958 (procfs_corefile_thread_callback): Adjust to unique pointer.
1959 (procfs_target::make_corefile_notes): Change return type to
1961 * target-delegates.c: Re-generate.
1962 * gcore.c (write_gcore_file_1): Adjust.
1963 * target-debug.h (target_debug_print_gdb_unique_xmalloc_ptr_char):
1968 * block.c (find_block_in_blockvector): Make sure the returned block
1974 * dwarf2/read.c (load_full_comp_unit): Add existing_cu
1976 (load_cu): Pass existing CU.
1977 (process_imported_unit_die): Likewise.
1978 (follow_die_offset): Likewise.
1982 * corelow.c (core_target::xfer_partial): Also check for an empty
1983 m_core_unavailable_mappings vector.
1987 * expprint.c (dump_subexp_body_standard): Print RANGE_HAS_STRIDE.
1988 * expression.h (enum range_type): Add RANGE_HAS_STRIDE.
1989 * f-exp.y (arglist): Allow for a series of subranges.
1990 (subrange): Add cases for subranges with strides.
1991 * f-lang.c (value_f90_subarray): Catch use of array strides and
1993 * parse.c (operator_length_standard): Handle RANGE_HAS_STRIDE.
1997 * expprint.c (print_subexp_standard): Change enum range_type to
1998 range_flag and rename variables to match.
1999 (dump_subexp_body_standard): Likewise.
2000 * expression.h (enum range_type): Rename to...
2001 (enum range_flag): ...this.
2002 (range_types): Rename to...
2003 (range_flags): ...this.
2004 * f-lang.c (value_f90_subarray): Change enum range_type to
2005 range_flag and rename variables to match.
2006 * parse.c (operator_length_standard): Likewise.
2007 * rust-exp.y (rust_parser::convert_ast_to_expression): Change enum
2008 range_type to range_flag.
2009 * rust-lang.c (rust_evaluate_funcall): Likewise.
2010 (rust_range): Likewise.
2011 (rust_compute_range): Likewise.
2012 (rust_subscript): Likewise.
2016 * expprint.c (print_subexp_standard): Update to reflect changes to
2018 (dump_subexp_body_standard): Likewise.
2019 * expression.h (enum range_type): Convert to a bit field enum, and
2020 make the enum unsigned.
2021 * f-exp.y (subrange): Update to reflect changes to enum
2023 * f-lang.c (value_f90_subarray): Likewise.
2024 * parse.c (operator_length_standard): Likewise.
2025 * rust-exp.y (rust_parser::convert_ast_to_expression): Likewise.
2026 * rust-lang.c (rust_range): Likewise.
2027 (rust_compute_range): Likewise.
2028 (rust_subscript): Likewise.
2032 * infrun.c (displaced_step_in_progress_thread): Fix comment.
2033 (displaced_step_in_progress): Fix comment.
2037 * gdbarch.sh (make_corefile_notes): Return unique pointer.
2038 * gdbarch.c: Re-generate.
2039 * gdbarch.h: Re-generate.
2040 * gcore.c (write_gcore_file_1): Adjust.
2041 * fbsd-tdep.c (struct fbsd_collect_regset_section_cb_data): Add
2043 <note_data>: Change type to unique pointer.
2044 <abort_iteration>: Change type to bool.
2045 (fbsd_collect_regset_section_cb): Adjust to unique pointer.
2046 (fbsd_collect_thread_registers): Return void, adjust.
2047 (struct fbsd_corefile_thread_data): Add construtor.
2048 <note_data>: Change type to unique pointer.
2049 (fbsd_corefile_thread): Adjust.
2050 (fbsd_make_corefile_notes): Return unique pointer, adjust.
2051 * linux-tdep.c (linux_make_mappings_corefile_notes): Change type
2052 to unique pointer, adjust.
2053 (struct linux_collect_regset_section_cb_data): Add constructor.
2054 <note_data>: Change type to unique pointer.
2055 <abort_iteration>: Change type to bool.
2056 (linux_collect_thread_registers): Return void, adjust.
2057 (struct linux_corefile_thread_data): Add constructor.
2058 <note_data>: Change type to unique pointer.
2059 (linux_corefile_thread): Adjust.
2060 (linux_make_corefile_notes): Return unique pointer, adjust.
2064 * gdbarch.sh (displaced_step_hw_singlestep): Return bool.
2065 * gdbarch.c: Re-generate.
2066 * gdbarch.h: Re-generate.
2067 * aarch64-tdep.c (aarch64_displaced_step_hw_singlestep): Return
2069 * aarch64-tdep.h (aarch64_displaced_step_hw_singlestep):
2071 * arch-utils.h (default_displaced_step_hw_singlestep): Likewise.
2072 * arch-utils.c (default_displaced_step_hw_singlestep): Likewise.
2073 * rs6000-tdep.c (ppc_displaced_step_hw_singlestep): Likewise.
2074 * s390-tdep.c (s390_displaced_step_hw_singlestep): Likewise.
2078 * gdbarch.sh: Make generated predicates return bool.
2079 * gdbarch.c: Re-generate.
2080 * gdbarch.h: Re-generate.
2084 * varobj-iter.h (struct varobj_item): Remove typedef.
2088 * infrun.c (currently_stepping): Change int to bool
2089 (maybe_software_singlestep): Likewise.
2090 (show_stop_on_solib_events): Likewise.
2091 (stepping_past_nonsteppable_watchpoint): Likewise.
2092 (displaced_step_in_progress_any_inferior): Likewise.
2093 (displaced_step_in_progress_thread): Likewise.
2094 (keep_going_stepped_thread): Likewise.
2095 (thread_still_needs_step_over): Likewise.
2096 (start_step_over): Likewise.
2097 (do_target_resume): Likewise.
2098 (resume_1): Likewise.
2099 (clear_proceed_status): Likewise.
2100 (thread_still_needs_step_over_bp): Likewise.
2101 (proceed): Likewise.
2102 (switch_back_to_stepped_thread): Likewise.
2103 (adjust_pc_after_break): Likewise.
2104 (stepped_in_from): Likewise.
2105 (handle_stop_requested): Likewise.
2106 (handle_syscall_event): Likewise.
2107 (handle_no_resumed): Likewise.
2108 (handle_inferior_event): Likewise.
2109 (finish_step_over): Likewise.
2110 (handle_signal_stop): Likewise.
2111 (process_event_stop_test): Likewise.
2115 * infrun.c (get_displaced_stepping_state): Fix comment.
2119 * cli/cli-cmds.c (_initialize_cli_cmds): Fix alias command help.
2124 * tui/tui-winsource.h (struct tui_source_window_base)
2125 <refresh_window>: Rename from refresh_pad.
2126 * tui/tui-winsource.c (tui_source_window_base::refresh_window):
2127 Rename from refresh_pad.
2128 (tui_source_window_base::show_source_content)
2129 (tui_source_window_base::do_scroll_horizontal): Update.
2133 * thread.c (_initialize_thread): Fine-tune the help text of
2138 * frame.c: Remove the unused 'uinteger_option_def' type alias.
2142 * breakpoint.c (handle_jit_event): Add an argument, change how
2143 `jit_event_handler` is called.
2147 * xcoffread.c (xcoff_end_psymtab): Use partial_symtab::empty.
2148 (scan_xcoff_symtab): Update.
2149 * psymtab.h (class psymtab_storage) <global_psymbols,
2150 static_psymbols, current_global_psymbols,
2151 current_static_psymbols>: Remove.
2152 * psymtab.c (require_partial_symbols, find_pc_sect_psymbol)
2153 (match_partial_symbol, lookup_partial_symbol): Update.
2154 (print_partial_symbols): Change parameters.
2155 (dump_psymtab, recursively_search_psymtabs)
2156 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address)
2157 (sort_pst_symbols, partial_symtab::partial_symtab): Update.
2159 (end_psymtab_common): Simplify.
2160 (append_psymbol_to_list): Change parameters.
2161 (partial_symtabs::add_psymbol): Rename from add_psymbol_to_list.
2162 (init_psymbol_list): Simplify.
2163 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2164 * psympriv.h (struct partial_symtab) <empty>: New method.
2165 <globals_offset, n_global_syms, statics_offset, n_static_syms>:
2167 <global_psymbols, static_psymbols>: New members.
2168 <add_psymbol>: New methods.
2169 (add_psymbol_to_list): Don't declare.
2170 (psymbol_placement): Move earlier.
2171 * mdebugread.c (parse_partial_symbols): Update.
2172 (handle_psymbol_enumerators): Change parameters.
2173 (mdebug_expand_psymtab): Update.
2174 * dwarf2/read.c (process_psymtab_comp_unit_reader)
2175 (add_partial_symbol): Update.
2176 * dwarf2/index-write.c (write_psymbols): Change parameters.
2177 (write_one_signatured_type): Update.
2178 (recursively_count_psymbols): Update.
2179 (recursively_write_psymbols): Update.
2180 (class debug_names) <recursively_write_psymbols>: Update.
2181 <write_psymbols>: Change parameters.
2182 <write_one_signatured_type>: Update.
2183 * dbxread.c (read_dbx_symtab): Update.
2184 (dbx_end_psymtab): Use partial_symtab::empty.
2185 * ctfread.c (struct ctf_context) <pst>: New member.
2186 (create_partial_symtab): Set it.
2187 (ctf_psymtab_type_cb, ctf_psymtab_var_cb): Update.
2188 (scan_partial_symbols): Use the psymtab's context. Update.
2192 * valprint.c (generic_value_print): Remove comment.
2193 * m2-valprint.c (m2_value_print_inner): Remove comment.
2194 * gdbtypes.c (create_range_type): Set TYPE_UNSIGNED from base
2200 * source.c (select_source_symtab): Handling sal.symtab == NULL for
2206 * solib.c (solib_contains_address_p): Handle
2207 'solib->sections == nullptr'.
2212 * infrun.c (do_target_wait_1): Clear TARGET_WNOHANG if the
2213 target can't do async.
2214 * target.c (target_wait): Assert that we don't pass
2215 TARGET_WNOHANG to a target that can't async.
2219 * Makefile.in (ALL_64_TARGET_OBS, ALL_TARGET_OBS)
2220 HFILES_NO_SRCDIR, ALLDEPFILES): Rename files.
2221 * alpha-bsd-nat.c: Adjust include.
2222 * alpha-bsd-tdep.h: Adjust comment.
2223 * alpha-nbsd-tdep.c: Rename to ...
2224 * alpha-netbsd-tdep.c: ... this, adjust include.
2225 * amd64-nbsd-nat.c: Rename to ...
2226 * amd64-netbsd-nat.c: ... this, adjust include.
2227 * amd64-nbsd-tdep.c: Rename to ...
2228 * amd64-netbsd-tdep.c: ... this, adjust include.
2229 * amd64-tdep.h: Adjust include.
2230 * arm-nbsd-nat.c: Rename to ...
2231 * arm-netbsd-nat.c: ... this, adjust include.
2232 * arm-nbsd-tdep.c: Rename to ...
2233 * arm-netbsd-tdep.c: ... this, adjust include.
2234 * arm-nbsd-tdep.h: Rename to ...
2235 * arm-netbsd-tdep.h: ... this, adjust include.
2236 * configure.nat: Adjust file lists.
2237 * configure.tgt: Likewise.
2238 * hppa-nbsd-nat.c: Rename to ...
2239 * hppa-netbsd-nat.c: ... this, adjust include.
2240 * hppa-nbsd-tdep.c: Rename to ...
2241 * hppa-netbsd-tdep.c: ... this, adjust include.
2242 * i386-nbsd-nat.c: Rename to ...
2243 * i386-netbsd-nat.c: ... this, adjust include.
2244 * i386-nbsd-tdep.c: Rename to ...
2245 * i386-netbsd-tdep.c: ... this, adjust include.
2246 * m68k-bsd-nat.c: Adjust include.
2247 * mips-nbsd-nat.c: Rename to ...
2248 * mips-netbsd-nat.c: ... this, adjust include.
2249 * mips-nbsd-tdep.c: Rename to ...
2250 * mips-netbsd-tdep.c: ... this, adjust include.
2251 * mips-nbsd-tdep.h: Rename to ...
2252 * mips-netbsd-tdep.h: ... this.
2253 * nbsd-nat.c: Rename to ...
2254 * netbsd-nat.c: ... this, adjust include.
2255 * nbsd-nat.h: Rename to ...
2256 * netbsd-nat.h: ... this, adjust include.
2257 * nbsd-tdep.c: Rename to ...
2258 * netbsd-tdep.c: ... this, adjust include.
2259 * nbsd-tdep.h: Rename to ...
2260 * netbsd-tdep.h: ... this.
2261 * ppc-nbsd-nat.c: Rename to ...
2262 * ppc-netbsd-nat.c: ... this, adjust include.
2263 * ppc-nbsd-tdep.c: Rename to ...
2264 * ppc-netbsd-tdep.c: ... this, adjust include and comment.
2265 * ppc-nbsd-tdep.h: Rename to ...
2266 * ppc-netbsd-tdep.h: ... this.
2267 * sh-nbsd-nat.c: Rename to ...
2268 * sh-netbsd-nat.c: ... this, adjust include.
2269 * sh-nbsd-tdep.c: Rename to ...
2270 * sh-netbsd-tdep.c: ... this, adjust include.
2271 * sparc-nbsd-nat.c: Rename to ...
2272 * sparc-netbsd-nat.c: ... this.
2273 * sparc-nbsd-tdep.c: Rename to ...
2274 * sparc-netbsd-tdep.c: ... this, adjust include.
2275 * sparc64-nbsd-nat.c: Rename to ...
2276 * sparc64-netbsd-nat.c: ... this.
2277 * sparc64-nbsd-tdep.c: Rename to ...
2278 * sparc64-netbsd-tdep.c: ... this, adjust include.
2279 * sparc64-tdep.h: Adjust comment.
2280 * vax-bsd-nat.c: Adjust include.
2281 * vax-nbsd-tdep.c: Rename to ...
2282 * vax-netbsd-tdep.c: ... this, adjust include.
2286 * target.h (struct target_ops) <get_section_table>: Update.
2287 (target_get_section_table): Update.
2288 * target.c (target_get_section_table, target_section_by_addr)
2289 (memory_xfer_partial_1): Update.
2290 * target-section.h (target_section_table): Now an alias.
2291 * target-delegates.c: Rebuild.
2292 * target-debug.h (target_debug_print_target_section_table_p):
2293 Rename from target_debug_print_struct_target_section_table_p.
2294 * symfile.c (build_section_addr_info_from_section_table): Update.
2295 * solib.c (solib_map_sections, solib_contains_address_p): Update.
2296 * solib-svr4.c (scan_dyntag): Update.
2297 * solib-dsbt.c (scan_dyntag): Update.
2298 * remote.c (remote_target::remote_xfer_live_readonly_partial):
2300 * record-full.c (record_full_core_target::xfer_partial): Update.
2301 * progspace.h (struct program_space) <target_sections>: Update.
2302 * exec.h (print_section_info): Update.
2303 * exec.c (exec_target::close, build_section_table)
2304 (add_target_sections, add_target_sections_of_objfile)
2305 (remove_target_sections, exec_on_vfork)
2306 (section_table_available_memory)
2307 (section_table_xfer_memory_partial)
2308 (exec_target::get_section_table, exec_target::xfer_partial)
2309 (print_section_info, set_section_command)
2310 (exec_set_section_address, exec_target::has_memory): Update.
2311 * corelow.c (core_target::build_file_mappings)
2312 (core_target::xfer_partial, core_target::info_proc_mappings)
2313 (core_target::info_proc_mappings): Update.
2314 * bfd-target.c (class target_bfd): Update
2318 * progspace.c (program_space::~program_space): Don't call
2319 clear_section_table.
2320 * exec.h (clear_section_table): Don't declare.
2321 * exec.c (exec_target::close): Update.
2322 (clear_section_table): Remove.
2326 * exec.c (add_target_sections_of_objfile): Simplify.
2330 * solib.c (solib_map_sections): Update.
2331 * record-full.c (record_full_core_open_1): Update.
2332 * exec.h (build_section_table): Return a target_section_table.
2333 * exec.c (exec_file_attach): Update.
2334 (build_section_table): Return a target_section_table.
2335 * corelow.c (core_target::core_target): Update.
2336 * bfd-target.c (target_bfd::target_bfd): Update.
2340 * target.c (target_section_by_addr, memory_xfer_partial_1):
2342 * target-section.h (struct target_section_table): Use
2344 * symfile.h (build_section_addr_info_from_section_table): Take a
2345 target_section_table.
2346 * symfile.c (build_section_addr_info_from_section_table): Take a
2347 target_section_table.
2348 * solist.h (struct so_list) <sections>: Change type.
2349 <sections_end>: Remove.
2350 * solib.c (solib_map_sections, clear_so, solib_read_symbols)
2351 (solib_contains_address_p): Update.
2352 * solib-svr4.c (scan_dyntag): Update.
2353 * solib-dsbt.c (scan_dyntag): Update.
2354 * remote.c (remote_target::remote_xfer_live_readonly_partial):
2356 * record-full.c (record_full_core_start, record_full_core_end):
2358 (record_full_core_sections): New global.
2359 (record_full_core_open_1, record_full_core_target::xfer_partial):
2361 * exec.h (build_section_table, section_table_xfer_memory_partial)
2362 (add_target_sections): Take a target_section_table.
2363 * exec.c (exec_file_attach, clear_section_table): Update.
2364 (resize_section_table): Remove.
2365 (build_section_table, add_target_sections): Take a
2366 target_section_table.
2367 (add_target_sections_of_objfile, remove_target_sections)
2368 (exec_on_vfork): Update.
2369 (section_table_available_memory): Take a target_section_table.
2370 (section_table_read_available_memory): Update.
2371 (section_table_xfer_memory_partial): Take a target_section_table.
2372 (print_section_info, set_section_command)
2373 (exec_set_section_address, exec_target::has_memory): Update.
2374 * corelow.c (class core_target) <m_core_section_table,
2375 m_core_file_mappings>: Remove braces.
2376 <~core_target>: Remove.
2377 (core_target::core_target): Update.
2378 (core_target::~core_target): Remove.
2379 (core_target::build_file_mappings)
2380 (core_target::xfer_memory_via_mappings)
2381 (core_target::xfer_partial, core_target::info_proc_mappings):
2383 * bfd-target.c (target_bfd::xfer_partial): Update.
2384 (target_bfd::target_bfd): Update.
2385 (target_bfd::~target_bfd): Remove.
2389 * target.h (struct target_section, struct target_section_table):
2390 Move to target-section.h.
2391 * target-section.h: New file.
2396 * valops.c (struct struct_field_searcher): New.
2397 (update_search_result): Rename to ...
2398 (struct_field_searcher::update_result): ... this. Simplify
2399 prototype. Record all found fields.
2400 (do_search_struct_field): Rename to ...
2401 (struct_field_searcher::search): ... this. Simplify prototype.
2402 Maintain stack of visited baseclass path. Call update_result for
2403 fields too. Keep searching fields in baseclasses instead of
2404 stopping at the first found field.
2405 (search_struct_field): Use struct_field_searcher. When looking
2406 for fields, report ambiguous access attempts.
2410 * frame.c (inside_main_func): Check full symbols as well as
2415 * ada-lang.c (advance_wild_match): Rewrite the function's
2416 description. Change the type of target0, t0 and t1 to char.
2420 * dwarf2/read.c (dwarf2_add_field): Handle signed offsets.
2424 * ada-lang.h (ada_encode): Return std::string.
2425 * ada-lang.c (ada_encode_1): Return std::string.
2426 (ada_encode): Likewise.
2427 (type_from_tag, ada_lookup_name_info::ada_lookup_name_info):
2429 * ada-exp.y (block_lookup, write_var_or_type): Update.
2434 * printcmd.c (print_formatted): Handle void results as
2439 * arch/aarch32.c (aarch32_create_target_description): Release the
2440 target_desc_up as late as possible.
2441 * arch/aarch64.c (aarch64_create_target_description): Likewise.
2442 * arch/amd64.c (amd64_create_target_description): Likewise.
2443 * arch/arc.c (arc_create_target_description): Return a
2444 target_desc_up, don't release it.
2445 * arch/arc.h (arc_create_target_description): Update declaration.
2446 (arc_lookup_target_description): Move target_desc_up into the
2447 cache, and return a borrowed pointer.
2448 * arch/arm.c (arm_create_target_description): Release the
2449 target_desc_up as late as possible.
2450 * arch/i386.c (i386_create_target_description): Likewise.
2451 * arch/riscv.h (riscv_create_target_description): Update
2452 declaration to match definition.
2453 * arch/tic6x.c (tic6x_create_target_description): Release the
2454 target_desc_up as late as possible.
2458 * Makefile.in: Include Makefile.gnulib.inc. Don't define LIBGNU
2459 or INCGNU. Make use of LIBGNU_EXTRA_LIBS when linking.
2463 * source.c (directory_command): Notify observers that "directories"
2464 parameter has changed.
2468 * cli/cli-cmds.c (print_disassembly): Style function name and
2469 addresses. Add _() wrappers.
2473 * NEWS: Mention ARC support in GDBserver.
2477 * arch/aarch32.c (aarch32_create_target_description): Release
2478 unique_ptr returned from allocate_target_description.
2479 * arch/aarch64.c (aarch64_create_target_description): Likewise.
2480 * arch/amd64.c (amd64_create_target_description): Likewise.
2481 * arch/arc.c (arc_create_target_description): Likewise.
2482 * arch/arm.c (arm_create_target_description): Likewise.
2483 * arch/i386.c (i386_create_target_description): Likewise.
2484 * arch/riscv.c (riscv_create_target_description): Update return
2485 type. Handle allocate_target_description returning a unique_ptr.
2486 (riscv_lookup_target_description): Update to handle unique_ptr.
2487 * arch/tic6x.c (tic6x_create_target_description): Release
2488 unique_ptr returned from allocate_target_description.
2489 * features/microblaze-with-stack-protect.c: Regenerate.
2490 * features/microblaze.c: Regenerate.
2491 * features/mips-dsp-linux.c: Regenerate.
2492 * features/mips-linux.c: Regenerate.
2493 * features/mips64-dsp-linux.c: Regenerate.
2494 * features/mips64-linux.c: Regenerate.
2495 * features/nds32.c: Regenerate.
2496 * features/nios2.c: Regenerate.
2497 * features/or1k.c: Regenerate.
2498 * features/rs6000/powerpc-32.c: Regenerate.
2499 * features/rs6000/powerpc-32l.c: Regenerate.
2500 * features/rs6000/powerpc-403.c: Regenerate.
2501 * features/rs6000/powerpc-403gc.c: Regenerate.
2502 * features/rs6000/powerpc-405.c: Regenerate.
2503 * features/rs6000/powerpc-505.c: Regenerate.
2504 * features/rs6000/powerpc-601.c: Regenerate.
2505 * features/rs6000/powerpc-602.c: Regenerate.
2506 * features/rs6000/powerpc-603.c: Regenerate.
2507 * features/rs6000/powerpc-604.c: Regenerate.
2508 * features/rs6000/powerpc-64.c: Regenerate.
2509 * features/rs6000/powerpc-64l.c: Regenerate.
2510 * features/rs6000/powerpc-7400.c: Regenerate.
2511 * features/rs6000/powerpc-750.c: Regenerate.
2512 * features/rs6000/powerpc-860.c: Regenerate.
2513 * features/rs6000/powerpc-altivec32.c: Regenerate.
2514 * features/rs6000/powerpc-altivec32l.c: Regenerate.
2515 * features/rs6000/powerpc-altivec64.c: Regenerate.
2516 * features/rs6000/powerpc-altivec64l.c: Regenerate.
2517 * features/rs6000/powerpc-e500.c: Regenerate.
2518 * features/rs6000/powerpc-e500l.c: Regenerate.
2519 * features/rs6000/powerpc-isa205-32l.c: Regenerate.
2520 * features/rs6000/powerpc-isa205-64l.c: Regenerate.
2521 * features/rs6000/powerpc-isa205-altivec32l.c: Regenerate.
2522 * features/rs6000/powerpc-isa205-altivec64l.c: Regenerate.
2523 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Regenerate.
2524 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Regenerate.
2525 * features/rs6000/powerpc-isa205-vsx32l.c: Regenerate.
2526 * features/rs6000/powerpc-isa205-vsx64l.c: Regenerate.
2527 * features/rs6000/powerpc-isa207-htm-vsx32l.c: Regenerate.
2528 * features/rs6000/powerpc-isa207-htm-vsx64l.c: Regenerate.
2529 * features/rs6000/powerpc-isa207-vsx32l.c: Regenerate.
2530 * features/rs6000/powerpc-isa207-vsx64l.c: Regenerate.
2531 * features/rs6000/powerpc-vsx32.c: Regenerate.
2532 * features/rs6000/powerpc-vsx32l.c: Regenerate.
2533 * features/rs6000/powerpc-vsx64.c: Regenerate.
2534 * features/rs6000/powerpc-vsx64l.c: Regenerate.
2535 * features/rs6000/rs6000.c: Regenerate.
2536 * features/rx.c: Regenerate.
2537 * features/s390-gs-linux64.c: Regenerate.
2538 * features/s390-linux32.c: Regenerate.
2539 * features/s390-linux32v1.c: Regenerate.
2540 * features/s390-linux32v2.c: Regenerate.
2541 * features/s390-linux64.c: Regenerate.
2542 * features/s390-linux64v1.c: Regenerate.
2543 * features/s390-linux64v2.c: Regenerate.
2544 * features/s390-te-linux64.c: Regenerate.
2545 * features/s390-tevx-linux64.c: Regenerate.
2546 * features/s390-vx-linux64.c: Regenerate.
2547 * features/s390x-gs-linux64.c: Regenerate.
2548 * features/s390x-linux64.c: Regenerate.
2549 * features/s390x-linux64v1.c: Regenerate.
2550 * features/s390x-linux64v2.c: Regenerate.
2551 * features/s390x-te-linux64.c: Regenerate.
2552 * features/s390x-tevx-linux64.c: Regenerate.
2553 * features/s390x-vx-linux64.c: Regenerate.
2554 * mips-tdep.c (_initialize_mips_tdep): Release unique_ptr returned
2555 from allocate_target_description.
2556 * target-descriptions.c (allocate_target_description): Update
2558 (print_c_tdesc::visit_pre): Release unique_ptr returned from
2559 allocate_target_description.
2563 * unittests/search-memory-selftests.c: New file.
2564 * Makefile.in (SELFTESTS_SRCS): Add
2565 unittests/search-memory-selftests.c.
2570 * findcmd.c (_initialize_mem_search): Mention that the range is
2575 * target.h (simple_search_memory): Don't declare.
2576 * target.c (simple_search_memory): Move to gdbsupport.
2577 (default_search_memory): Update.
2578 * remote.c (remote_target::search_memory): Update.
2582 * Makefile.in (COMPILE): Add CXXFLAGS.
2583 (INTERNAL_CFLAGS_BASE): Remove CXXFLAGS.
2584 (check-headers): Add CXXFLAGS.
2588 * arc-linux-tdep.h: New file.
2589 * arc-linux-tdep.c (arc_linux_core_reg_offsets,
2590 arc_linux_supply_gregset, arc_linux_supply_v2_regset,
2591 arc_linux_collect_gregset, arc_linux_collect_v2_regset,
2592 arc_linux_gregset, arc_linux_v2_regset,
2593 arc_linux_iterate_over_regset_sections,
2594 arc_linux_core_read_description): Implement.
2595 (arc_linux_init_osabi): Set iterate_over_regset_sections.
2596 * arc-tdep.h (ARC_OFFSET_NO_REGISTER): Declare.
2597 (arc_gdbarch_features_create): Add.
2598 * arc-tdep.c (arc_gdbarch_features_create): Not static anymore.
2602 * arch/arc.h: Rename "arc_gdbarch_features" to
2603 "arc_arch_features".
2604 * arc-tdep.h: Likewise.
2605 * arc-tdep.c: Likewise.
2609 * infcmd.c (attach_command): Remove the redundant call to
2610 `clear_proceed_status`.
2614 * nat/netbsd-nat.c (write_memory, read_memory): Update.
2618 * nat/netbsd-nat.c (write_memory, read_memory): Add.
2619 * nat/netbsd-nat.h (write_memory, read_memory): Likewise.
2620 * nbsd-nat.c (nbsd_nat_target::xfer_partial): Update.
2624 * break-catch-sig.c (signal_catch_counts): Make a static arrray.
2625 (_initialize_break_catch_sig): Don't allocate array.
2629 * symtab.c (find_pc_line): Return unmapped addresses when the
2630 requested address is also unmapped.
2634 * Makefile.in (HFILES_NO_SRCDIR): Remove tui/tui-windata.h, add
2639 * amd64-windows-tdep.c (amd64_windows_return_value): Use
2640 type::is_vector instead of TYPE_VECTOR.
2644 * auto-load.c (auto_load_objfile_script_1): Don't use
2645 debugfile_holder as temporary variable when stripping drive
2650 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
2651 Add TYPE_CODE_COMPLEX.
2652 (amd64_windows_return_value): Fix types returned via XMM0.
2656 * MAINTAINERS (Responsible Maintainers): Add Luis Machado to
2657 AArch64/ARM maintainers.
2661 * NEWS: Mention set/show debug event-loop.
2665 * skip.c (skiplist_entry::skiplist_entry): Unconditionally use
2670 * aix-thread.c (aix_thread_inferior_created): Remove parameters.
2671 * procfs.c (procfs_inferior_created): Remove.
2672 (_initialize_procfs): Don't register procfs_inferior_created.
2676 * async-event.c (invoke_async_signal_handlers): Add debug
2678 (check_async_event_handlers): Likewise.
2679 * event-top.c (show_debug_event_loop): New function.
2680 (_initialize_event_top): Register "set debug event-loop"
2685 * debug.c (debug_prefixed_vprintf): Move to gdbsupport.
2687 * infrun.c: Include gdbsupport/common-debug.h.
2688 * linux-nat.c: Likewise.
2692 * async-event.h (create_async_signal_handler): Add name
2694 (create_async_event_handler): Likewise.
2695 * async-event.c (struct async_signal_handler) <name>: New field.
2696 (struct async_event_handler) <name>: New field.
2697 (create_async_signal_handler): Assign name.
2698 (create_async_event_handler): Assign name.
2699 * event-top.c (async_init_signals): Pass name when creating
2701 * infrun.c (_initialize_infrun): Likewise.
2702 * record-btrace.c (record_btrace_push_target): Likewise.
2703 * record-full.c (record_full_open): Likewise.
2704 * remote-notif.c (remote_notif_state_allocate): Likewise.
2705 * remote.c (remote_target::open_1): Likewise.
2706 * tui/tui-win.c (tui_initialize_win): Likewise.
2710 * async-event.c (initialize_async_signal_handlers): Pass name to
2712 * event-top.c (ui_register_input_event_handler): Likewise.
2713 * linux-nat.c (linux_nat_target::async): Likewise.
2714 * run-on-main-thread.c (_initialize_run_on_main_thread):
2716 * ser-base.c (reschedule): Likewise.
2717 (ser_base_async): Likewise.
2718 * tui/tui-io.c: Likewise.
2719 * top.h (struct ui) <num>: New field.
2720 * top.c (highest_ui_num): New variable.
2721 (ui::ui): Initialize num.
2725 * observable.h <inferior_created>: Remove parameters. Update all
2727 * inferior.h (post_create_inferior): Remove target parameter.
2732 * dwarf2/macro.c (dwarf_decode_macro_bytes): Handle DW_MACRO_define_strx
2733 and DW_MACRO_undef_strx.
2734 (dwarf_decode_macros): Likewise
2735 * dwarf2/read.c (dwarf_decode_macros): Pass str_offsets_base in the parameters
2736 which is the value of DW_AT_str_offsets_base.
2737 * dwarf2/macro.h (dwarf_decode_macros): Modify the definition to include
2742 * i386-tdep.h (i386nbsd_sc_reg_offset): Remove.
2746 * i386-bsd-nat.c (_initialize_i386bsd_nat): Update.
2747 * i386-nbsd-tdep.c (i386nbsd_sc_reg_offset): Now static.
2751 * i386-bsd-nat.c: Include "x86-bsd-nat.h".
2756 * dwarf2/read.c (dwarf2_name): Update attr_name after attr is updated.
2760 * dwarf2/read.c (handle_variant): Use constant_value.
2764 * dwarf2/read.c (lookup_dwo_id, get_type_unit_group)
2765 (read_file_scope, dwarf2_get_pc_bounds)
2766 (dwarf2_record_block_ranges, dwarf2_add_field, get_alignment)
2767 (read_structure_type, handle_struct_member_die)
2768 (read_enumeration_type, read_array_type, read_set_type)
2769 (read_tag_pointer_type, read_tag_reference_type)
2770 (read_subroutine_type, read_base_type, read_subrange_type)
2771 (read_full_die_1, partial_die_info::read)
2772 (partial_die_info::read, by, new_symbol)
2773 (dwarf2_const_value_data, dwarf2_const_value_attr)
2774 (dump_die_shallow, dwarf2_fetch_constant_bytes)
2775 (prepare_one_comp_unit): Update.
2776 * dwarf2/attribute.h (DW_UNSND): Remove.
2780 * dwarf2/read.c (read_func_scope, prototyped_function_p)
2781 (read_subroutine_type, partial_die_info::read)
2782 (dwarf2_flag_true_p, new_symbol, dump_die_shallow)
2783 (dwarf2_add_member_fn): Update.
2784 * dwarf2/attribute.h (struct attribute) <as_boolean>: Declare.
2785 * dwarf2/attribute.c (attribute::as_boolean): New method.
2789 * dwarf2/read.c (dwarf2_add_field, dwarf2_add_member_fn): Update.
2790 * dwarf2/attribute.h (struct attribute) <as_virtuality>: New
2792 * dwarf2/attribute.c (attribute::as_virtuality): New method.
2796 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: Check
2797 the attribute's form.
2801 * dwarf2/read.c (is_valid_DW_AT_defaulted): Move to attribute.c.
2802 (dwarf2_add_member_fn): Update.
2803 * dwarf2/attribute.h (struct attribute) <defaulted>: Declare.
2804 * dwarf2/attribute.c (attribute::defaulted): New method, from
2805 is_valid_DW_AT_defaulted.
2809 * dwarf2/read.c (dw2_get_file_names_reader)
2810 (dwarf2_build_include_psymtabs, handle_DW_AT_stmt_list)
2811 (dwarf2_cu::setup_type_unit_groups, fill_in_loclist_baton)
2812 (dwarf2_symbol_mark_computed): Use as_unsigned.
2813 * dwarf2/attribute.h (struct attribute) <as_unsigned>: New
2815 <form_is_section_offset>: Update comment.
2819 * dwarf2/read.c (dwarf2_access_attribute): Rename from
2820 dwarf2_default_access_attribute. Look up attribute.
2821 (dwarf2_add_field, dwarf2_add_type_defn, dwarf2_add_member_fn):
2826 * dwarf2/read.c (skip_one_die): Update.
2827 (read_full_die_1): Change how reprocessing is done.
2828 (partial_die_info::read): Update.
2829 (read_attribute_value): Remove need_reprocess parameter.
2830 (read_attribute): Likewise.
2831 * dwarf2/attribute.h (struct attribute) <requires_reprocessing_p>:
2836 * dwarf2/read.c (read_attribute_reprocess, read_attribute_value)
2837 (dwarf2_const_value_attr, dump_die_shallow)
2838 (dwarf2_fetch_constant_bytes): Update.
2839 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Update
2841 <set_address>: New method.
2843 * dwarf2/attribute.c (attribute::form_is_ref): Update comment.
2844 (attribute::as_string, attribute::as_address): Add assert.
2848 * dwarf2/read.c (read_cutu_die_from_dwo): Use OBSTACK_ZALLOC.
2849 (read_attribute_reprocess, read_attribute_value): Update.
2850 (read_attribute): Clear requires_reprocessing.
2851 * dwarf2/attribute.h (struct attribute) <as_unsigned_reprocess,
2852 form_requires_reprocessing>: New methods.
2853 <string_init>: Clear requires_reprocessing.
2854 <set_unsigned_reprocess>: New method.
2855 <name>: Shrink by one bit.
2856 <requires_reprocessing>: New member.
2857 * dwarf2/attribute.c (attribute::form_requires_reprocessing): New
2862 * dwarf2/read.c (read_attribute_value): Update.
2863 * dwarf2/attribute.h (struct attribute) <form_is_unsigned,
2864 set_unsigned>: New methods.
2865 * dwarf2/attribute.c (attribute::form_is_unsigned): New method.
2869 * dwarf2/read.c (get_alignment, read_array_order)
2870 (read_attribute_value, dwarf2_const_value_attr)
2871 (dump_die_shallow, dwarf2_fetch_constant_bytes): Update.
2872 * dwarf2/attribute.h (struct attribute) <as_signed, set_signed>:
2878 * dwarf2/read.c (read_attribute_value, lookup_die_type)
2879 (dump_die_shallow, follow_die_sig, get_DW_AT_signature_type):
2881 * dwarf2/attribute.h (struct attribute) <as_signature,
2882 set_signature>: New methods.
2883 (DW_SIGNATURE): Remove.
2887 * dwarf2/read.c (read_call_site_scope)
2888 (handle_data_member_location, dwarf2_add_member_fn)
2889 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
2890 (partial_die_info::read, read_attribute_value)
2891 (var_decode_location, dwarf2_const_value_attr, dump_die_shallow)
2892 (dwarf2_fetch_die_loc_sect_off, dwarf2_fetch_constant_bytes)
2893 (dwarf2_symbol_mark_computed): Update.
2894 * dwarf2/attribute.h (struct attribute) <as_block, set_block>: New
2897 * dwarf2/attribute.c (attribute::form_is_block): Add
2902 * dwarf2/read.c (read_cutu_die_from_dwo)
2903 (read_attribute_reprocess, read_attribute_value, read_attribute)
2904 (dwarf2_const_value_attr, dwarf2_name, dump_die_shallow)
2905 (dwarf2_fetch_constant_bytes): Update.
2906 * dwarf2/attribute.h (struct attribute) <form_is_string>: Declare.
2907 <set_string_noncanonical, set_string_canonical>: New methods.
2908 <string_is_canonical>: Update comment.
2909 <canonical_string_p>: Add assert.
2910 (DW_STRING, DW_STRING_IS_CANONICAL): Remove.
2911 * dwarf2/attribute.c (attribute::form_is_string): New method.
2912 (attribute::string): Use it.
2916 * dwarf2/read.c (anonymous_struct_prefix, dwarf2_name)
2917 (dump_die_shallow): Use canonical_string_p.
2918 * dwarf2/attribute.h (struct attribute) <canonical_string_p>: New
2923 * dwarf2/read.c (partial_die_info::read)
2924 (dwarf2_const_value_attr, anonymous_struct_prefix, )
2925 (dwarf2_name, dwarf2_fetch_constant_bytes): Use
2926 attribute::as_string.
2930 * dwarf2/attribute.c (attribute::address): Don't use DW_UNSND or
2932 (attribute::string): Don't use DW_STRING.
2933 (attribute::get_ref_die_offset): Don't use DW_UNSND.
2934 (attribute::constant_value): Don't use DW_UNSND or DW_SND.
2938 * dwarf2/read.c (dwarf2_find_base_address, read_call_site_scope)
2939 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
2940 (partial_die_info::read, dwarf2_string_attr, new_symbol): Update.
2941 * dwarf2/attribute.h (struct attribute): Rename methods.
2942 * dwarf2/attribute.c (attribute::as_address): Rename from
2944 (attribute::as_string): Rename from value_as_string.
2948 * dwarf2/read.c (partial_die_info::read) <case
2949 DW_AT_linkage_name>: Use value_as_string.
2950 (dwarf2_string_attr): Use value_as_string.
2951 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
2953 * dwarf2/attribute.c (attribute::value_as_string): New method.
2957 * unittests/enum-flags-selftests.c: Check whether __GNUC__ is
2958 defined before using '#pragma GCC diagnostic' instead of checking
2963 * infrun.c (displaced_step_fixup, thread_still_needs_step_over)
2964 (handle_signal_stop): Update.
2965 * procfs.c (procfs_target::insert_watchpoint): Update.
2966 * target.h (target_have_steppable_watchpoint): Now a function.
2970 * infrun.c (set_schedlock_func): Update.
2971 * target.h (target_can_lock_scheduler): Now a function.
2975 * inferior.h (class inferior) <has_execution>: Update.
2976 * windows-tdep.c (windows_solib_create_inferior_hook): Update.
2977 * valops.c (find_function_in_inferior)
2978 (value_allocate_space_in_inferior): Update.
2979 * top.c (kill_or_detach): Update.
2980 * target.c (target_preopen, set_target_permissions): Update.
2981 (target_has_execution_current): Remove.
2982 * sparc64-tdep.c (adi_examine_command, adi_assign_command):
2984 * solib.c (update_solib_list, reload_shared_libraries): Update.
2985 * solib-svr4.c (svr4_solib_create_inferior_hook): Update.
2986 * solib-dsbt.c (enable_break): Update.
2987 * score-tdep.c (score7_fetch_inst): Update.
2988 * rs6000-nat.c (rs6000_nat_target::xfer_shared_libraries):
2990 * remote.c (remote_target::start_remote)
2991 (remote_target::remote_check_symbols, remote_target::open_1)
2992 (remote_target::remote_detach_1, remote_target::verify_memory)
2993 (remote_target::xfer_partial, remote_target::read_description)
2994 (remote_target::get_min_fast_tracepoint_insn_len): Update.
2995 * record-full.c (record_full_open_1): Update.
2996 * record-btrace.c (record_btrace_target_open): Update.
2997 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2998 (value_nsstring): Update.
2999 * linux-thread-db.c (add_thread_db_info)
3000 (thread_db_find_new_threads_silently, check_thread_db_callback)
3001 (try_thread_db_load_1, record_thread): Update.
3002 * linux-tdep.c (linux_info_proc, linux_vsyscall_range_raw):
3004 * linux-fork.c (checkpoint_command): Update.
3005 * infrun.c (set_non_stop, set_observer_mode)
3006 (check_multi_target_resumption, for_each_just_stopped_thread)
3007 (maybe_remove_breakpoints, normal_stop)
3008 (class infcall_suspend_state): Update.
3009 * infcmd.c (ERROR_NO_INFERIOR, kill_if_already_running)
3010 (info_program_command, attach_command): Update.
3011 * infcall.c (call_function_by_hand_dummy): Update.
3012 * inf-loop.c (inferior_event_handler): Update.
3013 * gcore.c (gcore_command, derive_heap_segment): Update.
3014 * exec.c (exec_file_command): Update.
3015 * eval.c (evaluate_subexp): Update.
3016 * compile/compile.c (compile_to_object): Update.
3017 * cli/cli-dump.c (restore_command): Update.
3018 * breakpoint.c (update_watchpoint)
3019 (update_inserted_breakpoint_locations)
3020 (insert_breakpoint_locations, get_bpstat_thread): Update.
3021 * target.h (target_has_execution): Remove macro.
3022 (target_has_execution_current): Don't declare.
3023 (target_has_execution): Rename from target_has_execution_1. Add
3028 * mi/mi-main.c (exec_reverse_continue)
3029 (mi_cmd_list_target_features): Update.
3030 * infrun.c (set_exec_direction_func): Update.
3031 * target.c (default_execution_direction): Update.
3032 * reverse.c (exec_reverse_once): Update.
3033 * target.h (target_can_execute_reverse): Now a function.
3037 * tui/tui-regs.c (tui_get_register)
3038 (tui_data_window::show_registers): Update.
3039 * thread.c (scoped_restore_current_thread::restore)
3040 (scoped_restore_current_thread::scoped_restore_current_thread):
3042 * regcache-dump.c (regcache_print): Update.
3043 * python/py-finishbreakpoint.c (bpfinishpy_detect_out_scope_cb):
3045 * mi/mi-main.c (mi_cmd_data_write_register_values): Update.
3046 * mep-tdep.c (current_me_module, current_options): Update.
3047 * linux-thread-db.c (thread_db_load): Update.
3048 * infcmd.c (registers_info, info_vector_command)
3049 (info_float_command): Update.
3050 * ia64-tdep.c (ia64_frame_prev_register)
3051 (ia64_sigtramp_frame_prev_register): Update.
3052 * ia64-libunwind-tdep.c (libunwind_frame_prev_register): Update.
3053 * gcore.c (derive_stack_segment): Update.
3054 * frame.c (get_current_frame, has_stack_frames): Update.
3055 * findvar.c (language_defn::read_var_value): Update.
3056 * arm-tdep.c (arm_pc_is_thumb): Update.
3057 * target.c (target_has_registers): Rename from
3058 target_has_registers_1.
3059 * target.h (target_has_registers): Remove macro.
3060 (target_has_registers): Rename from target_has_registers_1.
3064 * windows-tdep.c (tlb_make_value): Update.
3065 * tui/tui-regs.c (tui_data_window::show_registers): Update.
3066 * thread.c (scoped_restore_current_thread::restore)
3067 (scoped_restore_current_thread::scoped_restore_current_thread)
3068 (thread_command): Update.
3069 * stack.c (backtrace_command_1, frame_apply_level_command)
3070 (frame_apply_all_command, frame_apply_command): Update.
3071 * infrun.c (siginfo_make_value, restore_infcall_control_state):
3073 * gcore.c (derive_stack_segment): Update.
3074 * frame.c (get_current_frame, has_stack_frames): Update.
3075 * auxv.c (info_auxv_command): Update.
3076 * ada-tasks.c (ada_build_task_list): Update.
3077 * target.c (target_has_stack): Rename from target_has_stack_1.
3078 * target.h (target_has_stack): Remove macro.
3079 (target_has_stack): Rename from target_has_stack_1.
3083 * target.c (target_has_memory): Rename from target_has_memory_1.
3084 * tui/tui-regs.c (tui_data_window::show_registers): Update.
3085 * thread.c (scoped_restore_current_thread::restore)
3086 (scoped_restore_current_thread::scoped_restore_current_thread):
3088 * frame.c (get_current_frame, has_stack_frames): Update.
3089 * target.h (target_has_memory): Remove macro.
3090 (target_has_memory): Rename from target_has_memory_1.
3094 * target.c (target_has_all_memory_1): Remove.
3095 * target.h (target_has_all_memory): Remove define.
3096 (target_has_all_memory_1): Don't declare.
3100 * ser-base.c: Adjust comments formatting.
3105 * tui/tui-io.c (tui_puts): Rewrite. Move earlier.
3110 * tui/tui-winsource.c (tui_copy_source_line): Use ISNCTRL.
3114 * unittests/tui-selftests.c: Update.
3115 * tui/tui-winsource.h (struct tui_source_window_base)
3116 <extra_margin, show_line_number, refresh_pad>: New methods.
3117 <m_max_length, m_pad>: New members.
3118 (tui_copy_source_line): Update.
3119 * tui/tui-winsource.c (tui_copy_source_line): Remove line_no,
3120 first_col, line_width, ndigits parameters. Add length.
3121 (tui_source_window_base::show_source_line): Write to pad. Line
3123 (tui_source_window_base::refresh_pad): New method.
3124 (tui_source_window_base::show_source_content): Write to pad. Call
3126 (tui_source_window_base::do_scroll_horizontal): Call refresh_pad,
3128 (tui_source_window_base::update_exec_info): Call
3130 * tui/tui-source.h (struct tui_source_window) <extra_margin>: New
3132 <m_digits>: New member.
3133 * tui/tui-source.c (tui_source_window::set_contents): Set m_digits
3135 (tui_source_window::show_line_number): New method.
3136 * tui/tui-io.h (tui_puts): Fix comment.
3137 * tui/tui-disasm.c (tui_disasm_window::set_contents): Set
3142 * tui/tui-winsource.c
3143 (tui_source_window_base::set_is_exec_point_at): Don't call
3148 * python/py-tui.c (class tui_py_window) <refresh_window>: New
3151 <cursor_x, cursor_y>: Remove.
3152 <m_inner_window>: New member.
3153 (tui_py_window::rerender): Create inner window.
3154 (tui_py_window::output): Write to inner window.
3159 * cli/cli-script.c (execute_control_commands): don't set
3160 instream to nullptr here as this breaks the from_tty argument
3161 to gdb.execute in Python.
3162 (execute_user_command): set instream to nullptr here instead.
3166 * infrun.h (infrun_debug_printf): Fix formatting.
3167 * linux-nat.c (linux_nat_debug_printf): Fix formatting.
3171 * compile/compile-object-load.h (struct munmap_list): Add
3172 explicitly-defined move constructor.
3177 * tui/tui-stack.h (struct tui_locator_window) <can_focus>: New
3179 * tui/tui-data.h (struct tui_win_info) <can_focus>: New method.
3180 * tui/tui-data.c (tui_next_win): Exclude non-focusable windows.
3181 (tui_prev_win): Rewrite.
3185 * nat/windows-nat.c (handle_exception): Handle 64bit breakpoints
3186 in WOW64 processes as SIGINT.
3187 * nat/windows-nat.h: Make wow64_process a shared variable.
3188 * windows-nat.c: Remove static wow64_process variable.
3193 * value.c (unpack_long, pack_long, pack_unsigned_long): Handle bit
3194 offset and bit size.
3195 * printcmd.c (print_scalar_formatted): Handle zero-length
3197 (print_scalar_formatted): Use bit_size_differs_p.
3198 * gdbtypes.h (enum type_specific_kind) <TYPE_SPECIFIC_INT>: New
3200 (union type_specific): <int_stuff>: New member.
3201 (struct type) <bit_size_differs_p, bit_size, bit_offset>: New
3203 * gdbtypes.c (init_integer_type, init_boolean_type): Initialize
3204 TYPE_SPECIFIC_FIELD.
3205 (recursive_dump_type, copy_type_recursive): Update.
3206 * dwarf2/read.c (read_base_type): Handle DW_AT_bit_size and
3207 DW_AT_data_bit_offset.
3211 * utils.h (class gdb_argv): Add move operators.
3212 <append>: New methods.
3213 * compile/compile.c (build_argc_argv): Remove.
3214 (compile_args_argc): Remove.
3215 (compile_args_argv): Change type.
3216 (set_compile_args): Simplify.
3217 (append_args): Remove.
3218 (filter_args): Remove argcp parameter.
3219 (get_args): Return gdb_argv. Simplify.
3220 (compile_to_object): Update.
3224 * compile/compile-object-run.c (do_module_cleanup)
3225 <~do_module_cleanup> :Remove.
3226 (do_module_cleanup): Update.
3227 * compile/compile-object-load.h (struct munmap_list): Add move
3228 assignment operator.
3229 <source_file>: Now a std::string.
3230 <munmap_list>: Rename. No longer a pointer.
3231 * compile/compile-object-load.c (struct setup_sections_data): Add
3233 <setup_one_section>: Declare.
3234 <munmap_list>: Move earlier.
3235 <m_bfd>: New member.
3236 <m_last_size, m_last_section_first, m_last_prot,
3237 m_last_max_alignment>: Rename, add initializers where needed.
3238 (setup_sections_data::setup_one_section): Rename from
3239 setup_sections. Update.
3240 (compile_object_load): Update. Don't use bfd_map_over_sections.
3244 * compile/compile-object-run.c (struct do_module_cleanup): Add
3245 parameters to constructor. Update destructor.
3246 <source_file, scope, scope_data, out_value_type, out_value_addr,
3247 munmap_list_head, objfile_name_string>: Remove.
3248 <module>: New member.
3249 (do_module_cleanup): Update.
3250 (compile_object_run): Update.
3254 * compile/compile.c (eval_compile_command): Update.
3255 * compile/compile-object-run.h (compile_object_run): Take a
3257 * compile/compile-object-run.c (compile_object_run): Take a
3259 * compile/compile-object-load.h (struct compile_module): Add
3260 constructor, destructor.
3261 (compile_module_up): New typedef.
3262 (compile_object_load): Return compile_object_up.
3263 * compile/compile-object-load.c (compile_object_load): Return
3268 * compile/compile-object-run.c (struct do_module_cleanup): Add
3269 constructor, destructor.
3270 <objfile_name_string>: Don't use struct hack.
3271 (do_module_cleanup): Use delete.
3272 (compile_object_run): Use new.
3276 * compile/compile-cplus-types.c
3277 (compile_cplus_convert_struct_or_union): Use std::vector.
3278 (compile_cplus_convert_func): Likewise.
3279 * compile/compile-c-types.c (convert_func): Use std::vector.
3283 * sparc-tdep.c (sparc32_skip_prologue): Use
3284 skip_prologue_using_sal.
3288 * symfile.c (add_section_size_callback): Remove.
3289 (load_one_section): Rename from load_section_callback. Change
3291 (generic_load): Use foreach.
3295 * exec.c (add_to_section_table): Remove.
3296 (build_section_table): Use foreach.
3300 * elfread.c (elf_locate_sections): Change parameters.
3301 (elf_symfile_read): Use foreach.
3305 * cli/cli-dump.c (struct callback_data): Remove.
3306 (restore_one_section): Rename from restore_section_callback.
3308 (restore_binary_file): Change parameters.
3309 (restore_command): Use foreach.
3313 * gcore.c (make_output_phdrs): Remove 'ignored' parameter.
3314 (gcore_copy_callback): Likewise.
3315 (gcore_memory_sections): Use foreach.
3319 * osabi.h (generic_elf_osabi_sniff_abi_tag_sections): Update.
3320 * osabi.c (generic_elf_osabi_sniff_abi_tag_sections): Change
3322 (generic_elf_osabi_sniffer): Use foreach.
3323 * mips-sde-tdep.c (mips_sde_elf_osabi_sniffer): Use foreach.
3324 * arm-tdep.c (arm_elf_osabi_sniffer): Use foreach.
3328 * dwarf2/read.c (locate_dwz_sections): Change parameters.
3329 (dwarf2_get_dwz_file): Use foreach.
3330 (dwarf2_locate_dwo_sections): Change parameters.
3331 (open_and_init_dwo_file): Use foreach.
3332 (dwarf2_locate_common_dwp_sections): Change parameters.
3333 (open_and_init_dwp_file): Use foreach.
3337 * symfile.h: (find_lowest_section): Don't declare.
3338 * symfile.c (find_lowest_section): Now static. Change
3340 (struct place_section_arg): Remove.
3341 (place_section): Change parameters.
3342 (addr_info_make_relative): Use foreach.
3343 (symfile_dummy_outputs): Remove.
3344 (default_symfile_relocate): Use foreach.
3348 * objfiles.c (add_to_objfile_sections): Rename from
3349 add_to_objfile_sections_full.
3350 (add_to_objfile_sections): Remove.
3351 (build_objfile_section_table): Use foreach.
3355 * stap-probe.c (get_stap_base_address_1): Remove.
3356 (get_stap_base_address): Use foreach.
3360 * gdb_bfd.c (free_one_bfd_section): Remove 'abfd' and 'ignore'
3362 (gdb_bfd_close_or_warn): Use foreach.
3366 * corelow.c (add_to_thread_list): Change parameters.
3367 (core_target_open): Use foreach.
3371 * gdb_bfd.h (gdb_bfd_sections): New overload. Fix formatting of
3376 * f-valprint.c (f77_print_array_1): Adjust printing of whitespace
3381 * eval.c: Remove 'f-lang.h' include.
3382 (value_f90_subarray): Moved to f-lang.c.
3383 (eval_call): Renamed to...
3384 (evaluate_subexp_do_call): ...this, is no longer static, header
3385 comment moved into header file.
3386 (evaluate_funcall): Update call to eval_call.
3387 (skip_undetermined_arglist): Moved to f-lang.c.
3388 (fortran_value_subarray): Likewise.
3389 (evaluate_subexp_standard): OP_F77_UNDETERMINED_ARGLIST handling
3390 moved to evaluate_subexp_f.
3391 (calc_f77_array_dims): Moved to f-lang.c
3392 * expprint.c (print_subexp_funcall): New function.
3393 (print_subexp_standard): OP_F77_UNDETERMINED_ARGLIST handling
3394 moved to print_subexp_f, OP_FUNCALL uses new function.
3395 (dump_subexp_body_funcall): New function.
3396 (dump_subexp_body_standard): OP_F77_UNDETERMINED_ARGLIST handling
3397 moved to dump_subexp_f, OP_FUNCALL uses new function.
3398 * expression.h (evaluate_subexp_do_call): Declare.
3399 * f-lang.c (value_f90_subarray): Moved from eval.c.
3400 (skip_undetermined_arglist): Likewise.
3401 (calc_f77_array_dims): Likewise.
3402 (fortran_value_subarray): Likewise.
3403 (evaluate_subexp_f): Add OP_F77_UNDETERMINED_ARGLIST support.
3404 (operator_length_f): Likewise.
3405 (print_subexp_f): Likewise.
3406 (dump_subexp_body_f): Likewise.
3407 * fortran-operator.def (OP_F77_UNDETERMINED_ARGLIST): Move
3408 declaration of this operation to here.
3409 * parse.c (operator_length_standard): OP_F77_UNDETERMINED_ARGLIST
3410 support moved to operator_length_f.
3411 * parser-defs.h (dump_subexp_body_funcall): Declare.
3412 (print_subexp_funcall): Declare.
3413 * std-operator.def (OP_F77_UNDETERMINED_ARGLIST): Moved to
3414 fortran-operator.def.
3418 * eval.c (fortran_value_subarray): New function, content is taken
3420 (evaluate_subexp_standard): ...here, in two places. Now arrays
3421 and strings both call the new function.
3422 (calc_f77_array_dims): Add header comment, handle strings.
3427 * i386-tdep.c (i386_skip_endbr): Add a helper function to skip endbr.
3428 (i386_analyze_prologue): Call i386_skip_endbr.
3432 * windows-nat.c (struct windows_nat_target) <wait>: Update.
3433 (windows_nat_target::wait): Update.
3434 * target/wait.h (enum target_wait_flag): New. Use
3435 DEF_ENUM_FLAGS_TYPE.
3436 * target/target.h (target_wait): Change type of options.
3437 * target.h (target_options_to_string, default_target_wait):
3439 (struct target_ops) <wait>: Change type of options.
3440 * target.c (target_wait, default_target_wait, do_option): Change
3442 (target_options_to_string): Likewise.
3443 * target-delegates.c: Rebuild.
3444 * target-debug.h (target_debug_print_target_wait_flags): Rename
3445 from target_debug_print_options.
3446 * sol-thread.c (class sol_thread_target) <wait>: Update.
3447 (sol_thread_target::wait): Update.
3448 * rs6000-nat.c (class rs6000_nat_target) <wait>: Update.
3449 (rs6000_nat_target::wait): Update.
3450 * remote.c (class remote_target) <wait, wait_ns, wait_as>:
3452 (remote_target::wait_ns, remote_target::wait_as): Change type of
3454 (remote_target::wait): Update.
3455 * remote-sim.c (struct gdbsim_target) <wait>: Update.
3456 (gdbsim_target::wait): Update.
3457 * record-full.c (class record_full_base_target) <wait>: Update.
3458 (record_full_wait_1): Change type of "options".
3459 (record_full_base_target::wait): Update.
3460 * record-btrace.c (class record_btrace_target) <wait>: Update.
3461 (record_btrace_target::wait): Update.
3462 * ravenscar-thread.c (struct ravenscar_thread_target) <wait>:
3464 (ravenscar_thread_target::wait): Update.
3465 * procfs.c (class procfs_target) <wait>: Update.
3466 (procfs_target::wait): Update.
3467 * obsd-nat.h (class obsd_nat_target) <wait>: Update.
3468 * obsd-nat.c (obsd_nat_target::wait): Update.
3469 * nto-procfs.c (struct nto_procfs_target) <wait>: Update.
3470 (nto_procfs_target::wait): Update.
3471 * nbsd-nat.h (struct nbsd_nat_target) <wait>: Update.
3472 * nbsd-nat.c (nbsd_wait): Change type of "options".
3473 (nbsd_nat_target::wait): Update.
3474 * linux-thread-db.c (class thread_db_target) <wait>: Update.
3475 (thread_db_target::wait): Update.
3476 * linux-nat.h (class linux_nat_target) <wait>: Update.
3477 * linux-nat.c (linux_nat_target::wait): Update.
3478 (linux_nat_wait_1): Update.
3479 * infrun.c (do_target_wait_1, do_target_wait): Change type of
3481 * inf-ptrace.h (struct inf_ptrace_target) <wait>: Update.
3482 * inf-ptrace.c (inf_ptrace_target::wait): Update.
3483 * go32-nat.c (struct go32_nat_target) <wait>: Update.
3484 (go32_nat_target::wait): Update.
3485 * gnu-nat.h (struct gnu_nat_target) <wait>: Update.
3486 * gnu-nat.c (gnu_nat_target::wait): Update.
3487 * fbsd-nat.h (class fbsd_nat_target) <wait>: Update.
3488 * fbsd-nat.c (fbsd_nat_target::wait): Update.
3489 * darwin-nat.h (class darwin_nat_target) <wait>: Update.
3490 * darwin-nat.c (darwin_nat_target::wait): Update.
3491 * bsd-uthread.c (struct bsd_uthread_target) <wait>: Update.
3492 (bsd_uthread_target::wait): Update.
3493 * aix-thread.c (class aix_thread_target) <wait>: Update.
3494 (aix_thread_target::wait): Update.
3498 * compile/compile-object-run.c (create_copied_type_recursive): New
3500 (compile_object_run): Use new function.
3504 * NEWS: Mention x86_64 Cygwin core file support.
3508 * windows-tdep.c (NOTE_INFO_MODULE, NOTE_INFO_MODULE64): Define.
3509 (core_process_module_section): Handle NOTE_INFO_MODULE64.
3513 * windows-tdep.h: Add prototypes.
3514 * i386-windows-tdep.c(windows_core_xfer_shared_libraries): Move.
3515 (i386_windows_core_pid_to_str): Move and rename ...
3516 * windows-tdep.c (windows_core_xfer_shared_libraries): ... to here
3517 (windows_core_pid_to_str): ... and here.
3518 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Register here.
3521 * amd64-windows-tdep.c(amd64_windows_gregset_reg_offset): Add.
3522 (amd64_windows_init_abi_common): ... and register.
3526 * amd64-windows-tdep.c (amd64_cygwin_core_osabi_sniffer): New.
3527 (_initialize_amd64_windows_tdep): Register amd64_cygwin_core_osabi_sniffer.
3532 * thread.c (thread_find_command): Switch inferior before calling
3537 * tic6x-tdep.c (tic6x_gdbarch_init): Update.
3538 * target-descriptions.h (struct tdesc_arch_data_deleter): New.
3539 (tdesc_arch_data_up): New typedef.
3540 (tdesc_use_registers, tdesc_data_alloc): Update.
3541 (tdesc_data_cleanup): Don't declare.
3542 * target-descriptions.c (tdesc_data_alloc): Return a
3544 (tdesc_arch_data_deleter::operator()): Rename from
3545 tdesc_data_cleanup. Change argument type.
3546 (tdesc_use_registers): Change early_data to an rvalue reference.
3547 (tdesc_use_registers): Don't use delete.
3548 * sparc-tdep.c (sparc32_gdbarch_init): Update.
3549 * s390-tdep.c (s390_gdbarch_init): Update.
3550 * rx-tdep.c (rx_gdbarch_init): Update.
3551 * rs6000-tdep.c (rs6000_gdbarch_init): Update.
3552 * riscv-tdep.c (riscv_gdbarch_init): Update.
3553 * or1k-tdep.c (or1k_gdbarch_init): Update.
3554 * nios2-tdep.c (nios2_gdbarch_init): Update.
3555 * nds32-tdep.c (nds32_gdbarch_init): Update.
3556 * mips-tdep.c (mips_gdbarch_init): Update.
3557 * microblaze-tdep.c (microblaze_gdbarch_init): Update.
3558 * m68k-tdep.c (m68k_gdbarch_init): Update.
3559 * i386-tdep.c (i386_gdbarch_init): Update.
3560 * arm-tdep.c (arm_gdbarch_init): Update.
3561 * arc-tdep.c (arc_tdesc_init): Update.
3562 (arc_gdbarch_init): Update.
3563 * aarch64-tdep.c (aarch64_gdbarch_init): Update.
3567 * windows-nat.c (ctrl_c_handler): Use 32bit DbgUiRemoteBreakin
3568 for WOW64 processes.
3572 * dwarf2/read.c (compute_compunit_symtab_includes): Use htab_up.
3576 * value.c (preserve_values): Update.
3577 * python/py-type.c (save_objfile_types): Update.
3578 * guile/scm-type.c (save_objfile_types): Update.
3579 * gdbtypes.h (create_copied_types_hash): Return htab_up.
3580 * gdbtypes.c (create_copied_types_hash): Return htab_up.
3581 * compile/compile-object-run.c (compile_object_run): Update.
3585 * typeprint.h (class typedef_hash_table) <~typedef_hash_table>:
3587 <m_table>: Now htab_up.
3588 * typeprint.c (typedef_hash_table::recursively_update)
3589 (typedef_hash_table::add_template_parameters)
3590 (typedef_hash_table::typedef_hash_table): Update.
3591 (typedef_hash_table::~typedef_hash_table): Remove.
3592 (typedef_hash_table::typedef_hash_table)
3593 (typedef_hash_table::find_global_typedef)
3594 (typedef_hash_table::find_typedef): Update.
3598 * target-descriptions.c (tdesc_use_registers): Use htab_up.
3602 * linespec.c (class decode_compound_collector)
3603 <~decode_compound_collector>: Remove.
3604 <m_unique_syms>: Now htab_up.
3605 (decode_compound_collector::operator ()): Update.
3606 (class symtab_collector) <~symtab_collector>: Remove.
3607 <m_symtab_table>: Now htab_up.
3608 (symtab_collector::operator ()): Update.
3612 * filename-seen-cache.c (filename_seen_cache::filename_seen_cache)
3613 (filename_seen_cache::clear): Update.
3614 (~filename_seen_cache): Remove.
3615 (filename_seen_cache::seen): Update.
3616 * filename-seen-cache.h (class filename_seen_cache) <m_tab>: Now
3618 <~filename_seen_cache>: Remove.
3623 * completer.c (completion_tracker::discard_completions)
3624 (completion_tracker::~completion_tracker)
3625 (completion_tracker::maybe_add_completion)
3626 (completion_tracker::remove_completion)
3627 (completion_tracker::recompute_lowest_common_denominator)
3628 (completion_tracker::build_completion_result): Update.
3629 * completer.h (class completion_tracker) <have_completions>:
3631 <m_entries_hash>: Now htab_up.
3635 * breakpoint.c (ambiguous_names_p): Use htab_up.
3639 * auto-load.c (struct auto_load_pspace_info)
3640 <~auto_load_pspace_info, auto_load_pspace_info>: Remove.
3641 <loaded_script_files, loaded_script_texts>: Change type to
3643 (~auto_load_pspace_info) Remove.
3644 (init_loaded_scripts_info, maybe_add_script_file)
3645 (maybe_add_script_text, auto_load_info_scripts): Update.
3649 * c-exp.y (name_obstack): Now static.
3653 * riscv-tdep.c (riscv-insn::decode): Fix recorded insn type.
3657 * breakpoint.h (init_catchpoint): Change int parameter to bool.
3658 (add_solib_catchpoint): Likewise.
3659 * breakpoint.c (struct solib_catchpoint) <is_load>: Change type
3661 (add_solib_catchpoint): Change int parameter/variable to bool.
3662 (catch_load_or_unload): Likewise.
3663 (init_catchpoint): Likewise.
3664 (create_fork_vfork_event_catchpoint): Likewise.
3665 (catch_fork_command_1): Likewise.
3666 (catch_exec_command_1): Likewise.
3670 * gdb-gdb.py.in (class StructTypePrettyPrinter) <to_string>:
3671 Change instance_flags to m_instance_flags.
3676 * infrun.c (fill_in_stop_func): Use find_pc_partial_function_sym.
3680 * fbsd-nat.c (fbsd_nat_target::wait): Always check for
3682 (fbsd_nat_target::insert_exec_catchpoint)
3683 (fbsd_nat_target::remove_exec_catchpoint): Always define.
3684 * fbsd-nat.h (fbsd_nat_target::insert_exec_catchpoint)
3685 (fbsd_nat_target::remove_exec_catchpoint): Always declare.
3689 * configure.ac: Remove check for kinfo_getvmmap().
3690 * configure, config.in: Regenerate.
3691 * fbsd-nat.c (fbsd_read_mapping): Remove
3692 (fbsd_nat_target::find_memory_regions): Remove the procfs version.
3693 (fbsd_nat_target::info_proc): Assume kinfo_getfile() and
3694 kinfo_get_vmmap() are always present.
3698 * fbsd-nat.c: Always include support for
3699 TARGET_OBJECT_SIGNAL_INFO.
3703 * fbsd-nat.c (fbsd_nat_target::pid_to_exec_file): Always use
3704 sysctl and remove procfs fallback.
3708 * fbsd-nat.c: Assume PT_LWPINFO is always defined.
3709 * fbsd-nat.h: Likewise.
3713 * breakpoint.c (commands_command_1): Make a copy of the 'arg'
3718 * ada-lang.c (ada_language_data): Delete.
3719 (ada_language): Remove references to ada_language_data.
3720 * c-lang.c (c_language_data): Delete.
3721 (c_language): Remove references to c_language_data.
3722 (cplus_language_data): Delete.
3723 (cplus_language): Remove references to cplus_language_data.
3724 (asm_language_data): Delete.
3725 (asm_language): Remove references to asm_language_data.
3726 (minimal_language_data): Delete.
3727 (minimal_language): Remove references to minimal_language_data.
3728 * d-lang.c (d_language_data): Delete.
3729 (d_language): Remove references to d_language_data.
3730 * f-lang.c (f_language_data): Delete.
3731 (f_language): Remove references to f_language_data.
3732 * go-lang.c (go_language_data): Delete.
3733 (go_language): Remove references to go_language_data.
3734 * language.c (unknown_language_data): Delete.
3735 (unknown_language): Remove references to unknown_language_data.
3736 (auto_language_data): Delete.
3737 (auto_language): Remove references to auto_language_data.
3738 * language.h (language_data): Delete struct.
3739 (language_defn): No longer inherit from language_data.
3740 * m2-lang.c (m2_language_data): Delete.
3741 (m2_language): Remove references to m2_language_data.
3742 * objc-lang.c (objc_language_data): Delete.
3743 (objc_language): Remove references to objc_language_data.
3744 * opencl-lang.c (opencl_language_data): Delete.
3745 (opencl_language): Remove references to opencl_language_data.
3746 * p-lang.c (pascal_language_data): Delete.
3747 (pascal_language): Remove references to pascal_language_data.
3748 * rust-lang.c (rust_language_data): Delete.
3749 (rust_language): Remove references to rust_language_data.
3753 * ada-lang.c (ada_language_data): Remove la_op_print_tab
3755 (ada_language::opcode_print_table): New member function.
3756 * c-lang.c (c_language_data): Remove la_op_print_tab initializer.
3757 (c_language::opcode_print_table): New member function.
3758 (cplus_language_data): Remove la_op_print_tab initializer.
3759 (cplus_language::opcode_print_table): New member function.
3760 (asm_language_data): Remove la_op_print_tab initializer.
3761 (asm_language::opcode_print_table): New member function.
3762 (minimal_language_data): Remove la_op_print_tab initializer.
3763 (minimal_language::opcode_print_table): New member function.
3764 * d-lang.c (d_language_data): Remove la_op_print_tab initializer.
3765 (d_language::opcode_print_table): New member function.
3766 * expprint.c (print_subexp_standard): Update call to
3768 (op_string): Likewise.
3769 * f-lang.c (f_language_data): Remove la_op_print_tab initializer.
3770 (f_language::opcode_print_table): New member function.
3771 * go-lang.c (go_language_data): Remove la_op_print_tab
3773 (go_language::opcode_print_table): New member function.
3774 * language.c (unknown_language_data): Remove la_op_print_tab
3776 (unknown_language::opcode_print_table): New member function.
3777 (auto_language_data): Remove la_op_print_tab initializer.
3778 (auto_language::opcode_print_table): New member function.
3779 * language.h (language_data): Remove la_op_print_tab field.
3780 (language_defn::opcode_print_table): Declare new member function.
3781 * m2-lang.c (m2_language_data): Remove la_op_print_tab
3783 (m2_language::opcode_print_table): New member function.
3784 * objc-lang.c (objc_language_data): Remove la_op_print_tab
3786 (objc_language::opcode_print_table): New member function.
3787 * opencl-lang.c (opencl_language_data): Remove la_op_print_tab
3789 (opencl_language::opcode_print_table): New member function.
3790 * p-lang.c (pascal_language_data): Remove la_op_print_tab
3792 (pascal_language::opcode_print_table): New member function.
3793 * rust-lang.c (rust_language_data): Remove la_op_print_tab
3795 (rust_language::opcode_print_table): New member function.
3799 * ada-lang.c (ada_language_data): Remove la_exp_desc initializer.
3800 (ada_language::expression_ops): New member function.
3801 * c-lang.c (c_language_data): Remove la_exp_desc initializer.
3802 (c_language::expression_ops): New member function.
3803 (cplus_language_data): Remove la_exp_desc initializer.
3804 (cplus_language::expression_ops): New member function.
3805 (asm_language_data): Remove la_exp_desc initializer.
3806 (asm_language::expression_ops): New member function.
3807 (minimal_language_data): Remove la_exp_desc initializer.
3808 (minimal_language::expression_ops): New member function.
3809 * d-lang.c (d_language_data): Remove la_exp_desc initializer.
3810 (d_language::expression_ops): New member function.
3811 * eval.c (evaluate_subexp): Update call to expression_ops.
3812 * expprint.c (print_subexp): Likewise.
3813 (op_name): Likewise.
3814 (dump_subexp_body): Likewise.
3815 * f-lang.c (f_language_data): Remove la_exp_desc initializer.
3816 (f_language::expression_ops): New member function.
3817 * go-lang.c (go_language_data): Remove la_exp_desc initializer.
3818 (go_language::expression_ops): New member function.
3819 * language.c (language_defn::expression_ops): New function.
3820 (unknown_language_data): Remove la_exp_desc initializer.
3821 (auto_language_data): Likewise.
3822 * language.h (language_data): Remove la_exp_desc field.
3823 (language_defn::expression_ops): Declare new member function.
3824 * m2-lang.c (m2_language_data): Remove la_exp_desc initializer.
3825 (m2_language::expression_ops): New member function.
3826 * objc-lang.c (objc_language_data): Remove la_exp_desc
3828 * opencl-lang.c (opencl_language_data): Remove la_exp_desc
3830 (opencl_language::expression_ops): New member function.
3831 * p-lang.c (pascal_language_data): Remove la_exp_desc initializer.
3832 * parse.c (operator_length): Update call to expression_ops.
3833 (exp_iterate): Likewise.
3834 * rust-lang.c (rust_language_data): Remove la_exp_desc
3836 (ruse_language::expression_ops): New member function.
3840 * ada-lang.c (ada_language_data): Remove la_varobj_ops
3842 (ada_language::varobj_ops): New member function.
3843 * c-lang.c (c_language_data): Remove la_varobj_ops
3845 (cplus_language_data): Likewise.
3846 (cplus_language::varobj_ops): New member function.
3847 (asm_language_data): Remove la_varobj_ops initializer.
3848 (minimal_language_data): Likewise.
3849 * d-lang.c (d_language_data): Likewise.
3850 * f-lang.c (f_language_data): Likewise.
3851 * go-lang.c (go_language_data): Likewise.
3852 * language.c (language_defn::varobj_ops): New function.
3853 (unknown_language_data): Remove la_varobj_ops
3855 (auto_language_data): Likewise.
3856 * language.h (language_data): Remove la_varobj_ops field.
3857 (language_defn::varobj_ops): Declare new member function.
3858 * m2-lang.c (m2_language_data): Remove la_varobj_ops initializer.
3859 * objc-lang.c (objc_language_data): Likewise.
3860 * opencl-lang.c (opencl_language_data): Likewise.
3861 * p-lang.c (pascal_language_data): Likewise.
3862 * rust-lang.c (rust_language_data): Likewise.
3863 * varobj.c (varobj_create): Update call to varobj_ops.
3864 * varobj.h (default_varobj_ops): Delete define.
3868 * ada-lang.c (ada_language_data): Remove la_macro_expansion
3870 * c-lang.c (c_language_data): Likewise.
3871 (c_language::macro_expansion): New member function.
3872 (cplus_language_data): Likewise.
3873 (cplus_language::macro_expansion): New member function.
3874 (asm_language_data): Likewise.
3875 (asm_language::macro_expansion): New member function.
3876 (minimal_language_data): Likewise.
3877 (minimal_language::macro_expansion): New member function.
3878 * d-lang.c (d_language_data): Remove la_macro_expansion
3880 * f-lang.c (f_language_data): Likewise.
3881 * go-lang.c (go_language_data): Likewise.
3882 * language.c (unknown_language_data): Likewise.
3883 (auto_language_data): Likewise.
3884 * language.h (language_data): Remove la_macro_expansion field.
3885 (language_defn::macro_expansion): New member function.
3886 * m2-lang.c (m2_language_data): Remove la_macro_expansion
3888 * objc-lang.c (objc_language_data): Likewise.
3889 (objc_language::macro_expansion): New member function.
3890 * opencl-lang.c (opencl_language_data): Likewise.
3891 (opencl_language::macro_expansion): New member function.
3892 * p-lang.c (pascal_language_data): Remove la_macro_expansion
3894 * rust-lang.c (rust_language_data): Likewise.
3895 * symtab.c (default_collect_symbol_completion_matches_break_on):
3896 Update call to macro_expansion.
3900 * ada-lang.c (ada_language_data): Remove la_array_ordering
3902 * c-lang.c (c_language_data): Likewise.
3903 (cplus_language_data): Likewise.
3904 (asm_language_data): Likewise.
3905 (minimal_language_data): Likewise.
3906 * d-lang.c (d_language_data): Likewise.
3907 * dwarf2/read.c (read_array_order): Update for call to
3909 * f-lang.c (f_language_data): Remove la_array_ordering
3911 (f_language::array_ordering): New member function.
3912 * go-lang.c (go_language_data): Remove la_array_ordering
3914 * language.c (unknown_language_data): Likewise.
3915 (auto_language_data): Likewise.
3916 * language.h (language_data): Delete la_array_ordering field.
3917 (language_defn::array_ordering): New member function.
3918 * m2-lang.c (m2_language_data): Remove la_array_ordering
3920 * objc-lang.c (objc_language_data): Likewise.
3921 * opencl-lang.c (opencl_language_data): Likewise.
3922 * p-lang.c (pascal_language_data): Likewise.
3923 * rust-lang.c (rust_language_data): Likewise.
3927 * ada-lang.c (ada_language_data): Remove la_case_sensitivity
3929 * c-lang.c (c_language_data): Likewise.
3930 (cplus_language_data): Likewise.
3931 (asm_language_data): Likewise.
3932 (minimal_language_data): Likewise.
3933 * d-lang.c (d_language_data): Likewise.
3934 * f-lang.c (f_language_data): Likewise.
3935 (f_language::case_sensitivity): New member function.
3936 * go-lang.c (go_language_data): Remove la_case_sensitivity
3938 * language.c (enum case_mode): Moved here from language.h.
3939 (case_mode): Make static.
3940 (show_case_command): Update for case_sensitivity being a method.
3941 (set_case_command): Likewise.
3942 (set_range_case): Likewise.
3943 (unknown_language_data): Remove la_case_sensitivity initializer.
3944 (auto_language_data): Likewise.
3945 * language.h (case_mode): Delete, move enum declaration to
3947 (language_data): Delete la_case_sensitivity field.
3948 (language_defn::case_sensitivity): New member function.
3949 * m2-lang.c (m2_language_data): Remove la_case_sensitivity
3951 * objc-lang.c (objc_language_data): Likewise.
3952 * opencl-lang.c (opencl_language_data): Likewise.
3953 * p-lang.c (pascal_language_data): Likewise.
3954 * rust-lang.c (rust_language_data): Likewise.
3958 * ada-lang.c (ada_language_data): Remove la_range_check
3960 * c-lang.c (c_language_data): Likewise.
3961 (cplus_language_data): Likewise.
3962 (asm_language_data): Likewise.
3963 (minimal_language_data): Likewise.
3964 * d-lang.c (d_language_data): Likewise.
3965 * f-lang.c (f_language_data): Likewise.
3966 (f_language::range_checking_on_by_default): New member function.
3967 * go-lang.c (go_language_data): Remove la_range_check initializer.
3968 * language.c (enum range_mode): Moved here from language.h.
3969 (range_mode): Made static.
3970 (show_range_command): Update to use
3971 range_checking_on_by_default.
3972 (set_range_command): Likewise.
3973 (set_range_case): Likewise.
3974 (unknown_language_data): Remove la_range_check initializer.
3975 (auto_language_data): Likewise.
3976 * language.h (range_mode): Delete. Enum definition moved to
3978 (language_data): Remove la_range_check field.
3979 (language_defn::range_checking_on_by_default): New member
3981 * m2-lang.c (m2_language_data): Remove la_range_check initializer.
3982 (m2_language::range_checking_on_by_default): New member function.
3983 * objc-lang.c (objc_language_data): Remove la_range_check
3985 * opencl-lang.c (opencl_language_data): Likewise.
3986 * p-lang.c (pascal_language_data): Likewise.
3987 (pascal_language::range_checking_on_by_default): New member
3989 * rust-lang.c (rust_language_data): Remove la_range_check
3991 (rust_language::range_checking_on_by_default): New member
3996 * dwarf2/read.c (dwarf2_physname): Remove special case for
3998 * go-lang.c (go_language::store_sym_names_in_linkage_form_p): New
4003 * ada-lang.c (ada_language_data): Remove
4004 la_store_sym_names_in_linkage_form_p initializer.
4005 (ada_language::store_sym_names_in_linkage_form_p): New member
4007 * c-lang.c (c_language_data): Remove
4008 la_store_sym_names_in_linkage_form_p initializer.
4009 (c_language::store_sym_names_in_linkage_form_p): New member
4011 (cplus_language_data): Remove la_store_sym_names_in_linkage_form_p
4013 (asm_language_data): Likewise.
4014 (asm_language::store_sym_names_in_linkage_form_p): New member
4016 (minimal_language_data): Remove
4017 la_store_sym_names_in_linkage_form_p initializer.
4018 (minimal_language::store_sym_names_in_linkage_form_p): New member
4020 * d-lang.c (d_language_data): Remove
4021 la_store_sym_names_in_linkage_form_p initializer.
4022 * dwarf2/read.c (dwarf2_physname): Update call to
4023 store_sym_names_in_linkage_form_p.
4024 * f-lang.c (f_language_data): Remove
4025 la_store_sym_names_in_linkage_form_p initializer.
4026 * go-lang.c (go_language_data): Remove
4027 la_store_sym_names_in_linkage_form_p initializer.
4028 * language.c (unknown_language_data): Remove
4029 la_store_sym_names_in_linkage_form_p initializer.
4030 (unknown_language::store_sym_names_in_linkage_form_p): New member
4032 (auto_language_data): Remove la_store_sym_names_in_linkage_form_p
4034 (auto_language::store_sym_names_in_linkage_form_p): New member
4036 * language.h (language_data): Remove
4037 la_store_sym_names_in_linkage_form_p member variable.
4038 (language_defn::store_sym_names_in_linkage_form_p): New member
4040 * m2-lang.c (m2_language_data): Remove
4041 la_store_sym_names_in_linkage_form_p initializer.
4042 * objc-lang.c (objc_language_data): Likewise.
4043 * opencl-lang.c (opencl_language_data): Likewise.
4044 * p-lang.c (pascal_language_data): Likewise.
4045 * rust-lang.c (rust_language_data): Likewise.
4049 * ada-lang.c (ada_language_data): Remove string_lower_bound
4051 * c-lang.c (c_language_data): Likewise.
4052 (cplus_language_data): Likewise.
4053 (asm_language_data): Likewise.
4054 (minimal_language_data): Likewise.
4055 * d-lang.c (d_language_data): Likewise.
4056 * f-lang.c (f_language_data): Likewise.
4057 * go-lang.c (go_language_data): Likewise.
4058 * language.c (unknown_language_data): Likewise.
4059 (auto_language_data): Likewise.
4060 * language.h (language_data): Remove string_lower_bound field.
4061 (language_defn::string_lower_bound): New member function.
4062 * m2-lang.c (m2_language_data): Remove string_lower_bound
4064 (m2_language::string_lower_bound): New member function.
4065 * objc-lang.c (objc_language_data): Remove string_lower_bound
4067 * opencl-lang.c (opencl_language_data): Likewise.
4068 * p-lang.c (pascal_language_data): Likewise.
4069 * rust-lang.c (rust_language_data): Likewise.
4070 * valops.c (value_cstring): Update call to string_lower_bound.
4071 (value_string): Likewise.
4072 * value.c (allocate_repeated_value): Likewise.
4076 * valops.c (value_repeat): Fix incorrect argument name in comment.
4080 * ada-lang.c (ada_language_data): Remove c_style_arrays
4082 (ada_language::c_style_arrays_p): New member fuction.
4083 * c-lang.c (c_language_data): Remove c_style_arrays
4085 (cplus_language_data): Likewise.
4086 (asm_language_data): Likewise.
4087 (minimal_language_data): Likewise.
4088 * d-lang.c (d_language_data): Likewise.
4089 * eval.c (ptrmath_type_p): Update call to c_style_arrays_p.
4090 * f-lang.c (f_language_data): Remove c_style_arrays initializer.
4091 (f_language::c_style_arrays_p): New member function.
4092 * go-lang.c (go_language_data): Remove c_style_arrays initializer.
4093 * infcall.c (value_arg_coerce): Update call to c_style_arrays_p.
4094 * language.c (unknown_language_data): Remove c_style_arrays
4096 (auto_language_data): Likewise.
4097 * language.h (language_data): Remove c_style_arrays field.
4098 (language_defn::c_style_arrays_p): New member function.
4099 * m2-lang.c (m2_language_data): Remove c_style_arrays initializer.
4100 (m2_language::c_style_arrays_p): New member function.
4101 * objc-lang.c (objc_language_data): Remove c_style_arrays
4103 * opencl-lang.c (opencl_language_data): Likewise.
4104 * p-lang.c (pascal_language_data): Likewise.
4105 * rust-lang.c (rust_language_data): Likewise.
4106 * valarith.c (value_subscript): Update call to c_style_arrays_p,
4107 and update local variable to a bool.
4108 * valops.c (value_cast): Update call to c_style_arrays_p.
4109 (value_array): Likewise.
4110 * value.c (coerce_array): Likewise.
4114 * ada-lang.c (ada_language_data): Remove la_language initializer.
4115 * c-lang.c (c_language_data): Likewise.
4116 (cplus_language_data): Likewise.
4117 (asm_language_data): Likewise.
4118 (minimal_language_data): Likewise.
4119 * d-lang.c (d_language_data): Likewise.
4120 * f-lang.c (f_language_data): Likewise.
4121 * go-lang.c (go_language_data): Likewise.
4122 * language.c (unknown_language_data): Likewise.
4123 (auto_language_data): Likewise.
4124 * language.h (language_data): Remove la_language field.
4125 (language_defn::language_defn): Initialise la_language field.
4126 (language_defn::la_language): New member variable.
4127 * m2-lang.c (m2_language_data): Remove la_language field.
4128 * objc-lang.c (objc_language_data): Likewise.
4129 * opencl-lang.c (opencl_language_data): Likewise.
4130 * p-lang.c (pascal_language_data): Likewise.
4131 * rust-lang.c (rust_language_data): Likewise.
4135 * ada-lang.c (ada_extensions): Delete, moved into
4136 ada_language::filename_extensions.
4137 (ada_language_data): Remove la_filename_extensions initializer.
4138 (ada_language::filename_extensions): New member function.
4139 * c-lang.c (c_extensions): Delete, moved into
4140 c_language::filename_extensions.
4141 (c_language_data): Remove la_filename_extensions initializer.
4142 (c_language::filename_extensions): New member function.
4143 (cplus_extensions): Delete, moved into
4144 cplus_language::filename_extensions.
4145 (cplus_language_data): Remove la_filename_extensions initializer.
4146 (cplus_language::filename_extensions): New member function.
4147 (asm_extensions): Delete, moved into
4148 asm_language::filename_extensions.
4149 (asm_language_data): Remove la_filename_extensions initializer.
4150 (asm_language::filename_extensions): New member function.
4151 (minimal_language_data): Remove la_filename_extensions
4153 * d-lang.c (d_extensions): Delete, moved into
4154 d_language::filename_extensions.
4155 (d_language_data): Remove la_filename_extensions initializer.
4156 (d_language::filename_extensions): New member function.
4157 * f-lang.c (f_extensions): Delete, moved into
4158 f_language::filename_extensions.
4159 (f_language_data): Remove la_filename_extensions initializer.
4160 (f_language::filename_extensions): New member function.
4161 * go-lang.c (go_language_data): Remove la_filename_extensions
4163 * language.c (add_set_language_command): Update now that
4164 filename_extensions returns a vector.
4165 (unknown_language_data): Remove la_filename_extensions
4167 (auto_language_data): Likewise.
4168 * language.h (language_data): Remove la_filename_extensions field.
4169 (language_defn::filename_extensions): New member function.
4170 * m2-lang.c (m2_language_data): Remove la_filename_extensions
4172 * objc-lang.c (objc_extensions): Delete, moved into
4173 objc_language::filename_extensions.
4174 (objc_language_data): Remove la_filename_extensions initializer.
4175 (objc_language::filename_extensions): New member function.
4176 * opencl-lang.c (opencl_language_data): Remove
4177 la_filename_extensions initializer.
4178 * p-lang.c (pascal_extensions): Delete, moved into
4179 pascal_language::filename_extensions.
4180 (pascal_language_data): Remove la_filename_extensions initializer.
4181 (pascal_language::filename_extensions): New member function.
4182 * rust-lang.c (rust_extensions): Delete, moved into
4183 rust_language::filename_extensions.
4184 (rust_language_data): Remove la_filename_extensions initializer.
4185 (rust_language::filename_extensions): New member function.
4186 * symfile.c (add_filename_language): Add new assert.
4190 * ada-lang.c (ada_language_data): Remove la_name and
4191 la_natural_name initializers.
4192 (ada_language::name): New member function.
4193 (ada_language::natural_name): New member function.
4194 * c-lang.c (c_language_data): Remove la_name and
4195 la_natural_name initializers.
4196 (c_language::name): New member function.
4197 (c_language::natural_name): New member function.
4198 (cplus_language_data): Remove la_name and
4199 la_natural_name initializers.
4200 (cplus_language::name): New member function.
4201 (cplus_language::natural_name): New member function.
4202 (asm_language_data): Remove la_name and
4203 la_natural_name initializers.
4204 (asm_language::name): New member function.
4205 (asm_language::natural_name): New member function.
4206 (minimal_language_data): Remove la_name and
4207 la_natural_name initializers.
4208 (minimal_language::name): New member function.
4209 (minimal_language::natural_name): New member function.
4210 * compile/compile.c (compile_to_object): Update call to
4211 lanugage_defn::name.
4212 * d-lang.c (d_language_data): Remove la_name and
4213 la_natural_name initializers.
4214 (d_language::name): New member function.
4215 (d_language::natural_name): New member function.
4216 * expprint.c (print_subexp_standard): Update call to
4217 language_defn::name.
4218 (dump_raw_expression): Likewise
4219 (dump_prefix_expression): Likewise.
4220 * f-lang.c (f_language_data): Remove la_name and
4221 la_natural_name initializers.
4222 (f_language::name): New member function.
4223 (f_language::natural_name): New member function.
4224 * go-lang.c (go_language_data): Remove la_name and
4225 la_natural_name initializers.
4226 (go_language::name): New member function.
4227 (go_language::natural_name): New member function.
4228 * language.c (show_language_command): Update call to
4229 language_defn::name.
4230 (set_language_command): Likewise.
4231 (language_enum): Likewise.
4232 (language_str): Likewise.
4233 (add_set_language_command): Likewise, use
4234 language_defn::natural_name in the doc string.
4235 (unknown_language_data): Remove la_name and
4236 la_natural_name initializers.
4237 (unknown_language::name): New member function.
4238 (unknown_language::natural_name): New member function.
4239 (auto_language_data): Remove la_name and
4240 la_natural_name initializers.
4241 (auto_language::name): New member function.
4242 (auto_language::natural_name): New member function.
4243 (language_lookup_primitive_type_as_symbol): Update call to
4244 language_defn::name.
4245 * language.h (language_data): Remove la_name and la_natural_name
4247 (language_defn::name): New member function.
4248 (language_defn::natural_name): New member function.
4249 * m2-lang.c (m2_language_data): Remove la_name and
4250 la_natural_name initializers.
4251 (m2_language::name): New member function.
4252 (m2_language::natural_name): New member function.
4253 * mi/mi-cmd-var.c (mi_cmd_var_info_expression): Update call to
4254 language_defn::natural_name.
4255 * objc-lang.c (objc_language_data): Remove la_name and
4256 la_natural_name initializers.
4257 (objc_language::name): New member function.
4258 (objc_language::natural_name): New member function.
4259 * opencl-lang.c (opencl_language_data): Remove la_name and
4260 la_natural_name initializers.
4261 (opencl_language::name): New member function.
4262 (opencl_language::natural_name): New member function.
4263 * p-lang.c (pascal_language_data): Remove la_name and
4264 la_natural_name initializers.
4265 (pascal_language::name): New member function.
4266 (pascal_language::natural_name): New member function.
4267 * rust-lang.c (rust_language_data): Remove la_name and
4268 la_natural_name initializers.
4269 (rust_language::name): New member function.
4270 (rust_language::natural_name): New member function.
4271 * symtab.c (lookup_language_this): Update call to
4272 language_defn::name.
4276 * ada-lang.c (ada_language_data): Remove la_name_of_this
4278 * ax-gdb.c (gen_expr): Update call to name_of_this.
4279 * c-exp.y (classify_name): Likewise.
4280 * c-lang.c (c_language_data): Remove la_name_of_this initializer.
4281 (cplus_language_data): Likewise.
4282 (cplus_language::name_of_this): New member function.
4283 (asm_language_data): Remove la_name_of_this initializer.
4284 (minimal_language_data): Likewise.
4285 * d-lang.c (d_language_data): Likewise.
4286 (d_language::name_of_this): New member function.
4287 * expprint.c (print_subexp_standard): Update call to name_of_this.
4288 * f-lang.c (f_language_data): Remove la_name_of_this initializer.
4289 * go-lang.c (go_language_data): Likewise.
4290 * language.c (unknown_language_data): Likewise.
4291 (unknown_language::name_of_this): New member function.
4292 (auto_language_data): Remove la_name_of_this initializer.
4293 (auto_language::name_of_this): New member function.
4294 * language.h (language_data): Delete la_name_of_this member
4296 (language_defn::name_of_this): New member function.
4297 * m2-lang.c (m2_language_data): Remove la_name_of_this
4299 * objc-lang.c (objc_language_data): Likewise.
4300 (objc_language::name_of_this): New member function.
4301 * opencl-lang.c (opencl_language_data): Remove la_name_of_this
4303 * p-lang.c (pascal_language_data): Likewise.
4304 (pascal_language::name_of_this): New member function.
4305 * rust-lang.c (rust_language_data): Remove la_name_of_this
4307 * symtab.c (lookup_language_this): Update call to name_of_this.
4308 (lookup_symbol_aux): Likewise.
4309 * valops.c (value_of_this): Likewise.
4313 * ada-lang.c (ada_language_data): Remove
4314 la_struct_too_deep_ellipsis initializer.
4315 (ada_language::struct_too_deep_ellipsis): New member function.
4316 * c-lang.c (c_language_data): Remove la_struct_too_deep_ellipsis
4318 (cplus_language_data): Likewise.
4319 (asm_language_data): Likewise.
4320 (minimal_language_data): Likewise.
4321 * cp-valprint.c (cp_print_value): Update call to
4322 struct_too_deep_ellipsis.
4323 * d-lang.c (d_language_data): Remove la_struct_too_deep_ellipsis
4325 * f-lang.c (f_language_data): Likewise.
4326 (f_language::struct_too_deep_ellipsis): New member function.
4327 * go-lang.c (go_language_data): Remove la_struct_too_deep_ellipsis
4329 * language.c (unknown_language_data): Likewise.
4330 (auto_language_data): Likewise.
4331 * language.h (language_data): Delete la_struct_too_deep_ellipsis
4333 (language_defn::struct_too_deep_ellipsis): New member function.
4334 * m2-lang.c (m2_language_data): Remove la_struct_too_deep_ellipsis
4336 * objc-lang.c (objc_language_data): Likewise.
4337 * opencl-lang.c (opencl_language_data): Likewise.
4338 * p-lang.c (pascal_language_data): Likewise.
4339 * rust-lang.c (rust_language_data): Likewise.
4340 * valprint.c (val_print_check_max_depth): Update call to
4341 struct_too_deep_ellipsis.
4345 * MAINTAINERS (Write After Approval): Add myself.
4349 * f-valprint.c (f_value_print_inner) <case TYPE_CODE_INT>:
4354 * rust-lang.c (rust_value_print_inner): Remove TYPE_CODE_MEMBERPTR
4355 and TYPE_CODE_METHODPTR cases.
4356 * c-valprint.c (c_value_print_memberptr): Move to valprint.c.
4357 (c_value_print_inner): Update.
4358 * valprint.c (generic_value_print_memberptr): New function, from
4359 c_value_print_memberptr.
4360 (generic_value_print): Use it. Call cplus_print_method_ptr.
4364 * python/python-internal.h (PyInt_FromLong): Remove define.
4365 * python/py-value.c (convert_value_from_python): Use
4366 gdb_py_object_from_longest.
4367 * python/py-type.c (typy_get_code): Use
4368 gdb_py_object_from_longest.
4369 * python/py-symtab.c (salpy_get_line): Use
4370 gdb_py_object_from_longest.
4371 * python/py-symbol.c (sympy_get_addr_class, sympy_line): Use
4372 gdb_py_object_from_longest.
4373 * python/py-record.c (recpy_gap_reason_code): Use
4374 gdb_py_object_from_longest.
4375 * python/py-record-btrace.c (recpy_bt_insn_size)
4376 (recpy_bt_func_level, btpy_list_count): Use
4377 gdb_py_object_from_longest.
4378 * python/py-infthread.c (gdbpy_create_ptid_object): Use
4379 gdb_py_object_from_longest. Fix error handling.
4380 * python/py-framefilter.c (bootstrap_python_frame_filters): Use
4381 gdb_py_object_from_longest.
4382 * python/py-frame.c (frapy_type, frapy_unwind_stop_reason): Use
4383 gdb_py_object_from_longest.
4384 * python/py-breakpoint.c (bppy_get_type, bppy_get_number)
4385 (bppy_get_thread, bppy_get_task, bppy_get_hit_count)
4386 (bppy_get_ignore_count): Use gdb_py_object_from_longest.
4390 * python/python.c (gdbpy_parameter_value): Use
4391 gdb_py_object_from_ulongest.
4395 * python/py-infevents.c (create_register_changed_event_object):
4396 Use gdb_py_object_from_longest.
4397 * python/py-exitedevent.c (create_exited_event_object): Use
4398 gdb_py_object_from_longest.
4402 * python/python.c (gdbpy_parameter_value): Use
4403 gdb_py_object_from_longest.
4404 * python/py-type.c (convert_field, typy_range): Use
4405 gdb_py_object_from_longest.
4406 * python/py-tui.c (gdbpy_tui_width, gdbpy_tui_height): Use
4407 gdb_py_object_from_longest.
4408 * python/py-lazy-string.c (stpy_get_length): Use
4409 gdb_py_object_from_longest.
4410 * python/py-infthread.c (thpy_get_num, thpy_get_global_num): Use
4411 gdb_py_object_from_longest.
4412 * python/py-infevents.c (create_memory_changed_event_object): Use
4413 gdb_py_object_from_longest.
4414 * python/py-inferior.c (infpy_get_num): Use
4415 gdb_py_object_from_longest.
4416 (infpy_get_pid): Likewise.
4420 * python/python-internal.h (gdb_py_long_from_ulongest): Remove
4422 * python/py-value.c (valpy_long): Use
4423 gdb_py_object_from_ulongest.
4424 * python/py-symtab.c (salpy_get_pc): Use
4425 gdb_py_object_from_ulongest.
4426 (salpy_get_last): Likewise.
4427 * python/py-record-btrace.c (recpy_bt_insn_pc): Use
4428 gdb_py_object_from_ulongest.
4429 * python/py-lazy-string.c (stpy_get_address): Use
4430 gdb_py_object_from_ulongest.
4431 * python/py-frame.c (frapy_pc): Use gdb_py_object_from_ulongest.
4432 * python/py-arch.c (archpy_disassemble): Use
4433 gdb_py_object_from_ulongest and gdb_py_object_from_longest. Fix
4438 * python/python-internal.h (gdb_py_long_from_longest): Remove
4440 * python/py-value.c (valpy_long): Use gdb_py_object_from_longest.
4441 * python/py-type.c (convert_field, typy_get_sizeof): Use
4442 gdb_py_object_from_longest.
4443 * python/py-record-btrace.c (btpy_list_index): Use
4444 gdb_py_object_from_longest.
4448 * python/python-internal.h (PyInt_FromSsize_t): Remove define.
4449 * python/py-record.c (recpy_element_number): Use
4450 gdb_py_object_from_longest.
4451 (recpy_gap_number): Likewise.
4455 * top.c (ui::ui): Update.
4456 (highest_ui_num): Remove.
4457 * top.h (struct ui) <num>: Remove.
4461 * unittests/memory-map-selftests.c (valid_mem_map): Now array.
4462 * ui-style.c (ansi_regex_text): Now array.
4463 * rust-exp.y (number_regex_text): Now array.
4464 * linespec.c (linespec_quote_characters): Now array.
4465 * jit.c (jit_break_name, jit_descriptor_name, reader_init_fn_sym):
4470 * debuginfod-support.c (debuginfod_client_deleter): New.
4471 (debuginfod_client_up): New.
4472 (debuginfod_init): Return debuginfod_client_up.
4473 (debuginfod_source_query): Adjust.
4474 (debuginfod_debuginfo_query): Adjust.
4478 * debuginfod-support.c (debuginfod_source_query): Use
4479 make_unique_xstrdup.
4483 * gdbtypes.h (TYPE_INSTANCE_FLAGS): Remove, replace all uses
4484 with `type::instance_flags`.
4488 * xml-tdesc.c [!defined(HAVE_LIBEXPAT)] (tdesc_parse_xml):
4489 Remove baton parameter.
4493 * Makefile.in (SELFTESTS_SRCS): Add
4494 unittests/enum-flags-selftests.c.
4495 * btrace.c (ftrace_update_caller, ftrace_fixup_calle): Use
4496 btrace_function_flags instead of enum btrace_function_flag.
4497 * compile/compile-c-types.c (convert_qualified): Use
4499 * compile/compile-cplus-symbols.c (convert_one_symbol)
4500 (convert_symbol_bmsym):
4501 * compile/compile-cplus-types.c (compile_cplus_convert_method)
4502 (compile_cplus_convert_struct_or_union_methods)
4503 (compile_cplus_instance::convert_qualified_base):
4504 * go-exp.y (parse_string_or_char): Add cast to int.
4505 * unittests/enum-flags-selftests.c: New file.
4506 * record-btrace.c (btrace_thread_flag_to_str): Change parameter's
4507 type to btrace_thread_flags from btrace_thread_flag.
4508 (record_btrace_cancel_resume, record_btrace_step_thread): Change
4509 local's type to btrace_thread_flags from btrace_thread_flag. Add
4514 * c-typeprint.c (c_type_print_modifier): Adjust to rename.
4515 * gdbtypes.c (address_space_name_to_int): Rename to ...
4516 (address_space_name_to_type_instance_flags): ... this.
4517 (address_space_int_to_name): Rename to ...
4518 (address_space_type_instance_flags_to_name): ... this.
4519 * gdbtypes.h (address_space_name_to_int): Rename to ...
4520 (address_space_name_to_type_instance_flags): ... this.
4521 (address_space_int_to_name): Rename to ...
4522 (address_space_type_instance_flags_to_name): ... this.
4523 * type-stack.c (type_stack::insert): Adjust to rename.
4524 * type-stack.h (type_stack::insert): Likewise.
4529 * avr-tdep.c (avr_address_class_type_flags): Return
4530 type_instance_flags.
4531 (avr_address_class_type_flags_to_name): Take a
4532 type_instance_flags.
4533 (avr_address_class_name_to_type_flags): Return bool and take a
4534 type_instance_flags.
4535 * d-lang.c (build_d_types): Use type::set_instance_flags.
4536 * ft32-tdep.c (ft32_address_class_type_flags): Return
4537 type_instance_flags.
4538 (ft32_address_class_type_flags_to_name): Take a
4539 type_instance_flags.
4540 (ft32_address_class_name_to_type_flags): Return bool and take a
4541 type_instance_flags.
4542 (ft32_gdbarch_init): Use type::set_instance_flags.
4543 * eval.c (fake_method::fake_method): Use type::set_instance_flags.
4544 * gdbarch.h, gdbarch.c: Regenerate.
4545 * gdbarch.sh (address_class_type_flags): Use type_instance_flags.
4546 (address_class_name_to_type_flags): Use type_instance_flags and
4548 * gdbtypes.c (address_space_name_to_int)
4549 (address_space_int_to_name, make_qualified_type): Use
4550 type_instance_flags.
4551 (make_qualified_type): Use type_instance_flags and
4552 type::set_instance_flags.
4553 (make_type_with_address_space, make_cv_type, make_vector_type)
4554 (check_typedef): Use type_instance_flags.
4555 (recursive_dump_type): Cast type_instance_flags to unsigned for
4557 (copy_type_recursive): Use type::set_instance_flags.
4558 (gdbtypes_post_init): Use type::set_instance_flags.
4559 * gdbtypes.h (struct type) <instance_flags>: Rename to ...
4560 <m_instance_flags>: ... this.
4561 <instance_flags, set_instance_flags>: New methods.
4562 (TYPE_INSTANCE_FLAGS): Use the instance_flags method.
4563 (SET_TYPE_INSTANCE_FLAGS): New.
4564 (address_space_name_to_int, address_space_int_to_name)
4565 (make_type_with_address_space): Pass flags using
4566 type_instance_flags instead of int.
4567 * stabsread.c (cleanup_undefined_types_noname): Use
4568 type::set_instance_flags.
4569 * s390-tdep.c (s390_address_class_type_flags): Return
4570 type_instance_flags.
4571 (s390_address_class_type_flags_to_name): Take a
4572 type_instance_flags.
4573 (s390_address_class_name_to_type_flags): Return bool and take a
4574 type_instance_flags.
4575 * type-stack.c (type_stack::follow_types): Use
4576 type_instance_flags.
4577 * dwarf2/read.c (read_tag_pointer_type): Use type_instance_flags.
4581 * x86-tdep.h (x86_in_indirect_branch_thunk): Update.
4582 * x86-tdep.c (x86_is_thunk_register_name)
4583 (x86_in_indirect_branch_thunk): Update.
4584 * sparc64-tdep.c (sparc64_fpu_register_names)
4585 (sparc64_cp0_register_names, sparc64_register_names)
4586 (sparc64_pseudo_register_names): Now const.
4587 * sparc-tdep.h (struct gdbarch_tdep) <fpu_register_names,
4588 cp0_registers_num>: Now const.
4589 * sparc-tdep.c (sparc_core_register_names)
4590 (sparc32_fpu_register_names, sparc32_cp0_register_names)
4591 (sparc32_pseudo_register_names): Now const.
4592 (validate_tdesc_registers): Update.
4593 * rust-lang.c (rust_extensions): Now const.
4594 * p-lang.c (p_extensions): Now const.
4595 * objc-lang.c (objc_extensions): Now const.
4596 * nto-tdep.c (nto_thread_state_str): Now const.
4597 * moxie-tdep.c (moxie_register_names): Now const.
4598 * mips-tdep.h (struct gdbarch_tdep) <mips_processor_reg_names>:
4600 * mips-tdep.c (mips_generic_reg_names, mips_tx39_reg_names)
4601 (mips_linux_reg_names): Now const.
4602 (mips_gdbarch_init): Update.
4603 * microblaze-tdep.c (microblaze_register_names): Now const.
4604 * m68k-tdep.c (m68k_register_names): Now const.
4605 * m32r-tdep.c (m32r_register_names): Now const.
4606 * ia64-tdep.c (ia64_register_names): Now const.
4607 * i386-tdep.h (struct gdbarch_tdep) <register_names,
4608 ymmh_register_names, ymm16h_regnum, mpx_register_names,
4609 k_register_names, zmmh_register_names, xmm_avx512_register_names,
4610 ymm_avx512_register_names, pkeys_register_names>: Now const.
4611 * i386-tdep.c (i386_register_names, i386_zmm_names)
4612 (i386_zmmh_names, i386_k_names, i386_ymm_names, i386_ymmh_names)
4613 (i386_mpx_names, i386_pkeys_names, i386_bnd_names)
4614 (i386_mmx_names, i386_byte_names, i386_word_names): Now const.
4615 * f-lang.c (f_extensions): Now const.
4616 * d-lang.c (d_extensions): Now const.
4617 * csky-tdep.c (csky_register_names): Now const.
4618 * charset.c (default_charset_names, charset_enum): Now const.
4619 (_initialize_charset): Update.
4620 * c-lang.c (c_extensions, cplus_extensions, asm_extensions): Now
4622 * bsd-uthread.c (bsd_uthread_solib_names): Now const.
4623 (bsd_uthread_solib_loaded): Update.
4624 (bsd_uthread_state): Now const.
4625 * amd64-tdep.c (amd64_register_names, amd64_ymm_names)
4626 (amd64_ymm_avx512_names, amd64_ymmh_names)
4627 (amd64_ymmh_avx512_names, amd64_mpx_names, amd64_k_names)
4628 (amd64_zmmh_names, amd64_zmm_names, amd64_xmm_avx512_names)
4629 (amd64_pkeys_names, amd64_byte_names, amd64_word_names)
4630 (amd64_dword_names): Now const.
4631 * agent.c (can_use_agent_enum): Now const.
4632 * ada-tasks.c (task_states, long_task_states): Now const.
4633 * ada-lang.c (known_runtime_file_name_patterns)
4634 (known_auxiliary_function_name_patterns, attribute_names)
4635 (standard_exc, ada_extensions): Now const.
4639 * bcache.h (struct bcache) <bcache>: Remove constructor.
4640 <m_hash_function, m_compare_function>: Remove.
4641 <~bcache>: Make virtual.
4642 <compare>: Remove static method, introduce virtual method.
4643 <default_hash>: Remove.
4644 <hash>: New virtual method.
4645 * bcache.c (bcache::expand_hash_table): Update.
4646 (bcache::insert): Update.
4647 (bcache::hash): New.
4648 (bcache::compare): Update comment and parameter names.
4649 * gdbtypes.c (types_deeply_equal): Update.
4650 * psymtab.h (struct psymbol_bcache): New struct.
4651 (class psymtab_storage) <psymtab_storage>: Make default.
4652 <psymbol_cache>: Change type to psymbol_bcache.
4653 * psymtab.c (psymtab_storage::psymtab_storage): Remove.
4654 (psymbol_hash): Change to...
4655 (psymbol_bcache::hash): ... this.
4656 (psymbol_compare): Change to...
4657 (psymbol_bcache::compare): ... this.
4661 * linux-nat.c (linux_nat_wait_1): Don't use inferior_ptid when
4662 checking for initial lwp.
4666 * m68k-tdep.c (m68k_extract_return_value): Use
4667 pointer_result_regnum.
4668 (m68k_store_return_value): Likewise.
4669 (m68k_reg_struct_return_p): Handle vectors and arrays.
4670 (m68k_return_value): Handle arrays.
4671 (m68k_svr4_return_value): Fix single-element aggregate handling.
4672 Handle long double. Adjust for embedded ABI.
4673 (m68k_svr4_init_abi): Set pointer_result_regnum.
4674 (m68k_embedded_init_abi): New function.
4675 (m68k_gdbarch_init): Handle Tag_GNU_M68K_ABI_FP.
4676 (m68k_osabi_sniffer): New function.
4677 (_initialize_m68k_tdep): Register osabi sniffer.
4678 * m68k-tdep.h (struct gdbarch_tdep) <pointer_result_regnum>: New
4683 * xml-support.c (xml_fetch_content_from_file): Replace xfree
4684 with gdb::unique_xmalloc_ptr<char>.
4688 * xml-support.h (xml_fetch_another): Change type to be a
4690 (xml_process_xincludes): Remove baton parameter.
4691 (xml_fetch_content_from_file): Change baton parameter to
4693 * xml-support.c (struct xinclude_parsing_data)
4694 <xinclude_parsing_data>: Remove baton parameter.
4695 <fetcher_baton>: Remove.
4696 (xinclude_start_include): Adjust.
4697 (xml_process_xincludes): Adjust.
4698 (xml_fetch_content_from_file): Replace baton parameter with
4700 * xml-syscall.c (syscall_parse_xml): Remove baton parameter.
4701 (xml_init_syscalls_info): Use a lambda.
4702 * xml-tdesc.c (tdesc_parse_xml): Remove baton parameter.
4703 (file_read_description_xml): Use a lambda.
4704 (fetch_available_features_from_target): Change baton parameter
4706 (target_read_description_xml): Use a lambda.
4707 (target_fetch_description_xml): Use a lambda.
4708 (string_read_description_xml): Update.
4712 * gdbtypes.h (TYPE_ENDIANITY_NOT_DEFAULT): Remove, replace all
4713 uses with type::endianity_is_not_default.
4717 * gdbtypes.h (struct type) <endianity_is_not_default,
4718 set_endianity_is_not_default>: New methods.
4719 (TYPE_ENDIANITY_NOT_DEFAULT): Use
4720 type::endianity_is_not_default, change all write call sites to
4721 use type::set_endianity_is_not_default.
4725 * gdbtypes.h (TYPE_FIXED_INSTANCE): Remove, replace all
4726 uses with type::is_fixed_instance.
4730 * gdbtypes.h (struct type) <is_fixed_instance,
4731 set_is_fixed_instance>: New methods.
4732 (TYPE_FIXED_INSTANCE): Use type::is_fixed_instance, change all
4733 write call sites to use type::set_is_fixed_instance.
4737 * gdbtypes.h (TYPE_GNU_IFUNC): Remove, replace all
4738 uses with type::is_gnu_ifunc.
4742 * gdbtypes.h (struct type) <is_gnu_ifunc, set_is_gnu_ifunc>: New methods.
4743 (TYPE_GNU_IFUNC): Use type::is_gnu_ifunc, change all write call sites to
4744 use type::set_is_gnu_ifunc.
4748 * gdbtypes.h (TYPE_STUB_SUPPORTED): Remove, replace all
4749 uses with type::stub_is_supported.
4753 * gdbtypes.h (struct type) <stub_is_supported, set_stub_is_supported>: New methods.
4754 (TYPE_STUB_SUPPORTED): Use type::stub_is_supported, change all write call sites to
4755 use type::set_stub_is_supported.
4759 * gdbtypes.h (TYPE_VECTOR): Remove, replace all
4760 uses with type::is_vector.
4764 * gdbtypes.h (struct type) <is_vector, set_is_vector>: New methods.
4765 (TYPE_VECTOR): Use type::is_vector, change all write call sites to
4766 use type::set_is_vector.
4770 * gdbtypes.h (TYPE_VARARGS): Remove, replace all
4771 uses with type::has_varargs.
4775 * gdbtypes.h (struct type) <has_varargs, set_has_varargs>: New methods.
4776 (TYPE_VARARGS): Use type::has_varargs, change all write call sites to
4777 use type::set_has_varargs.
4781 * gdbtypes.h (TYPE_PROTOTYPED): Remove, replace all
4782 uses with type::is_prototyped.
4786 * gdbtypes.h (struct type) <is_prototyped, set_is_prototyped>:
4788 (TYPE_PROTOTYPED): Use type::is_prototyped, change all write
4789 call sites to use type::set_is_prototyped.
4793 * gdbtypes.h (TYPE_TARGET_STUB): Remove, replace all
4794 uses with type::target_is_stub.
4798 * gdbtypes.h (struct type) <target_is_stub, set_target_is_stub>:
4800 (TYPE_TARGET_STUB): Use type::is_stub, change all write call
4801 sites to use type::set_target_is_stub.
4805 * gdbtypes.h (TYPE_STUB): Remove, replace all
4806 uses with type::is_stub.
4810 * gdbtypes.h (struct type) <is_stub, set_is_stub>: New methods.
4811 (TYPE_STUB): Use type::is_stub, change all write call sites to
4812 use type::set_is_stub.
4816 * gdbtypes.h (TYPE_NOSIGN): Remove, replace all uses with
4817 type::has_no_signedness.
4821 * gdbtypes.h (struct type) <has_no_signedness,
4822 set_has_no_signedness>: New methods.
4823 (TYPE_NOSIGN): Use type::has_no_signedness, change all write
4824 call sites to use type::set_has_no_signedness.
4828 * gdbtypes.h (TYPE_UNSIGNED): Remove, replace all uses with
4833 * gdbtypes.h (struct type) <is_unsigned, set_is_unsigned>: New
4835 (TYPE_UNSIGNED): Use type::is_unsigned. Change all write call
4836 sites to use type::set_is_unsigned.
4841 * arm-tdep.c (arm_m_exception_cache): Try use correct stack
4842 pointer and stack frame offset when unwinding.
4846 * NEWS: Document "-break-insert --qualified".
4847 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Handle "--qualified".
4851 * linespec.c (classify_mtype, compare_msyms): Delete.
4852 (search_minsyms_for_name): Remove classification logic. Instead
4853 filter out trampoline symbols if we also found an external
4854 function of the same name.
4858 * NEWS: Create a new section for the next release branch.
4859 Rename the section of the current branch, now that it has
4864 GDB 10 branch created (8087c3fa8b5d695e3e29e69d70d0b35ec902ac59):
4865 * version.in: Bump version to 11.0.50.DATE-git.
4869 * infrun.c (namespace selftests): Only define #if GDB_SELF_TEST.
4874 * gdbarch.sh: Added bfloat16 type.
4875 * gdbarch.c: Regenerated.
4876 * gdbarch.h: Regenerated.
4877 * gdbtypes.c (floatformats_bfloat16): New struct.
4878 (gdbtypes_post_init): Add builtin_bfloat16.
4879 * gdbtypes.h (struct builtin_type) <builtin_bfloat16>: New member.
4880 (floatformats_bfloat16): New struct.
4881 * i386-tdep.c (i386_zmm_type): Add field "v32_bfloat16"
4882 (i386_ymm_type): Add field "v16_bfloat16"
4883 (i386_gdbarch_init): Add set_gdbarch_bfloat16_format.
4884 * target-descriptions.c (make_gdb_type): Add case TDESC_TYPE_BFLOAT16.
4885 * gdbsupport/tdesc.cc (tdesc_predefined_types): New member bfloat16.
4886 * gdbsupport/tdesc.h (tdesc_type_kind): New member TDESC_TYPE_BFLOAT16.
4887 * features/i386/64bit-avx512.xml: Add bfloat16 type.
4888 * features/i386/64bit-avx512.c: Regenerated.
4889 * features/i386/64bit-sse.xml: Add bfloat16 type.
4890 * features/i386/64bit-sse.c: Regenerated.
4894 * i386-tdep.c (i386_zmm_type): Fix field names.
4895 (i386_ymm_type): Fix field names.
4899 * breakpoint.c: Fix typo in the help message of the
4900 "set breakpoint condition-evaluation" command.
4904 * nbsd-nat.c: Include "nat/netbsd-nat.h".
4905 * (nbsd_nat_target::pid_to_exec_file)
4906 (nbsd_nat_target::thread_alive, nbsd_nat_target::thread_name)
4907 (nbsd_nat_target::post_startup_inferior)
4908 (nbsd_nat_target::post_attach, nbsd_nat_target::xfer_partial)
4909 (nbsd_add_threads): Switch local code to common gdb/nat functions.
4910 * (nbsd_pid_to_cmdline): Call sysctl from the global namespace.
4911 * (nbsd_thread_lister): Remove.
4915 * fork-inferior.c (startup_inferior): Avoid double free.
4919 * netbsd-nat.h (netbsd_nat::qxfer_siginfo): Add.
4920 * netbsd-nat.c (netbsd_nat::qxfer_siginfo): Likewise.
4924 * netbsd-nat.h (netbsd_nat::enable_proc_events): Add.
4925 * netbsd-nat.c: Include <sys/ptrace.h>.
4926 * (netbsd_nat::enable_proc_events): Add.
4930 * netbsd-nat.h: Include "gdbsupport/function-view.h".
4931 * (netbsd_nat::thread_alive, netbsd_nat::thread_name)
4932 (netbsd_nat::for_each_thread): Add.
4933 * netbsd-nat.c: Include "gdbsupport/common-defs.h" and
4934 "gdbsupport/common-debug.h".
4935 * (netbsd_nat::netbsd_thread_lister)
4936 (netbsd_nat::thread_alive, netbsd_nat::thread_name)
4937 (netbsd_nat::for_each_thread): Add.
4941 * netbsd-nat.h: Include <unistd.h>.
4942 * (netbsd_nat::pid_to_exec_file): Add.
4943 * netbsd-nat.c: Include <sys/types.h> and <sys/sysctl.h>.
4944 * (netbsd_nat::pid_to_exec_file) Add.
4948 * configure.nat (NATDEPFILES): Add nat/netbsd-nat.o when needed.
4952 * netbsd-nat.h: New file.
4953 * netbsd-nat.c: Likewise.
4957 * ada-lang.c (remove_extra_symbols): Do not increment when
4962 * gdb_bfd.c (gdb_bfd_open): Call bfd_fopen when fstat fails.
4967 * gdb_bfd.c (gdb_bfd_data): Add "st" parameter.
4968 (gdb_bfd_init_data): New function.
4969 (gdb_bfd_open, gdb_bfd_ref): Use gdb_bfd_init_data.
4973 * infrun.c (fetch_inferior_event): Use
4974 `switch_to_target_no_thread` to switch the target.
4978 * symfile.h (dwarf2_free_objfile): Don't declare.
4982 * gdb/i386-tdep.c (i386_floatformat_for_type): Added conditions
4983 to match 16 byte real/complex type generated by Flang compiler.
4988 * dwarf2/read.c (new_symbol): Tag label symbol without DW_AT_low_pc as
4989 LOC_OPTIMIZED_OUT instead of LOC_LABEL.
4993 * maint.c (index_digits): New function.
4994 (struct maint_print_section_data): Remove.
4995 (print_bfd_section_info): Remove print_data parameter, add arg
4997 (print_objfile_section_info): Likewise.
4998 (print_bfd_section_info_maybe_relocated): Likewise (plus
5000 (maintenance_info_sections): Adjust calls.
5004 * ada-varobj.c (ada_varobj_get_ptr_number_of_children): Return 0
5006 (ada_varobj_adjust_for_child_access): Special-case null pointers.
5010 * bcache.h (struct bcache) <insert>: Change type of `added` to
5012 * bcache.c (bcache::insert): Likewise.
5013 * gdbtypes.c (check_types_worklist): Adjust.
5014 * psymtab.c (add_psymbol_to_bcache): Adjust.
5018 * corelow.c (unordered_set): Include.
5019 (class core_target): Add field 'm_core_unavailable_mappings'.
5020 (core_target::build_file_mappings): Print only one warning
5021 per inaccessible file. Add unavailable/broken mappings
5022 to m_core_unavailable_mappings.
5023 (core_target::xfer_partial): Call...
5024 (core_target::xfer_memory_via_mappings): New method.
5028 * dwarf2/read.c (struct field_info) <non_public_fields>: Change
5033 * dwarf2/read.c (struct field_info): Fix indentation.
5037 * frame-unwind.h (frame_prev_register_ftype): Fix adjective
5038 ordering in comment.
5039 * frame.c (frame_id_eq): Fix indentation.
5044 * inline-frame.c (inline_frame_this_id): Remove assert that prevents
5045 inline frame ids in outer frame.
5049 * frame.h (enum frame_id_stack_status) <FID_STACK_OUTER>: New.
5050 * frame.c (fprint_frame_id): Handle FID_STACK_OUTER.
5051 (outer_frame_id): Use FID_STACK_OUTER instead of
5053 (frame_id_p): Don't check for outer_frame_id.
5057 * frame-unwind.c (frame_unwind_got_optimized): Don't set
5058 regnum/frame in value. Call allocate_value_lazy.
5059 * frame.c (frame_unwind_register_value): Use
5060 val_print_not_saved.
5064 * gdbtypes.h (NULL_TYPE): Remove, change all uses to nullptr.
5068 * progspace.c (print_program_space): Use all_inferiors. Switch to
5069 the inferior before calling target_pid_to_str.
5073 * xcoffread.c (xcoff_end_psymtab): Update comment.
5074 * dbxread.c (dbx_end_psymtab): Update comment.
5079 * breakpoint.c (parse_breakpoint_sals): Remove const from struct
5081 (create_breakpoint): Same.
5082 (base_breakpoint_decode_location): Same.
5083 (bkpt_create_sals_from_location): Same.
5084 (bkpt_decode_location): Same.
5085 (bkpt_probe_create_sals_from_location): Same.
5086 (bkpt_probe_decode_location): Same.
5087 (tracepoint_create_sals_from_location): Same.
5088 (tracepoint_decode_location): Same.
5089 (tracepoint_probe_decode_location): Same.
5090 (strace_marker_create_sals_from_location): Same.
5091 (strace_marker_decode_location): Same.
5092 (create_sals_from_location_default): Same.
5093 (decode_location_default): Same.
5094 * breakpoint.h (struct breakpoint_ops): Same.
5095 (create_breakpoint): Same.
5096 * linespec.h (decode_line_full): Same.
5097 * linespec.c (decode_line_full): Same. Throw error if
5098 result.size () == 0.
5103 * breakpoint.c (until_break_fsm) <location_breakpoint,
5104 caller_breakpoint>: Delete fields.
5105 <breakpoints>: New field.
5106 <until_break_fsm>: Adjust to save a breakpoint vector instead of
5107 two individual breakpoints.
5108 (until_break_fsm::should_stop): Loop over breakpoints in the
5110 (until_break_fsm::clean_up): Adjust to clear the breakpoints
5112 (until_break_command): Handle location expanding into multiple
5118 * inline-frame.c (stopped_by_user_bp_inline_frame): Also consider
5119 bp_until breakpoints user-specified locations. Update intro
5124 * gdb_bfd.h (gdb_bfd_section_iterator, gdb_bfd_section_range,
5125 gdb_bfd_sections): New.
5126 * maint.c (print_bfd_section_info): Change param type to
5127 maint_print_section_data.
5128 (print_objfile_section_info): Likewise.
5129 (print_bfd_section_info_maybe_relocated): Likewise.
5130 (maintenance_info_sections): Use gdb_bfd_sections.
5134 * MAINTAINERS: Add ARC target and maintainer.
5138 * configure.tgt: ARC support for GNU/Linux.
5139 * Makefile.in (ALL_TARGET_OBJS): Likewise.
5140 * arc-linux-tdep.c: New file.
5141 * arc-tdep.h (ARC_STATUS32_L_MASK, ARC_STATUS32_DE_MASK): Declare.
5142 * arc-tdep.c (arc_write_pc): Use it.
5146 * arc-tdep.c (arc_check_for_hardware_loop): New.
5147 * arc-tdep.h (gdbarch_tdep): New field has_hw_loops.
5151 * arc-tdep.h: Include "gdbarch.h".
5156 (arc_gdbarch_features): New class to stir the selection of target XML.
5157 (arc_create_target_description): Use FEATURES to choose XML target.
5158 (arc_lookup_target_description): Use arc_create_target_description
5159 to create _new_ target descriptions or return the already created
5160 ones if the FEATURES is the same.
5161 * arch/arc.c: Implementation of prototypes described above.
5162 * gdb/arc-tdep.h (arc_regnum enum): Add more registers.
5163 (arc_gdbarch_features_init): Initialize the FEATURES struct.
5164 * arc-tdep.c (*_feature_name): Make feature names consistent.
5165 (arc_register_feature): A new struct to hold information about
5166 registers of a particular target/feature.
5167 (arc_check_tdesc_feature): Check if XML provides registers in
5168 compliance with ARC_REGISTER_FEATURE structs.
5169 (arc_update_acc_reg_names): Add aliases for r58 and r59.
5170 (determine_*_reg_feature_set): Which feature name to look for.
5171 (arc_gdbarch_features_init): Given MACH and ABFD, initialize FEATURES.
5172 (mach_type_to_arc_isa): Convert from a set of binutils machine types
5173 to expected ISA enums to be used in arc_gdbarch_features structs.
5174 * features/Makefile (FEATURE_XMLFILES): Add new files.
5175 * gdb/features/arc/v1-aux.c: New file.
5176 * gdb/features/arc/v1-aux.xml: Likewise.
5177 * gdb/features/arc/v1-core.c: Likewise.
5178 * gdb/features/arc/v1-core.xml: Likewise.
5179 * gdb/features/arc/v2-aux.c: Likewise.
5180 * gdb/features/arc/v2-aux.xml: Likewise.
5181 * gdb/features/arc/v2-core.c: Likewise.
5182 * gdb/features/arc/v2-core.xml: Likewise.
5183 * NEWS (Changes since GDB 9): Announce obsolence of old feature names.
5189 * m2-exp.y (exp): Improve comment for non_empty_arglist case, add
5190 an assert. Remove single element array indexing pattern as the
5191 MULTI_SUBSCRIPT support will handle this case too.
5195 * value.h (valprint_check_validity): Move declaration from
5197 * valprint.h (valprint_check_validity): ... to here.
5201 * debug.h: New file.
5202 * debug.c (debug_prefixed_vprintf): New function.
5203 * infrun.c (infrun_debug_printf_1): Use debug_prefixed_vprintf.
5204 * linux-nat.c (linux_nat_debug_printf_1): Likewise.
5208 * infrun.h (infrun_debug_printf_1): New function declaration.
5209 (infrun_debug_printf): New macro.
5210 * infrun.c (infrun_debug_printf_1): Use infrun_debug_printf
5212 (infrun_debug_printf): New function.
5213 * breakpoint.c (should_be_inserted): Use infrun_debug_printf.
5214 (handle_jit_event): Likewise.
5218 * ada-lex.l: Extend register warnings diagnostics comment for g++.
5222 * frame.c (enum class frame_id_status): New.
5223 (struct frame_info) <this_id::p>: Change type to frame_id_status.
5224 (fprintf_frame): Update.
5225 (compute_frame_id): Set frame id status to "computing" on entry.
5226 Set it back to "not_computed" on failure and to "computed" on
5228 (get_frame_id): Assert the frame id is not being computed.
5229 (create_sentinel_frame): Use frame_id_status::COMPUTED.
5230 (create_new_frame): Likewise.
5231 (frame_cleanup_after_sniffer): Update assert.
5235 * regcache.c (pid_ptid_regcache_map): New type.
5236 (target_ptid_regcache_map): Remove.
5237 (target_pid_ptid_regcache_map): New type.
5238 (regcaches): Change type to target_pid_ptid_regcache_map.
5239 (get_thread_arch_aspace_regcache): Update.
5240 (regcache_thread_ptid_changed): Update, handle pid-like ptid
5242 (regcaches_size): Update.
5243 (regcache_count): Update.
5244 (registers_changed_ptid_target_pid_test): New.
5245 (_initialize_regcache): Register new test.
5249 * regcache.c (regcache_count): New.
5250 (struct regcache_test_data): New.
5251 (regcache_test_data_up): New.
5252 (populate_regcaches_for_test): New.
5253 (regcaches_test): Remove.
5254 (get_thread_arch_aspace_regcache_test): New.
5255 (registers_changed_ptid_all_test): New.
5256 (registers_changed_ptid_target_test): New.
5257 (registers_changed_ptid_target_ptid_test): New.
5258 (regcache_thread_ptid_changed): Remove regcache_count lambda.
5259 (_initialize_regcache): Register new tests.
5263 * regcache.c (test_get_thread_arch_aspace_regcache): Rename to...
5264 (get_thread_arch_aspace_regcache_and_check): ... this. Remove
5265 gdbarch and aspace parameter. Use current inferior's aspace.
5266 Validate regcache's arch value.
5267 (regcaches_test): Update.
5271 * regcache.c (regcaches_test): Call registers_changed.
5275 * infrun.c (process_event_stop_test): Fix typo "breapoint".
5279 * amd64-tdep.c (amd64_skip_prologue): Using symbol table
5280 to find the end of prologue for flang compiled binaries.
5281 * arm-tdep.c (arm_skip_prologue): Likewise.
5282 * i386-tdep.c (i386_skip_prologue): Likewise.
5283 * producer.c (producer_is_llvm): New function.
5284 (producer_parsing_tests): Added new tests for clang/flang.
5285 * producer.h (producer_is_llvm): New declaration.
5289 * linux-nat.c (linux_nat_debug_printf): New function.
5290 (linux_nat_debug_printf_1): New macro. Use throughout the file.
5294 * Makefile.in (DEBUGINFOD_CFLAGS, DEBUGINFOD_LIBS): New variables.
5295 (INTERNAL_CFLAGS_BASE): Add DEBUGINFOD_CFLAGS.
5296 (CLIBS): Add DEBUGINFOD_LIBS.
5300 * ia64-linux-nat.c: Include "gdbarch.h" to declare used
5305 * ada-varobj.c (ada_varobj_decode_var): Handle case where
5306 ada_get_decoded_value returns NULL.
5310 * python/py-inferior.c (infpy_search_memory): Use
5311 gdb_py_object_from_ulongest.
5312 * python/py-infevents.c (create_inferior_call_event_object)
5313 (create_memory_changed_event_object): Use
5314 gdb_py_object_from_ulongest.
5315 * python/py-linetable.c (ltpy_entry_get_pc): Use
5316 gdb_py_object_from_ulongest.
5320 * loc.c (class symbol_needs_eval_context): Fix indentation.
5324 * dwarf2/loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
5330 * gdbtypes.c (dump_dynamic_prop): New function.
5331 (recursive_dump_type): Use dump_dynamic_prop for TYPE_CODE_RANGE.
5336 * stack.c (print_frame_args): Temporarily set the selected
5337 frame to FRAME while printing the frame's arguments.
5341 PR breakpoints/26385
5342 * ppc-linux-nat.c (ppc_linux_nat_target::low_prepare_to_resume):
5343 Always clear watchpoint with PTRACE_SET_DEBUGREG.
5347 * ppc-linux-nat.c (ppc_linux_dreg_interface::detect)
5348 (ppc_linux_nat_target::low_prepare_to_resume): Use ptrace () < 0
5349 and >= to check return value instead of == -1 and != -1.
5353 * utils.h (class gdb_argv) <as_array_view>: New method.
5354 * utils.c (gdb_argv_as_array_view_test): New.
5355 (_initialize_utils): Register selftest.
5356 * maint.c (maintenance_selftest): Use the new method.
5360 * target.h (supports_dumpcore, dumpcore): New
5361 function declarations.
5362 * target.c (supports_dumpcore, dumpcore): New
5364 * target-delegates.c: Rebuild.
5365 * gcore.c (gcore_command): Use target_supports_dumpcore ()
5366 and target_dumpcore ().
5370 * debuginfod-support.c: Replace global variables with user_data.
5374 * maint.c (maintenance_selftest): Split args and pass array_view
5379 * value.c (check_type_length_before_alloc): Use ULONGEST to store a
5381 Use %s and pulongest to print the length.
5385 * NEWS: Move "Multi-target debugging support" item to the
5386 "Changes since GDB 9" section.
5391 * progspace.c (program_space::remove_objfile): Invalidate the
5396 * MAINTAINERS: Mark ms1 as deleted.
5402 * aarch64-tdep.c (aarch64_analyze_prologue): Track use of SP/FP and
5404 (aarch64_analyze_prologue_test): Add more unit tests to exercise
5405 movz/str/stur/stp skipping behavior.
5409 * nat/aarch64-sve-linux-sigcontext.h (SVE_PT_REGS_OFFSET): Use
5410 struct user_sve_header instead of struct sve_context.
5414 * read.h (dwarf2_fetch_die_loc_sect_off,
5415 dwarf2_fetch_die_loc_cu_off): Replace function pointer +
5416 `void *` parameter with function_view.
5417 * read.c (dwarf2_fetch_die_loc_sect_off,
5418 dwarf2_fetch_die_loc_cu_off): Likewise.
5419 * loc.c (get_frame_pc_for_per_cu_dwarf_call): Remove.
5420 (per_cu_dwarf_call): Adjust.
5421 (get_frame_address_in_block_wrapper): Remove.
5422 (indirect_synthetic_pointer): Adjust.
5423 (get_ax_pc): Remove.
5424 (dwarf2_compile_expr_to_ax): Adjust.
5429 * arch/riscv.c (riscv_lookup_target_description): Use an explicit
5431 * regcache.c (get_thread_arch_aspace_regcache): Same.
5435 * ravenscar-thread.c
5436 (ravenscar_thread_target::set_base_thread_from_ravenscar_task):
5438 (ravenscar_thread_target::wait): Check
5439 runtime_initialized.
5440 (ravenscar_thread_target::prepare_to_store)
5441 (ravenscar_thread_target::stopped_by_sw_breakpoint)
5442 (ravenscar_thread_target::stopped_by_hw_breakpoint)
5443 (ravenscar_thread_target::stopped_by_watchpoint)
5444 (ravenscar_thread_target::stopped_data_address)
5445 (ravenscar_thread_target::core_of_thread): Use
5446 scoped_restore_current_thread and
5447 set_base_thread_from_ravenscar_task.
5451 * ravenscar-thread.c (update_thread_list): Set inferior_ptid.
5455 * ravenscar-thread.c (ravenscar_thread_target::wait): Call
5456 update_inferior_ptid before update_thread_list.
5457 (temporarily_change_regcache_ptid): New class.
5458 (ravenscar_thread_target::fetch_registers)
5459 (ravenscar_thread_target::store_registers)
5460 (ravenscar_thread_target::prepare_to_store): Use base thread when
5461 forwarding operation.
5465 * ravenscar-thread.c (ravenscar_thread_target::resume): Handle
5470 * ravenscar-thread.c (xfer_partial, enable_btrace, add_thread):
5472 (ravenscar_thread_target::get_thread_base_cpu): Check m_cpu_map
5474 (ravenscar_thread_target::add_thread): Rename from
5475 ravenscar_add_thread.
5476 (ravenscar_thread_target::update_thread_list): Use a lambda.
5477 (ravenscar_thread_target::xfer_partial): New method.
5481 * ada-lang.h (ada_task_list_iterator_ftype): Now a
5483 (iterate_over_live_ada_tasks): Change type of argument.
5484 * ada-tasks.c (iterate_over_live_ada_tasks): Change type
5489 * ravenscar-thread.c (ravenscar_thread_target) <extra_thread_info>:
5491 (ravenscar_thread_target::extra_thread_info): Remove.
5492 (ravenscar_thread_target::pid_to_str): Mention Ravenscar in result;
5493 defer to target beneath for non-Ravenscar threads.
5497 * ravenscar-thread.c (ravenscar_thread_target) <get_base_cpu,
5498 get_base_thread_from_ravenscar_task>: Now methods.
5499 <m_cpu_map>: New member.
5500 (ravenscar_thread_target::get_thread_base_cpu): Rename from
5501 ravenscar_get_thread_base_cpu. Check m_cpu_map.
5502 (ravenscar_thread_target::task_is_currently_active): Update.
5503 (ravenscar_thread_target::get_base_thread_from_ravenscar_task):
5505 (ravenscar_thread_target::add_active_thread): Put initial thread
5510 * ravenscar-thread.c (ravenscar_thread_target::wait): Return
5515 * ravenscar-thread.c (ravenscar_thread_target::wait): Check
5516 runtime_initialized.
5520 * ravenscar-thread.c (ravenscar_thread_target): Don't call
5522 (ravenscar_thread_target::add_active_thread): Now public.
5523 (ravenscar_inferior_created): Call add_active_thread after pushing
5528 * regcache.c (ptid_regcache_map): New type.
5529 (target_ptid_regcache_map): New type.
5530 (regcaches): Change type to target_ptid_regcache_map.
5531 (get_thread_arch_aspace_regcache): Update to regcaches' new
5533 (regcache_thread_ptid_changed): Likewise.
5534 (registers_changed_ptid): Likewise.
5535 (regcaches_size): Likewise.
5536 (regcaches_test): Update.
5537 (regcache_thread_ptid_changed): Update.
5538 * regcache.h (regcache_up): New type.
5539 * gdbsupport/ptid.h (hash_ptid): New struct.
5543 * observable.h (thread_ptid_changed): Add parameter
5544 `process_stratum_target *`.
5545 * infrun.c (infrun_thread_ptid_changed): Add parameter
5546 `process_stratum_target *` and use it.
5547 (selftests): New namespace.
5548 (infrun_thread_ptid_changed): New function.
5549 (_initialize_infrun): Register selftest.
5550 * regcache.c (regcache_thread_ptid_changed): Add parameter
5551 `process_stratum_target *` and use it.
5552 (regcache_thread_ptid_changed): New function.
5553 (_initialize_regcache): Register selftest.
5554 * thread.c (thread_change_ptid): Pass target to
5555 thread_ptid_changed observable.
5559 * dwarf2/read.c (struct dwo_file): Update comment on 'sections' field.
5560 (struct dwp_sections): Update field comments. Add loclists and
5562 (struct virtual_v2_dwo_sections): Rename struct to
5563 'virtual_v2_or_v5_dwo_sections'; update comments at top of struct; add
5564 size & offset fields for loclists and rnglists.
5565 (struct dwp_hash_table): Add a 'v5' struct field to the union section.
5566 (create_debug_type_hash_table): Add 'DW_UT_split_type' to the check for
5567 skipping dummy type units.
5568 (create_dwp_hash_table): Update the large comment above the function to
5569 discuss Version 5 DWP files as well, with references. Update all the
5570 version checks in the function to check for version 5 as well. Add new
5571 section at the end to create dwp hash table for version 5.
5572 (create_dwp_v2_section): Rename function to
5573 'create_dwp_v2_or_v5_section'. Update function comment appropriately.
5574 Add V5 to error message text.
5575 (create_dwo_unit_in_dwp_v2): Change calls to create_dwp_v2_section
5576 into calls to create_dwp_v2_or_v5_section.
5577 (create_dwo_unit_in_dwp_v5): New function.
5578 (lookup_dwo_unit_in_dwp): Update conditional statement to explicitly
5579 check for version2; add else clause to handle version 5.
5580 (open_and_init_dwo_file): Add code to check dwarf version & only call
5581 create_debug_types_hash_table (with sections.types) if version is not 5;
5582 else call create_debug_type_hash_table, with sections.info.
5583 (dwarf2_locate_v2_dwp_sections): Update function comment to mention
5585 (dwarf2_locate_v5_dwp_sections): New function.
5586 (open_and_init_dwp_file): Add else-if clause for version 5 to call
5587 bfd_map_over_sections with dwarf2_locate_v5_dwp_sections.
5591 * regcache.h (class regcache): Remove friend
5592 registers_changed_ptid.
5593 <regcache_thread_ptid_changed>: Remove.
5594 <regcaches>: Remove.
5595 * regcache.c (regcache::regcaches): Rename to...
5596 (regcaches): ... this. Make static.
5597 (get_thread_arch_aspace_regcache): Update.
5598 (regcache::regcache_thread_ptid_changed): Rename to...
5599 (regcache_thread_ptid_changed): ... this. Update.
5600 (class regcache_access): Remove.
5601 (regcaches_test): Update.
5602 (_initialize_regcache): Update.
5603 * sparc64-tdep.c, dwarf2/index-write.c, record-btrace.c: Include
5608 * regcache.h (class regcache) <current_regcache>: Rename to...
5609 <regcaches>: ... this. Move doc here.
5610 * regcache.c (regcache::current_regcache) Rename to...
5611 (regcache::regcaches): ... this. Move doc to header.
5612 (get_thread_arch_aspace_regcache): Update.
5613 (regcache::regcache_thread_ptid_changed): Update.
5614 (registers_changed_ptid): Update.
5615 (class regcache_access) <current_regcache_size>: Rename to...
5616 <regcaches_size>: ... this.
5617 (current_regcache_test): Rename to...
5618 (regcaches_test): ... this.
5619 (_initialize_regcache): Update.
5623 * amd64-tdep.c (amd64_analyze_prologue): Fix incorrect comment.
5627 * corelow.c (core_target::build_file_mappings): Don't output
5628 null pathname in warning.
5632 * gdb.dwarf2/clztest.exp, gdb.dwarf2/dw2-common-block.exp,
5633 gdb.dwarf2/dw2-dup-frame.exp, gdb.dwarf2/dw2-reg-undefined.exp,
5634 gdb.dwarf2/dw2-single-line-discriminators.exp,
5635 dw2-undefined-ret-addr.exp: Pass nopie to compilation options.
5640 * dwarf2/read.c (alloc_rust_variant): Handle univariant case.
5641 (quirk_rust_enum): Call alloc_rust_variant for univariant case.
5642 Fix off-by-one and type size errors in ordinary case.
5646 * gdbtypes.c (type_not_allocated, type_not_associated): Use
5647 "prop->const_val () == 0" instead of "prop->const_val () != 0".
5651 * frame.h (frame_id_p): Return bool.
5652 (frame_id_artificial_p): Return bool.
5653 (frame_id_eq): Return bool.
5654 (has_stack_frames): Return bool.
5655 (get_selected_frame): Fix typo in comment.
5656 (get_frame_pc_if_available): Return bool.
5657 (get_frame_address_in_block_if_available): Return bool.
5658 (get_frame_func_if_available): Return bool.
5659 (read_frame_register_unsigned): Return bool.
5660 (get_frame_register_bytes): Return bool.
5661 (safe_frame_unwind_memory): Return bool.
5662 (deprecated_frame_register_read): Return bool.
5663 (frame_unwinder_is): Return bool.
5664 * frame.c (struct frame_info) <prev_arch::p>: Change type to
5666 <this_id::p>: Likewise.
5668 (frame_stash_add): Return bool.
5669 (get_frame_id): Use bool.
5670 (frame_id_build_special) Use bool.
5671 (frame_id_build_unavailable_stack): Use bool.
5672 (frame_id_build): Use bool.
5673 (frame_id_p): Return bool, use true/false instead of 1/0.
5674 (frame_id_artificial_p): Likewise.
5675 (frame_id_eq): Likewise.
5676 (frame_id_inner): Likewise.
5677 (get_frame_func_if_available): Likewise.
5678 (read_frame_register_unsigned): Likewise.
5679 (deprecated_frame_register_read): Likewise.
5680 (get_frame_register_bytes): Likewise.
5681 (has_stack_frames): Likewise.
5682 (inside_main_func): Likewise.
5683 (inside_entry_func): Likewise.
5684 (get_frame_pc_if_available): Likewise.
5685 (get_frame_address_in_block_if_available): Likewise.
5686 (frame_unwinder_is): Likewise.
5687 (safe_frame_unwind_memory): Likewise.
5688 (frame_unwind_arch): Likewise.
5692 * frame.c (frame_info) <prev_func> <p>: Rename to status, change
5693 type to cached_copy_status.
5694 (fprintf_frame): Adjust.
5695 (get_frame_func_if_available): Adjust.
5696 (frame_cleanup_after_sniffer): Adjust.
5700 * MAINTAINERS (Write After Approval): Update email address.
5704 * gdbtypes.h (TYPE_DYN_PROP_ADDR): Remove, replace uses with
5705 dynamic_prop::const_val.
5709 * gdbtypes.h (TYPE_DYN_PROP_KIND): Remove, replace uses with
5714 * gdbtypes.h (TYPE_DYN_PROP_BATON): Remove.
5718 * configure.tgt: Set gdb_sim for bpf-*-* targets.
5723 * configure.tgt: Add entry for bpf-*-*.
5724 * Makefile.in (ALL_TARGET_OBS): Add bpf-tdep.o
5725 (ALLDEPFILES): Add bpf-tdep.c.
5726 * bpf-tdep.c: New file.
5727 * MAINTAINERS: Add bpf target and maintainer.
5728 * NEWS: Mention the support for the new target.
5733 * dwarf2/read.c (find_partial_die): Change internal error into Dwarf
5738 * syscalls/freebsd.xml: Regenerate.
5742 * syscalls/update-freebsd.sh: Fix usage and year range.
5747 * dwarf2/read.c (dwarf_decode_lines_1): Ignore
5748 DW_LNE_lo_user/DW_LNE_hi_user range.
5753 * ada-lang.c (ada_modulus): Return 0 if property is not of const
5758 * breakpoint.c (set_breakpoint_condition): Do minor refactoring.
5762 * breakpoint.c (set_breakpoint_condition): Update the condition
5763 expressions after checking that the input condition string parses
5764 successfully and does not contain junk at the end.
5768 * breakpoint.c (set_breakpoint_condition): Update the
5769 condition string after parsing the new condition successfully.
5773 * proc-api.c (_STRUCTURED_PROC): Don't define.
5774 * proc-events.c: Likewise.
5775 * proc-flags.c: Likewise.
5776 * proc-why.c: Likewise.
5777 * procfs.c: Likewise.
5779 * Makefile.in (INTERNAL_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
5780 * configure, config.in: Regenerate.
5785 * ui-style.h (struct ui_file_style::color): Wrap m_value and
5786 m_red/m_green/m_blue in a union.
5791 * s390-tdep.c (s390_displaced_step_fixup): Fix Wmaybe-uninitialized.
5796 * symtab.h (find_pc_partial_function_sym): Declare.
5797 * cli/cli-cmds.c (disassemble_command): Use
5798 find_pc_partial_function_sym. Check asm_demangle.
5799 * blockframe.c (cache_pc_function_sym): New global.
5800 (cache_pc_function_name): Remove.
5801 (clear_pc_function_cache): Update.
5802 (find_pc_partial_function_sym): New function, from
5803 find_pc_partial_function.
5804 (find_pc_partial_function): Rewrite using
5805 find_pc_partial_function_sym.
5809 * cli/cli-cmds.c (_initialize_cli_cmds): Rearrange "disassemble"
5814 * dwarf2/expr.c (dwarf_expr_context::execute_stack_op)
5815 <DW_OP_GNU_variable_value>: Cast to address type.
5819 * nbsd-nat.h (nbsd_nat_target::xfer_partial): New declaration.
5820 * nbsd-nat.c (nbsd_nat_target::xfer_partial): New function.
5821 * nbsd-tdep.c (nbsd_gdbarch_data_handle, struct nbsd_gdbarch_data)
5822 (init_nbsd_gdbarch_data, get_nbsd_gdbarch_data)
5823 (nbsd_get_siginfo_type): New.
5824 (nbsd_init_abi): Install gdbarch "get_siginfo_type" method.
5825 (_initialize_nbsd_tdep): New.
5830 * configure: Regenerated.
5835 * configure: Regenerated.
5839 * python/py-frame.c: Remove 'user-regs.h' include.
5840 (frapy_read_register): Rewrite to make use of
5841 gdbpy_parse_register_id.
5842 * python/py-registers.c (gdbpy_parse_register_id): New function,
5843 moved here from python/py-unwind.c. Updated the return type, and
5844 also accepts register descriptor objects.
5845 * python/py-unwind.c: Remove 'user-regs.h' include.
5846 (pyuw_parse_register_id): Moved to python/py-registers.c.
5847 (unwind_infopy_add_saved_register): Update to use
5848 gdbpy_parse_register_id.
5849 (pending_framepy_read_register): Likewise.
5850 * python/python-internal.h (gdbpy_parse_register_id): Declare.
5854 * python/py-registers.c: Add 'user-regs.h' include.
5855 (register_descriptor_iter_find): New function.
5856 (register_descriptor_iterator_object_methods): New static global
5858 (register_descriptor_iterator_object_type): Add pointer to methods
5863 * fbsd-nat.h: Include <osreldate.h>. Define USE_SIGTRAP_SIGINFO
5864 for all architectures on FreeBSD 11.3 and later.
5868 * gcore.h (load_corefile): Don't declare.
5872 * configure.ac: Fix sys/sockets.h -> sys/socket.h typo.
5873 * config.in: Regenerate.
5874 * configure: Regenerate.
5878 * configure.ac (AC_CHECK_HEADERS): Check for sys/socket.h and
5879 ws2tcpip.h. When checking whether socklen_t type is defined, use
5880 ws2tcpip.h if it is available and sys/socket.h isn't.
5881 * configure: Regenerate.
5882 * config.in: Regenerate.
5888 * valops.c (value_ind): Pass address to
5889 readjust_indirect_value_type.
5890 * value.c (readjust_indirect_value_type): Make parameter
5891 non-const, and add extra address parameter. Resolve original type
5893 * value.h (readjust_indirect_value_type): Update function
5894 signature and comment.
5899 * dwarf2/read.c (lnp_state_machine::record_line): Ignore zero line
5904 * Makefile.in: Replace LIBDEBUGINFOD with DEBUGINFOD_LIBS.
5905 * configure: Rebuild.
5910 * corelow.c (_initialize_corelow): Add period to help text
5911 for "maintenance print core-file-backed-mappings".
5915 * frame-unwind.c (frame_unwind_try_unwinder): On exception, don't
5916 touch THIS_CACHE/THIS_FRAME if the frame cache was cleared
5918 * frame.c (frame_cache_generation, get_frame_cache_generation):
5920 (reinit_frame_cache): Increment FRAME_CACHE_GENERATION.
5921 (get_prev_frame_if_no_cycle): On exception, don't touch
5922 PREV_FRAME/THIS_FRAME if the frame cache was cleared meanwhile.
5923 * frame.h (get_frame_cache_generation): Declare.
5928 * tui/tui-winsource.h (struct tui_source_windows::tui_source_windows):
5929 New default constructor.
5933 * disasm.c (do_mixed_source_and_assembly_deprecated): Don't
5934 exclude non-statement entries.
5938 * NEWS (New commands): Mention new command
5939 "maintenance print core-file-backed-mappings".
5943 * corelow.c (gdbcmd.h): Include.
5944 (core_target::info_proc_mappings): New method.
5945 (get_current_core_target): New function.
5946 (maintenance_print_core_file_backed_mappings): New function.
5947 (_initialize_corelow): Add core-file-backed-mappings to
5948 "maint print" commands.
5952 * linux-tdep.c (dump_note_entry_p): New function.
5953 (linux_dump_mapping_p_ftype): New typedef.
5954 (linux_find_memory_regions_full): Add new parameter,
5955 should_dump_mapping_p.
5956 (linux_find_memory_regions): Adjust call to
5957 linux_find_memory_regions_full.
5958 (linux_make_mappings_core_file_notes): Use dump_note_entry_p in
5959 call to linux_find_memory_regions_full.
5963 * corelow.c (solist.h, unordered_map): Include.
5964 (class core_target): Add field m_core_file_mappings and
5965 method build_file_mappings.
5966 (core_target::core_target): Call build_file_mappings.
5967 (core_target::~core_target): Free memory associated with
5968 m_core_file_mappings.
5969 (core_target::build_file_mappings): New method.
5970 (core_target::xfer_partial): Use m_core_file_mappings
5971 for memory transfers.
5972 * linux-tdep.c (linux_read_core_file_mappings): New
5974 (linux_core_info_proc_mappings): Rewrite to use
5975 linux_read_core_file_mappings.
5976 (linux_init_abi): Register linux_read_core_file_mappings.
5980 * arch-utils.c (default_read_core_file_mappings): New function.
5981 * arch-utils.c (default_read_core_file_mappings): Declare.
5982 * gdbarch.sh (read_core_file_mappings): New gdbarch method.
5983 * gdbarch.h, gdbarch.c: Regenerate.
5988 * corelow.c (core_target:xfer_partial): Revise
5989 TARGET_OBJECT_MEMORY case to consider non-SEC_HAS_CONTENTS
5990 case after first checking the stratum beneath the core
5992 (has_all_memory): Return true.
5993 * target.c (raw_memory_xfer_partial): Revise comment
5994 regarding use of has_all_memory.
5998 * exec.h (section_table_xfer_memory): Revise declaration,
5999 replacing section name parameter with an optional callback
6001 * exec.c (section_table_xfer_memory): Likewise.
6002 * bfd-target.c, exec.c, target.c, corelow.c: Adjust all callers
6003 of section_table_xfer_memory.
6007 * mi/mi-cmd-stack.c (list_args_or_locals): Use
6008 lookup_symbol_search_name.
6012 * python/py-registers.c (gdbpy_register_object_data_init): Remove
6013 redundant local variable.
6014 (gdbpy_get_register_descriptor): Extract descriptor vector as a
6015 reference, not pointer, update code accordingly.
6020 * objfiles.h (struct objfile) <skip_jit_symbol_lookup>: New field.
6021 * jit.c (jit_breakpoint_re_set_internal): Use the
6022 `skip_jit_symbol_lookup` field.
6027 * jit.c (jit_read_descriptor): Define the descriptor address once,
6029 (jit_breakpoint_deleted): Move the declaration of the loop variable
6030 `iter` into the loop header.
6031 (jit_breakpoint_re_set_internal): Move the declaration of the local
6032 variable `objf_data` to the first point of definition.
6033 (jit_event_handler): Move the declaration of local variables
6034 `code_entry`, `entry_addr`, and `objf` to their first point of use.
6035 Rename `objf` to `jited`.
6039 * jit.h (struct jiter_objfile_data) <jiter_objfile_data, objfile>:
6041 * jit.c (get_jiter_objfile_data): Update.
6046 * jit.c (struct jit_program_space_data): Remove.
6047 (jit_program_space_key): Remove.
6048 (jiter_objfile_data::~jiter_objfile_data): Remove program space
6050 (get_jit_program_space_data): Remove.
6051 (jit_breakpoint_deleted): Iterate on all of the program space's
6053 (jit_inferior_init): Likewise.
6054 (jit_breakpoint_re_set_internal): Likewise. Also change return
6056 (jit_breakpoint_re_set): Pass current_program_space to
6057 jit_breakpoint_re_set_internal.
6061 * jit.h (struct jiter_objfile_data) <cached_code_address,
6062 jit_breakpoint>: Move to here from ...
6063 * jit.c (jit_program_space_data): ... here.
6064 (jiter_objfile_data::~jiter_objfile_data): Update.
6065 (jit_breakpoint_deleted): Update.
6066 (jit_breakpoint_re_set_internal): Update.
6070 * jit.c (jiter_objfile_data::~jiter_objfile_data): Remove some
6072 (jit_read_descriptor): Remove NULL check.
6073 (jit_event_handler): Add an assertion.
6077 * jit.h (struct jit_objfile_data): Split into...
6078 (struct jiter_objfile_data): ... this ...
6079 (struct jited_objfile_data): ... and this.
6080 * objfiles.h (struct objfile) <jit_data>: Remove.
6081 <jiter_data, jited_data>: New fields.
6082 * jit.c (jit_objfile_data::~jit_objfile_data): Rename to ...
6083 (jiter_objfile_data::~jiter_objfile_data): ... this.
6084 (get_jit_objfile_data): Rename to ...
6085 (get_jiter_objfile_data): ... this.
6086 (add_objfile_entry): Update.
6087 (jit_read_descriptor): Use get_jiter_objfile_data.
6088 (jit_find_objf_with_entry_addr): Use objfile's jited_data field.
6089 (jit_breakpoint_re_set_internal): Use get_jiter_objfile_data.
6090 (jit_inferior_exit_hook): Use objfile's jited_data field.
6094 * jit.h: Forward-declare `struct minimal_symbol`.
6095 (struct jit_objfile_data): Migrate to here from jit.c; also add a
6096 constructor, destructor, and an objfile* field.
6097 * jit.c (jit_objfile_data): Remove.
6098 (struct jit_objfile_data): Migrate from here to jit.h.
6099 (jit_objfile_data::~jit_objfile_data): New destructor
6100 implementation with code moved from free_objfile_data.
6101 (free_objfile_data): Delete.
6102 (get_jit_objfile_data): Update to use the jit_data field of objfile.
6103 (jit_find_objf_with_entry_addr): Ditto.
6104 (jit_inferior_exit_hook): Ditto.
6105 (_initialize_jit): Remove the call to
6106 register_objfile_data_with_cleanup.
6107 * objfiles.h (struct objfile) <jit_data>: New field.
6111 * jit.h: Forward-declare `struct objfile`.
6112 (jit_event_handler): Add a second parameter, the JITer objfile.
6113 * jit.c (jit_read_descriptor): Change the signature to take the
6114 JITer objfile as an argument instead of the jit_program_space_data.
6115 (jit_inferior_init): Update the call to jit_read_descriptor.
6116 (jit_event_handler): Use the new JITer objfile argument when calling
6117 jit_read_descriptor.
6118 * breakpoint.c (handle_jit_event): Update the call to
6119 jit_event_handler to pass the JITer objfile.
6123 * gdbarch.c: Regenerate.
6124 * gdbarch.h: Regenerate.
6125 * gdbarch.sh (handle_segmentation_fault): Remove method.
6126 * infrun.c (handle_segmentation_fault): Remove.
6127 (print_signal_received_reason): Remove call to
6128 handle_segmentation_fault.
6132 * sparc64-linux-tdep.c (sparc64_linux_handle_segmentation_fault):
6133 Rename to sparc64_linux_report_signal_info and add siggnal
6135 (sparc64_linux_init_abi): Use sparc64_linux_report_signal_info
6136 instead of sparc64_linux_handle_segmentation_fault.
6140 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Use
6141 i386_linux_report_signal_info instead of
6142 i386_linux_handle_segmentation_fault.
6143 * i386-linux-tdep.c (i386_linux_handle_segmentation_fault): Rename
6144 to i386_linux_report_signal_info and add siggnal argument.
6145 (i386_linux_init_abi): Use i386_linux_report_signal_info instead
6146 of i386_linux_handle_segmentation_fault.
6147 * i386-linux-tdep.h (i386_linux_handle_segmentation_fault): Rename
6148 to i386_linux_report_signal_info and add siggnal argument.
6152 * corelow.c (core_target_open): Invoke gdbarch report_signal_info
6157 * gdbarch.c: Regenerate.
6158 * gdbarch.h: Regenerate.
6159 * gdbarch.sh (report_signal_info): New method.
6160 * infrun.c (print_signal_received_reason): Invoke gdbarch
6161 report_signal_info hook if present.
6165 * python/py-registers.c : Add 'unordered_map' include.
6166 (gdbpy_new_reggroup): Renamed to...
6167 (gdbpy_get_reggroup): ...this. Update to only create register
6168 group descriptors when needed.
6169 (gdbpy_reggroup_iter_next): Update.
6173 * python/py-registers.c (gdbpy_register_object_data): New static
6175 (gdbpy_register_object_data_init): New function.
6176 (gdbpy_new_register_descriptor): Renamed to...
6177 (gdbpy_get_register_descriptor): ...this, and update to reuse
6178 existing register descriptors where possible.
6179 (gdbpy_register_descriptor_iter_next): Update.
6180 (gdbpy_initialize_registers): Register new gdbarch data.
6184 * linux-nat.c (stopped_pids): Make static.
6189 * gdbtypes.c (ada_discrete_type_low_bound,
6190 ada_discrete_type_high_bound): Handle undefined bounds.
6194 * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
6196 * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
6201 * fbsd-tdep.c (fbsd_skip_solib_resolver): New function.
6202 (fbsd_init_abi): Install gdbarch "skip_solib_resolver" method.
6203 * fbsd-tdep.h (fbsd_skip_solib_resolver): New prototype.
6204 * mips-fbsd-tdep.c (mips_fbsd_skip_solib_resolver): New function.
6205 (mips_fbsd_init_abi): Install gdbarch "skip_solib_resolver"
6210 * guile/scm-math.c (vlscm_integer_fits_p): Use 'uintmax_t'
6211 and 'intmax_t' instead of 'scm_t_uintmax' and 'scm_t_intmax',
6212 which are deprecated in Guile 3.0.
6213 * configure.ac (try_guile_versions): Add "guile-3.0".
6214 * configure (try_guile_versions): Regenerate.
6215 * NEWS: Update entry.
6221 * guile/scm-ports.c (USING_GUILE_BEFORE_2_2): New macro.
6222 (ioscm_memory_port)[read_buf_size, write_buf_size]: Wrap in #if
6223 USING_GUILE_BEFORE_2_2.
6224 (stdio_port_desc, memory_port_desc) [!USING_GUILE_BEFORE_2_2]:
6225 Change type to 'scm_t_port_type *'.
6226 (natural_buffer_size) [!USING_GUILE_BEFORE_2_2]: New variable.
6227 (ioscm_open_port) [USING_GUILE_BEFORE_2_2]: Add 'stream'
6228 parameter and honor it. Update callers.
6229 (ioscm_open_port) [!USING_GUILE_BEFORE_2_2]: New function.
6230 (ioscm_read_from_port, ioscm_write) [!USING_GUILE_BEFORE_2_2]: New
6232 (ioscm_fill_input, ioscm_input_waiting, ioscm_flush): Wrap in #if
6233 USING_GUILE_BEFORE_2_2.
6234 (ioscm_init_gdb_stdio_port) [!USING_GUILE_BEFORE_2_2]: Use
6235 'ioscm_read_from_port'. Call 'scm_set_port_read_wait_fd'.
6236 (ioscm_init_stdio_buffers) [!USING_GUILE_BEFORE_2_2]: New function.
6237 (gdbscm_stdio_port_p) [!USING_GUILE_BEFORE_2_2]: Use 'SCM_PORTP'
6238 and 'SCM_PORT_TYPE'.
6239 (gdbscm_memory_port_end_input, gdbscm_memory_port_seek)
6240 (ioscm_reinit_memory_port): Wrap in #if USING_GUILE_BEFORE_2_2.
6241 (gdbscm_memory_port_read, gdbscm_memory_port_write)
6242 (gdbscm_memory_port_seek, gdbscm_memory_port_close)
6243 [!USING_GUILE_BEFORE_2_2]: New functions.
6244 (gdbscm_memory_port_print): Remove use of 'SCM_PTOB_NAME'.
6245 (ioscm_init_memory_port_type) [!USING_GUILE_BEFORE_2_2]: Use
6246 'gdbscm_memory_port_read'.
6247 Wrap 'scm_set_port_end_input', 'scm_set_port_flush', and
6248 'scm_set_port_free' calls in #if USING_GUILE_BEFORE_2_2.
6249 (gdbscm_get_natural_buffer_sizes) [!USING_GUILE_BEFORE_2_2]: New
6251 (ioscm_init_memory_port): Remove.
6252 (ioscm_init_memory_port_stream): New function
6253 (ioscm_init_memory_port_buffers) [USING_GUILE_BEFORE_2_2]: New
6255 (gdbscm_memory_port_read_buffer_size) [!USING_GUILE_BEFORE_2_2]:
6256 Return scm_from_uint (0).
6257 (gdbscm_set_memory_port_read_buffer_size_x)
6258 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
6259 (gdbscm_memory_port_write_buffer_size) [!USING_GUILE_BEFORE_2_2]:
6260 Return scm_from_uint (0).
6261 (gdbscm_set_memory_port_write_buffer_size_x)
6262 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
6263 * configure.ac (try_guile_versions): Add "guile-2.2".
6264 * configure: Regenerate.
6269 * linux-nat.c (linux_multi_process): Remove.
6270 (linux_nat_target::supports_multi_process): Return true.
6274 * arch/riscv.c (riscv_tdesc_cache): Change map type.
6275 (riscv_lookup_target_description): Return pointer out of
6277 * target-descriptions.c (allocate_target_description): Add
6279 (target_desc_deleter::operator()): Likewise.
6280 * target-descriptions.h (struct target_desc_deleter): Moved to
6282 (target_desc_up): Likewise.
6286 * linux-nat.c (linux_nat_target::supports_non_stop)
6287 (linux_nat_target::always_non_stop_p): Use "true".
6288 (linux_nat_target::supports_disable_randomization): Use "true" and
6293 * dwarf2/read.c (RNGLIST_HEADER_SIZE32) New constant definition.
6294 (RNGLIST_HEADER_SIZE64): New constant definition.
6295 (struct dwop_section_names): Add rnglists_dwo.
6296 (dwop_section_names): Add .debug_rnglists.dwo, .zdebug_rnglists.dwo.
6297 (struct loclist_header): Rename to 'loclists_rnglists_header'.
6298 (struct dwo_sections): Add rnglists field.
6299 (read_attribut_reprocess): Add tag parameter.
6300 (dwarf2_ranges_read): Add tag parameter & remove forward function decl.
6301 (cu_debug_rnglists_section): New function (decl & definition).
6302 (dwarf2_locate_dwo_sections): Add code to read rnglists_dwo section.
6303 (dwarf2_rnglists_process): Add a dwarf_tag parameter, for the kind of
6304 die whose range is being checked; get rnglist section from
6305 cu_debug_rnglists_section, to get from either objfile or dwo file as
6306 appropriate. Add cases for DW_RLE_base_addressx,
6307 DW_RLE_startx_length, DW_RLE_startx_endx. Also, update to only add
6308 the base address to DW_RLE_offset_pairs (not to all ranges), moving
6309 test inside if-condition and updating complaint message.
6310 (dwarf2_ranges_process): Add dwarf tag parameter and pass it to
6311 dwarf2_rnglists_process.
6312 (dwarf2_ranges_read): Add dwarf tag parameter and pass it to
6313 dwarf2_ranges_process.
6314 (dwarf2_get_pc_bounds): Check for DW_FORM_rnglistx when setting
6315 need_ranges_base and update comment appropriately. Also pass die tag
6316 to dwarf2_ranges_read.
6317 (dwarf2_record_block_ranges): Check for DW_FORM_rnglistx when setting
6318 need_ranges_base and update comment appropriately. Also pass die tag
6319 to dwarf2_ranges_process.
6320 (read_full_die_1): Add code to read DW_AT_rnglists_base and assign to
6321 cu->ranges_base. Also pass die tag to read_attribute_reprocess.
6322 (partial_die_info::read): Check for DW_FORM_rnglistx when setting
6323 need_ranges_base and update comment appropriately. Also pass die tag
6324 to read_attribute_reprocess and dwarf2_ranges_read.
6325 (read_loclist_header): Rename function to read_loclists_rnglists_header,
6326 and update function comment appropriately.
6327 (read_loclist_index): Call read_loclists_rnglists_header instead of
6328 read_loclist_header.
6329 (read_rnglist_index): New function.
6330 (read_attribute_reprocess): Add tag parameter. Add code for
6331 DW_FORM_rnglistx, passing tag to read_rnglist_index.
6332 (read_attribute_value): Mark DW_FORM_rnglistx with need_reprocess.
6336 * f-typeprint.c (f_type_print_base): Allow for dynamic types not
6341 * arch-utils.c (show_architecture): Update formatting of messages.
6345 * gdbtypes.h (struct type) <bounds>: Handle array and string
6347 * ada-lang.c (assign_aggregate): Use type::bounds on
6349 * c-typeprint.c (c_type_print_varspec_suffix): Likewise.
6350 * c-varobj.c (c_number_of_children): Likewise.
6351 (c_describe_child): Likewise.
6352 * eval.c (evaluate_subexp_for_sizeof): Likewise.
6353 * f-typeprint.c (f_type_print_varspec_suffix): Likewise.
6354 (f_type_print_base): Likewise.
6355 * f-valprint.c (f77_array_offset_tbl): Likewise.
6356 (f77_get_upperbound): Likewise.
6357 (f77_print_array_1): Likewise.
6358 * guile/scm-type.c (gdbscm_type_range): Likewise.
6359 * m2-typeprint.c (m2_array): Likewise.
6360 (m2_is_long_set_of_type): Likewise.
6361 * m2-valprint.c (get_long_set_bounds): Likewise.
6362 * p-typeprint.c (pascal_type_print_varspec_prefix): Likewise.
6363 * python/py-type.c (typy_range): Likewise.
6364 * rust-lang.c (rust_internal_print_type): Likewise.
6365 * type-stack.c (type_stack::follow_types): Likewise.
6366 * valarith.c (value_subscripted_rvalue): Likewise.
6367 * valops.c (value_cast): Likewise.
6371 * gdbtypes.c (TYPE_ARRAY_BIT_STRIDE): Remove. Update all
6372 callers to use the equivalent accessor methods.
6376 * gdbtypes.h (struct range_bounds) <bit_stride>: New method.
6377 (struct type) <bit_stride>: New method.
6378 (TYPE_BIT_STRIDE): Remove.
6379 * gdbtypes.c (update_static_array_size): Use type::bit_stride.
6383 * gdbtypes.h (TYPE_ARRAY_LOWER_BOUND_VALUE,
6384 TYPE_ARRAY_UPPER_BOUND_VALUE): Remove. Update all
6385 callers to use the equivalent accessor methods instead.
6389 * gdbtypes.h (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED,
6390 TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): Remove. Update all
6391 callers to use the equivalent accessor methods instead.
6395 * gdbtypes.h (TYPE_LOW_BOUND_KIND,
6396 TYPE_HIGH_BOUND_KIND): Remove. Update all callers
6397 to use dynamic_prop::kind.
6401 * gdbtypes.h (TYPE_LOW_BOUND_UNDEFINED,
6402 TYPE_HIGH_BOUND_UNDEFINED): Remove. Update all callers
6403 to get the bound property's kind and check against
6408 * gdbtypes.h (TYPE_LOW_BOUND, TYPE_HIGH_BOUND): Remove. Update
6409 all callers to use type::range_bounds followed by
6410 dynamic_prop::{low,high}.
6414 * gdbtypes.h (struct dynamic_prop) <kind, set_undefined,
6415 const_val, set_const_val, baton, set_locexpr, set_loclist,
6416 set_addr_offset, variant_parts, set_variant_parts,
6417 original_type, set_original_type>: New methods.
6418 <kind>: Rename to...
6419 <m_kind>: ... this. Update all users to use the new methods
6421 <data>: Rename to...
6422 <m_data>: ... this. Update all users to use the new methods
6427 * gdbtypes.c (get_discrete_bounds): Return failure if
6428 the range type's bounds are not both defined and constant
6430 (get_array_bounds): Update comment. Remove undefined bound check.
6434 * gdbtypes.h (TYPE_RANGE_DATA): Remove. Update callers to use
6435 the type::bounds method directly.
6439 * gdbtypes.h (struct type) <bounds, set_bounds>: New methods.
6440 (TYPE_RANGE_DATA): Use type::bounds. Change all uses that
6441 are used to set the range type's bounds to use set_bounds.
6445 * exec.c (_initialize_exec): Update exec-file-mismatch help.
6449 * gdbthread.h (inferior_ref): Define.
6450 (scoped_restore_current_thread) <m_thread>: Now a thread_info_ref.
6451 (scoped_restore_current_thread) <m_inf>: Now an inferior_ref.
6453 (scoped_restore_current_thread::restore):
6454 Adjust to gdb::ref_ptr.
6455 (scoped_restore_current_thread::~scoped_restore_current_thread):
6456 Remove manual decref handling.
6457 (scoped_restore_current_thread::scoped_restore_current_thread):
6459 inferior_ref::new_reference/thread_info_ref::new_reference.
6460 Incref the thread before calling get_frame_id instead of after.
6461 Let TARGET_CLOSE_ERROR propagate.
6465 * frame-tailcall.c (dwarf2_tailcall_sniffer_first): Only swallow
6466 NO_ENTRY_VALUE_ERROR / MEMORY_ERROR / OPTIMIZED_OUT_ERROR /
6467 NOT_AVAILABLE_ERROR.
6468 * value.c (value_optimized_out): Only swallow MEMORY_ERROR /
6469 OPTIMIZED_OUT_ERROR / NOT_AVAILABLE_ERROR.
6475 * infrun.c (threads_are_resumed_pending_p): Delete.
6476 (do_target_wait): Remove threads_are_executing and
6477 threads_are_resumed_pending_p checks from the inferior_matches
6478 lambda. Update comments.
6483 * infrun.c (handle_no_resumed): Transfer terminal to inferior with
6489 * infrun.c (handle_no_resumed): Handle multiple targets.
6494 * infrun.c (prepare_to_wait): Check target_can_async_p instead of
6500 * target.c (target_pass_ctrlc): Look at the inferior's non-exited
6501 threads, not all threads.
6506 * remote.c (remote_target::open_1): Pass remote target pointer as
6507 data to create_async_event_handler.
6508 (remote_async_inferior_event_handler): Mark async event handler
6509 before returning if the remote target still has either pending
6510 events or unacknowledged notifications.
6514 * fbsd-nat.h (fbsd_nat_target::supports_multi_process): New
6516 * fbsd-nat.c (fbsd_nat_target::supports_multi_process): New
6521 * inf-ptrace.c (inf_ptrace_target::wait): Don't compare against
6526 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
6527 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
6528 AT_FREEBSD_PS_STRINGS.
6532 * auto-load.c (auto_load_objfile_script_1): Convert drive part
6533 of debugfile path on Windows.
6537 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
6542 * ada-lang.c (ada_exception_message_1): Use read_memory.
6547 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
6548 special handling for inline frames.
6549 * findvar.c (value_of_register_lazy): Skip inline frames when
6550 creating lazy register values.
6551 * frame.c (frame_id_computed_p): Delete definition.
6552 * frame.h (frame_id_computed_p): Delete declaration.
6556 * NEWS: Mention additions to Python API.
6557 * python/py-arch.c (archpy_register_groups): New function.
6558 (arch_object_methods): Add 'register_groups' method.
6559 * python/py-registers.c (reggroup_iterator_object): New struct.
6560 (reggroup_object): New struct.
6561 (gdbpy_new_reggroup): New function.
6562 (gdbpy_reggroup_to_string): New function.
6563 (gdbpy_reggroup_name): New function.
6564 (gdbpy_reggroup_iter): New function.
6565 (gdbpy_reggroup_iter_next): New function.
6566 (gdbpy_new_reggroup_iterator): New function
6567 (gdbpy_initialize_registers): Register new types.
6568 (reggroup_iterator_object_type): Define new Python type.
6569 (gdbpy_reggroup_getset): New static global.
6570 (reggroup_object_type): Define new Python type.
6571 * python/python-internal.h
6575 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
6576 * python/py-arch.c (archpy_registers): New function.
6577 (arch_object_methods): Add 'registers' method.
6578 * python/py-registers.c: New file.
6579 * python/python-internal.h
6580 (gdbpy_new_register_descriptor_iterator): Declare.
6581 (gdbpy_initialize_registers): Declare.
6582 * python/python.c (do_start_initialization): Call
6583 gdbpy_initialize_registers.
6584 * NEWS: Mention additions to the Python API.
6588 * NEWS: Mention new Python API method.
6589 * python/py-unwind.c (pending_framepy_architecture): New function.
6590 (pending_frame_object_methods): Add architecture method.
6594 * gdbarch.c: Regenerate.
6595 * gdbarch.h: Regenerate.
6596 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
6597 (gdbarch_data): Use internal_error for the case where
6598 deprecated_set_gdbarch_data was originally needed.
6599 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
6600 and use passed in obstack.
6601 (libunwind_frame_set_descr): Should no longer get back NULL from
6603 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
6605 * user-regs.c (user_regs_init): Update parameters, and use passed
6607 (user_reg_add): Should no longer get back NULL from gdbarch_data.
6608 (_initialize_user_regs): Register as a pre-init gdbarch data type.
6612 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
6613 End-Of-Sequence in lte_is_less_than.
6614 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
6615 "gdb: Don't reorder line table entries too much when sorting".
6620 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
6625 * inferior.h (struct infcall_suspend_state_deleter): If available, use
6626 std::uncaught_exceptions instead of deprecated
6627 std::uncaught_exception.
6631 * macroexp.h (macro_stringify): Return
6632 gdb::unique_xmalloc_ptr<char>.
6633 * macroexp.c (macro_stringify): Likewise.
6634 * macrotab.c (fixup_definition): Update.
6638 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
6639 (lex_one_token): Update.
6640 * macroexp.c (struct macro_buffer) <release>: Return
6641 gdb::unique_xmalloc_ptr<char>.
6642 (macro_stringify): Update.
6643 (macro_expand): Update.
6644 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
6645 * macroexp.h (macro_expand_next): Likewise.
6649 * macroexp.h (macro_lookup_ftype): Remove.
6650 (macro_expand, macro_expand_once, macro_expand_next): Remove
6651 lookup function parameters, add scope parameter.
6652 * macroexp.c (scan, substitute_args, expand, maybe_expand,
6653 macro_expand, macro_expand_once, macro_expand_next): Likewise.
6654 * macroscope.h (standard_macro_lookup): Change parameter type
6656 * macroscope.c (standard_macro_lookup): Likewise.
6657 * c-exp.y (lex_one_token): Update.
6658 * macrocmd.c (macro_expand_command): Likewise.
6659 (macro_expand_once_command): Likewise.
6663 * inf-loop.c (inferior_event_handler): Remove client_data param.
6664 * inf-loop.h (inferior_event_handler): Likewise.
6665 * infcmd.c (step_1): Adjust.
6666 * infrun.c (proceed): Adjust.
6667 (fetch_inferior_event): Remove client_data param.
6668 (infrun_async_inferior_event_handler): Adjust.
6669 * infrun.h (fetch_inferior_event): Remove `void *` param.
6670 * linux-nat.c (handle_target_event): Adjust.
6671 * record-btrace.c (record_btrace_handle_async_inferior_event):
6673 * record-full.c (record_full_async_inferior_event_handler):
6675 * remote.c (remote_async_inferior_event_handler): Adjust.
6679 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
6680 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
6684 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
6686 (tui_win_info::make_window): Merge with
6687 tui_gen_win_info::make_window.
6688 (tui_win_info::make_visible): Move from tui_gen_win_info.
6689 * tui/tui-win.c (tui_win_info::max_width): Move from
6691 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
6693 <window_factory>: Likewise.
6694 * tui/tui-layout.c (tui_win_info::resize): Move from
6696 (make_standard_window): Change return type.
6697 (get_locator_window, tui_get_window_by_name): Likewise.
6698 (tui_layout_window::apply): Remove a cast.
6699 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
6700 (struct tui_win_info): Merge with tui_gen_win_info.
6701 (struct tui_gen_win_info): Remove.
6705 * tui/tui-stack.h (struct tui_locator_window): Derive from
6707 <do_scroll_horizontal, do_scroll_vertical>: New methods.
6708 <can_box>: New method.
6712 * tui/tui-stack.h (struct tui_locator_window): Remove body.
6716 * tui/tui-regs.c (tui_data_window::display_registers_from)
6717 (tui_data_window::display_registers_from)
6718 (tui_data_window::first_data_item_displayed)
6719 (tui_data_window::delete_data_content_windows): Update.
6720 (tui_data_window::refresh_window, tui_data_window::no_refresh):
6722 (tui_data_window::check_register_values): Update.
6723 (tui_data_item_window::rerender): Add parameters. Update.
6724 (tui_data_item_window::refresh_window): Remove.
6725 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
6727 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
6729 <refresh_window, max_height, min_height>: Remove.
6730 <rerender>: Add parameters.
6731 <x, y, visible>: New members.
6732 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
6733 <m_item_width>: New member.
6737 * tui/tui-regs.c (tui_data_window::show_register_group)
6738 (tui_data_window::check_register_values): Update.
6739 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
6744 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
6749 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
6750 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
6754 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
6755 * tui/tui-winsource.h (enum tui_line_or_address_kind)
6756 (struct tui_line_or_address): Move from tui-data.h.
6757 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
6758 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
6759 (tui_cmd_window, tui_source_window_base, tui_source_window)
6760 (tui_disasm_window): Don't declare.
6761 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
6763 (SINGLE_KEY): Move to tui-stack.c.
6767 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
6769 * tui/tui-regs.c (class tab_expansion_file): New.
6770 (tab_expansion_file::write): New method.
6771 (tui_register_format): Change return type. Use
6773 (tui_get_register, tui_data_window::display_registers_from)
6774 (tui_data_item_window::rerender): Update.
6775 * tui/tui-io.h (tui_expand_tabs): Don't declare.
6776 * tui/tui-io.c (tui_expand_tabs): Remove.
6780 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
6784 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
6788 * dwarf2/read.c (set_die_type): Removed conditions to restrict
6789 forms for DW_AT_associated and DW_AT_allocated attributes,
6790 which is already checked in function attr_to_dynamic_prop.
6794 * dwarf2/read.c (quirk_rust_enum): Correctly call
6795 alloc_rust_variant for default-less enum.
6800 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
6805 * gdbarch.sh (displaced_step_copy_insn): Update doc.
6806 * gdbarch.h: Re-generate.
6810 * command.h (cmd_types): Remove.
6811 (cmd_type): Don't declare.
6812 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
6814 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
6815 * cli/cli-decode.c (cmd_type): Remove.
6819 * fork-child.c (prefork_hook): Adjust.
6820 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
6822 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
6823 * inferior.c (inferior::set_tty, inferior::tty): New methods.
6824 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
6825 Remove declarations.
6826 (struct inferior) <set_tty, tty>: New methods.
6827 (struct inferior) <terminal>: Rename to ...
6828 (struct inferior) <m_terminal>: ... this and make private.
6829 * main.c (captured_main_1): Adjust.
6830 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
6831 (mi_cmd_inferior_tty_show): Adjust.
6832 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
6833 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
6837 * configure.ac: Add --enable-libctf: handle --disable-static
6839 * acinclude.m4: sinclude ../config/enable.m4.
6840 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
6841 (LIBCTF): Substitute in.
6842 (CTF_DEPS): New, likewise.
6843 (CLIBS): libctf needs symbols from libbfd: move earlier.
6844 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
6846 * ctfread.c: Surround in ENABLE_LIBCTF.
6847 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
6848 * configure: Regenerate.
6849 * config.in: Likewise.
6853 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
6857 * inferior.h (struct inferior) <terminal>: Change type to
6858 gdb::unique_xmalloc_ptr<char>.
6859 * inferior.c (inferior::~inferior): Don't free inf->terminal.
6860 * infcmd.c (set_inferior_io_terminal): Don't free terminal
6861 field, adjust to unique pointer.
6862 (get_inferior_io_terminal): Adjust to unique pointer.
6866 * riscv-tdep.c (riscv_print_registers_info): Loop over all
6867 registers, not just the known core set of registers.
6871 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
6872 fflags, frm, and fcsr registers.
6873 (riscv_register_reggroup_p): Remove unknown CSRs from save and
6875 (riscv_tdesc_unknown_reg): New function.
6876 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
6877 tdesc_use_registers.
6878 * riscv-tdep.h (struct gdbarch_tdep): Add
6879 unknown_csrs_first_regnum, unknown_csrs_count,
6880 duplicate_fflags_regnum, duplicate_frm_regnum, and
6881 duplicate_fcsr_regnum fields.
6885 * target-descriptions.c (tdesc_use_registers): Add new parameter a
6886 callback, use the callback (when not null) to help number unknown
6888 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
6889 (tdesc_use_registers): Add extra parameter to declaration.
6893 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
6895 (class riscv_pending_register_alias): Likewise.
6896 (riscv_register_feature::register_info): Change 'required_p' field
6897 to 'required', and change its type. Add 'check' member function.
6898 (riscv_register_feature::register_info::check): Define new member
6900 (riscv_xreg_feature): Change initialisation of 'required' field.
6901 (riscv_freg_feature): Likewise.
6902 (riscv_virtual_feature): Likewise.
6903 (riscv_csr_feature): Likewise.
6904 (riscv_check_tdesc_feature): Take extra parameter, the csr
6905 tdesc_feature, rewrite the function to use the new
6906 riscv_register_feature::register_info::check function.
6907 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
6911 * features/Makefile: Remove all references to the deleted files
6913 * features/riscv/32bit-csr.c: Deleted.
6914 * features/riscv/32bit-csr.xml: Deleted.
6915 * features/riscv/64bit-csr.c: Deleted.
6916 * features/riscv/64bit-csr.xml: Deleted.
6917 * features/riscv/rebuild-csr-xml.sh: Deleted.
6921 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
6922 whitespace error for declaration of names member variable.
6923 (struct riscv_register_feature): Add new prefer_first_name member
6924 variable, and fix whitespace error in declaration of registers.
6925 (riscv_xreg_feature): Initialize prefer_first_name field.
6926 (riscv_freg_feature): Likewise.
6927 (riscv_virtual_feature): Likewise.
6928 (riscv_csr_feature): Likewise.
6929 (riscv_register_name): Expand on comments. Remove register name
6930 modifications for CSR and virtual registers.
6934 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
6939 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
6941 (class riscv_pending_register_alias): New class.
6942 (riscv_check_tdesc_feature): Take vector of pending aliases and
6943 populate it as appropriate.
6944 (riscv_setup_register_aliases): Delete.
6945 (riscv_gdbarch_init): Create vector of pending aliases and pass it
6946 to riscv_check_tdesc_feature in all cases. Use the vector to
6947 create the register aliases.
6951 * sol2-tdep.c (sol2_static_transform_name): Remove.
6952 (sol2_init_abi): Don't register it.
6953 * gdbarch.sh (static_transform_name): Remove.
6954 * gdbarch.c, gdbarch.h: Regenerate.
6956 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
6957 gdbarch_static_transform_name.
6958 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
6959 * stabsread.c (define_symbol) <'X'>: Remove.
6960 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
6963 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
6964 <'S'>: Remove call to gdbarch_static_transform_name.
6968 * procfs.c (procfs_pre_trace): New function.
6969 (procfs_target::create_inferior): Pass it to fork_inferior.
6973 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
6974 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
6975 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
6976 sol2-tdep.o, sparc-sol2-tdep.o.
6977 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
6978 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
6979 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
6980 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
6984 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
6985 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
6987 Remove calls to set_gdbarch_skip_solib_resolver,
6988 set_gdbarch_core_pid_to_str.
6989 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
6990 (i386_sol2_static_transform_name): Remove.
6991 (i386_sol2_init_abi): Call sol2_init_abi.
6992 Remove calls to set_gdbarch_sofun_address_maybe_missing,
6993 set_gdbarch_static_transform_name,
6994 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
6995 Use sol2_sigtramp_p.
6996 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
6997 (sol2_sigtramp_p): New function.
6998 (sol2_static_transform_name): New function.
6999 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
7000 (sol2_init_abi): New function.
7001 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
7002 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
7003 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
7004 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
7005 (sparc_sol2_static_transform_name): Remove.
7006 (sparc32_sol2_init_abi): Call sol2_init_abi.
7007 Remove calls to set_gdbarch_sofun_address_maybe_missing,
7008 set_gdbarch_static_transform_name,
7009 set_gdbarch_skip_solib_resolver,
7010 set_gdbarch_core_pid_to_str.
7011 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
7012 (sparc_sol2_static_transform_name): Remove
7013 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
7014 call sol2_sigtramp_p.
7015 (sparc64_sol2_init_abi): Call sol2_init_abi.
7016 Remove calls to set_gdbarch_sofun_address_maybe_missing,
7017 set_gdbarch_static_transform_name,
7018 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
7022 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
7023 * exec.c (validate_exec_file): If from_tty, set both
7024 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
7025 * symfile.c (symbol_file_add_with_addrs): if always_confirm
7026 and from_tty, unconditionally ask a confirmation.
7030 * target-descriptions.c (tdesc_architecture_name): Protect against
7031 NULL pointer dereference.
7032 (maint_print_xml_tdesc_cmd): New function.
7033 (_initialize_target_descriptions): Register new 'maint print
7034 xml-tdesc' command and give it the filename completer.
7035 * NEWS: Mention new 'maint print xml-tdesc' command.
7039 * target-descriptions.c (class tdesc_compatible_info): New class.
7040 (struct target_desc): Change type of compatible vector.
7041 (tdesc_compatible_p): Update for change in type of
7042 target_desc::compatible.
7043 (tdesc_compatible_info_list): New function.
7044 (tdesc_compatible_info_arch_name): New function.
7045 (tdesc_add_compatible): Update for change in type of
7046 target_desc::compatible.
7047 (print_c_tdesc::visit_pre): Likewise.
7051 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
7052 whitespace to underscore.
7053 (maint_print_c_tdesc_cmd): Use fake filename for target
7054 descriptions that came from the target.
7055 (_initialize_target_descriptions): Add filename command completion
7056 for 'maint print c-tdesc'.
7060 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
7065 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
7067 (dwarf2_find_location_expression): Likewise.
7068 (call_site_parameter_matches): Likewise.
7069 (dwarf2_compile_expr_to_ax): Likewise.
7070 (disassemble_dwarf_expression): Likewise.
7071 (loclist_describe_location): Likewise.
7075 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
7076 progspace-and-thread.h. Include scoped-mock-context.h instead.
7077 (register_to_value_test): Use scoped_mock_context.
7078 * regcache.c: Include "scoped-mock-context.h".
7079 (cooked_read_test): Don't error out if a target is already pushed.
7080 Use scoped_mock_context. Adjust.
7081 * scoped-mock-context.h: New file.
7085 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
7087 (ada_language::is_string_type_p): New member function.
7088 * c-lang.c (c_language_data): Delete la_is_string_type_p
7090 (cplus_language_data): Likewise.
7091 (asm_language_data): Likewise.
7092 (minimal_language_data): Likewise.
7093 * d-lang.c (d_language_data): Likewise.
7094 * f-lang.c (f_is_string_type_p): Delete function, implementation
7095 moved to f_language::is_string_type_p.
7096 (f_language_data): Delete la_is_string_type_p initializer.
7097 (f_language::is_string_type_p): New member function,
7098 implementation from f_is_string_type_p.
7099 * go-lang.c (go_is_string_type_p): Delete function, implementation
7100 moved to go_language::is_string_type_p.
7101 (go_language_data): Delete la_is_string_type_p initializer.
7102 (go_language::is_string_type_p): New member function,
7103 implementation from go_is_string_type_p.
7104 * language.c (language_defn::is_string_type_p): Define new member
7106 (default_is_string_type_p): Make static, add comment copied from
7108 (unknown_language_data): Delete la_is_string_type_p initializer.
7109 (unknown_language::is_string_type_p): New member function.
7110 (auto_language_data): Delete la_is_string_type_p initializer.
7111 (auto_language::is_string_type_p): New member function.
7112 * language.h (language_data): Delete la_is_string_type_p field.
7113 (language_defn::is_string_type_p): Declare new function.
7114 (default_is_string_type_p): Delete desclaration, move comment to
7116 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
7117 moved to m2_language::is_string_type_p.
7118 (m2_language_data): Delete la_is_string_type_p initializer.
7119 (m2_language::is_string_type_p): New member function,
7120 implementation from m2_is_string_type_p.
7121 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
7123 * opencl-lang.c (opencl_language_data): Likewise.
7124 * p-lang.c (pascal_is_string_type_p): Delete function,
7125 implementation moved to pascal_language::is_string_type_p.
7126 (pascal_language_data): Delete la_is_string_type_p initializer.
7127 (pascal_language::is_string_type_p): New member function,
7128 implementation from pascal_is_string_type_p.
7129 * rust-lang.c (rust_is_string_type_p): Delete function,
7130 implementation moved to rust_language::is_string_type_p.
7131 (rust_language_data): Delete la_is_string_type_p initializer.
7132 (rust_language::is_string_type_p): New member function,
7133 implementation from rust_is_string_type_p.
7134 * valprint.c (val_print_scalar_or_string_type_p): Update call to
7139 * ada-lang.c (ada_language_data): Delete la_print_typedef
7141 (ada_language::print_typedef): New member function.
7142 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
7143 (cplus_language_data): Likewise.
7144 (asm_language_data): Likewise.
7145 (minimal_language_data): Likewise.
7146 * d-lang.c (d_language_data): Likewise.
7147 * f-lang.c (f_language_data): Likewise.
7148 (f_language::print_typedef): New member function.
7149 * go-lang.c (go_language_data): Delete la_print_typedef
7151 * language.c (language_defn::print_typedef): Define member
7153 (unknown_language_data): Delete la_print_typedef initializer.
7154 (unknown_language::print_typedef): New member function.
7155 (auto_language_data): Delete la_print_typedef initializer.
7156 (auto_language::print_typedef): New member function.
7157 * language.h (language_data): Delete la_print_typedef field.
7158 (language_defn::print_typedef): Declare new member function.
7159 (LA_PRINT_TYPEDEF): Update call to print_typedef.
7160 (default_print_typedef): Delete declaration.
7161 * m2-lang.c (m2_language_data): Delete la_print_typedef
7163 (m2_language::print_typedef): New member function.
7164 * objc-lang.c (objc_language_data): Delete la_print_typedef
7166 * opencl-lang.c (opencl_language_data): Likewise.
7167 * p-lang.c (pascal_language_data): Likewise.
7168 (pascal_language::print_typedef): New member function.
7169 * rust-lang.c (rust_print_typedef): Delete function,
7170 implementation moved to rust_language::print_typedef.
7171 (rust_language): Delete la_print_typedef initializer.
7172 (rust_language::print_typedef): New member function,
7173 implementation from rust_print_typedef.
7174 * typeprint.c (default_print_typedef): Delete.
7178 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
7179 (ada_language::printstr): New member function.
7180 * c-lang.c (c_language_data): Delete la_printstr initializer.
7181 (cplus_language_data): Likewise.
7182 (asm_language_data): Likewise.
7183 (minimal_language_data): Likewise.
7184 * d-lang.c (d_language_data): Likewise.
7185 * f-lang.c (f_printstr): Rename to f_language::printstr.
7186 (f_language_data): Delete la_printstr initializer.
7187 (f_language::printstr): New member function, implementation from
7189 * go-lang.c (go_language_data): Delete la_printstr initializer.
7190 * language.c (language_defn::printstr): Define new member
7192 (unk_lang_printstr): Delete.
7193 (unknown_language_data): Delete la_printstr initializer.
7194 (unknown_language::printstr): New member function.
7195 (auto_language_data): Delete la_printstr initializer.
7196 (auto_language::printstr): New member function.
7197 * language.h (language_data): Delete la_printstr field.
7198 (language_defn::printstr): Declare new member function.
7199 (LA_PRINT_STRING): Update call to printstr.
7200 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
7201 (m2_language_data): Delete la_printstr initializer.
7202 (m2_language::printstr): New member function, implementation from
7204 * objc-lang.c (objc_language_data): Delete la_printstr
7206 * opencl-lang.c (opencl_language_data): Likewise.
7207 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
7208 (pascal_language_data): Delete la_printstr initializer.
7209 (pascal_language::printstr): New member function, implementation
7210 from pascal_printstr.
7211 * p-lang.h (pascal_printstr): Delete declaration.
7212 * rust-lang.c (rust_printstr): Update header comment.
7213 (rust_language_data): Delete la_printstr initializer.
7214 (rust_language::printstr): New member function.
7218 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
7219 (ada_language::printchar): New member function.
7220 * c-lang.c (c_language_data): Delete la_printchar initializer.
7221 (cplus_language_data): Likewise.
7222 (asm_language_data): Likewise.
7223 (minimal_language_data): Likewise.
7224 * d-lang.c (d_language_data): Likewise.
7225 * f-lang.c (f_printchar): Rename to f_language::printchar.
7226 (f_language_data): Delete la_printchar initializer.
7227 (f_language::printchar): New member function, implementation from
7229 * go-lang.c (go_language_data): Delete la_printchar initializer.
7230 * language.c (unk_lang_printchar): Delete.
7231 (language_defn::printchar): Define new member function.
7232 (unknown_language_data): Delete la_printchar initializer.
7233 (unknown_language::printchar): New member function.
7234 (auto_language_data): Delete la_printchar initializer.
7235 (auto_language::printchar): New member function.
7236 * language.h (language_data): Delete la_printchar field.
7237 (language_defn::printchar): Declare new member function.
7238 (LA_PRINT_CHAR): Update call to printchar.
7239 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
7240 (m2_language::printchar): New member function.
7241 * objc-lang.c (objc_language_data): Delete la_printchar
7243 * opencl-lang.c (opencl_language_data): Likewise.
7244 * p-lang.c (pascal_language_data): Delete la_printchar
7246 (pascal_language::printchar): New member function.
7247 * rust-lang.c (rust_printchar): Rename to
7248 rust_language::printchar.
7249 (rust_language_data): Delete la_printchar initializer.
7250 (rust_language::printchar): New member function, implementation
7251 from rust_printchar.
7255 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
7256 (ada_language_data): Delete la_emitchar initializer.
7257 (ada_language::emitchar): New member function, implementation from
7259 * c-lang.c (c_language_data): Delete la_emitchar initializer.
7260 (cplus_language_data): Likewise.
7261 (asm_language_data): Likewise.
7262 (minimal_language_data): Likewise.
7263 * d-lang.c (d_language_data): Likewise.
7264 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
7265 (f_language_data): Delete la_emitchar initializer.
7266 (f_language::emitchar): New member function, implementation from
7268 * go-lang.c (go_language_data): Delete la_emitchar initializer.
7269 * language.c (unk_lang_emit_char): Delete.
7270 (language_defn::emitchar): New member function definition.
7271 (unknown_language_data): Delete la_emitchar initializer.
7272 (unknown_language::emitchar): New member function.
7273 (auto_language_data): Delete la_emitchar initializer.
7274 (auto_language::emitchar): New member function.
7275 * language.h (language_data): Delete la_emitchar field.
7276 (language_defn::emitchar): New member field declaration.
7277 (LA_EMIT_CHAR): Update call to emitchar.
7278 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
7279 (m2_language_data): Delete la_emitchar initializer.
7280 (m2_language::emitchar): New member function, implementation from
7282 * objc-lang.c (objc_language_data): Delete la_emitchar
7284 * opencl-lang.c (opencl_language_data): Likewise.
7285 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
7286 (pascal_language_data): Delete la_emitchar initializer.
7287 (pascal_language::emitchar): New member function, implementation
7288 from pascal_emit_char.
7289 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
7290 (rust_language_data): Delete la_emitchar initializer.
7291 (rust_language::emitchar): New member function, implementation
7296 * ada-lang.c (resolve): Rename to ada_language::post_parser.
7297 (ada_language_data): Delete la_post_parser initializer.
7298 (ada_language::post_parser): New member function.
7299 * c-lang.c (c_language_data): Delete la_post_parser initializer.
7300 (cplus_language_data): Likewise.
7301 (asm_language_data): Likewise.
7302 (minimal_language_data): Likewise.
7303 * d-lang.c (d_language_data): Likewise.
7304 * f-lang.c (f_language_data): Likewise.
7305 * go-lang.c (go_language_data): Likewise.
7306 * language.c (unknown_language_data): Likewise.
7307 (auto_language_data): Likewise.
7308 * language.h (language_data): Delete la_post_parser field.
7309 (language_defn::post_parser): New member function.
7310 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
7311 * objc-lang.c (objc_language_data): Likewise.
7312 * opencl-lang.c (opencl_language_data): Likewise.
7313 * p-lang.c (pascal_language_data): Likewise.
7314 * parse.c (parse_exp_in_context): Update call to post_parser.
7315 (null_post_parser): Delete definition.
7316 * parser-defs.h (null_post_parser): Delete declaration.
7317 * rust-lang.c (rust_language_data): Delete la_post_parser
7322 * ada-lang.c (parse): Rename to ada_language::parser.
7323 (ada_language_data): Delete la_parser initializer.
7324 (ada_language::parser): New member function, implementation from
7326 * c-lang.c (c_language_data): Delete la_parser initializer.
7327 (cplus_language_data): Likewise.
7328 (asm_language_data): Likewise.
7329 (minimal_language_data): Likewise.
7330 * d-lang.c (d_language_data): Likewise.
7331 (d_language::parser): New member function.
7332 * f-lang.c (f_language_data): Delete la_parser initializer.
7333 (f_language::parser): New member function.
7334 * go-lang.c (go_language_data): Delete la_parser initializer.
7335 (go_language::parser): New member function.
7336 * language.c (unk_lang_parser): Delete.
7337 (language_defn::parser): Define new member function.
7338 (unknown_language_data): Delete la_parser initializer.
7339 (unknown_language::parser): New member function.
7340 (auto_language_data): Delete la_parser initializer.
7341 (auto_language::parser): New member function.
7342 * language.h (language_data): Delete la_parser field.
7343 (language_defn::parser): Declare new member function.
7344 * m2-lang.c (m2_language_data): Delete la_parser initializer.
7345 (m2_language::parser): New member function.
7346 * objc-lang.c (objc_language_data): Delete la_parser initializer.
7347 * opencl-lang.c (opencl_language_data): Likewise.
7348 * p-lang.c (pascal_language_data): Likewise.
7349 (pascal_language::parser): New member function.
7350 * parse.c (parse_exp_in_context): Update call to parser.
7351 * rust-lang.c (rust_language_data): Delete la_parser initializer.
7352 (rust_language::parser): New member function.
7356 * top.c (print_gdb_configuration): Print --with-python-libdir
7357 configuration value.
7361 * NEWS: Mention change to the alias command.
7365 * cli/cli-cmds.c (lookup_cmd_for_default_args)
7366 (alias_command_completer)
7367 (make_alias_options_def_group): New functions.
7368 (alias_opts, alias_option_defs): New struct and array.
7369 (alias_usage_error): Update usage.
7370 (alias_command): Handles optional DEFAULT-ARGS... arguments.
7371 Use option framework.
7372 (_initialize_cli_cmds): Update alias command help.
7373 Update aliases command help.
7375 Add NULL for new default_args lookup_cmd argument.
7376 (valid_command_p): Rename to validate_aliased_command.
7377 Add NULL for new default_args lookup_cmd argument. Verify that the
7378 aliased_command has no default args.
7379 * cli/cli-decode.c (help_cmd): Show aliases definitions.
7380 (lookup_cmd_1, lookup_cmd): New argument default_args.
7382 Add NULL for new default_args lookup_cmd argument.
7383 (print_help_for_command): Show default args under the layout
7384 alias some_alias = some_aliased_cmd some_alias_default_arg.
7385 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
7386 xfree default_args in destructor.
7387 * cli/cli-script.c (process_next_line, do_define_command):
7388 Add NULL for new default_args lookup_cmd argument.
7389 * command.h: Declare new default_args argument in lookup_cmd
7391 * completer.c (complete_line_internal_1):
7392 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
7393 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
7394 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
7396 * infcmd.c (_initialize_infcmd): Likewise.
7397 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
7398 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
7399 * python/py-param.c (add_setshow_generic): Likewise.
7400 * remote.c (_initialize_remote): Likewise.
7401 * top.c (execute_command): Prepend default_args if command has some.
7403 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
7404 * tracepoint.c (validate_actionline, encode_actions_1):
7405 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
7409 * jit.c (jit_read_descriptor): Use bool as the return type.
7410 (jit_breakpoint_re_set_internal): Use bool as the return type.
7411 Invert the return value logic; return true if the jit breakpoint
7412 has been successfully initialized.
7413 (jit_inferior_init): Update the call to
7414 jit_breakpoint_re_set_internal.
7419 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
7420 Use the current inferior instead. Don't return
7421 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
7423 * sol-thread.c (sol_thread_target::wait): Don't reference
7425 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
7426 (sol_update_thread_list_callback): Use the current inferior's pid
7427 instead of inferior_ptid.
7431 * procfs.c: Cleanup many comments.
7433 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
7434 (AFTER_WATCHFLAG): Replace by value.
7436 (MAIN_PROC_NAME_FORMAT): Inline ...
7437 (create_procinfo): ... here.
7439 (procfs_debug_inferior): Remove SYS_exec handling.
7440 (syscall_is_exec): Likewise.
7441 (procfs_set_exec_trap): Likewise.
7443 (syscall_is_lwp_exit): Inline in callers.
7444 (syscall_is_exit): Likewise.
7445 (syscall_is_exec): Likewise.
7446 (syscall_is_lwp_create): Likewise.
7448 (invalidate_cache): Remove #if 0 code.
7450 (make_signal_thread_runnable): Remove.
7451 (procfs_target::resume): Remove #if 0 code.
7456 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
7458 (procfs_target::create_inferior): ... here.
7462 * exec.c (validate_exec_file): Ensure the build-id is up to
7463 date by calling reopen_exec_file (that checks file timestamp
7464 to decide to re-read the file).
7469 * gdbthread.h (delete_thread, delete_thread_silent)
7470 (find_thread_ptid): Update comments.
7471 * thread.c (current_thread_): New global.
7472 (is_current_thread): Move higher, and reimplement.
7473 (inferior_thread): Reimplement.
7474 (set_thread_exited): Use bool. Add assertions.
7475 (add_thread_silent): Simplify thread-reuse handling by always
7476 calling delete_thread.
7477 (delete_thread): Remove intro comment.
7478 (find_thread_ptid): Skip exited threads.
7479 (switch_to_thread_no_regs): Write to current_thread_.
7480 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
7481 INFERIOR_PTID. Clear current_thread_.
7485 * aix-thread.c (pd_update): Use switch_to_thread.
7489 * ravenscar-thread.c (ravenscar_thread_target): Update.
7490 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
7491 (ravenscar_thread_target::add_active_thread): ... this. Don't
7492 set m_base_ptid here. Update to avoid referencing inferior_ptid.
7493 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
7497 * nat/windows-nat.c (current_windows_thread): Remove.
7498 * nat/windows-nat.h (current_windows_thread): Remove.
7499 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
7501 (display_selectors): Adjust to fetch the current
7502 windows_thread_info based on inferior_ptid.
7503 (fake_create_process): No longer write to current_windows_thread.
7504 (windows_nat_target::get_windows_debug_event):
7505 Don't set inferior_ptid or current_windows_thread.
7506 (windows_nat_target::wait): Adjust to not rely on
7507 current_windows_thread.
7508 (do_initial_windows_stuff): Now a method of windows_nat_target.
7509 Switch to the last_ptid thread.
7510 (windows_nat_target::attach): Adjust.
7511 (windows_nat_target::detach): Use switch_to_no_thread instead of
7512 writing to inferior_ptid directly.
7513 (windows_nat_target::create_inferior): Adjust.
7517 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
7521 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
7522 after creating it, instead of writing to inferior_ptid. Don't
7523 write to inferior_ptid.
7527 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
7531 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
7532 it, instead of writing to inferior_ptid.
7536 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
7541 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
7542 instead of writing to inferior_ptid directly.
7546 * corelow.c (core_target::close): Use switch_to_no_thread instead
7547 of writing to inferior_ptid directly.
7548 (add_to_thread_list, core_target_open): Use switch_to_thread
7549 instead of writing to inferior_ptid directly.
7553 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
7555 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
7557 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
7558 inferior_ptid directly.
7559 (darwin_nat_target::init_thread_list): Switch to thread, instead
7560 of writing to inferior_ptid.
7561 (darwin_nat_target::attach): Don't write to inferior_ptid.
7562 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
7566 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
7568 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
7569 Instead use switch_to_thread.
7570 (gnu_nat_target::detach): Use switch_to_no_thread
7571 instead of writing to inferior_ptid directly. Used passed-in
7572 inferior instead of looking up the inferior by pid.
7576 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
7581 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
7583 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
7585 (nto_procfs_target::detach): Avoid referencing
7586 inferior_ptid. Use switch_to_no_thread instead of writing to
7587 inferior_ptid directly.
7588 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
7589 instead of writing to inferior_ptid directly.
7590 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
7595 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
7596 after creating it, instead of writing to inferior_ptid.
7597 (gdbsim_target_open): Use switch_to_no_thread instead of writing
7598 to inferior_ptid directly.
7599 (gdbsim_target::wait): Don't write to inferior_ptid.
7603 * remote.c (remote_target::remote_notice_new_inferior): Use
7604 switch_to_thread instead of writing to inferior_ptid directly.
7605 (remote_target::add_current_inferior_and_thread): Use
7606 switch_to_no_thread instead of writing to inferior_ptid directly.
7607 (extended_remote_target::attach): Use switch_to_inferior_no_thread
7608 and switch_to_thread instead of using set_current_inferior or
7609 writing to inferior_ptid directly.
7613 * tracectf.c (ctf_target_open): Switch to added thread instead of
7614 writing to inferior_ptid directly.
7615 (ctf_target::close): Use switch_to_no_thread instead of writing to
7616 inferior_ptid directly.
7620 * tracefile-tfile.c (tfile_target_open): Don't write to
7621 inferior_ptid directly, instead switch to added thread.
7622 (tfile_target::close): Use switch_to_no_thread instead of writing
7623 to inferior_ptid directly.
7627 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
7628 (procfs_target::detach): Use switch_to_no_thread
7629 instead of writing to inferior_ptid directly.
7630 (do_attach): Change return type to void. Switch to the added
7632 (procfs_target::create_inferior): Switch to the added thread.
7633 (procfs_do_thread_registers): Don't write to inferior_ptid.
7637 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
7638 of writing to inferior_ptid.
7639 (scoped_restore_exited_inferior): Delete.
7640 (handle_vfork_child_exec_or_exit): Simplify using
7641 scoped_restore_current_pspace_and_thread. Use switch_to_thread
7642 instead of writing to inferior_ptid.
7643 (THREAD_STOPPED_BY): Delete.
7644 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
7645 (thread_stopped_by_hw_breakpoint): Delete.
7646 (save_waitstatus): Use
7647 scoped_restore_current_thread+switch_to_thread, and call
7648 target_stopped_by_watchpoint instead of
7649 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
7650 instead of thread_stopped_by_sw_breakpoint, and
7651 target_stopped_by_hw_breakpoint instead of
7652 thread_stopped_by_hw_breakpoint.
7653 (handle_inferior_event)
7654 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
7655 inferior_ptid directly, nor
7656 set_current_inferior/set_current_program_space. Use
7657 switch_to_thread / switch_to_inferior_no_thread instead.
7661 * target.c (generic_mourn_inferior): Use switch_to_no_thread
7662 instead of writing to inferior_ptid.
7666 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
7668 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
7669 to the added thread.
7670 (inf_ptrace_target::detach_success): Use switch_to_no_thread
7671 instead of writing to inferior_ptid.
7675 * gdbarch-selftests.c: Include "progspace-and-thread.h".
7676 (register_to_value_test): Mock a program_space too. Heap-allocate
7677 the address space. Don't write to inferior_ptid. Use
7678 switch_to_thread instead.
7682 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
7684 (find_signalled_thread()): New, factored out from
7685 linux_make_corefile_notes and adjusted to handle exited threads.
7686 (linux_make_corefile_notes): Adjust to use the new
7687 find_signalled_thread.
7691 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
7692 of saving/restoring inferior_ptid.
7696 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
7697 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
7699 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
7703 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
7708 * regformats/reg-arm.dat: Remove.
7709 * regformats/reg-bfin.dat: Remove.
7710 * regformats/reg-cris.dat: Remove.
7711 * regformats/reg-crisv32.dat: Remove.
7712 * regformats/reg-m32r.dat: Remove.
7713 * regformats/reg-tilegx.dat: Remove.
7714 * regformats/reg-tilegx32.dat: Remove.
7718 * features/Makefile (WHICH): Remove arm files.
7719 * regformats/arm/arm-with-iwmmxt.dat: Remove.
7720 * regformats/arm/arm-with-neon.dat: Remove.
7721 * regformats/arm/arm-with-vfpv2.dat: Remove.
7722 * regformats/arm/arm-with-vfpv3.dat: Remove.
7726 * features/Makefile (XMLTOC): Remove rx.xml.
7730 * gdbthread.h (thread_control_state) <trap_expected> Update
7735 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
7736 ada_language::lookup_symbol_nonlocal.
7737 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
7738 (ada_language::lookup_symbol_nonlocal): New member function,
7739 implementation from ada_lookup_symbol_nonlocal.
7740 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
7742 (cplus_language_data): Delete la_lookup_symbol_nonlocal
7744 (cplus_language::lookup_symbol_nonlocal): New member function.
7745 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
7746 (minimal_language_data) Likewise.
7747 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
7748 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
7750 (d_language::lookup_symbol_nonlocal): New member function.
7751 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
7753 (f_language::lookup_symbol_nonlocal): New member function.
7754 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
7756 * language.c (unknown_language_data): Likewise.
7757 (auto_language_data): Likewise.
7758 * language.h (language_data): Delete la_lookup_symbol_nonlocal
7760 (language_defn::lookup_symbol_nonlocal): New member function.
7761 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
7763 * objc-lang.c (objc_language_data): Likewise.
7764 * opencl-lang.c (opencl_language_data): Likewise.
7765 * p-lang.c (pascal_language_data): Likewise.
7766 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
7767 rust_language::lookup_symbol_nonlocal.
7768 (rust_language_data): Delete la_lookup_symbol_nonlocal
7770 (rust_language::lookup_symbol_nonlocal): New member function,
7771 implementation from rust_lookup_symbol_nonlocal.
7772 * symtab.c (lookup_symbol_aux): Update call to
7773 lookup_symbol_nonlocal.
7774 (basic_lookup_symbol_nonlocal): Rename to...
7775 (language_defn::lookup_symbol_nonlocal): ...this, and update
7776 header comment. Remove language_defn parameter, and replace with
7778 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
7782 * ada-lang.c (ada_language_data): Delete la_value_print_inner
7784 (ada_language::value_print_inner): New member function.
7785 * c-lang.c (c_language_data): Delete la_value_print_inner
7787 (cplus_language_data): Likewise.
7788 (asm_language_data): Likewise.
7789 (minimal_language_data): Likewise.
7790 * d-lang.c (d_language_data): Likewise.
7791 (d_language::value_print_inner): New member function.
7792 * f-lang.c (f_language_data): Delete la_value_print_inner
7794 (f_language::value_print_inner): New member function.
7795 * f-lang.h (f_value_print_innner): Rename to...
7796 (f_value_print_inner): ...this (note spelling of 'inner').
7797 * f-valprint.c (f_value_print_innner): Rename to...
7798 (f_value_print_inner): ...this (note spelling of 'inner').
7799 * go-lang.c (go_language_data): Delete la_value_print_inner
7801 (go_language::value_print_inner): New member function.
7802 * language.c (language_defn::value_print_inner): Define new member
7804 (unk_lang_value_print_inner): Delete.
7805 (unknown_language_data): Delete la_value_print_inner initializer.
7806 (unknown_language::value_print_inner): New member function.
7807 (auto_language_data): Delete la_value_print_inner initializer.
7808 (auto_language::value_print_inner): New member function.
7809 * language.h (language_data): Delete la_value_print_inner field.
7810 (language_defn::value_print_inner): Delcare new member function.
7811 * m2-lang.c (m2_language_data): Delete la_value_print_inner
7813 (m2_language::value_print_inner): New member function.
7814 * objc-lang.c (objc_language_data): Delete la_value_print_inner
7816 * opencl-lang.c (opencl_language_data): Likewise.
7817 * p-lang.c (pascal_language_data): Likewise.
7818 (pascal_language::value_print_inner): New member function.
7819 * rust-lang.c (rust_language_data): Delete la_value_print_inner
7821 (rust_language::value_print_inner): New member function.
7822 * valprint.c (do_val_print): Update call to value_print_inner.
7826 * ada-lang.c (ada_language_data): Delete la_value_print
7828 (ada_language::value_print): New member function.
7829 * c-lang.c (c_language_data): Delete la_value_print initializer.
7830 (cplus_language_data): Likewise.
7831 (asm_language_data): Likewise.
7832 (minimal_language_data): Likewise.
7833 * d-lang.c (d_language_data): Likewise.
7834 * f-lang.c (f_language_data): Likewise.
7835 * go-lang.c (go_language_data): Likewise.
7836 * language.c (unk_lang_value_print): Delete.
7837 (language_defn::value_print): Define new member function.
7838 (unknown_language_data): Delete la_value_print initializer.
7839 (unknown_language::value_print): New member function.
7840 (auto_language_data): Delete la_value_print initializer.
7841 (auto_language::value_print): New member function.
7842 * language.h (language_data): Delete la_value_print field.
7843 (language_defn::value_print): Declare new member function.
7844 (LA_VALUE_PRINT): Update call to value_print.
7845 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
7846 * objc-lang.c (objc_language_data): Likewise.
7847 * opencl-lang.c (opencl_language_data): Likewise.
7848 * p-lang.c (pascal_language_data): Likewise.
7849 (pascal_language::value_print): New member function.
7850 * rust-lang.c (rust_language_data): Delete la_value_print
7855 * ada-lang.c (ada_watch_location_expression): Rename to
7856 ada_language::watch_location_expression.
7857 (ada_language_data): Delete la_watch_location_expression
7859 (ada_language::watch_location_expression): New member function,
7860 implementation from ada_watch_location_expression.
7861 * breakpoint.c (watch_command_1): Update call to
7862 watch_location_expression.
7863 * c-lang.c (c_watch_location_expression): Rename to
7864 language_defn::watch_location_expression.
7865 (c_language_data): Delete la_watch_location_expression
7867 (cplus_language_data): Likewise.
7868 (asm_language_data): Likewise.
7869 (minimal_language_data): Likewise.
7870 * c-lang.h (c_watch_location_expression): Delete declaration.
7871 * d-lang.c (d_language_data): Delete la_watch_location_expression
7873 * f-lang.c (f_language_data): Likewise.
7874 * go-lang.c (go_language_data): Likewise.
7875 * language.c (language_defn::watch_location_expression): Member
7876 function implementation from c_watch_location_expression.
7877 (unknown_language_data): Delete la_watch_location_expression
7879 (auto_language_data): Likewise.
7880 * language.h (language_data): Delete la_watch_location_expression
7882 (language_defn::watch_location_expression): Declare new member
7884 * m2-lang.c (m2_language_data): Delete
7885 la_watch_location_expression initializer.
7886 * objc-lang.c (objc_language_data): Likewise.
7887 * opencl-lang.c (opencl_language_data): Likewise.
7888 * p-lang.c (pascal_language_data): Likewise.
7889 * rust-lang.c (rust_watch_location_expression): Rename to
7890 rust_language::watch_location_expression.
7891 (rust_language_data): Delete la_watch_location_expression
7893 (rust_language::watch_location_expression): New member function,
7894 implementation from rust_watch_location_expression.
7898 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
7899 ada_language::collect_symbol_completion_matches.
7900 (ada_language_data): Delete la_collect_symbol_completion_matches
7902 (ada_language::collect_symbol_completion_matches): New member
7903 function, implementation from
7904 ada_collect_symbol_completion_matches.
7905 * c-lang.c (c_language_data): Delete
7906 la_collect_symbol_completion_matches initializer.
7907 (cplus_language_data): Likewise.
7908 (asm_language_data): Likewise.
7909 (minimal_language_data): Likewise.
7910 * d-lang.c (d_language_data): Likewise.
7911 * f-lang.c (f_collect_symbol_completion_matches): Rename to
7912 f_language::collect_symbol_completion_matches.
7913 (f_language_data): Delete la_collect_symbol_completion_matches
7915 (f_language::collect_symbol_completion_matches) New member
7916 function, implementation from f_collect_symbol_completion_matches.
7917 * go-lang.c (go_language_data): Delete
7918 la_collect_symbol_completion_matches initializer.
7919 * language.c (unknown_language_data): Likewise.
7920 (auto_language_data): Likewise.
7921 * language.h (language_data): Delete
7922 la_collect_symbol_completion_matches field.
7923 (language_defn::collect_symbol_completion_matches): New member
7925 * m2-lang.c (m2_language_data): Delete
7926 la_collect_symbol_completion_matches initializer.
7927 * objc-lang.c (objc_language_data): Likewise.
7928 * opencl-lang.c (opencl_language_data): Likewise.
7929 * p-lang.c (pascal_language_data): Likewise.
7930 * rust-lang.c (rust_language_data): Likewise.
7931 * symtab.c (default_collect_symbol_completion_matches): Delete.
7932 (collect_symbol_completion_matches): Update call to
7933 collect_symbol_completion_matches.
7934 (collect_symbol_completion_matches_type): Likewise.
7935 * symtab.h (default_collect_symbol_completion_matches): Delete
7940 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
7941 (ada_language_data): Delete la_word_break_characters initializer.
7942 (ada_language::word_break_characters): New member function.
7943 * c-lang.c (c_language_data): Delete la_word_break_characters
7945 (cplus_language_data): Likewise.
7946 (asm_language_data): Likewise.
7947 (minimal_language_data): Likewise.
7948 * completer.c: Update global comment.
7949 (advance_to_expression_complete_word_point): Update call to
7950 word_break_characters.
7951 (complete_files_symbols): Likewise.
7952 (complete_line_internal_1): Likewise.
7953 (default_completer_handle_brkchars): Likewise.
7954 (skip_quoted_chars): Likewise.
7955 * d-lang.c (d_language_data): Delete la_word_break_characters
7957 * f-lang.c (f_word_break_characters): Delete.
7958 (f_language_data): Delete la_word_break_characters initializer.
7959 (f_language::word_break_characters): New member function.
7960 * go-lang.c (go_language_data): Delete la_word_break_characters
7962 * language.c (unknown_language_data): Likewise.
7963 (auto_language_data): Likewise.
7964 * language.h (default_word_break_characters): Move declaration to
7965 earlier in the file.
7966 (language_data): Delete la_word_break_characters field.
7967 (language_defn::word_break_characters): New member function.
7968 * m2-lang.c (m2_language_data): Delete la_word_break_characters
7970 * objc-lang.c (objc_language_data): Likewise.
7971 * opencl-lang.c (opencl_language_data): Likewise.
7972 * p-lang.c (pascal_language_data): Likewise.
7973 * rust-lang.c (rust_language_data): Likewise.
7977 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
7978 (ada_language_data): Delete la_get_symbol_name_matcher
7980 (language_defn::get_symbol_name_matcher_inner): New member
7982 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
7984 (cplus_language_data): Likewise.
7985 (cplus_language::get_symbol_name_matcher_inner): New member
7987 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
7988 (minimal_language_data): Likewise.
7989 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
7990 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
7992 * dictionary.c (iter_match_first_hashed): Update call to
7993 get_symbol_name_matcher.
7994 (iter_match_next_hashed): Likewise.
7995 (iter_match_next_linear): Likewise.
7996 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
7997 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
7999 (f_language::get_symbol_name_matcher_inner): New member function.
8000 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
8002 * language.c (default_symbol_name_matcher): Update header comment,
8004 (language_defn::get_symbol_name_matcher): New definition.
8005 (language_defn::get_symbol_name_matcher_inner): Likewise.
8006 (get_symbol_name_matcher): Delete.
8007 (unknown_language_data): Delete la_get_symbol_name_matcher
8009 (auto_language_data): Likewise.
8010 * language.h (language_data): Delete la_get_symbol_name_matcher
8012 (language_defn::get_symbol_name_matcher): New member function.
8013 (language_defn::get_symbol_name_matcher_inner): Likewise.
8014 (default_symbol_name_matcher): Delete declaration.
8015 * linespec.c (find_methods): Update call to
8016 get_symbol_name_matcher.
8017 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
8019 * minsyms.c (lookup_minimal_symbol): Update call to
8020 get_symbol_name_matcher.
8021 (iterate_over_minimal_symbols): Likewise.
8022 * objc-lang.c (objc_language_data): Delete
8023 la_get_symbol_name_matcher initializer.
8024 * opencl-lang.c (opencl_language_data): Likewise.
8025 * p-lang.c (pascal_language_data): Likewise.
8026 * psymtab.c (psymbol_name_matches): Update call to
8027 get_symbol_name_matcher.
8028 * rust-lang.c (rust_language_data): Delete
8029 la_get_symbol_name_matcher initializer.
8030 * symtab.c (symbol_matches_search_name): Update call to
8031 get_symbol_name_matcher.
8032 (compare_symbol_name): Likewise.
8036 * ada-lang.c (ada_language_data): Delete la_compute_program
8038 * c-lang.c (c_language_data): Likewise.
8039 (c_language::compute_program): New member function.
8040 (cplus_language_data): Delete la_compute_program initializer.
8041 (cplus_language::compute_program): New member function.
8042 (asm_language_data): Delete la_compute_program initializer.
8043 (minimal_language_data): Likewise.
8044 * c-lang.h (c_compute_program): Update comment.
8045 (cplus_compute_program): Likewise.
8046 * compile/compile-c-support.c (c_compute_program): Likewise.
8047 (cplus_compute_program): Likewise.
8048 * compile/compile.c (compile_to_object): Update call to
8050 * d-lang.c (d_language_data): Delete la_compute_program
8052 * f-lang.c (f_language_data): Likewise.
8053 * go-lang.c (go_language_data): Likewise.
8054 * language.c (unknown_language_data): Likewise.
8055 (auto_language_data): Likewise.
8056 * language.h (language_data): Delete la_compute_program field.
8057 (language_defn::compute_program): New member function.
8058 * m2-lang.c (m2_language_data): Delete la_compute_program
8060 * objc-lang.c (objc_language_data): Likewise.
8061 * opencl-lang.c (opencl_language_data): Likewise.
8062 * p-lang.c (pascal_language_data): Likewise.
8063 * rust-lang.c (rust_language_data): Likewise.
8067 * ada-lang.c (ada_language_data) Delete
8068 la_class_name_from_physname initializer.
8069 * c-lang.c (c_language_data): Likewise.
8070 (cplus_language_data): Likewise.
8071 (cplus_language::class_name_from_physname): New member function.
8072 (asm_language_data): Delete la_class_name_from_physname
8074 (minimal_language_data): Likewise.
8075 * d-lang.c (d_language_data): Likewise.
8076 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
8077 method on language_defn class.
8078 (guess_full_die_structure_name): Likewise.
8079 * f-lang.c (f_language_data): Delete la_class_name_from_physname
8081 * go-lang.c (go_language_data): Likewise.
8082 * language.c (language_class_name_from_physname): Delete.
8083 (unk_lang_class_name): Delete.
8084 (unknown_language_data): Delete la_class_name_from_physname
8086 (auto_language_data): Likewise.
8087 * language.h (language_data): Delete la_class_name_from_physname
8089 (language_defn::class_name_from_physname): New function.
8090 (language_class_name_from_physname): Delete declaration.
8091 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
8093 * objc-lang.c (objc_language_data): Likewise.
8094 * opencl-lang.c (opencl_language_data): Likewise.
8095 * p-lang.c (pascal_language_data): Likewise.
8096 * rust-lang.c (rust_language_data): Likewise.
8100 * tui/tui-data.h (STATUS_NAME): New macro.
8101 * tui/tui-layout.c (tui_remove_some_windows)
8102 (initialize_known_windows, tui_register_window)
8103 (tui_layout_split::remove_windows, initialize_layouts)
8104 (tui_new_layout_command): Don't use hard-coded window names.
8109 * tui/tui.c (tui_ensure_readline_initialized): Rename from
8110 tui_initialize_readline. Only run once. Call rl_initialize.
8111 * tui/tui.h (tui_ensure_readline_initialized): Rename from
8112 tui_initialize_readline.
8113 * tui/tui-io.c (tui_setup_io): Call
8114 tui_ensure_readline_initialized.
8115 * tui/tui-interp.c (tui_interp::init): Update.
8119 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
8120 Also preserve the status window.
8124 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
8125 where m_window==nullptr.
8129 * windows-nat.c (windows_nat::handle_output_debug_string):
8131 (windows_nat::handle_ms_vc_exception): Update.
8132 * target.h (target_read_string): Change API.
8133 * target.c (target_read_string): Change API.
8134 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
8136 * solib-frv.c (frv_current_sos): Update.
8137 * solib-dsbt.c (dsbt_current_sos): Update.
8138 * solib-darwin.c (darwin_current_sos): Update.
8139 * linux-thread-db.c (inferior_has_bug): Update.
8140 * expprint.c (print_subexp_standard): Update.
8141 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
8142 (ada_exception_message_1): Update.
8146 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
8150 * valprint.c (read_string): Update comment.
8151 * target.c (MIN): Remove.
8152 (target_read_string): Rewrite.
8156 * corefile.c (read_memory_string): Remove.
8157 * ada-valprint.c (ada_value_print_ptr): Update.
8158 * ada-lang.h (ada_tag_name): Change return type.
8159 * ada-lang.c (type_from_tag): Update.
8160 (ada_tag_name_from_tsd): Change return type. Use
8162 (ada_tag_name): Likewise.
8163 * gdbcore.h (read_memory_string): Don't declare.
8167 * symtab.c (rbreak_command): Ignore Windows drive colon.
8171 * NEWS: Mention removed GDBserver host support.
8175 * features/riscv/rebuild-csr-xml.sh: Updated.
8180 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
8185 * main.c (captured_main_1): Don't print new line after help.
8186 (print_gdb_help): add mailing list and IRC channel information
8187 to --help. Add new lines between items in the footer. Remove
8188 quotes around bug url.
8193 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
8194 Resolve typedefs for type length calculations.
8199 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
8200 (write_psymbols): Enable .gdb_index for ada.
8201 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
8206 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
8207 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
8208 namei" instead of "const char *name" argument.
8209 (dw2_map_matching_symbols): Use "offset_type namei" variant of
8210 dw2_symtab_iter_init.
8214 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
8215 to use type::field and field::type instead.
8219 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
8220 to use field::type instead.
8224 * gdbtypes.h (struct field) <type, set_type>: New methods.
8225 Rename `type` field to...
8226 <m_type>: ... this. Change references throughout to use type or
8228 (FIELD_TYPE): Use field::type. Change call sites that modify
8229 the field's type to use field::set_type instead.
8233 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
8234 to use type::index_type instead.
8238 * gdbtypes.h (struct type) <index_type, set_index_type>: New
8240 (TYPE_INDEX_TYPE): Use type::index_type.
8241 * gdbtypes.c (create_array_type_with_stride): Likewise.
8245 * valprint.c (generic_val_print_float): Remove "embedded_offset"
8247 (generic_value_print): Update.
8251 Revert commit 982a38f60b0.
8252 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
8256 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
8257 avoid use after free.
8265 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
8267 (dwarf2_read_debug_names): Likewise.
8268 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
8269 object when re-using a per_bfd object with an index.
8274 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
8276 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
8281 * ada-lang.c (ada_language_data): Delete skip_trampoline
8283 * c-lang.c (c_language_data): Likewise.
8284 (cplus_language_data): Likewise.
8285 (cplus_language::skip_trampoline): New member function.
8286 (asm_language_data): Delete skip_trampoline initializer.
8287 (minimal_language_data): Likewise.
8288 * d-lang.c (d_language_data): Likewise.
8289 * f-lang.c (f_language_data): Likewise.
8290 * go-lang.c (go_language_data): Likewise.
8291 * language.c (unk_lang_trampoline): Delete function.
8292 (skip_language_trampoline): Update.
8293 (unknown_language_data): Delete skip_trampoline initializer.
8294 (auto_language_data): Likewise.
8295 * language.h (language_data): Delete skip_trampoline field.
8296 (language_defn::skip_trampoline): New function.
8297 * m2-lang.c (m2_language_data): Delete skip_trampoline
8299 * objc-lang.c (objc_skip_trampoline): Delete function, move
8300 implementation to objc_language::skip_trampoline.
8301 (objc_language_data): Delete skip_trampoline initializer.
8302 (objc_language::skip_trampoline): New member function with
8303 implementation from objc_skip_trampoline.
8304 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
8306 * p-lang.c (pascal_language_data): Likewise.
8307 * rust-lang.c (rust_language_data): Likewise.
8311 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
8312 (ada_language::demangle): New member function.
8313 * c-lang.c (c_language_data): Delete la_demangle initializer.
8314 (cplus_language_data): Delete la_demangle initializer.
8315 (cplus_language::demangle): New member function.
8316 (asm_language_data): Delete la_demangle initializer.
8317 (minimal_language_data): Delete la_demangle initializer.
8318 * d-lang.c (d_language_data): Delete la_demangle initializer.
8319 (d_language::demangle): New member function.
8320 * f-lang.c (f_language_data): Delete la_demangle initializer.
8321 (f_language::demangle): New member function.
8322 * go-lang.c (go_language_data): Delete la_demangle initializer.
8323 (go_language::demangle): New member function.
8324 * language.c (language_demangle): Update.
8325 (unk_lang_demangle): Delete.
8326 (unknown_language_data): Delete la_demangle initializer.
8327 (unknown_language::demangle): New member function.
8328 (auto_language_data): Delete la_demangle initializer.
8329 (auto_language::demangle): New member function.
8330 * language.h (language_data): Delete la_demangle field.
8331 (language_defn::demangle): New function.
8332 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
8333 * objc-lang.c (objc_language_data): Delete la_demangle
8335 (objc_language::demangle): New member function.
8336 * opencl-lang.c (opencl_language_data): Delete la_demangle
8338 * p-lang.c (pascal_language_data): Likewise.
8339 * rust-lang.c (rust_language_data): Likewise.
8340 (rust_language::demangle): New member function.
8344 * ada-lang.c (ada_language_data): Delete la_print_type
8346 (ada_language::print_type): New member function.
8347 * c-lang.c (c_language_data): Delete la_print_type initializer.
8348 (c_language::print_type): New member function.
8349 (cplus_language_data): Delete la_print_type initializer.
8350 (cplus_language::print_type): New member function.
8351 (asm_language_data): Delete la_print_type initializer.
8352 (asm_language::print_type): New member function.
8353 (minimal_language_data): Delete la_print_type initializer.
8354 (minimal_language::print_type): New member function.
8355 * d-lang.c (d_language_data): Delete la_print_type initializer.
8356 (d_language::print_type): New member function.
8357 * f-lang.c (f_language_data): Delete la_print_type initializer.
8358 (f_language::print_type): New member function.
8359 * go-lang.c (go_language_data): Delete la_print_type initializer.
8360 (go_language::print_type): New member function.
8361 * language.c (unk_lang_print_type): Delete.
8362 (unknown_language_data): Delete la_print_type initializer.
8363 (unknown_language::print_type): New member function.
8364 (auto_language_data): Delete la_print_type initializer.
8365 (auto_language::print_type): New member function.
8366 * language.h (language_data): Delete la_print_type field.
8367 (language_defn::print_type): New function.
8368 (LA_PRINT_TYPE): Update.
8369 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
8370 (m2_language::print_type): New member function.
8371 * objc-lang.c (objc_language_data): Delete la_print_type
8373 (objc_language::print_type): New member function.
8374 * opencl-lang.c (opencl_print_type): Delete, implementation moved
8375 to opencl_language::print_type.
8376 (opencl_language_data): Delete la_print_type initializer.
8377 (opencl_language::print_type): New member function, implementation
8378 from opencl_print_type.
8379 * p-lang.c (pascal_language_data): Delete la_print_type
8381 (pascal_language::print_type): New member function.
8382 * rust-lang.c (rust_print_type): Delete, implementation moved to
8383 rust_language::print_type.
8384 (rust_language_data): Delete la_print_type initializer.
8385 (rust_language::print_type): New member function, implementation
8386 from rust_print_type.
8390 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
8391 implementation moves to...
8392 (ada_language::sniff_from_mangled_name): ...here. Update return
8394 (ada_language_data): Delete la_sniff_from_mangled_name
8396 * c-lang.c (c_language_data): Likewise.
8397 (cplus_language_data): Likewise.
8398 (cplus_language::sniff_from_mangled_name): New member function,
8399 implementation taken from gdb_sniff_from_mangled_name.
8400 (asm_language_data): Delete la_sniff_from_mangled_name
8402 (minimal_language_data): Likewise.
8403 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
8404 implementation moves to cplus_language::sniff_from_mangled_name.
8405 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
8406 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
8408 (d_language::sniff_from_mangled_name): ...here.
8409 (d_language_data): Delete la_sniff_from_mangled_name initializer.
8410 * f-lang.c (f_language_data): Likewise.
8411 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
8413 (go_language::sniff_from_mangled_name): ...here.
8414 (go_language_data): Delete la_sniff_from_mangled_name initializer.
8415 * language.c (language_sniff_from_mangled_name): Delete.
8416 (unknown_language_data): Delete la_sniff_from_mangled_name
8418 (auto_language_data): Likewise.
8419 * language.h (language_data): Delete la_sniff_from_mangled_name
8421 (language_defn::sniff_from_mangled_name): New function.
8422 (language_sniff_from_mangled_name): Delete declaration.
8423 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
8425 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
8426 implementation moves to...
8427 (objc_language::sniff_from_mangled_name): ...here.
8428 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
8429 * opencl-lang.c (opencl_language_data): Likewise.
8430 * p-lang.c (pascal_language_data): Likewise.
8431 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
8432 implementation moves to...
8433 (rust_language::sniff_from_mangled_name): ...here.
8434 (rust_language_data): Delete la_sniff_from_mangled_name
8436 * symtab.c (symbol_find_demangled_name): Call
8437 sniff_from_mangled_name member function.
8441 * ada-lang.c (ada_language_data): Delete la_search_name_hash
8443 * c-lang.c (c_language_data): Likewise.
8444 (cplus_language_data): Likewise.
8445 (cplus_language::search_name_hash): New member function.
8446 (asm_language_data): Delete la_search_name_hash initializer.
8447 (minimal_language_data): Likewise.
8448 * d-lang.c (d_language_data): Likewise.
8449 * dictionary.c (default_search_name_hash): Rename to...
8450 (language_defn::search_name_hash): ...this.
8451 * f-lang.c (f_language_data): Likewise.
8452 (f_language::search_name_hash): New member function.
8453 * go-lang.c (go_language_data): Delete la_search_name_hash
8455 * language.c (unknown_language_data): Likewise.
8456 (auto_language_data): Likewise.
8457 * language.h (struct language_data): Delete la_search_name_hash
8459 (language_defn::search_name_hash): Declare new member function.
8460 (default_search_name_hash): Delete declaration.
8461 * m2-lang.c (m2_language_data): Delete la_search_name_hash
8463 * objc-lang.c (objc_language_data): Likewise.
8464 * opencl-lang.c (opencl_language_data): Likewise.
8465 * p-lang.c (pascal_language_data): Likewise.
8466 * rust-lang.c (rust_language_data): Likewise.
8467 * symtab.c (search_name_hash): Update call.
8471 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
8473 * c-lang.c (class compile_instance): Declare.
8474 (c_language_data): Delete la_get_compile_instance initializer.
8475 (c_language::get_compile_instance): New member function.
8476 (cplus_language_data): Delete la_get_compile_instance initializer.
8477 (cplus_language::get_compile_instance): New member function.
8478 (asm_language_data): Delete la_get_compile_instance initializer.
8479 (minimal_language_data): Likewise.
8480 * c-lang.h (c_get_compile_context): Update comment.
8481 (cplus_get_compile_context): Update comment.
8482 * compile/compile.c (compile_to_object): Update calls, don't rely
8483 on function pointer being NULL.
8484 * d-lang.c (d_language_data): Delete la_get_compile_instance
8486 * f-lang.c (f_language_data): Likewise.
8487 * go-lang.c (go_language_data): Likewise.
8488 * language.c (unknown_language_data): Likewise.
8489 (auto_language_data): Likewise.
8490 * language.h (language_data): Delete la_get_compile_instance field.
8491 (language_defn::get_compile_instance): New member function.
8492 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
8494 * objc-lang.c (objc_language_data): Likewise.
8495 * opencl-lang.c (opencl_language_data): Likewise.
8496 * p-lang.c (pascal_language_data): Likewise.
8497 * rust-lang.c (rust_language_data): Likewise.
8501 * ada-lang.c (ada_add_all_symbols): Update comment.
8502 (ada_iterate_over_symbols): Delete, move implementation to...
8503 (ada_language::iterate_over_symbols): ...here, a new member
8504 function, rewrite to use range based for loop.
8505 (ada_language_data): Delete la_iterate_over_symbols initializer.
8506 * c-lang.c (c_language_data): Likewise.
8507 (cplus_language_data): Likewise.
8508 (asm_language_data): Likewise.
8509 (minimal_language_data): Likewise.
8510 * d-lang.c (d_language_data): Likewise.
8511 * f-lang.c (f_language_data): Likewise.
8512 * go-lang.c (go_language_data): Likewise.
8513 * language.c (unknown_language_data): Likewise.
8514 (auto_language_data): Likewise.
8515 * language.h (language_data): Delete la_iterate_over_symbols field.
8516 (language_defn::iterate_over_symbols): New member function.
8517 (LA_ITERATE_OVER_SYMBOLS): Update.
8518 * linespec.c (iterate_over_all_matching_symtabs): Update.
8519 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
8521 * objc-lang.c (objc_language_data): Likewise.
8522 * opencl-lang.c (opencl_language_data): Likewise.
8523 * p-lang.c (pascal_language_data): Likewise.
8524 * rust-lang.c (rust_language_data): Likewise.
8528 * ada-lang.c (ada_language_data): Delete
8529 la_lookup_transparent_type initializer.
8530 * c-lang.c (c_language_data): Likewise.
8531 (cplus_language_data): Likewise.
8532 (cplus_language::lookup_transparent_type): New member function.
8533 (asm_language_data): Delete la_lookup_transparent_type
8535 (minimal_language_data): Likewise.
8536 * d-lang.c (d_language_data): Likewise.
8537 * f-lang.c (f_language_data): Likewise.
8538 * go-lang.c (go_language_data): Likewise.
8539 * language.c (unknown_language_data): Likewise.
8540 (auto_language_data): Likewise.
8541 * language.h (struct language_data): Delete
8542 la_lookup_transparent_type field.
8543 (language_defn::lookup_transparent_type): New member function.
8544 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
8546 * objc-lang.c (objc_language_data): Likewise.
8547 * opencl-lang.c (opencl_language_data): Likewise.
8548 * p-lang.c (pascal_language_data): Likewise.
8549 * rust-lang.c (rust_language_data): Likewise.
8550 * symtab.c (symbol_matches_domain): Update call.
8554 * ada-lang.c (ada_language_arch_info): Delete function, move
8555 implementation to...
8556 (ada_language::language_arch_info): ...here, a new member
8558 (ada_language_data): Delete la_language_arch_info.
8559 * c-lang.c (c_language_data): Likewise.
8560 (c_language::language_arch_info): New member function.
8561 (cplus_language_arch_info): Delete function, move
8562 implementation to...
8563 (cplus_language::language_arch_info): ...here, a new member
8565 (cplus_language_data): Delete la_language_arch_info.
8566 (asm_language_data): Likewise.
8567 (asm_language::language_arch_info): New member function.
8568 (minimal_language_data): Delete la_language_arch_info.
8569 (minimal_language::language_arch_info): New member function.
8570 * d-lang.c (d_language_arch_info): Delete function, move
8571 implementation to...
8572 (d_language::language_arch_info): ...here, a new member
8574 (d_language_data): Delete la_language_arch_info.
8575 * f-lang.c (f_language_arch_info): Delete function, move
8576 implementation to...
8577 (f_language::language_arch_info): ...here, a new member
8579 (f_language_data): Delete la_language_arch_info.
8580 * go-lang.c (go_language_arch_info): Delete function, move
8581 implementation to...
8582 (go_language::language_arch_info): ...here, a new member
8584 (go_language_data): Delete la_language_arch_info.
8585 * language.c (unknown_language_data): Likewise.
8586 (unknown_language::language_arch_info): New member function.
8587 (auto_language_data): Delete la_language_arch_info.
8588 (auto_language::language_arch_info): New member function.
8589 (language_gdbarch_post_init): Update call to
8590 la_language_arch_info.
8591 * language.h (language_data): Delete la_language_arch_info
8593 (language_defn::language_arch_info): New function.
8594 * m2-lang.c (m2_language_arch_info): Delete function, move
8595 implementation to...
8596 (m2_language::language_arch_info): ...here, a new member
8598 (m2_language_data): Delete la_language_arch_info.
8599 * objc-lang.c (objc_language_arch_info): Delete function, move
8600 implementation to...
8601 (objc_language::language_arch_info): ...here, a new member
8603 (objc_language_data): Delete la_language_arch_info.
8604 * opencl-lang.c (opencl_language_arch_info): Delete function, move
8605 implementation to...
8606 (opencl_language::language_arch_info): ...here, a new member
8608 (opencl_language_data): Delete la_language_arch_info.
8609 * p-lang.c (pascal_language_arch_info): Delete function, move
8610 implementation to...
8611 (pascal_language::language_arch_info): ...here, a new member
8613 (pascal_language_data): Delete la_language_arch_info.
8614 * rust-lang.c (rust_language_arch_info): Delete function, move
8615 implementation to...
8616 (rust_language::language_arch_info): ...here, a new member
8618 (rust_language_data): Delete la_language_arch_info.
8622 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
8624 * c-lang.c (c_language_data): Likewise.
8625 (cplus_language_data): Likewise.
8626 (cplus_language::pass_by_reference_info): New method.
8627 (asm_language_data): Delete la_pass_by_reference initializer.
8628 (minimal_language_data): Likewise.
8629 * cp-abi.c (cp_pass_by_reference): Remove use of
8630 default_pass_by_reference.
8631 * d-lang.c (d_language_data): Likewise.
8632 * f-lang.c (f_language_data): Likewise.
8633 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
8634 default_pass_by_reference.
8635 * go-lang.c (go_language_data): Likewise.
8636 * language.c (language_pass_by_reference): Update.
8637 (default_pass_by_reference): Delete.
8638 (unknown_language_data): Delete la_pass_by_reference
8640 (auto_language_data): Likewise.
8641 * language.h (struct language_data): Delete la_pass_by_reference
8643 (language_defn::pass_by_reference_info): New member function.
8644 (default_pass_by_reference): Delete declaration.
8645 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
8647 * objc-lang.c (objc_language_data): Likewise.
8648 * opencl-lang.c (opencl_language_data): Likewise.
8649 * p-lang.c (pascal_language_data): Likewise.
8650 * rust-lang.c (rust_language_data): Likewise.
8654 * ada-lang.c (ada_read_var_value): Delete function, move
8655 implementation to...
8656 (ada_language::read_var_value): ...here.
8657 (ada_language_data): Delete la_read_var_value initializer.
8658 * c-lang.c (c_language_data): Likewise.
8659 (cplus_language_data): Likewise.
8660 (minimal_language_data): Likewise.
8661 * d-lang.c (d_language_data): Likewise.
8662 * f-lang.c (f_language_data): Likewise.
8663 * findvar.c (default_read_var_value): Rename to...
8664 (language_defn::read_var_value): ...this.
8665 * findvar.c (read_var_value): Update header comment, and change to
8666 call member function instead of function pointer.
8667 * go-lang.c (go_language_data): Likewise.
8668 * language.c (unknown_language_data): Delete la_read_var_value
8670 (auto_language_data): Likewise.
8671 * language.h (struct language_data): Delete la_read_var_value
8673 (language_defn::read_var_value): New member function.
8674 (default_read_var_value): Delete declaration.
8675 * m2-lang.c (m2_language_data): Delete la_read_var_value
8677 * objc-lang.c (objc_language_data): Likewise.
8678 * opencl-lang.c (opencl_language_data): Likewise.
8679 * p-lang.c (pascal_language_data): Likewise.
8680 * rust-lang.c (rust_language_data): Likewise.
8681 * value.h (default_read_var_value): Delete declaration.
8685 * ada-lang.c (ada_print_array_index): Delete function, move
8686 implementation to...
8687 (ada_language::print_array_index): ...here.
8688 (ada_language_data): Delete la_print_array_index initializer.
8689 * c-lang.c (c_language_data): Likewise.
8690 (cplus_language_data): Likewise.
8691 (minimal_language_data): Likewise.
8692 * d-lang.c (d_language_data): Likewise.
8693 * f-lang.c (f_language_data): Likewise.
8694 * go-lang.c (go_language_data): Likewise.
8695 * language.c (default_print_array_index): Delete function, move
8696 implementation to...
8697 (language_defn::print_array_index): ...here.
8698 (unknown_language_data): Delete la_print_array_index initializer.
8699 (auto_language_data): Likewise.
8700 * language.h (struct language_data): Delete la_print_array_index
8702 (language_defn::print_array_index): New member function.
8703 (LA_PRINT_ARRAY_INDEX): Update.
8704 (default_print_array_index): Delete declaration.
8705 * m2-lang.c (m2_language_data): Delete la_print_array_index
8707 * objc-lang.c (objc_language_data): Likewise.
8708 * opencl-lang.c (opencl_language_data): Likewise.
8709 * p-lang.c (pascal_language_data): Likewise.
8710 * rust-lang.c (rust_language_data): Likewise.
8714 * gdb/ada-lang.c (ada_language_defn): Convert to...
8715 (ada_language_data): ...this.
8716 (class ada_language): New class.
8717 (ada_language_defn): New static global.
8718 * gdb/c-lang.c (c_language_defn): Convert to...
8719 (c_language_data): ...this.
8720 (class c_language): New class.
8721 (c_language_defn): New static global.
8722 (cplus_language_defn): Convert to...
8723 (cplus_language_data): ...this.
8724 (class cplus_language): New class.
8725 (cplus_language_defn): New static global.
8726 (asm_language_defn): Convert to...
8727 (asm_language_data): ...this.
8728 (class asm_language): New class.
8729 (asm_language_defn): New static global.
8730 (minimal_language_defn): Convert to...
8731 (minimal_language_data): ...this.
8732 (class minimal_language): New class.
8733 (minimal_language_defn): New static global.
8734 * gdb/d-lang.c (d_language_defn): Convert to...
8735 (d_language_data): ...this.
8736 (class d_language): New class.
8737 (d_language_defn): New static global.
8738 * gdb/f-lang.c (f_language_defn): Convert to...
8739 (f_language_data): ...this.
8740 (class f_language): New class.
8741 (f_language_defn): New static global.
8742 * gdb/go-lang.c (go_language_defn): Convert to...
8743 (go_language_data): ...this.
8744 (class go_language): New class.
8745 (go_language_defn): New static global.
8746 * gdb/language.c (unknown_language_defn): Remove declaration.
8747 (current_language): Initialize to nullptr, real initialization is
8748 moved to _initialize_language.
8749 (languages): Delete global.
8750 (language_defn::languages): Define.
8751 (set_language_command): Use language_defn::languages.
8752 (set_language): Likewise.
8753 (range_error): Likewise.
8754 (language_enum): Likewise.
8755 (language_def): Likewise.
8756 (add_set_language_command): Use language_def::languages for the
8757 language list, and language_def to lookup language pointers.
8758 (skip_language_trampoline): Use language_defn::languages.
8759 (unknown_language_defn): Convert to...
8760 (unknown_language_data): ...this.
8761 (class unknown_language): New class.
8762 (unknown_language_defn): New static global.
8763 (auto_language_defn): Convert to...
8764 (auto_language_data): ...this.
8765 (class auto_language): New class.
8766 (auto_language_defn): New static global.
8767 (language_gdbarch_post_init): Use language_defn::languages.
8768 (_initialize_language): Initialize current_language.
8769 * gdb/language.h (struct language_defn): Rename to...
8770 (struct language_data): ...this.
8771 (struct language_defn): New.
8772 (auto_language_defn): Delete.
8773 (unknown_language_defn): Delete.
8774 (minimal_language_defn): Delete.
8775 (ada_language_defn): Delete.
8776 (asm_language_defn): Delete.
8777 (c_language_defn): Delete.
8778 (cplus_language_defn): Delete.
8779 (d_language_defn): Delete.
8780 (f_language_defn): Delete.
8781 (go_language_defn): Delete.
8782 (m2_language_defn): Delete.
8783 (objc_language_defn): Delete.
8784 (opencl_language_defn): Delete.
8785 (pascal_language_defn): Delete.
8786 (rust_language_defn): Delete.
8787 * gdb/m2-lang.c (m2_language_defn): Convert to...
8788 (m2_language_data): ...this.
8789 (class m2_language): New class.
8790 (m2_language_defn): New static global.
8791 * gdb/objc-lang.c (objc_language_defn): Convert to...
8792 (objc_language_data): ...this.
8793 (class objc_language): New class.
8794 (objc_language_defn): New static global.
8795 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
8796 (opencl_language_data): ...this.
8797 (class opencl_language): New class.
8798 (opencl_language_defn): New static global.
8799 * gdb/p-lang.c (pascal_language_defn): Convert to...
8800 (pascal_language_data): ...this.
8801 (class pascal_language): New class.
8802 (pascal_language_defn): New static global.
8803 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
8804 language pointer, update comment format.
8805 * gdb/rust-lang.c (rust_language_defn): Convert to...
8806 (rust_language_data): ...this.
8807 (class rust_language): New class.
8808 (rust_language_defn): New static global.
8812 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
8814 <m_stmt_at_address>: New member variable.
8815 (lnp_state_machine::record_line): Don't record some lines, update
8816 tracking of is_stmt at the same address.
8817 (lnp_state_machine::lnp_state_machine): Initialise new member
8822 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
8823 "-include gnu-nat-mig.h".
8824 * gnu-nat-mig.h: New file.
8825 * gnu-nat.c: Include "gnu-nat-mig.h".
8826 (exc_server, msg_reply_server, notify_server,
8827 process_reply_server): Remove declarations.
8831 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
8832 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
8833 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
8834 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
8835 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
8836 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
8837 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
8838 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
8839 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
8840 to gnu_nat_target class.
8841 * gnu-nat.c: Likewise.
8842 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
8843 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
8844 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
8846 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
8847 instead of `gnu_target'.
8851 * i386-gnu-tdep.c: Include "gdbcore.h"
8852 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
8853 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
8854 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
8855 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
8856 i386_gnu_sigcontext_addr): New functions
8857 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
8858 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
8863 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
8864 before fork_inferior call. Avoid calling it if target_is_pushed returns
8869 * gnu-nat.h (gnu_target): New variable declaration.
8870 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
8872 * gnu-nat.c (gnu_target): New variable.
8873 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
8874 add_thread_silent, and add_thread calls.
8875 (gnu_nat_target::create_inferior): Pass gnu_target to
8876 add_thread_silent, thread_change_ptid call.
8877 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
8882 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
8883 (gnu_nat_target::find_memory_regions): Remove unused
8884 `old_address' variable.
8888 * gnu-nat.c: Include "gdbarch.h".
8892 * reply_mig_hack.awk (Error return): Cast function through
8893 void *, to bypass compiler function call check.
8897 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
8898 $(srcdir)/reply_mig_hack.awk.
8902 * gnu-nat.h (gnu_debug_flag): Set type to bool.
8906 * configure.ac (ACX_BUGURL): change bug URL to https.
8910 * cp-support.c (replace_typedefs_template): New.
8911 (replace_typedefs_qualified_name): Handle
8912 DEMANGLE_COMPONENT_TEMPLATE.
8916 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
8917 dwarf2/index-cache.h, dwarf2/index-write.c,
8918 dwarf2/index-write.h, dwarf2/line-header.c,
8919 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
8920 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
8921 variables and fields from `dwarf2_per_objfile` to just
8922 `per_objfile` throughout.
8926 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
8927 <push_dwarf_reg_entry_value>: Add comment.
8932 * python/python.c (do_start_initialization): Call PyEval_SaveThread
8933 instead of PyEval_ReleaseLock.
8934 (class gdbpy_gil): Move to earlier in file.
8935 (finalize_python): Set gdb_python_initialized.
8936 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
8937 when not initialized.
8941 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
8942 <push_dwarf_reg_entry_value>: Remove assert. Override
8943 per_objfile with caller_per_objfile.
8947 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
8948 PR gold/15646 workaround to symbol kind "type".
8952 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
8956 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
8957 Use htab_find_with_hash.
8958 <add_abbrev>: Remove "abbrev_number" parameter.
8959 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
8960 "abbrev_number" parameter. Use htab_find_slot_with_hash.
8961 (hash_abbrev): Add comment.
8962 (abbrev_table::lookup_abbrev): Move to header file.
8963 (abbrev_table::read): Update.
8967 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
8969 <canonical_name>: New member.
8970 <raw_name>: Rename from "name".
8971 (partial_die_info): Initialize canonical_name.
8972 (scan_partial_symbols): Check raw_name.
8973 (partial_die_parent_scope, partial_die_full_name)
8974 (add_partial_symbol, add_partial_subprogram)
8975 (add_partial_enumeration, load_partial_dies): Use "name" method.
8976 (partial_die_info::name): New method.
8977 (partial_die_info::read, guess_partial_die_structure_name)
8978 (partial_die_info::fixup): Update.
8982 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
8983 <get_ref_die_offset>: Inline.
8984 <get_ref_die_offset_complaint>: New method.
8985 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
8986 (attribute::get_ref_die_offset_complaint): Rename from
8987 get_ref_die_offset. Just issue complaint.
8991 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
8995 * exec.c (exec_file_attach): Use errno value of first openp failure.
8999 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
9000 Don't close thread handle.
9005 * objfiles.h (struct objfile) <partial_symtabs>: Now a
9007 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
9009 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
9010 dwarf2_per_bfd_objfile_data_key>: New globals.
9011 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
9012 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
9013 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
9015 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
9016 short-circuit when sharing.
9017 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
9018 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
9022 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
9024 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
9025 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
9029 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
9030 build_name_components, find_name_components_bounds>:
9031 Add per_objfile parameter.
9032 (struct mapped_index) <symbol_name_at>: Likewise.
9033 (struct mapped_debug_names): Remove constructor.
9034 <dwarf2_per_objfile>: Remove field.
9035 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
9036 (mapped_index_base::find_name_components_bounds,
9037 mapped_index_base::build_name_components,
9038 dw2_expand_symtabs_matching_symbol): Likewise.
9039 (class mock_mapped_index) <symbol_name_at>: Likewise.
9040 (check_match): Likewise.
9041 (check_find_bounds_finds): Likewise.
9042 (test_mapped_index_find_name_component_bounds): Update.
9043 (CHECK_MATCH): Update.
9044 (dw2_expand_symtabs_matching): Update.
9045 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
9046 per_objfile parameter.
9047 <find_vec_in_debug_names>: Likewise.
9048 <m_per_objfile>: New field.
9049 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
9051 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
9052 (dw2_debug_names_iterator::next): Update.
9053 (dw2_debug_names_lookup_symbol): Update.
9054 (dw2_debug_names_expand_symtabs_for_function): Update.
9055 (dw2_debug_names_map_matching_symbols): Update.
9056 (dw2_debug_names_expand_symtabs_matching): Update.
9057 (dwarf2_read_debug_names): Update.
9061 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
9062 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
9063 move to dwarf2_per_objfile.
9064 <read_in_chain>: Remove.
9065 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
9066 remove_all_cus, age_comp_units>: New methods.
9067 <m_dwarf2_cus>: New member.
9068 (struct dwarf2_per_cu_data) <cu>: Remove.
9069 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
9070 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
9071 moved to methods of dwarf2_per_objfile.
9072 (dwarf2_clear_marks): Remove.
9073 (dwarf2_queue_item::~dwarf2_queue_item): Update.
9074 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
9075 (dwarf2_per_bfd::free_cached_comp_units): Remove.
9076 (dwarf2_per_objfile::remove_all_cus): New.
9077 (class free_cached_comp_units) <~free_cached_comp_units>:
9080 (dw2_do_instantiate_symtab): Adjust.
9081 (fill_in_sig_entry_from_dwo_entry): Adjust.
9082 (cutu_reader::init_tu_and_read_dwo_dies): Update.
9083 (cutu_reader::cutu_reader): Likewise.
9084 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
9085 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
9086 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
9087 and dwarf2_per_objfile::age_comp_units.
9088 (load_partial_comp_unit): Update.
9089 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
9090 (process_queue): Likewise.
9091 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
9093 (dwarf2_read_addr_index): Likewise.
9094 (follow_die_offset): Likewise.
9095 (dwarf2_fetch_die_loc_sect_off): Likewise.
9096 (dwarf2_fetch_constant_bytes): Likewise.
9097 (dwarf2_fetch_die_type_sect_off): Likewise.
9098 (follow_die_sig_1): Likewise.
9099 (load_full_type_unit): Likewise.
9100 (read_signatured_type): Likewise.
9101 (dwarf2_cu::dwarf2_cu): Don't set cu field.
9102 (dwarf2_cu::~dwarf2_cu): Remove.
9103 (dwarf2_per_objfile::get_cu): New.
9104 (dwarf2_per_objfile::set_cu): New.
9105 (age_cached_comp_units): Rename to...
9106 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
9107 to std::unordered_map.
9108 (free_one_cached_comp_unit): Rename to...
9109 (dwarf2_per_objfile::remove_cu): ... this. Adjust
9110 to std::unordered_map.
9111 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
9112 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
9113 a dwarf2_per_objfile in data.
9114 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
9115 (dwarf2_clear_marks): Remove.
9119 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
9120 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
9121 (init_tu_and_read_dwo_dies): Likewise.
9122 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
9123 (cutu_reader::cutu_reader): Likewise.
9124 (load_partial_comp_unit): Likewise.
9125 (process_psymtab_comp_unit): Update.
9126 (build_type_psymtabs_1): Update.
9127 (process_skeletonless_type_unit): Update.
9128 (load_full_comp_unit): Update.
9129 (find_partial_die): Update.
9130 (dwarf2_read_addr_index): Update.
9131 (read_signatured_type): Update.
9135 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
9136 m_header_read_in>: New fields.
9137 <get_header>: New method.
9138 * dwarf2/read.c (per_cu_header_read_in): Remove.
9139 (dwarf2_per_cu_data::get_header): New.
9140 (dwarf2_per_cu_data::addr_size): Update.
9141 (dwarf2_per_cu_data::offset_size): Update.
9142 (dwarf2_per_cu_data::ref_addr_size): Update.
9146 * dwarf2/read.c (load_cu): Return dwarf2_cu.
9147 (dw2_do_instantiate_symtab): Update.
9148 (queue_and_load_all_dwo_tus): Change parameter from
9149 dwarf2_per_cu_data to dwarf2_cu.
9150 (dwarf2_fetch_die_loc_sect_off): Update.
9151 (dwarf2_fetch_constant_bytes): Update.
9152 (dwarf2_fetch_die_type_sect_off): Update.
9156 * dwarf2/read.c (process_full_comp_unit,
9157 process_full_type_unit): Remove per_cu, per_objfile paramters.
9158 Add dwarf2_cu parameter.
9159 (process_queue): Update.
9163 * dwarf2/read.c (create_cu_from_index_list): Replace
9164 dwarf2_per_objfile parameter with dwarf2_per_bfd.
9165 (create_cus_from_index_list): Likewise.
9166 (create_cus_from_index): Likewise.
9167 (create_signatured_type_table_from_index): Likewise.
9168 (create_cus_from_debug_names_list): Likewise.
9169 (create_cus_from_debug_names): Likewise.
9170 (dwarf2_read_gdb_index): Update.
9171 (dwarf2_read_debug_names): Update.
9176 * dwarf2/read.h (struct dwarf2_per_objfile)
9177 <get_type_for_signatured_type, set_type_for_signatured_type>:
9179 <m_type_map>: New member.
9180 (struct signatured_type) <type>: Remove.
9182 (dwarf2_per_objfile::get_type_for_signatured_type,
9183 dwarf2_per_objfile::set_type_for_signatured_type): New.
9184 (get_signatured_type): Use new methods.
9189 * dwarf2/read.h (struct type_unit_group_unshareable): New.
9190 (struct dwarf2_per_objfile) <type_units>: New member.
9191 <get_type_unit_group_unshareable>: New method.
9192 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
9193 num_symtabs, symtabs>: Remove; move to
9194 type_unit_group_unshareable.
9195 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
9196 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
9197 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
9201 * dwarf2/read.h (struct dwarf2_per_cu_data):
9202 <dwarf2_per_objfile>: Remove.
9203 * dwarf2/read.c (create_cu_from_index_list): Don't assign
9205 (create_signatured_type_table_from_index): Likewise.
9206 (create_signatured_type_table_from_debug_names): Likewise.
9207 (create_debug_type_hash_table): Likewise.
9208 (fill_in_sig_entry_from_dwo_entry): Likewise.
9209 (create_type_unit_group): Likewise.
9210 (read_comp_units_from_section): Likewise.
9211 (create_cus_hash_table): Likewise.
9215 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
9216 dwarf2_per_cu_data::dwarf2_per_objfile.
9217 (compute_compunit_symtab_includes): Likewise.
9218 (dwarf2_cu::start_symtab): Likewise.
9222 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
9224 * dwarf2/read.c (get_die_type_at_offset): Likewise.
9225 (read_namespace_alias): Update.
9226 (lookup_die_type): Update.
9227 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
9228 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
9230 (disassemble_dwarf_expression): Update.
9234 * dwarf2/read.h (struct dwarf2_queue_item): Add
9235 dwarf2_per_objfile parameter, assign new parameter.
9236 <per_objfile>: New field.
9237 * dwarf2/read.c (free_one_cached_comp_unit): Add
9238 dwarf2_per_objfile parameter.
9239 (queue_comp_unit): Likewise.
9240 (dw2_do_instantiate_symtab): Update.
9241 (process_psymtab_comp_unit): Update.
9242 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
9243 (process_imported_unit_die): Update.
9244 (queue_and_load_dwo_tu): Update.
9245 (follow_die_offset): Update.
9246 (follow_die_sig_1): Update.
9250 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
9251 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
9252 (read_call_site_scope): Assign per_objfile.
9253 (dwarf2_per_cu_data::objfile): Remove.
9254 * gdbtypes.h (struct call_site) <per_objfile>: New member.
9255 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
9256 dwarf2_per_objfile parameter.
9257 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
9258 dwarf2_per_objfile parameter.
9259 (dwarf_expr_reg_to_entry_parameter): Add output
9260 dwarf2_per_objfile parameter.
9261 (locexpr_get_frame_base): Update.
9262 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
9263 <push_dwarf_reg_entry_value>: Update.
9264 <call_site_to_target_addr>: Update.
9265 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
9267 (value_of_dwarf_reg_entry): Update.
9268 (rw_pieced_value): Update.
9269 (indirect_synthetic_pointer): Update.
9270 (dwarf2_evaluate_property): Update.
9271 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
9273 (locexpr_read_variable): Update.
9274 (locexpr_get_symbol_read_needs): Update.
9275 (loclist_read_variable): Update.
9279 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
9280 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
9281 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
9283 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
9284 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
9285 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
9287 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
9288 sect_variable_value): Add dwarf2_per_objfile parameter.
9289 (class dwarf_evaluate_loc_desc) <dwarf_call,
9290 dwarf_variable_value>: Update.
9291 (fetch_const_value_from_synthetic_pointer): Add
9292 dwarf2_per_objfile parameter.
9293 (fetch_const_value_from_synthetic_pointer): Update.
9294 (coerced_pieced_ref): Update.
9295 (class symbol_needs_eval_context) <dwarf_call,
9296 dwarf_variable_value>: Update.
9297 (dwarf2_compile_expr_to_ax): Update.
9301 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
9303 (dwarf2_evaluate_loc_desc_full): Update.
9307 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
9309 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
9310 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
9311 dwarf2_per_objfile parameter.
9312 (decode_debug_loc_dwo_addresses): Likewise.
9313 (dwarf2_find_location_expression): Update.
9314 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
9315 (locexpr_describe_location_piece): Add dwarf2_per_objfile
9317 (disassemble_dwarf_expression): Add dwarf2_per_objfile
9319 (locexpr_describe_location_1): Likewise.
9320 (locexpr_describe_location): Update.
9324 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
9326 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
9327 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
9328 (dwarf2_compile_property_to_c): Update.
9329 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
9330 use text offset from objfile.
9331 (locexpr_tracepoint_var_ref): Update.
9332 (locexpr_generate_c_location): Update.
9333 (loclist_describe_location): Update.
9334 (loclist_tracepoint_var_ref): Update.
9335 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
9336 dwarf2_per_objfile parameter.
9337 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
9338 use text offset from objfile.
9339 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
9343 * dwarf2/expr.h (struct dwarf_expr_context)
9344 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
9346 <per_objfile>: New member.
9347 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
9348 dwarf2_per_objfile parameter. Don't set offset, set
9350 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
9351 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
9352 a dwarf2_per_objfile object instead of an offset.
9353 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
9355 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
9356 to dwarf2_expr_executor constructor. Don't set offset.
9357 (dwarf2_fetch_cfa_info): Update.
9358 (struct dwarf2_frame_cache) <text_offset>: Remove.
9359 <per_objfile>: New field.
9360 (dwarf2_frame_cache): Update.
9361 (dwarf2_frame_prev_register): Update.
9362 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
9363 <dwarf_evaluate_loc_desc>: Add constructor.
9364 (dwarf2_evaluate_loc_desc_full): Update.
9365 (dwarf2_locexpr_baton_eval): Update.
9366 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
9368 (dwarf2_loc_desc_get_symbol_read_needs): Update.
9372 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
9373 addr_sized_int_type>: Move to dwarf2_cu.
9374 <int_type>: Move to dwarf2_per_objfile.
9375 (struct dwarf2_per_objfile) <int_type>: Move here.
9376 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
9377 addr_sized_int_type>: Move here.
9378 (read_func_scope): Update.
9379 (read_array_type): Update.
9380 (read_tag_string_type): Update.
9381 (attr_to_dynamic_prop): Update.
9382 (dwarf2_per_cu_data::int_type): Rename to...
9383 (dwarf2_per_objfile::int_type): ... this.
9384 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
9385 (dwarf2_cu::addr_sized_int_type): ... this.
9386 (read_subrange_type): Update.
9387 (dwarf2_per_cu_data::addr_type): Rename to...
9388 (dwarf2_cu::addr_type): ... this.
9389 (set_die_type): Update.
9393 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
9394 data through per_cu->cu.
9398 * dwarf2/read.c (lookup_dwo_comp_unit): Change
9399 dwarf2_per_cu_data parameter fo dwarf2_cu.
9400 (lookup_dwo_type_unit): Likewise.
9401 (read_cutu_die_from_dwo): Likewise.
9402 (lookup_dwo_unit): Likewise.
9403 (open_and_init_dwo_file): Likewise.
9404 (lookup_dwo_cutu): Likewise.
9405 (lookup_dwo_comp_unit): Likewise.
9406 (lookup_dwo_type_unit): Likewise.
9407 (cutu_reader::init_tu_and_read_dwo_dies): Update.
9408 (cutu_reader::cutu_reader): Update.
9412 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
9414 (process_full_type_unit): Likewise.
9415 (process_queue): Update.
9419 * dwarf2/read.c (recursively_compute_inclusions): Add
9420 dwarf2_per_objfile parameter.
9421 (compute_compunit_symtab_includes): Likewise.
9422 (process_cu_includes): Update.
9426 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
9428 (create_type_unit_group): Update.
9429 (process_psymtab_comp_unit_reader): Update.
9430 (build_type_psymtabs_reader): Update.
9434 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
9435 object through m_this_cu->cu.
9439 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
9441 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
9445 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
9446 per_objfile parameter.
9447 (load_full_type_unit): Add per_objfile parameter.
9448 (read_signatured_type): Likewise.
9449 (load_full_comp_unit): Likewise.
9450 (load_cu): Likewise.
9451 (dw2_do_instantiate_symtab): Likewise.
9452 (dw2_get_file_names): Likewise.
9453 (dw2_map_symtabs_matching_filename): Update.
9454 (dw_expand_symtabs_matching_file_matcher): Update.
9455 (dw2_map_symbol_filenames): Update.
9456 (process_psymtab_comp_unit): Add per_objfile parameter.
9457 (build_type_psymtabs_1): Update.
9458 (process_skeletonless_type_unit): Update.
9459 (dwarf2_build_psymtabs_hard): Update.
9460 (load_partial_comp_unit): Add per_objfile parameter.
9461 (scan_partial_symbols): Update.
9462 (load_full_comp_unit): Add per_objfile parameter.
9463 (process_imported_unit_die): Update.
9464 (create_cus_hash_table): Update.
9465 (find_partial_die): Update.
9466 (dwarf2_read_addr_index): Update.
9467 (follow_die_offset): Update.
9468 (dwarf2_fetch_die_loc_sect_off): Update.
9469 (dwarf2_fetch_constant_bytes): Update.
9470 (dwarf2_fetch_die_type_sect_off): Update.
9471 (follow_die_sig_1): Update.
9472 (load_full_type_unit): Add per_objfile parameter.
9473 (read_signatured_type): Likewise.
9477 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
9482 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
9483 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
9484 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
9486 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
9487 (create_cus_from_index): Update.
9488 (dwarf2_read_gdb_index): Update.
9489 (create_cus_from_debug_names): Update.
9490 (dwarf2_read_debug_names): Update.
9491 (get_abbrev_section_for_cu): Update.
9492 (create_all_comp_units): Update.
9493 (read_attribute_value): Update.
9494 (get_debug_line_section): Update.
9495 * dwarf2/index-cache.c (index_cache::store): Update.
9496 * dwarf2/index-write.c (save_gdb_index_command): Update.
9497 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
9501 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
9503 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
9504 dwarf2_per_cu_data::per_bfd.
9505 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
9506 (create_type_unit_group): Likewise.
9507 (queue_comp_unit): Remove reference to
9508 per_cu->dwarf2_per_objfile.
9509 (maybe_queue_comp_unit): Likewise.
9510 (fill_in_sig_entry_from_dwo_entry): Assign new field.
9511 (create_cus_hash_table): Assign new field.
9515 * dwarf2/read.c: Replace
9516 dwarf2_cu->per_cu->dwarf2_per_objfile references with
9517 dwarf2_cu->per_objfile throughout.
9521 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
9522 parameter, don't use per_cu->dwarf2_per_objfile.
9523 (dw2_instantiate_symtab): Likewise.
9524 (dw2_find_last_source_symtab): Update.
9525 (dw2_map_expand_apply): Update.
9526 (dw2_lookup_symbol): Update.
9527 (dw2_expand_symtabs_for_function): Update.
9528 (dw2_expand_all_symtabs): Update.
9529 (dw2_expand_symtabs_with_fullname): Update.
9530 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
9531 don't use per_cu->dwarf2_per_objfile.
9532 (dw2_expand_marked_cus): Update.
9533 (dw2_find_pc_sect_compunit_symtab): Update.
9534 (dw2_debug_names_lookup_symbol): Update.
9535 (dw2_debug_names_expand_symtabs_for_function): Update.
9536 (dw2_debug_names_map_matching_symbols): Update.
9537 (dwarf2_psymtab::expand_psymtab): Update.
9541 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
9542 <per_objfile>: New member.
9543 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
9544 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
9546 (cutu_reader::cutu_reader): Update.
9547 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
9551 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
9552 struct dwarf2_per_objfile.
9553 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
9555 * dwarf2/read.c (set_die_type): Update.
9556 (get_die_type_at_offset): Update.
9561 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
9563 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
9564 get_symtab, set_symtab>: New methods.
9565 <m_symtabs>: New field.
9566 (struct dwarf2_psymtab): Derive from partial_symtab.
9567 <readin_p, get_compunit_symtab>: Declare methods.
9568 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
9569 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
9571 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
9572 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
9573 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
9574 (dw2_symtab_iter_next, dw2_print_stats)
9575 (dw2_expand_symtabs_with_fullname)
9576 (dw2_expand_symtabs_matching_one)
9577 (dw_expand_symtabs_matching_file_matcher)
9578 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
9579 (dw2_debug_names_iterator::next)
9580 (dw2_debug_names_map_matching_symbols)
9581 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
9582 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
9583 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
9585 (get_compunit_symtab, process_full_comp_unit)
9586 (process_full_type_unit): Update.
9587 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
9591 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
9592 then introduce a new dwarf2_per_objfile type.
9593 <read_line_string>: Move to the new dwarf2_per_objfile type.
9594 <objfile>: Likewise.
9595 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
9596 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
9597 dwarf2_per_objfile->per_bfd.
9598 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
9599 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
9600 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
9601 (dwarf2_per_bfd::free_cached_comp_units): ... this.
9602 (dwarf2_has_info): Allocate dwarf2_per_bfd.
9603 (dwarf2_per_objfile::locate_sections): Rename to...
9604 (dwarf2_per_bfd::locate_sections): ... this.
9605 (dwarf2_per_objfile::get_cutu): Rename to...
9606 (dwarf2_per_bfd::get_cutu): ... this.
9607 (dwarf2_per_objfile::get_cu): Rename to...
9608 (dwarf2_per_bfd::get_cu): ... this.
9609 (dwarf2_per_objfile::get_tu): Rename to...
9610 (dwarf2_per_bfd::get_tu): ... this.
9611 (dwarf2_per_objfile::allocate_per_cu): Rename to...
9612 (dwarf2_per_bfd::allocate_per_cu): ... this.
9613 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
9614 (dwarf2_per_bfd::allocate_signatured_type): ... this.
9615 (get_gdb_index_contents_ftype): Change parameter from
9616 dwarf2_per_objfile to dwarf2_per_bfd.
9617 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
9618 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
9623 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
9624 (allocate_piece_closure): Set "per_objfile" member.
9625 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
9626 (locexpr_describe_location, loclist_describe_location): Use new
9628 * dwarf2/read.c (read_call_site_scope)
9629 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
9630 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
9631 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
9632 handle_data_member_location): Set per_objfile member.
9633 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
9635 (struct dwarf2_loclist_baton) <per_objfile>: New member.
9639 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
9640 allocate_signatured_type>: Declare new methods.
9641 <m_num_psymtabs>: New member.
9642 (struct dwarf2_per_cu_data) <index>: New member.
9643 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
9644 (dwarf2_per_objfile::allocate_signatured_type): New methods.
9645 (create_cu_from_index_list): Use allocate_per_cu.
9646 (create_signatured_type_table_from_index)
9647 (create_signatured_type_table_from_debug_names)
9648 (create_debug_type_hash_table, add_type_unit)
9649 (read_comp_units_from_section): Use allocate_signatured_type.
9653 * psymtab.c (partial_map_expand_apply)
9654 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
9655 (psym_lookup_global_symbol_language)
9656 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
9657 (psym_print_stats, psym_expand_symtabs_for_function)
9658 (psym_map_symbol_filenames, psym_map_matching_symbols)
9659 (psym_expand_symtabs_matching)
9660 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
9661 (maintenance_check_psymtabs): Update.
9662 * psympriv.h (struct partial_symtab) <readin_p,
9663 get_compunit_symtab>: Add objfile parameter.
9664 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
9666 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
9667 get_compunit_symtab>: Likewise.
9668 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
9672 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
9674 * dwarf2/read.c (delete_file_name_entry): Fix comment.
9675 (create_cu_from_index_list)
9676 (create_signatured_type_table_from_index)
9677 (create_signatured_type_table_from_debug_names)
9678 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
9679 (dwarf2_create_include_psymtab)
9680 (create_debug_type_hash_table, add_type_unit)
9681 (create_type_unit_group, read_comp_units_from_section)
9682 (dwarf2_compute_name, create_cus_hash_table)
9683 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
9684 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
9686 (dw2_get_real_path): Likewise. Change argument to
9692 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
9693 for ldrd (immediate).
9697 * command.h: Add comment giving the name of class_tui.
9698 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
9699 create the fake command for the help for class_tui.
9703 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
9704 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
9705 (val_atr): New function.
9706 (value_val_atr): Use it.
9707 * ada-valprint.c (print_optional_low_bound): Change low bound
9709 (val_print_packed_array_elements): Don't call discrete_position.
9710 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
9711 discrete_position for enum types.
9712 * language.c (default_print_array_index): Change type.
9713 * language.h (struct language_defn) <la_print_array_index>: Add
9714 index_type parameter, change type of index_value.
9715 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
9716 (default_print_array_index): Update.
9717 * valprint.c (maybe_print_array_index): Don't call
9718 value_from_longest. Update.
9719 (value_print_array_elements): Don't call discrete_position.
9723 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
9724 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
9729 * avr-tdep.c (avr_integer_to_address): Return data or code
9730 address accordingly to the second 'type' argument of the
9735 * infcmd.c, inferior.h: (construct_inferior_arguments):
9736 Moved function from here to gdbsupport/common-inferior.{h,cc}
9740 Revert commit eca1f90c:
9741 * NEWS: Remove entry for completion styling.
9742 * completer.c (_rl_completion_prefix_display_length): Move
9744 (gdb_fnprint): Revert.
9745 (gdb_display_match_list_1): Likewise.
9746 * cli/cli-style.c (completion_prefix_style)
9747 (completion_difference_style, completion_suffix_style): Remove.
9748 (_initialize_cli_style): Revert.
9749 * cli/cli-style.h (completion_prefix_style)
9750 (completion_difference_style, completion_suffix_style): Don't
9755 * symtab.c (completion_list_add_name): Return boolean indication
9756 of whether the symbol matched.
9757 (completion_list_add_symbol): Don't try to remove C++ aliases if
9758 the symbol didn't match in the first place.
9759 * symtab.h (completion_list_add_name): Return bool.
9763 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
9772 * NEWS: Add entry for completion styling.
9773 * completer.c (_rl_completion_prefix_display_length): Move
9774 declaration earlier.
9775 (gdb_fnprint): Use completion_style.
9776 (gdb_display_match_list_1): Likewise.
9777 * cli/cli-style.c (completion_prefix_style)
9778 (completion_difference_style, completion_suffix_style): New
9780 (_initialize_cli_style): Register new globals.
9781 * cli/cli-style.h (completion_prefix_style)
9782 (completion_difference_style, completion_suffix_style): Declare.
9786 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
9787 (parse_escape): Use ISDIGIT instead of isdigit.
9788 (puts_debug): Use gdb_isprint instead of isprint.
9789 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
9790 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
9791 ISSPACE instead of isspace.
9792 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
9794 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
9795 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
9796 instead of isxdigit and ISDIGIT instead of isdigit.
9800 * gdbtypes.h (struct type) <field>: New method.
9801 (TYPE_FIELDS): Remove, replace all uses with either type::fields
9806 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
9807 (TYPE_FIELDS): Use type::fields. Change all call sites that
9808 modify the propery to use type::set_fields instead.
9812 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
9813 type::num_fields instead.
9817 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
9819 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
9820 that modify the number of fields to use type::set_num_fields
9825 * compile/compile-object-load.h (munmap_list_free): Don't
9830 * annotate.c (annotate_source_line): Update return type, add call
9831 to update current symtab and line.
9832 * annotate.h (annotate_source_line): Update return type, and
9833 extend header comment.
9834 * source.c (info_line_command): Check annotation_level before
9835 calling annotate_source_line.
9836 * stack.c (print_frame_info): If calling annotate_source_line
9837 returns true, then don't print any other source line information.
9841 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
9845 * coffread.c (patch_type): Remove NULL check before xfree.
9846 * corefile.c (set_gnutarget): Likewise.
9847 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
9848 * exec.c (build_section_table): Likewise.
9849 * remote.c (remote_target::pass_signals): Likewise.
9850 * utils.c (n_spaces): Likewise.
9851 * cli/cli-script.c (document_command): Likewise.
9852 * i386-windows-tdep.c (core_process_module_section): Likewise.
9853 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
9857 * symfile.c (reread_symbols): Clear objfile's section_offsets
9858 vector and section indices, re-compute them by calling
9863 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
9864 (desc_one_bound, desc_index_type): Compute field name.
9869 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
9874 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
9876 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
9877 passed to bfd_set_filename.
9878 * symfile-mem.c (add_vsyscall_page): Likewise for string
9879 passed to symbol_file_add_from_memory.
9880 (symbol_file_add_from_memory): Make name param a const char* and
9885 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
9886 rather than accessing bfd->filename directly.
9887 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
9888 and use bfd_section_name.
9889 * dwarf2/frame.c (decode_frame_entry): Likewise.
9890 * exec.c (exec_set_section_address): Likewise.
9891 * solib-aix.c (solib_aix_bfd_open): Likewise.
9892 * stap-probe.c (get_stap_base_address): Likewise.
9893 * symfile.c (reread_symbols): Likewise.
9897 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
9901 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
9905 * NEWS (set exec-file-mismatch): Adjust entry.
9906 * exec.c: Include "build-id.h".
9907 (validate_exec_file): Try to match build IDs instead of filenames.
9908 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
9909 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
9910 and pass down 'warn_if_slow'.
9911 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
9912 gdb_bfd_open_closure to pass it down.
9913 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
9917 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
9918 * target.c (target_fileio_open_1): Rename to target_fileio_open
9919 and make extern. Use bool.
9920 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
9921 (target_fileio_read_alloc_1): Adjust.
9922 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
9923 (target_fileio_open_warn_if_slow): Delete declaration.
9927 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
9932 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
9933 whether disp is negative.
9937 * symfile.h (struct symfile_segment_data)
9938 <~symfile_segment_data>: Remove.
9939 <segment_info>: Change to std::vector.
9940 * symfile.c (default_symfile_segments): Update.
9941 * elfread.c (elf_symfile_segments): Update.
9945 * symfile.h (struct symfile_segment_data) <struct segment>: New.
9947 <segment_bases, segment_sizes>: Remove.
9948 * symfile.c (default_symfile_segments): Update.
9949 * elfread.c (elf_symfile_segments): Update.
9950 * remote.c (remote_target::get_offsets): Update.
9951 * solib-target.c (solib_target_relocate_section_addresses):
9956 * symfile.h (struct symfile_segment_data): Initialize fields.
9957 <~symfile_segment_data>: Add.
9958 (symfile_segment_data_up): New.
9959 (struct sym_fns) <sym_segments>: Return a
9960 symfile_segment_data_up.
9961 (default_symfile_segments): Return a symfile_segment_data_up.
9962 (free_symfile_segment_data): Remove.
9963 (get_symfile_segment_data): Return a symfile_segment_data_up.
9964 * symfile.c (default_symfile_segments): Likewise.
9965 (get_symfile_segment_data): Likewise.
9966 (free_symfile_segment_data): Remove.
9967 (symfile_find_segment_sections): Update.
9968 * elfread.c (elf_symfile_segments): Return a
9969 symfile_segment_data_up.
9970 * remote.c (remote_target::get_offsets): Update.
9971 * solib-target.c (solib_target_relocate_section_addresses):
9973 * symfile-debug.c (debug_sym_segments): Return a
9974 symfile_segment_data_up.
9979 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
9980 Hardcode register numbers.
9983 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
9984 procfs_find_LDT_entry): Remove.
9985 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
9986 procfs_find_LDT_entry): Remove.
9987 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
9995 * breakpoint.c (build_target_condition_list): Update comments.
9996 (build_target_command_list): Update comments and skip matching
9998 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
9999 a separate function. Simplify "set breakpoint auto-hw off"
10001 (insert_breakpoints): Update comment.
10002 (tracepoint_locations_match): New parameter. For breakpoints,
10003 compare location types too, if the caller wants to.
10004 (handle_automatic_hardware_breakpoints): New functions.
10005 (bp_location_is_less_than): Also sort by location type and
10006 hardware breakpoint length.
10007 (update_global_location_list): Handle "set breakpoint auto-hw on"
10009 (update_breakpoint_locations): Ask breakpoint_locations_match to
10010 ignore location types.
10014 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
10015 type::name instead.
10019 * gdbtypes.h (struct type) <name, set_name>: New methods.
10020 (TYPE_CODE): Use type::name. Change all call sites used to set
10021 the name to use type::set_name instead.
10025 * top.c (quit_force): Update.
10026 * infrun.c (handle_no_resumed): Update.
10027 * top.h (all_uis): New function.
10032 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
10037 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
10039 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
10043 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
10044 (sparc64_adi_info): Likewise.
10048 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
10050 (lookup_objfile_from_block): Remove.
10051 (lookup_symbol_in_block, lookup_symbol_in_static_block)
10052 (lookup_global_symbol): Use block_objfile.
10053 * symtab.h (lookup_objfile_from_block): Don't declare.
10054 * printcmd.c (clear_dangling_display_expressions): Use
10056 * parse.c (operator_check_standard): Use block_objfile.
10060 * language.c (language_alloc_type_symbol): Set
10062 * symtab.c (initialize_objfile_symbol): Remove.
10063 (allocate_symbol): Remove.
10064 (allocate_template_symbol): Remove.
10065 * dwarf2/read.c (fixup_go_packaging): Use "new".
10066 (new_symbol): Use "new".
10067 (read_variable): Don't call initialize_objfile_symbol. Use
10069 (read_func_scope): Use "new".
10070 * xcoffread.c (process_xcoff_symbol): Don't call
10071 initialize_objfile_symbol.
10072 (SYMBOL_DUP): Remove.
10073 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
10075 * symtab.h (allocate_symbol, initialize_objfile_symbol)
10076 (allocate_template_symbol): Don't declare.
10077 (struct symbol): Add copy constructor. Change defaults.
10078 * jit.c (finalize_symtab): Use "new".
10079 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
10081 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
10082 (common_block_end): Use "new".
10083 * mdebugread.c (parse_symbol): Use "new".
10084 (new_symbol): Likewise.
10088 * NEWS: Mention changes to help and apropos.
10092 * command.h (enum command_class): Improve comments, document
10093 that class_alias is for user-defined aliases, give the class
10094 name for each class, remove unused class_xdb.
10095 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
10096 * breakpoint.c (_initialize_breakpoint): Replace class_alias
10097 by a precise class.
10098 * infcmd.c (_initialize_infcmd): Likewise.
10099 * reverse.c (_initialize_reverse): Likewise.
10100 * stack.c (_initialize_stack): Likewise.
10101 * symfile.c (_initialize_symfile): Likewise.
10102 * tracepoint.c (_initialize_tracepoint): Likewise.
10106 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
10107 when their aliased command is traversed.
10108 (help_cmd): Add fput_command_names_styled call to
10109 output command name and aliases when command has an alias.
10113 * cli/cli-decode.h (help_cmd_list): Remove declaration.
10114 * cli/cli-decode.c (help_cmd_list): Declare as static,
10115 remove prefix argument, use bool for recurse arg, rework to show the aliases of
10116 a command together with the command.
10117 (fput_command_name_styled, fput_command_names_styled): New functions.
10118 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
10119 fput_command_name_styled.
10120 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
10121 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
10125 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
10126 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
10127 * command.h (cmd_show_list): Likewise.
10128 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
10129 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
10133 * unittests/command-def-selftests.c (traverse_command_structure):
10134 Verify all commands of a list have the same prefix command and
10135 that only the top cmdlist commands have a null prefix.
10139 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
10140 as prefix, not one of its aliases.
10141 (set_cmd_prefix): Remove.
10142 (do_add_cmd): Centralize the setting of the prefix of a command, when
10143 command is defined after its full chain of prefix commands.
10144 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
10145 (add_setshow_cmd_full): Likewise.
10146 (update_prefix_field_of_prefixed_commands): New function.
10147 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
10148 update_prefix_field_of_prefixed_commands.
10149 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
10150 addresses of remote_set_cmdlist and remote_show_cmdlist given
10151 as argument, not the address of an argument.
10152 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
10153 * gdb/remote.c (_initialize_remote): Likewise.
10157 * cli/cli-cmds.c (alias_command): Check for an existing alias
10158 using lookup_cmd_composition, as valid_command_p is too strict
10159 and forbids aliases that are the prefix of an existing alias
10161 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
10162 command is properly recognised as a valid command.
10166 * unittests/help-doc-selftests.c: Rename to
10167 unittests/command-def-selftests.c
10168 * unittests/command-def-selftests.c (help_doc_tests): Update some
10170 (command_structure_tests, traverse_command_structure): New namespace
10172 (command_structure_invariants_tests): New function.
10173 (_initialize_command_def_selftests) Renamed from
10174 _initialize_help_doc_selftests, register command_structure_invariants
10179 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
10180 an alias of 'show'.
10184 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
10185 ada_is_fixed_point_type. Update all callers.
10186 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
10188 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
10189 Update all callers.
10190 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
10191 print_fixed_point_type. Update all callers.
10192 * ada-valprint.c (ada_value_print_num): Replace call to
10193 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
10197 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
10199 (cpu_supports_bts): Add CV_AMD case.
10204 * infrun.c (stop_all_threads): Collect multiple wait events at
10209 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
10210 type::code instead.
10214 * gdbtypes.h (struct type) <code, set_code>: New methods.
10215 (TYPE_CODE): Use type::code. Change all call sites used to set
10216 the code to use type::set_code instead.
10223 * infrun.c (stop_all_threads): Do NOT ignore
10224 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
10225 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
10227 (handle_no_resumed): Remove code handling a live inferior with no
10229 * remote.c (has_single_non_exited_thread): New.
10230 (remote_target::update_thread_list): Do not delete a thread if is
10231 the last thread of the process.
10232 * thread.c (thread_select): Call delete_exited_threads instead of
10237 * infrun.c (stop_all_threads): Enable/disable thread events of all
10238 targets. Move a debug message denoting the end of the function
10239 into the SCOPED_EXIT block.
10243 * process-stratum-target.h: Include <set>.
10244 (all_non_exited_process_targets, switch_to_target_no_thread): New
10245 function declarations.
10246 * process-stratum-target.c (all_non_exited_process_targets)
10247 (switch_to_target_no_thread): New function implementations.
10251 * infrun.c (handle_inferior_event): Extract out a piece of code
10253 (mark_non_executing_threads): ...this new function.
10257 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
10262 * regcache.c (regcache_read_pc_protected): New function
10263 implementation that returns 0 if the PC cannot read via
10264 'regcache_read_pc'.
10265 * infrun.c (proceed): Call 'regcache_read_pc_protected'
10266 instead of 'regcache_read_pc'.
10267 (keep_going_pass_signal): Ditto.
10271 * ada-lang.c (align_value): Remove.
10272 (ada_template_to_fixed_record_type_1): Use align_up.
10276 * async-event.c: Update the copyright year.
10277 * async-event.h: Update the copyright year.
10281 * objfiles.h (is_addr_in_objfile,
10282 shared_objfile_contains_address_p): Return bool.
10283 * objfile.c (is_addr_in_objfile,
10284 shared_objfile_contains_address_p): Return bool.
10288 * cli/cli-cmds.c (info_command): Restore.
10289 (_initialize_cli_cmds): Use add_prefix_command for "info".
10290 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
10294 * ada-lang.c (ada_value_primitive_field): Now public.
10295 * ada-lang.h (ada_value_primitive_field): Declare.
10296 * ada-valprint.c (print_field_values): Use
10297 ada_value_primitive_field for wrapper fields.
10301 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
10307 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
10308 with length 0, if not gdb-produced.
10309 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
10314 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
10319 * top.c (server_command): Now bool.
10320 * top.h (server_command): Now bool.
10324 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
10325 already being processed.
10329 * printcmd.c (struct display) <next>: Remove.
10330 <display>: New constructor.
10331 <exp_string>: Now a std::string.
10332 <enabled_p>: Now a bool.
10333 (display_number): Move definition earlier.
10334 (displays): Rename from display_chain. Now a std::vector.
10335 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
10336 (display_command): Update.
10337 (do_one_display, disable_display)
10338 (enable_disable_display_command, do_enable_disable_display):
10340 (free_display): Remove.
10341 (clear_displays): Rewrite.
10342 (delete_display): Update.
10343 (map_display_numbers): Use function_view. Remove "data"
10345 (do_delete_display): Remove.
10346 (undisplay_command): Update.
10347 (do_one_display, do_displays, disable_display)
10348 (info_display_command): Update.
10349 (do_enable_disable_display): Remove.
10350 (enable_disable_display_command)
10351 (clear_dangling_display_expressions): Update.
10355 * symtab.c (set_symbol_cache_size)
10356 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
10357 (maintenance_print_symbol_cache_statistics): Update.
10358 * symmisc.c (print_symbol_bcache_statistics)
10359 (print_objfile_statistics, maintenance_print_objfiles)
10360 (maintenance_info_symtabs, maintenance_check_symtabs)
10361 (maintenance_expand_symtabs, maintenance_info_line_tables):
10363 * symfile-debug.c (set_debug_symfile): Update.
10364 * source.c (forget_cached_source_info): Update.
10365 * python/python.c (gdbpy_progspaces): Update.
10366 * psymtab.c (maintenance_info_psymtabs): Update.
10367 * probe.c (parse_probes): Update.
10368 * linespec.c (iterate_over_all_matching_symtabs)
10369 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
10370 * guile/scm-progspace.c (gdbscm_progspaces): Update.
10371 * exec.c (exec_target::close): Update.
10372 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
10373 * breakpoint.c (print_one_breakpoint_location)
10374 (create_longjmp_master_breakpoint)
10375 (create_std_terminate_master_breakpoint): Update.
10376 * progspace.c (program_spaces): Now a std::vector.
10377 (maybe_new_address_space): Update.
10378 (add_program_space): Remove.
10379 (program_space::program_space): Update.
10380 (remove_program_space): Update.
10381 (number_of_program_spaces): Remove.
10382 (print_program_space, update_address_spaces): Update.
10383 * progspace.h (program_spaces): Change type.
10384 (ALL_PSPACES): Remove.
10385 (number_of_program_spaces): Don't declare.
10386 (struct program_space) <next>: Remove.
10390 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
10391 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
10392 (enable_break): Update.
10393 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
10394 (frv_fdpic_find_canonical_descriptor): Update.
10395 (frv_fetch_objfile_link_map): Update.
10396 * progspace.c (program_space::free_all_objfiles): Update.
10397 (program_space::solibs): New method.
10398 * progspace.h (struct program_space) <solibs>: New method.
10399 * solist.h (master_so_list): Don't declare.
10400 (ALL_SO_LIBS): Remove.
10401 * solib.h (so_list_head): Remove.
10402 (update_solib_list): Update comment.
10403 * solib.c (master_so_list): Remove.
10404 (solib_used, update_solib_list, solib_add)
10405 (info_sharedlibrary_command, clear_solib)
10406 (reload_shared_libraries_1, remove_user_added_objfile): Update.
10410 * extension.c (extension_languages): Now a std::array.
10411 (ALL_EXTENSION_LANGUAGES): Remove.
10412 (get_ext_lang_defn, get_ext_lang_of_file)
10413 (eval_ext_lang_from_control_command): Update.
10414 (finish_ext_lang_initialization)
10415 (auto_load_ext_lang_scripts_for_objfile)
10416 (ext_lang_type_printers::ext_lang_type_printers)
10417 (apply_ext_lang_type_printers)
10418 (ext_lang_type_printers::~ext_lang_type_printers)
10419 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
10420 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
10421 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
10422 (get_matching_xmethod_workers, ext_lang_colorize)
10423 (ext_lang_before_prompt): Update.
10424 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
10428 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
10430 <swap_string, m_string>: Remove.
10431 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
10433 * stabsread.c (define_symbol, read_type): Update.
10434 * linespec.c (find_linespec_symbols): Update.
10435 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
10436 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
10437 * dbxread.c (read_dbx_symtab): Update.
10438 * cp-support.h (cp_canonicalize_string_full)
10439 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
10440 Return unique_xmalloc_ptr.
10441 * cp-support.c (inspect_type): Update.
10442 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
10443 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
10445 * c-typeprint.c (print_name_maybe_canonical): Update.
10446 * break-catch-throw.c (check_status_exception_catchpoint):
10451 * infrun.c (follow_fork): Copy current_line and current_symtab to
10456 * async-event.c (struct async_signal_handler, struct
10457 async_event_handler): Reformat, remove typedef.
10461 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
10462 access thistype->main_type->dyn_prop_list directly.
10466 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
10467 (remove_dyn_prop): Remove. Update all users to use
10468 type::remove_dyn_prop.
10469 * gdbtypes.c (remove_dyn_prop): Rename to...
10470 (type::remove_dyn_prop): ... this.
10474 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
10475 (add_dyn_prop): Remove. Update all users to use
10476 type::add_dyn_prop.
10477 * gdbtypes.c (add_dyn_prop): Rename to...
10478 (type::add_dyn_prop): ... this.
10482 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
10483 (get_dyn_prop): Remove. Update all users to use
10485 * gdbtypes.c (get_dyn_prop): Rename to...
10486 (type::dyn_prop): ... this.
10490 * gdbtypes.h (struct main_type) <flag_static>: Remove.
10494 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
10495 instruction, skip it if it's there.
10499 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
10503 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
10504 * gdbtypes.c (recursive_dump_type): Remove use of
10509 * breakpoint.c (catch_command, tcatch_command): Remove.
10510 (_initialize_breakpoint): Use add_basic_prefix_cmd,
10511 add_show_prefix_cmd.
10512 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
10513 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
10515 (add_internal_problem_command): Use add_basic_prefix_cmd,
10516 add_show_prefix_cmd.
10517 * mips-tdep.c (set_mipsfpu_command): Remove.
10518 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
10519 * dwarf2/index-cache.c (set_index_cache_command): Remove.
10520 (_initialize_index_cache): Use add_basic_prefix_cmd.
10521 * memattr.c (dummy_cmd): Remove.
10522 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
10523 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
10524 (_initialize_tui_win): Use add_basic_prefix_cmd,
10525 add_show_prefix_cmd.
10526 * cli/cli-logging.c (set_logging_command): Remove.
10527 (_initialize_cli_logging): Use add_basic_prefix_cmd,
10528 add_show_prefix_cmd.
10529 (show_logging_command): Remove.
10530 * target.c (target_command): Remove.
10531 (add_target): Use add_basic_prefix_cmd.
10535 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
10539 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
10544 * nbsd-nat.c (nbsd_enable_proc_events)
10545 (nbsd_nat_target::post_startup_inferior): Add.
10546 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
10547 (nbsd_nat_target::update_thread_list): Rewrite.
10548 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
10549 "PTRACE_LWP_CREATE".
10550 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
10554 * stack.c (_initialize_stack): Remove duplicated creation
10555 of "frame" command and "f" alias.
10560 * gdbtypes.c (check_typedef): Calculate size of array of
10566 * i386-tdep.c (i386_push_dummy_call): Call
10567 i386_thiscall_push_dummy_call.
10568 (i386_thiscall_push_dummy_call): New function.
10569 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
10570 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
10571 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
10575 * gdbarch.sh (do_read): Add shellcheck disable directive for
10580 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
10581 "referenced but not assigned" warning.
10585 * gdbarch.sh: Remove code that sets fallbackdefault.
10589 * gdbarch.sh: Use shell operators && and || instead of
10594 * gdbarch.sh: Use $(...) instead of `...`.
10598 * gdbarch.sh: Use double quotes around variables.
10602 * gdbarch.sh: Use %s with printf, instead of variables in the
10608 * dwarf2/read.c (update_enumeration_type_from_children): Compute
10610 (read_enumeration_type): Call
10611 update_enumeration_type_from_children later. Update comments.
10612 (process_enumeration_scope): Don't create type fields.
10616 * nbsd-tdep.c: Include "xml-syscall.h".
10617 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
10621 * nbsd-nat.c: Include "sys/wait.h".
10622 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
10623 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
10624 (nbsd_nat_target::remove_exec_catchpoint)
10625 (nbsd_nat_target::set_syscall_catchpoint): Add.
10626 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
10627 (nbsd_nat_target::insert_exec_catchpoint)
10628 (nbsd_nat_target::remove_exec_catchpoint)
10629 (nbsd_nat_target::set_syscall_catchpoint): Add.
10630 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
10631 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
10632 `nbsd_get_syscall_number'.
10636 * stack.c (print_block_frame_labels): Remove.
10641 * ada-valprint.c (val_print_packed_array_elements): Move array
10642 end bracket to new line.
10643 (ada_val_print_string): Remove extra spaces before first array
10645 * c-valprint.c (c_value_print_array): Likewise.
10646 * m2-valprint.c (m2_print_array_contents): Likewise.
10647 (m2_value_print_inner): Likewise.
10648 * p-valprint.c (pascal_value_print_inner): Likewise.
10649 * valprint.c (generic_val_print_array): Likewise.
10650 (value_print_array_elements): Move first array element and array
10651 end bracket to new line.
10656 * linespec.c (find_method): Fix ix calculation.
10660 * syscalls/update-netbsd.sh: New file.
10661 * syscalls/netbsd.xml: Regenerate.
10662 * data-directory/Makefile.in: Register `netbsd.xml' in
10667 * syscalls/update-freebsd.sh: Add double quotes.
10672 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
10673 (cmdpy_init): Allow class_tui.
10678 * dwarf2read.c: Add missing assingments to list_in_scope when
10679 start_symtab was already called.
10684 * dwarf2/read.c (offset_map_type): Use
10685 gdb:hash_enum<sect_offset> as hash function.
10689 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
10690 with DW_AT_signature.
10694 * configure.ac: Remove check for fs_base/gs_base in
10696 * configure: Re-generate.
10697 * config.in: Re-generate.
10698 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
10699 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
10700 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
10704 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
10705 problematic inline frame unwinding situation.
10706 * frame.c (frame_id_computed_p): New function.
10707 * frame.h (frame_id_computed_p): New prototype.
10711 * command.h (enum command_class) <class_pseudo>: Remove.
10715 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
10720 * inf-ptrace.c (inf_ptrace_target::wait): Remove
10721 `PT_GET_PROCESS_STATE' block.
10725 * symtab.h (symbol_get_demangled_name): Don't declare.
10726 * symtab.c (symbol_get_demangled_name): Remove.
10727 (general_symbol_info::natural_name)
10728 (general_symbol_info::demangled_name): Update.
10733 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
10738 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
10740 (new_symbol): Likewise.
10741 * compile/compile-object-load.c (get_out_value_type): Use
10742 symbol_matches_search_name.
10746 * dwarf2/read.c (add_partial_symbol): Do not call
10747 compute_and_set_names.
10751 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
10756 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
10757 (add_psymbol_to_list): New overload. Make old overload call new
10759 * psympriv.h (add_psymbol_to_list): New overload.
10763 * dwarf2/read.c (partial_die_info::read) <case
10764 DW_AT_linkage_name>: Use value_as_string.
10765 (dwarf2_string_attr): Use value_as_string.
10766 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
10768 * dwarf2/attribute.c (attribute::value_as_string): New method.
10772 * symtab.c (general_symbol_info::natural_name)
10773 (general_symbol_info::demangled_name): Check for language_rust.
10777 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
10778 (dwarf2_physname): ... from here.
10779 (partial_die_info::read): Add Rust "{" hack.
10783 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
10785 (symbol_set_demangled_name): Don't declare.
10786 * symtab.c (general_symbol_info::set_demangled_name): Rename from
10787 symbol_set_demangled_name.
10788 (general_symbol_info::set_language)
10789 (general_symbol_info::compute_and_set_names): Update.
10790 * minsyms.c (minimal_symbol_reader::install): Update.
10791 * dwarf2/read.c (new_symbol): Update.
10796 * python/py-type.c (convert_field): Handle
10797 FIELD_LOC_KIND_DWARF_BLOCK.
10798 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
10799 (typy_get_dynamic): Nw function.
10800 (type_object_getset): Add "dynamic".
10805 * ada-typeprint.c (print_choices, print_variant_part)
10806 (print_record_field_types_dynamic): New functions.
10807 (print_record_field_types): Use print_record_field_types_dynamic.
10811 * dwarf2/read.c (handle_data_member_location): New overload.
10812 (dwarf2_add_field): Use it.
10813 (decode_locdesc): Add "computed" parameter. Update comment.
10814 * gdbtypes.c (is_dynamic_type_internal): Also look for
10815 FIELD_LOC_KIND_DWARF_BLOCK.
10816 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
10817 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
10818 virtual base classes.
10819 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
10820 FIELD_LOC_KIND_DWARF_BLOCK.
10824 * dwarf2/read.c (read_structure_type): Handle dynamic length.
10825 * gdbtypes.c (is_dynamic_type_internal): Check
10826 TYPE_HAS_DYNAMIC_LENGTH.
10827 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
10828 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
10830 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
10835 * dwarf2/read.c (struct variant_field): Rewrite.
10836 (struct variant_part_builder): New.
10837 (struct nextfield): Remove "variant" field. Add "offset".
10838 (struct field_info): Add "current_variant_part" and
10840 (alloc_discriminant_info): Remove.
10841 (alloc_rust_variant): New function.
10842 (quirk_rust_enum): Update.
10843 (dwarf2_add_field): Set "offset" member. Don't handle
10844 DW_TAG_variant_part.
10845 (offset_map_type): New typedef.
10846 (convert_variant_range, create_one_variant)
10847 (create_one_variant_part, create_variant_parts)
10848 (add_variant_property): New functions.
10849 (dwarf2_attach_fields_to_type): Call add_variant_property.
10850 (read_structure_type): Don't handle DW_TAG_variant_part.
10851 (handle_variant_part, handle_variant): New functions.
10852 (handle_struct_member_die): Use them.
10853 (process_structure_scope): Don't handle variant parts.
10854 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
10855 (struct discriminant_info): Remove.
10856 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
10857 (struct main_type) <flag_discriminated_union>: Remove.
10858 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
10859 (rust_enum_variant): Return int. Remove "contents". Rewrite.
10860 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
10862 * valops.c (value_union_variant): Remove.
10863 * value.h (value_union_variant): Don't declare.
10867 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
10868 (ada_value_primitive_packed_val): Update.
10869 * ada-valprint.c (ada_value_print_1): Update.
10870 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
10871 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
10872 just an address. Use evaluate_for_locexpr_baton.
10873 (dwarf2_evaluate_property): Update.
10874 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
10876 * findvar.c (default_read_var_value): Update.
10877 * gdbtypes.c (compute_variant_fields_inner)
10878 (resolve_dynamic_type_internal): Update.
10879 (resolve_dynamic_type): Change type of valaddr parameter.
10880 * gdbtypes.h (resolve_dynamic_type): Update.
10881 * valarith.c (value_subscripted_rvalue): Update.
10882 * value.c (value_from_contents_and_address): Update.
10886 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
10887 "push_initial_value" parameter.
10888 (dwarf2_evaluate_property): Likewise.
10889 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
10893 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
10894 (variant::matches, compute_variant_fields_recurse)
10895 (compute_variant_fields_inner, compute_variant_fields): New
10897 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
10898 Use resolved_type after type is made.
10899 (operator==): Add new cases.
10900 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
10901 (struct discriminant_range, struct variant, struct variant_part):
10903 (union dynamic_prop_data) <variant_parts, original_type>: New
10905 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
10906 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
10908 * value.c (unpack_bits_as_long): Now public.
10909 * value.h (unpack_bits_as_long): Declare.
10913 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
10914 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
10918 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
10922 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
10923 (remove_fork_catchpoint, post_startup_inferior)
10924 (post_attach): Move...
10925 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
10926 (remove_fork_catchpoint, post_startup_inferior)
10927 (post_attach): ...here.
10928 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
10929 (remove_fork_catchpoint, post_startup_inferior)
10930 (post_attach): Move...
10931 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
10932 (remove_fork_catchpoint, post_startup_inferior)
10933 (post_attach): ...here.
10937 * nat/windows-nat.h (struct windows_thread_info)
10938 <pc_adjusted>: New member.
10939 * windows-nat.c (windows_fetch_one_register): Check
10941 (windows_nat_target::get_windows_debug_event)
10942 (windows_nat_target::wait): Set pc_adjusted.
10946 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
10947 Run gdb-add-index inside temp dir.
10951 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
10956 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
10957 get_frame_register instead of gdbarch_unwind_pc.
10961 * symtab.c (lookup_global_symbol): Prefer def over decl.
10966 * block.c (best_symbol, better_symbol): Promote to external.
10967 * block.h (best_symbol, better_symbol): Declare.
10968 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
10974 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
10975 "const char *", not a "const std::string &".
10976 <name_and_matcher::operator==>: Update.
10977 * unittests/lookup_name_info-selftests.c: Change type of
10982 * inferior.h (iterate_over_inferiors): Don't declare.
10983 * inferior.c (iterate_over_inferiors): Remove.
10984 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
10986 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
10987 use iterate_over_inferiors.
10988 (darwin_resume_inferior_it)
10989 (struct resume_inferior_threads_param)
10990 (darwin_resume_inferior_threads_it): Remove.
10991 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
10995 * blockframe.c (find_pc_partial_function): Use
10996 find_pc_sect_compunit_symtab rather than
10997 objfile->sf->qf->find_pc_sect_compunit_symtab.
11002 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
11008 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
11014 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
11015 CU if already created.
11019 * infrun.c (displaced_step_fixup): Switch to the event_thread
11020 before calling displaced_step_restore, not after.
11024 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
11025 its inferior is not recorded by us.
11026 (record_btrace_target_open): Replace call to
11027 all_non_exited_threads () with call to current_inferior
11028 ()->non_exited_threads ().
11029 (record_btrace_target::stop_recording): Likewise.
11030 (record_btrace_target::close): Likewise.
11031 (record_btrace_target::wait): Likewise.
11032 (record_btrace_target::record_stop_replaying): Likewise.
11036 * btrace.c (btrace_enable): Throw an error on double enables and
11037 when enabling recording fails.
11038 (btrace_disable): Throw an error if the thread is not recorded.
11042 * record-btrace.c (record_btrace_target::fetch_registers): Forward
11043 request if we do not have a thread_info.
11049 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
11050 exception in get_frame_id.
11054 * python/python.c (struct gdbpy_event): Mark move constructor as
11056 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
11057 constructor as noexcept.
11058 * completer.h (struct completion_result): Mark move constructor as
11060 * completer.c (completion_result::completion_result): Use
11061 initialization style. Don't call reset_match_list.
11065 * MAINTAINERS (Write After Approval): Add myself.
11069 * windows-tdep.c (init_w32_command_list)
11070 (w32_prefix_command_valid): Restore.
11071 (_initialize_windows_tdep): Call init_w32_command_list.
11075 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
11076 * value.c (value_fn_field): Update.
11077 * valops.c (find_function_in_inferior)
11078 (value_allocate_space_in_inferior): Update.
11079 * tui/tui-winsource.c (tui_update_source_windows_with_line):
11081 * tui/tui-source.c (tui_source_window::set_contents): Update.
11082 * symtab.c (lookup_global_or_static_symbol)
11083 (find_function_start_sal_1, skip_prologue_sal)
11084 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
11085 * symmisc.c (dump_msymbols, dump_symtab_1)
11086 (maintenance_print_one_line_table): Update.
11087 * symfile.c (init_entry_point_info, section_is_mapped)
11088 (list_overlays_command, simple_read_overlay_table)
11089 (simple_overlay_update_1): Update.
11090 * stap-probe.c (handle_stap_probe): Update.
11091 * stabsread.c (dbx_init_float_type, define_symbol)
11092 (read_one_struct_field, read_enum_type, read_range_type): Update.
11093 * source.c (info_line_command): Update.
11094 * python/python.c (gdbpy_source_objfile_script)
11095 (gdbpy_execute_objfile_script): Update.
11096 * python/py-type.c (save_objfile_types): Update.
11097 * python/py-objfile.c (py_free_objfile): Update.
11098 * python/py-inferior.c (python_new_objfile): Update.
11099 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
11100 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
11101 (maintenance_check_psymtabs): Update.
11102 * printcmd.c (info_address_command): Update.
11103 * objfiles.h (struct objfile) <arch>: New method, from
11105 (get_objfile_arch): Don't declare.
11106 * objfiles.c (get_objfile_arch): Remove.
11107 (filter_overlapping_sections): Update.
11108 * minsyms.c (msymbol_is_function): Update.
11109 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
11110 (output_nondebug_symbol): Update.
11111 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
11112 (mdebug_expand_psymtab): Update.
11113 * machoread.c (macho_add_oso_symfile): Update.
11114 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
11116 * linux-fork.c (checkpoint_command): Update.
11117 * linespec.c (convert_linespec_to_sals): Update.
11118 * jit.c (finalize_symtab): Update.
11119 * infrun.c (insert_exception_resume_from_probe): Update.
11120 * ia64-tdep.c (ia64_find_unwind_table): Update.
11121 * hppa-tdep.c (internalize_unwinds): Update.
11122 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
11124 * gcore.c (call_target_sbrk): Update.
11125 * elfread.c (record_minimal_symbol, elf_symtab_read)
11126 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
11127 (elf_gnu_ifunc_resolve_by_got): Update.
11128 * dwarf2/read.c (create_addrmap_from_index)
11129 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
11130 (read_debug_names_from_section)
11131 (process_psymtab_comp_unit_reader, add_partial_symbol)
11132 (add_partial_subprogram, process_full_comp_unit)
11133 (read_file_scope, read_func_scope, read_lexical_block_scope)
11134 (read_call_site_scope, dwarf2_ranges_read)
11135 (dwarf2_record_block_ranges, dwarf2_add_field)
11136 (mark_common_block_symbol_computed, read_tag_pointer_type)
11137 (read_tag_string_type, dwarf2_init_float_type)
11138 (dwarf2_init_complex_target_type, read_base_type)
11139 (partial_die_info::read, partial_die_info::read)
11140 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
11141 (dwarf2_fetch_die_loc_sect_off): Update.
11142 * dwarf2/loc.c (dwarf2_find_location_expression)
11143 (class dwarf_evaluate_loc_desc, rw_pieced_value)
11144 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
11145 (dwarf2_loc_desc_get_symbol_read_needs)
11146 (locexpr_describe_location_piece, locexpr_describe_location_1)
11147 (loclist_describe_location): Update.
11148 * dwarf2/index-write.c (write_debug_names): Update.
11149 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
11150 * dtrace-probe.c (dtrace_process_dof): Update.
11151 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
11152 (process_one_symbol): Update.
11153 * ctfread.c (ctf_init_float_type, read_base_type): Update.
11154 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
11155 (coff_read_enum_type): Update.
11156 * cli/cli-cmds.c (edit_command, list_command): Update.
11157 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
11158 * breakpoint.c (create_overlay_event_breakpoint)
11159 (create_longjmp_master_breakpoint)
11160 (create_std_terminate_master_breakpoint)
11161 (create_exception_master_breakpoint, get_sal_arch): Update.
11162 * block.c (block_gdbarch): Update.
11163 * annotate.c (annotate_source_line): Update.
11167 * auto-load.c (show_auto_load_cmd): Remove.
11168 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
11169 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
11170 (maintenance_print_arc_command): Remove.
11171 * tui/tui-win.c (tui_command): Remove.
11172 (tui_get_cmd_list): Use add_basic_prefix_cmd.
11173 * tui/tui-layout.c (tui_layout_command): Remove.
11174 (_initialize_tui_layout): Use add_basic_prefix_cmd.
11175 * python/python.c (user_set_python, user_show_python): Remove.
11176 (_initialize_python): Use add_basic_prefix_cmd,
11177 add_show_prefix_cmd.
11178 * guile/guile.c (set_guile_command, show_guile_command): Remove.
11179 (install_gdb_commands): Use add_basic_prefix_cmd,
11180 add_show_prefix_cmd.
11181 (info_guile_command): Remove.
11182 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
11183 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
11184 add_show_prefix_cmd.
11185 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
11186 Remove do_set and do_show parameters.
11187 * cli/cli-style.c (set_style, show_style): Remove.
11188 (_initialize_cli_style): Use add_basic_prefix_cmd,
11189 add_show_prefix_cmd.
11190 (cli_style_option::add_setshow_commands): Remove do_set and
11191 do_show parameters.
11192 (cli_style_option::add_setshow_commands): Use
11193 add_basic_prefix_cmd, add_show_prefix_cmd.
11194 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
11195 (set_style_name): Remove.
11196 * cli/cli-dump.c (dump_command, append_command): Remove.
11197 (srec_dump_command, ihex_dump_command, verilog_dump_command)
11198 (tekhex_dump_command, binary_dump_command)
11199 (binary_append_command): Remove.
11200 (_initialize_cli_dump): Use add_basic_prefix_cmd.
11201 * windows-tdep.c (w32_prefix_command_valid): Remove global.
11202 (init_w32_command_list): Remove; move into ...
11203 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
11204 * valprint.c (set_print, show_print, set_print_raw)
11205 (show_print_raw): Remove.
11206 (_initialize_valprint): Use add_basic_prefix_cmd,
11207 add_show_prefix_cmd.
11208 * typeprint.c (set_print_type, show_print_type): Remove.
11209 (_initialize_typeprint): Use add_basic_prefix_cmd,
11210 add_show_prefix_cmd.
11211 * record.c (set_record_command, show_record_command): Remove.
11212 (_initialize_record): Use add_basic_prefix_cmd,
11213 add_show_prefix_cmd.
11214 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
11215 add_show_prefix_cmd.
11216 (info_command, show_command, set_debug, show_debug): Remove.
11217 * top.h (set_history, show_history): Don't declare.
11218 * top.c (set_history, show_history): Remove.
11219 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
11220 (unset_tdesc_cmd): Remove.
11221 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
11222 add_show_prefix_cmd.
11223 * symtab.c (info_module_command): Remove.
11224 (_initialize_symtab): Use add_basic_prefix_cmd.
11225 * symfile.c (overlay_command): Remove.
11226 (_initialize_symfile): Use add_basic_prefix_cmd.
11227 * sparc64-tdep.c (info_adi_command): Remove.
11228 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
11229 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
11230 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
11231 add_show_prefix_cmd.
11232 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
11233 (_initialize_serial): Use add_basic_prefix_cmd,
11234 add_show_prefix_cmd.
11235 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
11236 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
11237 add_show_prefix_cmd.
11238 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
11239 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
11240 add_show_prefix_cmd.
11241 * riscv-tdep.c (show_riscv_command, set_riscv_command)
11242 (show_debug_riscv_command, set_debug_riscv_command): Remove.
11243 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
11244 add_show_prefix_cmd.
11245 * remote.c (remote_command, set_remote_cmd): Remove.
11246 (_initialize_remote): Use add_basic_prefix_cmd.
11247 * record-full.c (set_record_full_command)
11248 (show_record_full_command): Remove.
11249 (_initialize_record_full): Use add_basic_prefix_cmd,
11250 add_show_prefix_cmd.
11251 * record-btrace.c (cmd_set_record_btrace)
11252 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
11253 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
11254 (cmd_show_record_btrace_pt): Remove.
11255 (_initialize_record_btrace): Use add_basic_prefix_cmd,
11256 add_show_prefix_cmd.
11257 * ravenscar-thread.c (set_ravenscar_command)
11258 (show_ravenscar_command): Remove.
11259 (_initialize_ravenscar): Use add_basic_prefix_cmd,
11260 add_show_prefix_cmd.
11261 * mips-tdep.c (show_mips_command, set_mips_command)
11262 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
11263 add_show_prefix_cmd.
11264 * maint.c (maintenance_command, maintenance_info_command)
11265 (maintenance_check_command, maintenance_print_command)
11266 (maintenance_set_cmd, maintenance_show_cmd): Remove.
11267 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
11268 add_show_prefix_cmd.
11269 (show_per_command_cmd): Remove.
11270 * maint-test-settings.c (maintenance_set_test_settings_cmd):
11272 (maintenance_show_test_settings_cmd): Remove.
11273 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
11274 add_show_prefix_cmd.
11275 * maint-test-options.c (maintenance_test_options_command):
11277 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
11278 * macrocmd.c (macro_command): Remove
11279 (_initialize_macrocmd): Use add_basic_prefix_cmd.
11280 * language.c (set_check, show_check): Remove.
11281 (_initialize_language): Use add_basic_prefix_cmd,
11282 add_show_prefix_cmd.
11283 * infcmd.c (unset_command): Remove.
11284 (_initialize_infcmd): Use add_basic_prefix_cmd.
11285 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
11286 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
11287 add_show_prefix_cmd.
11288 * go32-nat.c (go32_info_dos_command): Remove.
11289 (_initialize_go32_nat): Use add_basic_prefix_cmd.
11290 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
11291 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
11292 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
11293 (_initialize_frame): Use add_basic_prefix_cmd,
11294 add_show_prefix_cmd.
11295 * dcache.c (set_dcache_command, show_dcache_command): Remove.
11296 (_initialize_dcache): Use add_basic_prefix_cmd,
11297 add_show_prefix_cmd.
11298 * cp-support.c (maint_cplus_command): Remove.
11299 (_initialize_cp_support): Use add_basic_prefix_cmd.
11300 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
11301 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
11302 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
11303 add_basic_prefix_cmd, add_show_prefix_cmd.
11304 * breakpoint.c (save_command): Remove.
11305 (_initialize_breakpoint): Use add_basic_prefix_cmd.
11306 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
11307 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
11308 add_show_prefix_cmd.
11309 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
11310 (set_ada_command, show_ada_command): Remove.
11311 (_initialize_ada_language): Use add_basic_prefix_cmd,
11312 add_show_prefix_cmd.
11313 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
11317 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
11318 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
11322 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
11327 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
11328 import table is not at beginning of .idata section.
11332 * inferior.c (delete_inferior): Use delete operator directly
11333 instead of delete_program_space.
11334 * progspace.c (add_program_space): New, factored out from
11335 program_space::program_space.
11336 (remove_program_space): New, factored out from
11337 delete_program_space.
11338 (program_space::program_space): Remove intro comment. Rewrite.
11339 (program_space::~program_space): Remove intro comment. Call
11340 remove_program_space.
11341 (delete_program_space): Delete.
11342 * progspace.h (program_space::program_space): Make explicit. Move
11343 intro comment here, adjusted.
11344 (program_space::~program_space): Move intro comment here,
11346 (delete_program_space): Remove.
11350 * windows-nat.c (windows_nat::handle_access_violation): New
11352 * nat/windows-nat.h (handle_access_violation): Declare.
11353 * nat/windows-nat.c (handle_exception): Move Cygwin code to
11354 windows-nat.c. Call handle_access_violation.
11359 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
11360 CUs without psymtab.
11364 * python/python.c (do_start_initialization): Don't call
11365 PyEval_InitThreads for Python 3.9 and beyond.
11369 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
11371 (obsd_nat_target::wait): Likewise.
11375 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
11376 (DEBUG_EXCEPT): Use debug_printf.
11380 * completer.c (class completion_tracker::completion_hash_entry)
11381 <hash_name>: New member function.
11382 (completion_tracker::discard_completions): New callback to hash a
11383 completion_hash_entry, pass this to htab_create_alloc.
11387 * windows-nat.c (windows_make_so): Warn rather than stopping with
11388 an error if realpath() fails.
11392 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
11393 (nbsd_nat_target::info_proc): Add do_status.
11399 * psympriv.h (struct partial_symtab::read_symtab)
11400 (struct partial_symtab::expand_psymtab)
11401 (struct partial_symtab::read_dependencies): Update comments.
11402 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
11403 read_symtab for includer.
11404 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
11405 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
11406 (struct dwarf2_include_psymtab::m_readin): Remove.
11407 (struct dwarf2_include_psymtab::includer): New member function.
11408 (dwarf2_psymtab::expand_psymtab): Assert !readin.
11413 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
11414 with NULL symbol_matcher and lookup_name.
11415 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
11417 * dwarf2/read.c (dw2_expand_symtabs_matching)
11418 (dw2_debug_names_expand_symtabs_matching): Same.
11419 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
11420 Make lookup_name a pointer. Update comment.
11421 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
11422 lookup_name being a pointer.
11423 * symfile.c (expand_symtabs_matching): Same.
11424 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
11425 * linespec.c (iterate_over_all_matching_symtabs): Same.
11429 * run-on-main-thread.c: Update include.
11430 * unittests/main-thread-selftests.c: Update include.
11431 * tui/tui-win.c: Update include.
11432 * tui/tui-io.c: Update include.
11433 * tui/tui-interp.c: Update include.
11434 * tui/tui-hooks.c: Update include.
11435 * top.h: Update include.
11436 * top.c: Update include.
11437 * ser-base.c: Update include.
11438 * remote.c: Update include.
11439 * remote-notif.c: Update include.
11440 * remote-fileio.c: Update include.
11441 * record-full.c: Update include.
11442 * record-btrace.c: Update include.
11443 * python/python.c: Update include.
11444 * posix-hdep.c: Update include.
11445 * mingw-hdep.c: Update include.
11446 * mi/mi-main.c: Update include.
11447 * mi/mi-interp.c: Update include.
11448 * main.c: Update include.
11449 * linux-nat.c: Update include.
11450 * interps.c: Update include.
11451 * infrun.c: Update include.
11452 * inf-loop.c: Update include.
11453 * event-top.c: Update include.
11454 * event-loop.c: Move to ../gdbsupport/.
11455 * event-loop.h: Move to ../gdbsupport/.
11456 * async-event.h: Update include.
11457 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
11461 * tui/tui-win.c: Include async-event.h.
11462 * remote.c: Include async-event.h.
11463 * remote-notif.c: Include async-event.h.
11464 * record-full.c: Include async-event.h.
11465 * record-btrace.c: Include async-event.h.
11466 * infrun.c: Include async-event.h.
11467 * event-top.c: Include async-event.h.
11468 * event-loop.h: Move some declarations to async-event.h.
11469 * event-loop.c: Don't include ser-event.h or top.h. Move some
11470 code to async-event.c.
11471 * async-event.h: New file.
11472 * async-event.c: New file.
11473 * Makefile.in (COMMON_SFILES): Add async-event.c.
11474 (HFILES_NO_SRCDIR): Add async-event.h.
11478 * utils.c (flush_streams): New function.
11479 * event-loop.c (gdb_wait_for_event): Call flush_streams.
11483 * event-loop.c (handle_file_event): Use warning, not
11488 * event-loop.c: Include <chrono>.
11492 * gdb_select.h: Move to ../gdbsupport/.
11493 * event-loop.c: Update include path.
11494 * top.c: Update include path.
11495 * ser-base.c: Update include path.
11496 * ui-file.c: Update include path.
11497 * ser-tcp.c: Update include path.
11498 * guile/scm-ports.c: Update include path.
11499 * posix-hdep.c: Update include path.
11500 * ser-unix.c: Update include path.
11501 * gdb_usleep.c: Update include path.
11502 * mingw-hdep.c: Update include path.
11503 * inflow.c: Update include path.
11504 * infrun.c: Update include path.
11505 * event-top.c: Update include path.
11509 * configure: Rebuild.
11510 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
11514 * event-loop.h (start_event_loop): Don't declare.
11515 * event-loop.c (start_event_loop): Move...
11516 * main.c (start_event_loop): ...here. Now static.
11520 * MAINTAINERS: Update my email address.
11524 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
11529 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
11530 (nbsd_nat_target::info_proc): Add do_cmdline.
11534 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
11535 (nbsd_nat_target::info_proc): Add do_cwd.
11539 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
11543 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
11544 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
11545 (nbsd_nat_target::info_proc): New functions.
11546 * nbsd-nat.c (kinfo_get_vmmap): New function.
11547 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
11548 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
11549 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
11550 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
11552 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
11553 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
11554 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
11555 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
11556 (KINFO_VME_FLAG_GROWS_DOWN): New.
11560 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
11565 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
11569 * symtab.c (get_symbol_address, get_msymbol_address): Skip
11570 separate debug files.
11574 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
11576 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
11578 * windows-nat.c (windows_nat_target::get_windows_debug_event):
11579 Check for STATUS_WX86_BREAKPOINT.
11580 (windows_nat_target::wait): Same.
11585 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
11589 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
11590 (Write After Approval): Remove Tom de Vries.
11597 * buildsym.c (record_line): Fix undefined behavior and preserve
11602 * auxv.h (svr4_auxv_parse): New.
11603 * auxv.c (default_auxv_parse): Split into default_auxv_parse
11604 and generic_auxv_parse.
11605 (svr4_auxv_parse): Add.
11606 * obsd-tdep.c: Include "auxv.h".
11607 (obsd_auxv_parse): Remove.
11608 (obsd_init_abi): Remove comment.
11609 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
11610 from `obsd_auxv_parse' to `svr4_auxv_parse'.
11611 * nbsd-tdep.c: Include "auxv.h".
11612 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
11616 * nat/windows-nat.h (last_wait_event): Don't declare.
11617 (wait_for_debug_event): Update comment.
11618 * nat/windows-nat.c (last_wait_event): Now static.
11622 * windows-nat.c (wait_for_debug_event): Move to
11624 * nat/windows-nat.h (wait_for_debug_event): Declare.
11625 * nat/windows-nat.c (wait_for_debug_event): Move from
11626 windows-nat.c. No longer static.
11630 * windows-nat.c (get_windows_debug_event): Use
11631 fetch_pending_stop.
11632 * nat/windows-nat.h (fetch_pending_stop): Declare.
11633 * nat/windows-nat.c (fetch_pending_stop): New function.
11637 * windows-nat.c (windows_continue): Use matching_pending_stop and
11638 continue_last_debug_event.
11639 * nat/windows-nat.h (matching_pending_stop)
11640 (continue_last_debug_event): Declare.
11641 * nat/windows-nat.c (DEBUG_EVENTS): New define.
11642 (matching_pending_stop, continue_last_debug_event): New
11647 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
11648 (handle_exception_result): Move to nat/windows-nat.h.
11649 (DEBUG_EXCEPTION_SIMPLE): Remove.
11650 (windows_nat::handle_ms_vc_exception): New function.
11651 (handle_exception): Move to nat/windows-nat.c.
11652 (get_windows_debug_event): Update.
11653 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
11655 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
11656 (handle_exception_result): Move from windows-nat.c.
11657 (handle_exception): Declare.
11658 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
11659 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
11664 * windows-nat.c (exception_count, event_count): Remove.
11665 (handle_exception, get_windows_debug_event)
11666 (do_initial_windows_stuff): Update.
11670 * windows-nat.c (windows_nat::handle_load_dll)
11671 (windows_nat::handle_unload_dll): Rename. No longer static.
11672 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
11677 * complaints.h (stop_whining): Declare at top-level.
11678 (complaint): Don't declare stop_whining.
11682 * windows-nat.c (windows_nat::handle_output_debug_string):
11683 Rename. No longer static.
11684 * nat/windows-nat.h (handle_output_debug_string): Declare.
11688 * windows-nat.c (current_process_handle, current_process_id)
11689 (main_thread_id, last_sig, current_event, last_wait_event)
11690 (current_windows_thread, desired_stop_thread_id, pending_stops)
11691 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
11692 (display_selectors, fake_create_process)
11693 (get_windows_debug_event): Update.
11694 * nat/windows-nat.h (current_process_handle, current_process_id)
11695 (main_thread_id, last_sig, current_event, last_wait_event)
11696 (current_windows_thread, desired_stop_thread_id, pending_stops)
11697 (struct pending_stop, siginfo_er): Move from windows-nat.c.
11698 * nat/windows-nat.c (current_process_handle, current_process_id)
11699 (main_thread_id, last_sig, current_event, last_wait_event)
11700 (current_windows_thread, desired_stop_thread_id, pending_stops)
11701 (siginfo_er): New globals. Move from windows-nat.c.
11705 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
11706 (handle_load_dll): Update.
11707 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
11711 * windows-nat.c (enum thread_disposition_type): Move to
11713 (windows_nat::thread_rec): Rename from thread_rec. No longer
11715 (windows_add_thread, windows_nat_target::fetch_registers)
11716 (windows_nat_target::store_registers, handle_exception)
11717 (windows_nat_target::resume, get_windows_debug_event)
11718 (windows_nat_target::get_tib_address)
11719 (windows_nat_target::thread_name)
11720 (windows_nat_target::thread_alive): Update.
11721 * nat/windows-nat.h (enum thread_disposition_type): Move from
11723 (thread_rec): Declare.
11727 * windows-nat.c: Add "using namespace".
11728 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
11729 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
11733 * nat/windows-nat.h (struct windows_thread_info): Declare
11735 * nat/windows-nat.c (~windows_thread_info): New.
11740 * windows-nat.c (current_event): Update comment.
11741 (last_wait_event, desired_stop_thread_id): New globals.
11742 (struct pending_stop): New.
11743 (pending_stops): New global.
11744 (windows_nat_target) <stopped_by_sw_breakpoint>
11745 <supports_stopped_by_sw_breakpoint>: New methods.
11746 (windows_fetch_one_register): Add assertions. Adjust PC.
11747 (windows_continue): Handle pending stops. Suspend other threads
11748 when stepping. Use last_wait_event
11749 (wait_for_debug_event): New function.
11750 (get_windows_debug_event): Use wait_for_debug_event. Handle
11751 pending stops. Queue spurious stops.
11752 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
11753 (windows_nat_target::kill): Use wait_for_debug_event.
11754 * nat/windows-nat.h (struct windows_thread_info)
11755 <stopped_at_software_breakpoint>: New field.
11756 * nat/windows-nat.c (windows_thread_info::resume): Clear
11757 stopped_at_software_breakpoint.
11761 * windows-nat.c (enum thread_disposition_type): New.
11762 (thread_rec): Replace "get_context" parameter with "disposition";
11764 (windows_add_thread, windows_nat_target::fetch_registers)
11765 (windows_nat_target::store_registers, handle_exception)
11766 (windows_nat_target::resume, get_windows_debug_event)
11767 (windows_nat_target::get_tib_address)
11768 (windows_nat_target::thread_name)
11769 (windows_nat_target::thread_alive): Update.
11773 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
11774 (windows_continue): Use windows_continue::resume.
11775 * nat/windows-nat.h (struct windows_thread_info) <suspend,
11776 resume>: Declare new methods.
11777 * nat/windows-nat.c: New file.
11778 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
11782 * windows-nat.c (windows_add_thread, windows_delete_thread)
11783 (windows_nat_target::fetch_registers)
11784 (windows_nat_target::store_registers, fake_create_process)
11785 (windows_nat_target::resume, windows_nat_target::resume)
11786 (get_windows_debug_event, windows_nat_target::wait)
11787 (windows_nat_target::pid_to_str)
11788 (windows_nat_target::get_tib_address)
11789 (windows_nat_target::get_ada_task_ptid)
11790 (windows_nat_target::thread_name)
11791 (windows_nat_target::thread_alive): Use lwp, not tid.
11795 * windows-nat.c (handle_exception)
11796 (windows_nat_target::thread_name): Update.
11797 * nat/windows-nat.h (windows_thread_info): Remove destructor.
11798 <name>: Now unique_xmalloc_ptr.
11802 * windows-nat.c (thread_rec)
11803 (windows_nat_target::fetch_registers): Update.
11804 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
11806 <debug_registers_changed, reload_context>: Now bool.
11810 * windows-nat.c (windows_add_thread): Use new.
11811 (windows_init_thread_list, windows_delete_thread): Use delete.
11812 (get_windows_debug_event): Update.
11813 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
11814 destructor, and initializers.
11818 * windows-nat.c (struct windows_thread_info): Remove.
11819 * nat/windows-nat.h: New file.
11823 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
11824 (thread_rec, windows_add_thread, windows_delete_thread)
11825 (windows_continue): Update.
11829 * windows-nat.c (struct windows_thread_info): Remove typedef.
11830 (thread_head): Remove.
11831 (thread_list): New global.
11832 (thread_rec, windows_add_thread, windows_init_thread_list)
11833 (windows_delete_thread, windows_continue): Update.
11837 * windows-tdep.h (windows_init_abi): Add comment.
11838 (cygwin_init_abi): New declaration.
11839 * windows-tdep.c: Split signal enumeration in two, one for
11840 Windows and one for Cygwin.
11841 (windows_gdb_signal_to_target): Only deal with signal of the
11843 (cygwin_gdb_signal_to_target): New function.
11844 (windows_init_abi): Rename to windows_init_abi_common, don't set
11845 gdb_signal_to_target gdbarch method. Add new new function with
11847 (cygwin_init_abi): New function.
11848 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
11849 comment. Don't call windows_init_abi.
11850 (amd64_windows_init_abi): Add comment, call windows_init_abi.
11851 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
11852 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
11853 i386_windows_init_abi_common, don't call windows_init_abi. Add
11854 a new function of this name.
11855 (i386_cygwin_init_abi): New function.
11856 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
11861 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
11863 (dwarf2_read_gdb_index): Update.
11867 * nbsd-tdep.c: Include "objfiles.h".
11868 (nbsd_skip_solib_resolver): New.
11869 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
11873 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
11874 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
11875 with DW_LLE_base_addressx are being emitted in DWARFv5.
11876 Add the newly added kind DW_LOC_OFFSET_PAIR also.
11877 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
11882 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
11883 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
11884 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
11885 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
11886 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
11887 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
11888 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
11893 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
11894 (read_loclist_index): New function definition.
11895 (lookup_loclist_base): New function definition.
11896 (read_loclist_header): New function definition.
11897 (dwarf2_cu): Add loclist_base and loclist_header field.
11898 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
11899 (read_full_die_1): Read the value of DW_AT_loclists_base.
11900 (read_attribute_reprocess): Handle DW_FORM_loclistx.
11901 (read_attribute_value): Handle DW_FORM_loclistx.
11902 (skip_one_die): Handle DW_FORM_loclistx.
11903 (loclist_header): New structure declaration.
11904 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
11908 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
11909 constructor. Remove `addr` parameter from other constructor and
11910 add `per_cu` parameter.
11911 * dwarf2/read.c (create_partial_symtab): Update.
11916 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
11917 (partial_die_info::fixup): Inherit has_const_value.
11921 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
11922 symbols without address.
11926 * nbsd-nat.h (struct thread_info): Add forward declaration.
11927 (nbsd_nat_target::thread_alive): Add.
11928 (nbsd_nat_target::thread_name): Likewise.
11929 (nbsd_nat_target::update_thread_list): Likewise.
11930 (update_thread_list::post_attach): Likewise.
11931 (post_attach::pid_to_str): Likewise.
11932 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
11933 (nbsd_thread_lister): Add.
11934 (nbsd_nat_target::thread_alive): Likewise.
11935 (nbsd_nat_target::thread_name): Likewise.
11936 (nbsd_add_threads): Likewise.
11937 (update_thread_list::post_attach): Likewise.
11938 (nbsd_nat_target::update_thread_list): Likewise.
11939 (post_attach::pid_to_str): Likewise.
11943 * ada-valprint.c (print_variant_part): Extract the variant field.
11944 (print_field_values): Use the field as the outer value when
11949 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
11950 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
11951 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
11952 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
11953 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
11957 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
11962 * nbsd-tdep.c: Include "gdbarch.h".
11963 Define enum with NetBSD signal numbers.
11964 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
11965 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
11966 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
11967 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
11968 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
11969 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
11970 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
11971 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
11972 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
11973 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
11974 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
11975 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
11980 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
11984 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
11985 Read constant block.
11989 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
11990 (gdb_bfd_get_full_section_contents): New declaration.
11991 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
11992 * windows-tdep.c (is_linked_with_cygwin_dll): Use
11993 gdb_bfd_get_full_section_contents.
11997 * exec.c (build_section_table): Replace internal_error with
11999 (section_table_xfer_memory_partial): Likewise.
12000 * mdebugread.c (parse_partial_symbols): Likewise.
12001 * psymtab.c (lookup_partial_symbol): Likewise.
12002 * utils.c (wrap_here): Likewise.
12006 * f-lang.c (build_fortran_types): Use arch_type to initialize
12007 builtin_complex_s32 in the TYPE_CODE_ERROR case.
12011 * dwarf2/read.c (partial_die_info::read): Do not create a vector
12018 * buildsym.c (buildsym_compunit::record_line): Remove
12019 deduplication code.
12024 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
12028 * dwarf2/read.c (dwarf2_gdb_index_functions,
12029 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
12031 * psymtab.c (psym_lookup_global_symbol_language): New function.
12032 (psym_functions): Init psym_lookup_global_symbol_language with
12033 psym_lookup_global_symbol_language.
12034 * symfile-debug.c (debug_sym_quick_functions): Init
12035 lookup_global_symbol_language with NULL.
12036 * symfile.c (set_initial_language): Remove fixme comment.
12037 * symfile.h (struct quick_symbol_functions): Add
12038 lookup_global_symbol_language.
12039 * symtab.c (find_quick_global_symbol_language): New function.
12040 (find_main_name): Use find_quick_global_symbol_language.
12044 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
12048 * buildsym.c (record_line): Fix undefined behavior and preserve
12053 * buildsym.c (record_line): Fix the resizing condition.
12057 * value.h (value_literal_complex): Add comment.
12058 * valops.c (value_literal_complex): Refer to value.h.
12062 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
12063 (scalar_type): New rule, from typebase.
12064 (typebase): Use scalar_type. Recognize complex types.
12065 (field_name): Handle FLOAT_KEYWORD.
12066 (ident_tokens): Add _Complex and __complex__.
12071 * valarith.c (promotion_type, complex_binop): New functions.
12072 (scalar_binop): Handle complex numbers. Use promotion_type.
12073 (value_pos, value_neg, value_complement): Handle complex numbers.
12077 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
12078 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
12079 (parse_number): Handle complex numbers.
12083 * c-valprint.c (c_decorations): Change complex suffix to "i".
12087 * valprint.c (generic_value_print_complex): Use accessors.
12088 * value.h (value_real_part, value_imaginary_part): Declare.
12089 * valops.c (value_real_part, value_imaginary_part): New
12091 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
12095 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
12096 (read_range_type): Update.
12097 * mdebugread.c (basic_type): Update.
12098 * go-lang.c (build_go_types): Use init_complex_type.
12099 * gdbtypes.h (struct main_type) <complex_type>: New member.
12100 (init_complex_type): Update.
12101 (arch_complex_type): Don't declare.
12102 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
12103 Make name if none given. Use alloc_type_copy. Look for cached
12105 (arch_complex_type): Remove.
12106 (gdbtypes_post_init): Use init_complex_type.
12107 * f-lang.c (build_fortran_types): Use init_complex_type.
12108 * dwarf2/read.c (read_base_type): Update.
12109 * d-lang.c (build_d_types): Use init_complex_type.
12110 * ctfread.c (read_base_type): Update.
12114 * infrun.c (stop_all_threads): Update assertion, plus when
12115 stopping threads, take into account that we might be trying
12116 to stop an all-stop target.
12117 (stop_waiting): Call 'stop_all_threads' if there exists a
12122 * target.h (exists_non_stop_target): New function declaration.
12123 * target.c (exists_non_stop_target): New function.
12128 * eval.c (is_integral_or_integral_reference): New function.
12129 (evaluate_subexp_standard): Allow integer references in
12130 pointer arithmetic.
12134 * remote.c (remote_target::remote_parse_stop_reply): Remove the
12135 check for no ptid in the stop reply when the target is non-stop.
12139 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
12140 "name" parameter to rvalue reference. Initialize m_name_holder.
12141 <lookup_name_info>: New overloads.
12142 <name>: Return gdb::string_view.
12143 <c_str>: New method.
12144 <make_ignore_params>: Update.
12145 <search_name_hash>: Update.
12146 <language_lookup_name>: Return const char *.
12147 <m_name>: Change type.
12148 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
12149 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
12150 (lookup_name_info::match_any): Update.
12151 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
12153 * minsyms.c (linkage_name_str): Update.
12154 * language.c (default_symbol_name_matcher): Update.
12155 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
12157 * ada-lang.c (ada_fold_name): Change parameter to string_view.
12158 (ada_lookup_name_info::ada_lookup_name_info): Update.
12159 (literal_symbol_name_matcher): Update.
12163 * psymtab.c (psymtab_search_name): Remove function.
12164 (psym_lookup_symbol): Create search name and lookup name here.
12165 (lookup_partial_symbol): Remove "name" parameter; add
12167 (psym_expand_symtabs_for_function): Update.
12172 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
12176 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
12181 * features/riscv/32bit-csr.xml: Regenerated.
12182 * features/riscv/64bit-csr.xml: Regenerated.
12186 * ada-valprint.c (print_variant_part): Update.
12187 * ada-lang.h (ada_which_variant_applies): Update.
12188 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
12189 outer_valaddr parameters; replace with "outer" value parameter.
12190 (to_fixed_variant_branch_type): Update.
12194 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
12195 <list>. Remove inclusion of observable.h.
12196 (PPC_DEBUG_CURRENT_VERSION): Move up define.
12197 (struct arch_lwp_info): New struct.
12198 (class ppc_linux_dreg_interface): New class.
12199 (struct ppc_linux_process_info): New struct.
12200 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
12201 <low_new_clone, low_forget_process, low_prepare_to_resume>
12202 <copy_thread_dreg_state, mark_thread_stale>
12203 <mark_debug_registers_changed, register_hw_breakpoint>
12204 <clear_hw_breakpoint, register_wp, clear_wp>
12205 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
12206 <num_memory_accesses, get_trigger_type>
12207 <create_watchpoint_request, hwdebug_point_cmp>
12208 <init_arch_lwp_info, get_arch_lwp_info>
12209 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
12211 <struct ptid_hash>: New inner struct.
12212 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
12214 (saved_dabr_value, hwdebug_info, max_slots_number)
12215 (struct hw_break_tuple, struct thread_points, ppc_threads)
12216 (have_ptrace_hwdebug_interface)
12217 (hwdebug_find_thread_points_by_tid)
12218 (hwdebug_insert_point, hwdebug_remove_point): Remove.
12219 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
12220 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
12221 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
12222 use m_dreg_interface.
12223 (hwdebug_point_cmp): Change to...
12224 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
12225 reference arguments instead of pointers.
12226 (ppc_linux_nat_target::ranged_break_num_registers): Use
12228 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
12229 m_dreg_interface. Call register_hw_breakpoint.
12230 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
12231 m_dreg_interface. Call clear_hw_breakpoint.
12232 (get_trigger_type): Change to...
12233 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
12235 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
12236 use m_dreg_interface. Call register_hw_breakpoint.
12237 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
12238 use m_dreg_interface. Call clear_hw_breakpoint.
12239 (can_use_watchpoint_cond_accel): Change to...
12240 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
12241 method. Update comment, use m_dreg_interface and
12243 (calculate_dvc): Change to...
12244 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
12246 (num_memory_accesses): Change to...
12247 (ppc_linux_nat_target::num_memory_accesses): ...this method.
12248 (check_condition): Change to...
12249 (ppc_linux_nat_target::check_condition): ...this method.
12250 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
12251 comment, use m_dreg_interface.
12252 (create_watchpoint_request): Change to...
12253 (ppc_linux_nat_target::create_watchpoint_request): ...this
12254 method. Use m_dreg_interface.
12255 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
12256 m_dreg_interface. Call register_hw_breakpoint or register_wp.
12257 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
12258 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
12259 (ppc_linux_nat_target::low_forget_process)
12260 (ppc_linux_nat_target::low_new_fork)
12261 (ppc_linux_nat_target::low_new_clone)
12262 (ppc_linux_nat_target::low_delete_thread)
12263 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
12264 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
12265 only call mark_thread_stale.
12266 (ppc_linux_thread_exit): Remove.
12267 (ppc_linux_nat_target::stopped_data_address): Change to...
12268 (ppc_linux_nat_target::low_stopped_data_address): This. Add
12269 comment, use m_dreg_interface and m_thread_hw_breakpoints.
12270 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
12271 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
12272 comment. Call low_stopped_data_address.
12273 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
12275 (ppc_linux_nat_target::masked_watch_num_registers): Use
12277 (ppc_linux_nat_target::copy_thread_dreg_state)
12278 (ppc_linux_nat_target::mark_thread_stale)
12279 (ppc_linux_nat_target::mark_debug_registers_changed)
12280 (ppc_linux_nat_target::register_hw_breakpoint)
12281 (ppc_linux_nat_target::clear_hw_breakpoint)
12282 (ppc_linux_nat_target::register_wp)
12283 (ppc_linux_nat_target::clear_wp)
12284 (ppc_linux_nat_target::init_arch_lwp_info)
12285 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
12286 (_initialize_ppc_linux_nat): Remove observer callback.
12290 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
12291 (ppc_linux_nat_target::auxv_parse)
12292 (ppc_linux_nat_target::read_description)
12293 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
12298 * linux-nat.h (low_new_clone): New method.
12299 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
12303 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
12304 (dbx_expand_psymtab): ... this.
12305 (start_psymtab): Update.
12306 * mdebugread.c (psymtab_to_symtab_1): Rename to...
12307 (mdebug_expand_psymtab): ... this.
12308 (parse_partial_symbols): Update.
12309 (new_psymtab): Update.
12310 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
12311 (xcoff_expand_psymtab): ... this.
12312 (xcoff_start_psymtab): Update.
12316 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
12317 <expand_dependencies>: ... this.
12318 * psymtab.c (partial_symtab::read_dependencies): Rename to...
12319 (partial_symtab::expand_dependencies): ... this.
12320 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
12322 (dwarf2_psymtab::expand_psymtab): Update.
12323 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
12324 * mdebugread.c (psymtab_to_symtab_1): Update.
12325 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
12329 * psympriv.h (discard_psymtab): Remove.
12330 * dbxread.c (dbx_end_psymtab): Update.
12331 * xcoffread.c (xcoff_end_psymtab): Update.
12335 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
12340 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
12344 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
12348 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
12352 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
12353 (mark_common_block_symbol_computed, read_tag_string_type)
12354 (attr_to_dynamic_prop, read_subrange_type): Update.
12355 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
12356 to be methods on struct attribute.
12357 (skip_one_die, process_imported_unit_die, read_namespace_alias)
12358 (read_call_site_scope, partial_die_info::read)
12359 (partial_die_info::read, lookup_die_type, follow_die_ref):
12361 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
12362 from dwarf2_get_ref_die_offset.
12363 (attribute::constant_value): New method, from
12364 dwarf2_get_attr_constant_value.
12365 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
12367 <constant_value>: New method.
12371 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
12372 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
12373 (dwarf_type_encoding_name): Move to stringify.c.
12374 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
12375 * dwarf2/stringify.c: New file.
12376 * dwarf2/stringify.h: New file.
12380 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
12385 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
12387 * dwarf2/read.c (lookup_addr_base): Move to die.h.
12388 (lookup_ranges_base): Likewise.
12389 (read_cutu_die_from_dwo, read_full_die_1): Update.
12393 * dwarf2/read.c (read_import_statement, read_file_scope)
12394 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
12395 (read_lexical_block_scope, read_call_site_scope)
12396 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
12397 (handle_struct_member_die, process_structure_scope)
12398 (update_enumeration_type_from_children)
12399 (process_enumeration_scope, read_array_type, read_common_block)
12400 (read_namespace, read_module, read_subroutine_type): Update.
12401 (sibling_die): Remove.
12405 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
12406 (build_type_psymtabs_reader, read_structure_type)
12407 (read_enumeration_type, read_full_die_1): Update.
12408 (dwarf2_attr_no_follow): Move to die.h.
12409 * dwarf2/die.h (struct die_info) <attr>: New method.
12413 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
12414 <base_address>: Now an optional.
12415 (dwarf2_find_base_address, dwarf2_rnglists_process)
12416 (dwarf2_ranges_process, fill_in_loclist_baton)
12417 (dwarf2_symbol_mark_computed): Update.
12421 * dwarf2/read.c (struct die_info): Move to die.h.
12422 * dwarf2/die.h: New file.
12426 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
12428 (dwarf2_statement_list_fits_in_line_number_section_complaint):
12429 Move to line-header.c.
12430 (read_checked_initial_length_and_offset, read_formatted_entries):
12432 (dwarf_decode_line_header): Split into two.
12433 * dwarf2/line-header.c
12434 (dwarf2_statement_list_fits_in_line_number_section_complaint):
12436 (read_checked_initial_length_and_offset, read_formatted_entries):
12438 (dwarf_decode_line_header): New function, split from read.c.
12442 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
12444 * dwarf2/read.c (read_attribute_value): Update.
12445 (dwarf2_per_objfile::read_line_string): Rename from
12446 read_indirect_line_string.
12447 (read_formatted_entries): Update.
12451 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
12456 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
12458 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
12459 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
12464 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
12465 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
12466 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
12467 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
12471 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
12472 file_names_size, file_full_name, file_file_name>: Use const.
12473 <file_name_at, file_names>: Add const overload.
12474 * dwarf2/line-header.c (line_header::file_file_name)
12475 (line_header::file_full_name): Update.
12479 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
12480 (macro_start_file, consume_improper_spaces)
12481 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
12482 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
12483 (dwarf_decode_macros): Move to macro.c.
12484 * dwarf2/macro.c: New file.
12485 * dwarf2/macro.h: New file.
12486 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
12490 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
12492 * dwarf2/section.c: New method. From
12493 read_indirect_string_at_offset_from.
12494 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
12495 (read_indirect_string_at_offset_from): Move to section.c.
12496 (read_indirect_string_at_offset): Rewrite.
12497 (read_indirect_line_string_at_offset): Remove.
12498 (read_indirect_string, read_indirect_line_string)
12499 (dwarf_decode_macro_bytes): Update.
12503 * dwarf2/section.h (struct dwarf2_section_info)
12504 <overload_complaint>: Declare.
12505 (dwarf2_section_buffer_overflow_complaint): Don't declare.
12506 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
12507 Rename from dwarf2_section_buffer_overflow_complaint.
12508 * dwarf2/read.c (skip_one_die, partial_die_info::read)
12509 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
12513 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
12515 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
12517 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
12522 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
12526 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
12528 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
12530 (dwarf_decode_macros): Update.
12534 * dwarf2/read.c (read_attribute_value): Update.
12535 (read_indirect_string_from_dwz): Move to dwz.c; change into
12537 (dwarf_decode_macro_bytes): Update.
12538 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
12539 * dwarf2/dwz.c: New file.
12540 * Makefile.in (COMMON_SFILES): Add dwz.c.
12544 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
12545 * dwarf2/read.c: Add include.
12546 * dwarf2/index-write.c: Add include.
12547 * dwarf2/index-cache.c: Add include.
12548 * dwarf2/dwz.h: New file.
12552 * compile/compile-object-load.c (get_out_value_type): Mention
12553 correct symbol name in error message.
12557 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
12561 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
12562 * symmisc.c (dump_symtab_1): Print user and includes fields.
12563 (maintenance_info_symtabs): Same.
12568 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
12569 (riscv_regcache_cooked_write): New function.
12570 (riscv_push_dummy_call): Use new function.
12571 (riscv_return_value): Likewise.
12575 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
12576 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
12577 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
12578 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
12579 * infrun.c (follow_fork): Likewise.
12580 (follow_fork_inferior): Likewise.
12581 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
12582 * linux-nat.h (class linux_nat_target): Likewise.
12583 * remote.c (class remote_target) <follow_fork>: Likewise.
12584 (remote_target::follow_fork): Likewise.
12585 * target-delegates.c: Re-generate.
12586 * target.c (default_follow_fork): Likewise.
12587 (target_follow_fork): Likewise.
12588 * target.h (struct target_ops) <follow_fork>: Likewise.
12589 (target_follow_fork): Likewise.
12593 * psymtab.c (maintenance_info_psymtabs): Print user field.
12597 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
12599 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
12604 * ptrace.m4: Don't check for ptrace declaration.
12605 * config.in: Re-generate.
12606 * configure: Re-generate.
12607 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
12612 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
12614 * i386-bsd-nat.c (gdb_ptrace): Likewise.
12615 * sparc-nat.c (gdb_ptrace): Likewise.
12616 * x86-bsd-nat.c (gdb_ptrace): Likewise.
12620 * c-exp.y (lex_one_token): Fix assert.
12624 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
12625 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
12630 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
12634 * ada-valprint.c (print_variant_part): Remove parameters; switch
12635 to value-based API.
12636 (print_field_values): Likewise.
12637 (ada_val_print_struct_union): Likewise.
12638 (ada_value_print_1): Update.
12642 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
12643 nbsd_nat_target instead of inf_ptrace_target.
12644 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
12649 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
12650 it to the ptrace call.
12651 * (store_registers): Likewise.
12655 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
12656 it to the ptrace call.
12657 * (store_registers): Likewise.
12661 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
12662 valid, fetch vg value from ptrace.
12665 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
12666 * inf-ptrace.c: Likewise.
12667 * (gdb_ptrace): Add.
12668 * (inf_ptrace_target::resume): Update.
12669 * (inf_ptrace_target::xfer_partial): Likewise.
12670 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
12671 * (inf_ptrace_peek_poke): Update.
12675 * x86-bsd-nat.c (gdb_ptrace): New.
12676 * (x86bsd_dr_set): Add new argument `ptid'.
12677 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
12678 x86bsd_dr_set_addr): Update.
12682 * remote.c (remote_target::process_stop_reply): Handle events for
12683 all threads differently.
12687 * completer.c (completion_tracker::remove_completion): Define new
12689 * completer.h (completion_tracker::remove_completion): Declare new
12691 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
12692 when adding a C++ function symbol.
12696 * completer.c (completion_tracker::completion_hash_entry): Define
12698 (advance_to_filename_complete_word_point): Call
12699 recompute_lowest_common_denominator.
12700 (completion_tracker::completion_tracker): Call discard_completions
12701 to setup the hash table.
12702 (completion_tracker::discard_completions): Allow for being called
12703 from the constructor, pass new equal function, and element deleter
12704 when constructing the hash table. Initialise new class member
12706 (completion_tracker::maybe_add_completion): Remove use of
12707 m_entries_vec, and store more information into m_entries_hash.
12708 (completion_tracker::recompute_lcd_visitor): New function, most
12709 content taken from...
12710 (completion_tracker::recompute_lowest_common_denominator):
12711 ...here, this now just visits each item in the hash calling the
12713 (completion_tracker::build_completion_result): Remove use of
12714 m_entries_vec, call recompute_lowest_common_denominator.
12715 * completer.h (completion_tracker::have_completions): Remove use
12717 (completion_tracker::completion_hash_entry): Declare new class.
12718 (completion_tracker::recompute_lowest_common_denominator): Change
12719 function signature.
12720 (completion_tracker::recompute_lcd_visitor): Declare new function.
12721 (completion_tracker::m_entries_vec): Delete.
12722 (completion_tracker::m_entries_hash): Initialize to NULL.
12723 (completion_tracker::m_lowest_common_denominator_valid): New
12725 (completion_tracker::m_lowest_common_denominator_max_length): New
12730 * regformats/regdef.h: Put reg in gdb namespace.
12734 * i386-bsd-nat.c (gdb_ptrace): New.
12735 * (i386bsd_fetch_inferior_registers,
12736 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
12737 * (i386bsd_fetch_inferior_registers,
12738 i386bsd_store_inferior_registers) Use gdb_ptrace.
12742 * amd64-bsd-nat.c (gdb_ptrace): New.
12743 * (amd64bsd_fetch_inferior_registers,
12744 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
12745 * (amd64bsd_fetch_inferior_registers,
12746 amd64bsd_store_inferior_registers) Use gdb_ptrace.
12750 * user-regs.c (user_reg::read): Rename to...
12751 (user_reg::xread): ...this.
12752 * (append_user_reg): Rename argument `read' to `xread'.
12753 * (user_reg_add_builtin): Likewise.
12754 * (user_reg_add): Likewise.
12755 * (value_of_user_reg): Likewise.
12759 * sparc-nat.c (gdb_ptrace): New.
12760 * sparc-nat.c (sparc_fetch_inferior_registers)
12761 (sparc_store_inferior_registers) Remove obsolete comment.
12762 * sparc-nat.c (sparc_fetch_inferior_registers)
12763 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
12764 * sparc-nat.c (sparc_fetch_inferior_registers)
12765 (sparc_store_inferior_registers) Use gdb_ptrace.
12769 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
12770 it to the ptrace call.
12771 * sh-nbsd-nat.c (store_registers): Likewise.
12775 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
12776 nbsd_nat_target instead of inf_ptrace_target.
12777 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
12782 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
12786 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
12788 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
12793 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
12795 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
12797 (process_imported_unit_die): Skip import of c++ CUs.
12801 * p-valprint.c (pascal_object_print_value): Initialize
12807 * Makefile.in: Add arch/arc.o
12808 * configure.tgt: Likewise.
12809 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
12810 (_initialize_arc_tdep): Don't initialize old target descriptions.
12811 (arc_read_description): New function to cache target descriptions.
12812 * arc-tdep.h (arc_read_description): Add proto type.
12813 * arch/arc.c: New file.
12814 * arch/arc.h: Likewise.
12815 * features/Makefile: Replace old target descriptions with new.
12816 * features/arc-arcompact.c: Remove.
12817 * features/arc-arcompact.xml: Likewise.
12818 * features/arc-v2.c: Likewise
12819 * features/arc-v2.xml: Likewise
12820 * features/arc/aux-arcompact.xml: New file.
12821 * features/arc/aux-v2.xml: Likewise.
12822 * features/arc/core-arcompact.xml: Likewise.
12823 * features/arc/core-v2.xml: Likewise.
12824 * features/arc/aux-arcompact.c: Generate.
12825 * features/arc/aux-v2.c: Likewise.
12826 * features/arc/core-arcompact.c: Likewise.
12827 * features/arc/core-v2.c: Likewise.
12828 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
12833 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
12834 putting value into bcache.
12839 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
12841 (amd64_windows_init_abi_common): ... this. Don't set size of
12843 (amd64_windows_init_abi): New function.
12844 (amd64_cygwin_init_abi): New function.
12845 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
12847 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
12852 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
12853 * windows-tdep.c (CYGWIN_DLL_NAME): New.
12854 (pe_import_directory_entry): New struct type.
12855 (is_linked_with_cygwin_dll): New function.
12856 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
12857 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
12858 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
12862 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
12863 i386_cygwin_core_osabi_sniffer.
12867 * i386-cygwin-tdep.c: Rename to...
12868 * i386-windows-tdep.c: ... this.
12869 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
12870 i386-windows-tdep.c.
12871 * configure.tgt: Likewise.
12875 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
12876 * osabi.c (gdb_osabi_names): Add "Windows".
12877 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
12878 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
12879 (i386_cygwin_core_osabi_sniffer): New function, extracted from
12880 i386_cygwin_osabi_sniffer.
12881 (_initialize_i386_cygwin_tdep): Register OS ABI
12882 GDB_OSABI_WINDOWS for i386.
12883 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
12884 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
12885 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
12887 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
12888 when the target matches '*-*-mingw*'.
12892 * defs.h (enum gdb_osabi): Move to...
12893 * osabi.h (enum gdb_osabi): ... here.
12894 * gdbarch.sh: Include osabi.h in gdbarch.h.
12895 * gdbarch.h: Re-generate.
12899 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
12901 (_initialize_amd64_windows_tdep): Register osabi sniffer.
12905 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
12907 (c_type_print_modifier): Likewise. Add "language" parameter.
12908 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
12909 (c_type_print_base_1): Update.
12910 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
12912 * type-stack.c (type_stack::insert): Handle tp_atomic and
12914 (type_stack::follow_type_instance_flags): Likewise.
12915 (type_stack::follow_types): Likewise. Merge type-following code.
12916 * c-exp.y (RESTRICT, ATOMIC): New tokens.
12917 (space_identifier, cv_with_space_id)
12918 (const_or_volatile_or_space_identifier_noopt)
12919 (const_or_volatile_or_space_identifier): Remove.
12920 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
12922 (ptr_operator, typebase): Update.
12923 (enum token_flag) <FLAG_C>: New constant.
12924 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
12926 (lex_one_token): Handle FLAG_C.
12930 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
12931 it to the ptrace call.
12932 * m68k-bsd-nat.c (store_registers): Likewise.
12936 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
12938 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
12939 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
12940 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
12944 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
12945 nbsd_nat_target instead of inf_ptrace_target.
12946 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
12951 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
12956 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
12957 it to the ptrace call.
12958 * alpha-bsd-nat.c (store_registers): Likewise.
12962 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
12964 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
12965 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
12966 fill_fpregset): Likewise.
12970 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
12971 nbsd_nat_target instead of inf_ptrace_target.
12972 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
12977 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
12982 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
12983 it to the ptrace call.
12984 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
12985 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
12986 * arm-nbsd-nat.c (store_register): Likewise.
12987 * arm-nbsd-nat.c (store_regs): Likewise.
12988 * arm-nbsd-nat.c (store_fp_register): Likewise.
12989 * arm-nbsd-nat.c (store_fp_regs): Likewise.
12993 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
12994 nbsd_nat_target instead of inf_ptrace_target.
12995 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
13000 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
13001 it to the ptrace call.
13002 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
13006 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
13007 it to the ptrace call.
13008 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
13012 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
13014 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
13018 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
13019 instead of inf_ptrace_target.
13020 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
13025 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
13030 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
13035 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
13040 * value.h (val_print): Don't declare.
13041 * valprint.h (val_print_array_elements)
13042 (val_print_scalar_formatted, generic_val_print): Don't declare.
13043 * valprint.c (generic_val_print_array): Take a struct value.
13044 (generic_val_print_ptr, generic_val_print_memberptr)
13045 (generic_val_print_bool, generic_val_print_int)
13046 (generic_val_print_char, generic_val_print_complex)
13047 (generic_val_print): Remove.
13048 (generic_value_print): Update.
13049 (do_val_print): Remove unused parameters. Don't call
13051 (val_print): Remove.
13052 (common_val_print): Update. Don't call value_check_printable.
13053 (val_print_scalar_formatted, val_print_array_elements): Remove.
13054 * rust-lang.c (rust_val_print): Remove.
13055 (rust_language_defn): Update.
13056 * p-valprint.c (pascal_val_print): Remove.
13057 (pascal_value_print_inner): Update.
13058 (pascal_object_print_val_fields, pascal_object_print_val):
13060 (pascal_object_print_static_field): Update.
13061 * p-lang.h (pascal_val_print): Don't declare.
13062 * p-lang.c (pascal_language_defn): Update.
13063 * opencl-lang.c (opencl_language_defn): Update.
13064 * objc-lang.c (objc_language_defn): Update.
13065 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
13066 * m2-lang.h (m2_val_print): Don't declare.
13067 * m2-lang.c (m2_language_defn): Update.
13068 * language.h (struct language_defn) <la_val_print>: Remove.
13069 * language.c (unk_lang_value_print_inner): Rename. Change
13071 (unknown_language_defn, auto_language_defn): Update.
13072 * go-valprint.c (go_val_print): Remove.
13073 * go-lang.h (go_val_print): Don't declare.
13074 * go-lang.c (go_language_defn): Update.
13075 * f-valprint.c (f_val_print): Remove.
13076 * f-lang.h (f_value_print): Don't declare.
13077 * f-lang.c (f_language_defn): Update.
13078 * d-valprint.c (d_val_print): Remove.
13079 * d-lang.h (d_value_print): Don't declare.
13080 * d-lang.c (d_language_defn): Update.
13081 * cp-valprint.c (cp_print_value_fields)
13082 (cp_print_value_fields_rtti, cp_print_value): Remove.
13083 (cp_print_static_field): Update.
13084 * c-valprint.c (c_val_print_array, c_val_print_ptr)
13085 (c_val_print_struct, c_val_print_union, c_val_print_int)
13086 (c_val_print_memberptr, c_val_print): Remove.
13087 * c-lang.h (c_val_print_array, cp_print_value_fields)
13088 (cp_print_value_fields_rtti): Don't declare.
13089 * c-lang.c (c_language_defn, cplus_language_defn)
13090 (asm_language_defn, minimal_language_defn): Update.
13091 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
13092 (ada_val_print_enum): Take a struct value.
13093 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
13094 (ada_val_print): Remove.
13095 (ada_value_print_1): Update.
13096 (printable_val_type): Remove.
13097 * ada-lang.h (ada_val_print): Don't declare.
13098 * ada-lang.c (ada_language_defn): Update.
13102 * valprint.c (do_val_print): Update.
13103 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
13105 (value_to_value_object_no_release): Declare.
13106 * python/py-value.c (value_to_value_object_no_release): New
13108 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
13110 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
13112 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
13114 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
13116 (gdbscm_apply_val_pretty_printer): Take a struct value.
13117 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
13119 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
13121 * extension-priv.h (struct extension_language_ops)
13122 <apply_val_pretty_printer>: Take a struct value.
13123 * cp-valprint.c (cp_print_value): Create a struct value.
13124 (cp_print_value): Update.
13128 * ada-valprint.c (print_field_values): Call common_val_print.
13132 * ada-valprint.c (val_print_packed_array_elements): Remove
13133 bitoffset and val parameters. Call common_val_print.
13134 (ada_val_print_string): Remove offset, address, and original_value
13136 (ada_val_print_array): Update.
13137 (ada_value_print_array): New function.
13138 (ada_value_print_1): Call it.
13142 * ada-valprint.c (ada_value_print): Use common_val_print.
13146 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
13150 * ada-valprint.c (ada_value_print_num): New function.
13151 (ada_value_print_1): Use it.
13155 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
13159 * ada-valprint.c (ada_value_print_ptr): New function.
13160 (ada_value_print_1): Use it.
13164 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
13165 call common_val_print.
13166 (ada_val_print_1): Update.
13167 (ada_value_print_1): New function.
13168 (ada_value_print_inner): Rewrite.
13172 * cp-valprint.c (cp_print_value_fields): Update.
13173 (cp_print_value): New function.
13177 * m2-valprint.c (m2_value_print_inner): Use
13178 cp_print_value_fields.
13179 * cp-valprint.c (cp_print_value_fields): New function.
13180 * c-valprint.c (c_value_print_struct): New function.
13181 (c_value_print_inner): Use c_value_print_struct.
13182 * c-lang.h (cp_print_value_fields): Declare.
13186 * c-valprint.c (c_value_print_array): New function.
13187 (c_value_print_inner): Use it.
13191 * c-valprint.c (c_value_print_memberptr): New function.
13192 (c_value_print_inner): Use it.
13196 * c-valprint.c (c_value_print_int): New function.
13197 (c_value_print_inner): Use it.
13201 * c-valprint.c (c_value_print_ptr): New function.
13202 (c_value_print_inner): Use it.
13206 * c-valprint.c (c_value_print_inner): Rewrite.
13210 * valprint.c (generic_value_print_complex): New function.
13211 (generic_value_print): Use it.
13215 * valprint.c (generic_val_print_float): Don't call
13216 val_print_scalar_formatted.
13217 (generic_val_print, generic_value_print): Update.
13221 * valprint.c (generic_value_print_char): New function
13222 (generic_value_print): Use it.
13226 * valprint.c (generic_value_print_int): New function.
13227 (generic_value_print): Use it.
13231 * valprint.c (generic_value_print_bool): New function.
13232 (generic_value_print): Use it.
13236 * valprint.c (generic_val_print_func): Simplify.
13237 (generic_val_print, generic_value_print): Update.
13241 * valprint.c (generic_val_print_flags): Remove.
13242 (generic_val_print, generic_value_print): Update.
13243 (val_print_type_code_flags): Add original_value parameter.
13247 * valprint.c (generic_val_print): Update.
13248 (generic_value_print): Update.
13249 * valprint.c (generic_val_print_enum): Don't call
13250 val_print_scalar_formatted.
13254 * valprint.c (generic_value_print): Call generic_value_print_ptr.
13255 * valprint.c (generic_value_print_ptr): New function.
13259 * valprint.c (generic_value_print): Rewrite.
13263 * p-valprint.c (pascal_object_print_value_fields)
13264 (pascal_object_print_value): New functions.
13268 * p-valprint.c (pascal_value_print_inner): Rewrite.
13272 * f-valprint.c (f_value_print_innner): Rewrite.
13276 * m2-valprint.c (m2_print_unbounded_array): New overload.
13277 (m2_print_unbounded_array): Update.
13278 (m2_print_array_contents): Take a struct value.
13279 (m2_value_print_inner): Rewrite.
13283 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
13284 (d_value_print_inner): New function.
13285 * d-lang.h (d_value_print_inner): Declare.
13286 * d-lang.c (d_language_defn): Use d_value_print_inner.
13290 * go-valprint.c (go_value_print_inner): New function.
13291 * go-lang.h (go_value_print_inner): Declare.
13292 * go-lang.c (go_language_defn): Use go_value_print_inner.
13296 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
13298 (rust_val_print): Rewrite.
13299 (rust_value_print_inner): New function, from rust_val_print.
13300 (rust_language_defn): Use rust_value_print_inner.
13304 * ada-valprint.c (ada_value_print_inner): New function.
13305 * ada-lang.h (ada_value_print_inner): Declare.
13306 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
13310 * f-valprint.c (f_value_print_innner): New function.
13311 * f-lang.h (f_value_print_innner): Declare.
13312 * f-lang.c (f_language_defn): Use f_value_print_innner.
13316 * p-valprint.c (pascal_value_print_inner): New function.
13317 * p-lang.h (pascal_value_print_inner): Declare.
13318 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
13322 * m2-valprint.c (m2_value_print_inner): New function.
13323 * m2-lang.h (m2_value_print_inner): Declare.
13324 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
13328 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
13329 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
13330 * c-valprint.c (c_value_print_inner): New function.
13331 * c-lang.h (c_value_print_inner): Declare.
13332 * c-lang.c (c_language_defn, cplus_language_defn)
13333 (asm_language_defn, minimal_language_defn): Use
13334 c_value_print_inner.
13338 * p-valprint.c (pascal_object_print_value_fields): Now static.
13339 * p-lang.h (pascal_object_print_value_fields): Don't declare.
13343 * c-valprint.c (c_val_print_array): Simplify.
13347 * valprint.c (value_print_array_elements): New function.
13348 * valprint.h (value_print_array_elements): Declare.
13352 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
13353 * mips-tdep.c (mips_print_register): Use
13354 value_print_scalar_formatted.
13358 * valprint.h (value_print_scalar_formatted): Declare.
13359 * valprint.c (value_print_scalar_formatted): New function.
13363 * valprint.h (generic_value_print): Declare.
13364 * valprint.c (generic_value_print): New function.
13368 * valprint.c (do_val_print): Call la_value_print_inner, if
13370 * rust-lang.c (rust_language_defn): Update.
13371 * p-lang.c (pascal_language_defn): Update.
13372 * opencl-lang.c (opencl_language_defn): Update.
13373 * objc-lang.c (objc_language_defn): Update.
13374 * m2-lang.c (m2_language_defn): Update.
13375 * language.h (struct language_defn) <la_value_print_inner>: New
13377 * language.c (unknown_language_defn, auto_language_defn): Update.
13378 * go-lang.c (go_language_defn): Update.
13379 * f-lang.c (f_language_defn): Update.
13380 * d-lang.c (d_language_defn): Update.
13381 * c-lang.c (c_language_defn, cplus_language_defn)
13382 (asm_language_defn, minimal_language_defn): Update.
13383 * ada-lang.c (ada_language_defn): Update.
13387 * c-valprint.c (c_value_print): Use common_val_print.
13391 * cp-valprint.c (cp_print_static_field): Use common_val_print.
13395 * f-valprint.c (f77_print_array_1, f_val_print): Use
13400 * riscv-tdep.c (riscv_print_one_register_info): Use
13405 * mi/mi-main.c (output_register): Use common_val_print.
13409 * infcmd.c (default_print_one_register_info): Use
13414 * valprint.h (common_val_print_checked): Declare.
13415 * valprint.c (common_val_print_checked): New function.
13416 * stack.c (print_frame_arg): Use common_val_print_checked.
13420 * valprint.c (do_val_print): New function, from val_print.
13421 (val_print): Use do_val_print.
13422 (common_val_print): Use do_val_print.
13426 * valprint.c (value_print): Use scoped_value_mark.
13431 * psymtab.c (partial_symtab::partial_symtab): Don't set
13432 globals_offset and statics_offset. Push element onto
13433 current_global_psymbols and current_static_psymbols stacks.
13434 (concat): New function.
13435 (end_psymtab_common): Set globals_offset and statics_offset. Pop
13436 element from current_global_psymbols and current_static_psymbols
13437 stacks. Concat popped elements to global_psymbols and
13439 (add_psymbol_to_list): Use current_global_psymbols and
13440 current_static_psymbols stacks.
13441 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
13442 current_static_psymbols fields.
13446 * corelow.c (sniff_core_bfd): Remove.
13447 (class core_target) <m_core_vec>: Remove.
13448 (core_target::core_target): Update.
13449 (core_file_fns): Remove.
13450 (deprecated_add_core_fns): Remove.
13451 (default_core_sniffer): Remove.
13452 (sniff_core_bfd): Remove.
13453 (default_check_format): Remove.
13454 (gdb_check_format): Remove.
13455 (core_target_open): Update.
13456 (core_target::get_core_register_section): Update.
13457 (get_core_registers_cb): Update.
13458 (core_target::fetch_registers): Update.
13459 * gdbcore.h (struct core_fns): Remove.
13460 (deprecated_add_core_fns): Remove.
13461 (default_core_sniffer): Remove.
13462 (default_check_format): Remove.
13466 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
13468 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
13472 * remote.c (remote_target::download_tracepoint)
13473 (remote_target::enable_tracepoint)
13474 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
13475 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
13480 * symfile-mem.c: Update CORE_ADDR size assert.
13484 * selftest.m4: Move to gdbsupport/.
13485 * acinclude.m4: Update path to selftest.m4.
13489 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
13490 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
13491 gdbarch-selfselftests.c and selftest-arch.c.
13492 (SUBDIR_UNITTESTS_OBS): Rename to...
13493 (SELFTESTS_OBS): ... this.
13494 (COMMON_SFILES): Remove disasm-selftests.c and
13495 gdbarch-selftests.c.
13496 * configure.ac: Don't add selftest-arch.{c,o} to
13498 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
13499 preprocessor conditions.
13503 * configure.ac: Don't source bfd/development.sh.
13504 * selftest.m4: Modify comment.
13505 * configure: Re-generate.
13509 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
13510 not "true" or "false".
13511 * configure: Re-generate.
13515 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
13516 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
13517 renamed to arm_nbsd_supply_gregset.
13518 (fetch_register): Update to call arm_nbsd_supply_gregset.
13519 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
13520 (arm_netbsd_nat_target::fetch_registers): Update.
13521 (fetch_elfcore_registers): Removed.
13522 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
13523 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
13524 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
13525 not require NetBSD system headers.
13526 (arm_nbsd_regset): New struct.
13527 (arm_nbsd_iterate_over_regset_sections): New function.
13528 (arm_netbsd_init_abi_common): Updated to call
13529 set_gdbarch_iterate_over_regset_sections.
13530 * arm-nbsd-tdep.h: New file.
13534 * symtab.c (find_pc_sect_line): Add check which prevents infinite
13539 * configure: Re-generate.
13543 * ada-typeprint.c (print_choices): Fix comment.
13547 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
13548 previous item in the list, when the list has no items.
13552 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
13553 PROP_LOCLIST handling code.
13557 * buildsym-legacy.c (record_line): Pass extra parameter to
13559 * buildsym.c (buildsym_compunit::record_line): Take an extra
13560 parameter, reduce duplication in the line table, and record the
13561 is_stmt flag in the line table.
13562 * buildsym.h (buildsym_compunit::record_line): Add extra
13564 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
13565 non-statement lines.
13566 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
13567 this to the symtab builder.
13568 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
13569 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
13570 through to dwarf_record_line_1.
13571 * infrun.c (process_event_stop_test): When stepping, don't stop at
13572 a non-statement instruction, and only refresh the step info when
13573 we land in the middle of a line's range. Also add an extra
13575 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
13577 * record-btrace.c (btrace_find_line_range): Only record lines
13578 marked as is-statement.
13579 * stack.c (frame_show_address): Show the frame address if we are
13580 in a non-statement sal.
13581 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
13582 (maintenance_print_one_line_table): Print a header for the is_stmt
13583 column, and include is_stmt information in the output.
13584 * symtab.c (find_pc_sect_line): Find lines marked as statements in
13585 preference to non-statements.
13586 (find_pcs_for_symtab_line): Prefer is-statement entries.
13587 (find_line_common): Likewise.
13588 * symtab.h (struct linetable_entry): Add is_stmt field.
13589 (struct symtab_and_line): Likewise.
13590 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
13591 arranging the line table.
13595 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
13600 * valops.c (value_literal_complex): Remove obsolete comment.
13601 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
13606 * infrun.h: Forward-declare thread_info.
13607 (set_step_info): Add thread_info parameter, add doc.
13608 * infrun.c (set_step_info): Add thread_info parameter, move doc
13610 * infrun.c (process_event_stop_test): Pass thread to
13611 set_step_info call.
13612 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
13614 (prepare_one_step): Add thread_info parameter, pass it to
13615 set_step_frame and prepare_one_step (recursive) call.
13616 (step_1): Pass thread to prepare_one_step call.
13617 (step_command_fsm::should_stop): Pass thread to
13619 (until_next_fsm): Pass thread to set_step_frame call.
13620 (finish_command): Pass thread to set_step_info call.
13624 * windows-tdep.c (windows_solib_create_inferior_hook):
13625 Check if inferior is running.
13629 * NEWS: Fix "the the".
13634 * psymtab.c (psymtab_to_symtab): Don't print "done.".
13638 * .dir-locals.el: Add a comment referencing the other copies of
13643 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
13648 * .gitattributes: New file.
13652 * symmisc.c (print_symbol_bcache_statistics)
13653 (print_objfile_statistics): Update.
13654 * symfile.c (allocate_symtab): Use intern.
13655 * psymtab.c (partial_symtab::partial_symtab): Use intern.
13656 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
13657 macro_cache>: Remove.
13658 <string_cache>: New member.
13659 (struct objfile) <intern>: New methods.
13660 * elfread.c (elf_symtab_read): Use intern.
13661 * dwarf2/read.c (fixup_go_packaging): Intern package name.
13662 (dwarf2_compute_name, dwarf2_physname)
13663 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
13665 (guess_partial_die_structure_name): Update.
13666 (partial_die_info::fixup): Intern name.
13667 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
13669 (dwarf2_name): Intern name. Update.
13670 * buildsym.c (buildsym_compunit::get_macro_table): Use
13675 * jit.c (bfd_open_from_target_memory): Make "target" const.
13676 * corefile.c (gnutarget): Now const.
13677 * gdbcore.h (gnutarget): Now const.
13681 * NEWS: Mention support for WOW64 processes.
13682 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
13683 (amd64_windows_segment_register_p): Remove static.
13684 (_initialize_amd64_windows_nat): Update.
13685 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
13686 * i386-windows-nat.c (context_offset): Update.
13687 (i386_mappings): Rename and remove static.
13688 (i386_windows_segment_register_p): Remove static.
13689 (_initialize_i386_windows_nat): Update.
13690 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
13691 (STATUS_WX86_SINGLE_STEP): New macro.
13692 (EnumProcessModulesEx): New macro.
13693 (Wow64SuspendThread): New macro.
13694 (Wow64GetThreadContext): New macro.
13695 (Wow64SetThreadContext): New macro.
13696 (Wow64GetThreadSelectorEntry): New macro.
13697 (windows_set_context_register_offsets): Add static.
13698 (windows_set_segment_register_p): Likewise.
13699 (windows_add_thread): Adapt for WOW64 processes.
13700 (windows_fetch_one_register): Likewise.
13701 (windows_nat_target::fetch_registers): Likewise.
13702 (windows_store_one_register): Likewise.
13703 (display_selector): Likewise.
13704 (display_selectors): Likewise.
13705 (handle_exception): Likewise.
13706 (windows_continue): Likewise.
13707 (windows_nat_target::resume): Likewise.
13708 (windows_add_all_dlls): Likewise.
13709 (do_initial_windows_stuff): Likewise.
13710 (windows_nat_target::attach): Likewise.
13711 (windows_get_exec_module_filename): Likewise.
13712 (windows_nat_target::create_inferior): Likewise.
13713 (windows_xfer_siginfo): Likewise.
13714 (_initialize_loadable): Initialize Wow64SuspendThread,
13715 Wow64GetThreadContext, Wow64SetThreadContext,
13716 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
13717 * windows-nat.h (windows_set_context_register_offsets):
13718 Remove declaration.
13719 (windows_set_segment_register_p): Likewise.
13720 (i386_windows_segment_register_p): Add declaration.
13721 (amd64_windows_segment_register_p): Likewise.
13725 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
13726 in "info registers" for AArch64/ARM.
13728 The change caused "info registers" to not print GPR's.
13734 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
13735 when reg->group is empty and reggroup is not.
13739 * dwarf2/frame.c (struct dwarf2_frame_cache)
13740 <checked_tailcall_bottom, entry_cfa_sp_offset,
13741 entry_cfa_sp_offset_p>: Remove members.
13742 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
13743 (dwarf2_frame_prev_register): Don't call
13744 dwarf2_tailcall_sniffer_first.
13745 (dwarf2_append_unwinders): Don't append tailcall unwinder.
13746 * frame-unwind.c (add_unwinder): New fuction.
13747 (frame_unwind_init): Use it. Add tailcall unwinder.
13752 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
13753 value should be printed as true.
13757 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
13758 (windows_init_abi): Set and use windows_so_ops.
13762 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
13763 when verifying if dealing with a convenience variable.
13767 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
13771 * infrun.c (gdbarch_supports_displaced_stepping): New.
13772 (use_displaced_stepping): Break up conditions in smaller pieces.
13773 Use gdbarch_supports_displaced_stepping.
13774 (displaced_step_prepare_throw): Use
13775 gdbarch_supports_displaced_stepping.
13779 * NEWS: Mention new behaviour of the history filename.
13780 * top.c (write_history_p): Add comment.
13781 (show_write_history_p): Add header comment, give a different
13782 message when history writing is on, but the history filename is
13784 (history_filename): Add comment.
13785 (history_filename_empty): New function.
13786 (show_history_filename): Add header comment, give a different
13787 message when the filename is empty.
13788 (init_history): Compare history_filename against nullptr, and only
13789 read history if the filename is not empty.
13790 (set_history_filename): Add header comment, and only make
13791 non-empty filenames absolute.
13792 (init_main): Make the filename argument to 'set history filename'
13797 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
13798 (arm_supply_vfpregset): ...this, and update to use VFP registers.
13799 (fetch_fp_register): Update.
13800 (fetch_fp_regs): Update.
13801 (store_fp_register): Update.
13802 (store_fp_regs): Update.
13803 (arm_netbsd_nat_target::read_description): New function.
13804 (fetch_elfcore_registers): Update.
13808 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
13809 general_thread if the stop reply is missing a thread-id.
13810 (remote_target::process_stop_reply): Use the first non-exited
13811 thread if the target didn't pass a thread-id.
13812 * infrun.c (do_target_wait): Move call to
13813 switch_to_inferior_no_thread to ....
13814 (do_target_wait_1): ... here.
13818 * debuginfod-support.c: Include defs.h first.
13822 * symfile.c (set_initial_language): Use default language for lookup.
13826 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
13827 reader variable, pass `this` to read_cutu_die_from_dwo.
13831 * source.c (open_source_file): Check for nullptr when computing
13836 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
13838 (dwarf2_add_field): Don't update nfields.
13839 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
13843 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
13848 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
13849 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
13850 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
13851 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
13856 * dwarf2/index-write.c (psym_index_map): Change type.
13857 (add_address_entry_worker, write_one_signatured_type)
13858 (recursively_count_psymbols, recursively_write_psymbols)
13859 (class debug_names, psyms_seen_size, write_gdbindex)
13860 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
13864 * Makefile.in: Handle optional debuginfod support.
13866 * README: Add --with-debuginfod summary.
13867 * config.in: Regenerate.
13868 * configure: Regenerate.
13869 * configure.ac: Handle optional debuginfod support.
13870 * debuginfod-support.c: debuginfod helper functions.
13871 * debuginfod-support.h: Ditto.
13872 * doc/gdb.texinfo: Add --with-debuginfod to configure options
13874 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
13875 when a dwz file cannot be found.
13876 * elfread.c (elf_symfile_read): Query debuginfod servers when a
13877 debuginfo file cannot be found.
13878 * source.c (open_source_file): Query debuginfod servers when a
13879 source file cannot be found.
13880 * top.c (print_gdb_configuration): Include
13881 --{with,without}-debuginfod in the output.
13885 * thread.c (thr_try_catch_cmd): Print thread name.
13889 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
13890 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
13891 dwarf2_fetch_die_type_sect_off): Move to...
13892 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
13893 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
13894 dwarf2_fetch_die_type_sect_off): ... here.
13895 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
13896 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
13897 dwarf2_fetch_die_type_sect_off): Move doc to header file.
13902 * symfile.c (set_initial_language): Exit-early if
13903 language_mode == language_mode_manual.
13907 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
13908 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
13909 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
13913 * gdbtypes.c (create_array_type_with_stride): Handle negative
13915 * valarith.c (value_subscripted_rvalue): Likewise.
13919 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
13923 * loc.h (dwarf2_get_die_type): Move to...
13924 * read.h (dwarf2_get_die_type): ... here.
13925 * read.c (dwarf2_get_die_type): Move doc to header.
13929 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
13930 'gnulib/Makefile.in' to the list.
13934 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
13936 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
13941 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
13943 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
13944 (dw2_do_instantiate_symtab, dw2_get_file_names)
13945 (build_type_psymtab_dependencies, load_full_type_unit): Update.
13949 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
13950 make_scoped_restore.
13951 (dwarf2_psymtab::read_symtab): Don't clear
13952 reading_partial_symbols.
13957 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
13961 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
13962 commands layout next/prev/regs.
13966 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
13967 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
13971 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
13975 * tui/tui-win.c (_initialize_tui_win): Add usage text.
13976 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
13977 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
13978 * tui/tui.c (_initialize_tui): Add usage text.
13982 * tui/tui-win.c (tui_set_focus_command)
13983 (tui_set_win_height_command): Use error_no_arg.
13984 (_initialize_tui_win): Update help text.
13985 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
13989 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
13990 * tui/tui-disasm.h (struct tui_disasm_window)
13991 <display_start_addr>: Declare.
13992 * tui/tui-source.h (struct tui_source_window)
13993 <display_start_addr>: Declare.
13994 * tui/tui-winsource.h (struct tui_source_window_base)
13995 <show_source_line, display_start_addr>: New methods.
13996 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
13997 Rename and move to protected section.
13998 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
13999 (tui_source_window_base::do_erase_source_content): Update.
14000 (tui_source_window_base::show_source_line): Now a method.
14001 (tui_source_window_base::show_source_content)
14002 (tui_source_window_base::tui_source_window_base)
14003 (tui_source_window_base::rerender)
14004 (tui_source_window_base::refill)
14005 (tui_source_window_base::do_scroll_horizontal)
14006 (tui_source_window_base::set_is_exec_point_at)
14007 (tui_source_window_base::update_breakpoint_info)
14008 (tui_source_window_base::update_exec_info): Update.
14009 * tui/tui-source.c (tui_source_window::set_contents)
14010 (tui_source_window::showing_source_p)
14011 (tui_source_window::do_scroll_vertical)
14012 (tui_source_window::location_matches_p)
14013 (tui_source_window::line_is_displayed): Update.
14014 (tui_source_window::display_start_addr): New method.
14015 * tui/tui-disasm.c (tui_disasm_window::set_contents)
14016 (tui_disasm_window::do_scroll_vertical)
14017 (tui_disasm_window::location_matches_p): Update.
14018 (tui_disasm_window::display_start_addr): New method.
14022 * NEWS: Add entry for gdb.register_window_type.
14023 * tui/tui-layout.h (window_factory): New typedef.
14024 (tui_register_window): Declare.
14025 * tui/tui-layout.c (saved_tui_windows): New global.
14026 (tui_apply_current_layout): Use it.
14027 (tui_register_window): New function.
14028 * python/python.c (do_start_initialization): Call
14029 gdbpy_initialize_tui.
14030 (python_GdbMethods): Add "register_window_type" function.
14031 * python/python-internal.h (gdbpy_register_tui_window)
14032 (gdbpy_initialize_tui): Declare.
14033 * python/py-tui.c: New file.
14034 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
14038 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
14042 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
14043 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
14044 * tui/tui-data.c (tui_set_win_with_focus): Remove.
14045 (tui_set_win_focus_to): Move from tui-win.c.
14049 * tui/tui-layout.c (make_standard_window, get_locator_window): New
14051 (known_window_types): New global.
14052 (tui_get_window_by_name): Reimplement.
14053 (initialize_known_windows): New function.
14054 (validate_window_name): Rewrite.
14055 (_initialize_tui_layout): Call initialize_known_windows.
14059 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
14061 * tui/tui-winsource.h (struct tui_source_window_base)
14062 <tui_source_window_base>: Remove parameter.
14063 * tui/tui-winsource.c
14064 (tui_source_window_base::tui_source_window_base): Remove
14066 (tui_source_window_base::refill): Update.
14067 * tui/tui-stack.h (struct tui_locator_window)
14068 <tui_locator_window>: Update.
14069 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
14070 Default the constructor.
14071 * tui/tui-regs.h (struct tui_data_item_window)
14072 <tui_data_item_window>: Default the constructor.
14073 (struct tui_data_window) <tui_data_window>: Likewise.
14074 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
14075 Default the constructor.
14076 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
14077 Default the constructor.
14079 (struct tui_win_info) <tui_win_info>: Default the constructor.
14080 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
14081 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
14082 Default the constructor.
14086 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
14087 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
14088 * tui/tui-win.c (tui_resize_all): Don't call
14089 tui_delete_invisible_windows.
14090 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
14092 (tui_set_layout): Update.
14093 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
14094 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
14095 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
14099 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
14104 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
14108 * tui/tui-winsource.h (struct tui_source_window_iterator)
14109 <inner_iterator>: New etytypedef.
14110 <tui_source_window_iterator>: Take "end" parameter.
14111 <tui_source_window_iterator>: Take iterator.
14112 <operator*, advance>: Update.
14113 <m_iter>: Change type.
14114 <m_end>: New field.
14115 (struct tui_source_windows) <begin, end>: Update.
14116 * tui/tui-layout.c (tui_windows): New global.
14117 (tui_apply_current_layout): Clear tui_windows.
14118 (tui_layout_window::apply): Update tui_windows.
14119 * tui/tui-data.h (tui_windows): Declare.
14120 (all_tui_windows): Now inline function.
14121 (class tui_window_iterator, struct all_tui_windows): Remove.
14126 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
14127 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
14129 (class tui_layout_window) <get_sizes>: Likewise.
14130 (class tui_layout_split) <tui_layout_split>: Add "vertical"
14132 <get_sizes>: Add "height" argument.
14133 <m_vertical>: New field.
14134 * tui/tui-layout.c (tui_layout_split::clone): Update.
14135 (tui_layout_split::get_sizes): Add "height" argument.
14136 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
14137 (tui_new_layout_command): Parse "-horizontal".
14138 (_initialize_tui_layout): Update help string.
14139 (tui_layout_split::specification): Add "-horizontal" when needed.
14140 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
14142 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
14147 * tui/tui-layout.h (enum tui_adjust_result): New.
14148 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
14149 (class tui_layout_window) <adjust_size>: Return
14150 tui_adjust_result. Rewrite.
14151 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
14152 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
14156 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
14157 parameter and return types.
14158 (class tui_layout_base) <specification>: Add "depth".
14159 (class tui_layout_window) <specification>: Add "depth".
14160 (class tui_layout_split) <specification>: Add "depth".
14161 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
14163 (tui_new_layout_command): Parse sub-layouts.
14164 (_initialize_tui_layout): Update help string.
14165 (tui_layout_window::specification): Add "depth".
14166 (add_layout_command): Update.
14170 * NEWS: Add "tui new-layout" item.
14171 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
14172 Add new-layout command to help text.
14173 (validate_window_name): New function.
14174 (tui_new_layout_command): New function.
14175 (_initialize_tui_layout): Register "new-layout".
14176 (tui_layout_window::specification): New method.
14177 (tui_layout_window::specification): New method.
14178 * tui/tui-layout.h (class tui_layout_base) <specification>: New
14180 (class tui_layout_window) <specification>: New method.
14181 (class tui_layout_split) <specification>: New method.
14185 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
14186 * tui/tui-win.c (window_name_completer): Update comment.
14187 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
14189 (class tui_layout_window) <replace_window>: Likewise.
14190 (class tui_layout_split) <replace_window>: Likewise.
14191 (tui_set_layout): Don't declare.
14192 (tui_set_initial_layout): Declare function.
14193 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
14194 (asm_regs_layout): New globals.
14195 (tui_current_layout, show_layout): Remove.
14196 (tui_set_layout, tui_add_win_to_layout): Rewrite.
14197 (find_layout, tui_apply_layout): New function.
14198 (layout_completer): Remove.
14199 (tui_next_layout): Reimplement.
14200 (tui_next_layout_command): New function.
14201 (tui_set_initial_layout, tui_prev_layout_command): New functions.
14202 (tui_regs_layout): Reimplement.
14203 (tui_regs_layout_command): New function.
14204 (extract_display_start_addr): Rewrite.
14205 (next_layout, prev_layout): Remove.
14206 (tui_layout_window::replace_window): New method.
14207 (tui_layout_split::replace_window): New method.
14208 (destroy_layout): New function.
14209 (layout_list): New global.
14210 (add_layout_command): New function.
14211 (initialize_layouts): Update.
14212 (tui_layout_command): New function.
14213 (_initialize_tui_layout): Install "layout" commands.
14214 * tui/tui-data.h (enum tui_layout_type): Remove.
14215 (tui_current_layout): Don't declare.
14219 * tui/tui-regs.c (tui_reg_layout): Remove.
14220 (tui_reg_command): Use tui_regs_layout.
14221 * tui/tui-layout.h (tui_reg_command): Declare.
14222 * tui/tui-layout.c (tui_reg_command): New function.
14226 * tui/tui.c (tui_rl_delete_other_windows): Call
14227 tui_remove_some_windows.
14228 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
14230 (class tui_layout_window) <remove_windows>: New method.
14231 (class tui_layout_split) <remove_windows>: Declare.
14232 (tui_remove_some_windows): Declare.
14233 * tui/tui-layout.c (tui_remove_some_windows): New function.
14234 (tui_layout_split::remove_windows): New method.
14238 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
14239 * tui/tui-layout.h (tui_next_layout): Declare.
14240 * tui/tui-layout.c (tui_next_layout): New function.
14244 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
14245 correct coordinates.
14249 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
14250 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
14255 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
14256 TUI_DISASM_WIN, not tui_win_list.
14260 * valprint.c (generic_val_print_enum_1)
14261 (val_print_type_code_flags): Style member names.
14262 * rust-lang.c (val_print_struct, rust_print_enum)
14263 (rust_print_struct_def, rust_internal_print_type): Style member
14265 * p-valprint.c (pascal_object_print_value_fields): Style member
14266 names. Only call fprintf_symbol_filtered for static members.
14267 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
14268 * f-valprint.c (f_val_print): Style member names.
14269 * f-typeprint.c (f_type_print_base): Style member names.
14270 * cp-valprint.c (cp_print_value_fields): Style member names. Only
14271 call fprintf_symbol_filtered for static members.
14272 (cp_print_class_member): Style member names.
14273 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
14275 * ada-valprint.c (ada_print_scalar): Style enum names.
14276 (ada_val_print_enum): Likewise.
14277 * ada-typeprint.c (print_enum_type): Style enum names.
14281 * psympriv.h (struct partial_symtab): Update comment.
14285 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
14291 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
14292 if dependencies[i]->user != NULL.
14296 * dwarf2/read.c (dwarf2_name): Add null check.
14300 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
14301 ">=", in binary search.
14302 (dwarf2_find_containing_comp_unit): New overload.
14303 (run_test): New self-test.
14304 (_initialize_dwarf2_read): Register new test.
14308 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
14309 * riscv-tdep.h: Likewise.
14310 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
14312 * features/riscv/64bit-csr.xml: Regenerated.
14317 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
14318 of 'fputc_unfiltered'.
14319 (putchar_unfiltered): Call 'fputc_unfiltered'.
14320 (fputc_unfiltered): Call 'fputs_unfiltered'.
14324 * config.in: Regenerate.
14325 * configure: Regenerate.
14326 * configure.ac: Add --with-python-libdir option.
14327 * main.c: Use WITH_PYTHON_LIBDIR.
14331 * symtab.c (general_symbol_info::compute_and_set_names): Use
14332 obstack_strndup. Simplify call to symbol_set_demangled_name.
14336 * dwarf2/read.c (allocate_signatured_type_table,
14337 allocate_dwo_unit_table, allocate_type_unit_groups_table,
14338 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
14339 Remove objfile parameter, update all callers.
14344 * rust-lang.c (rust_print_enum): Apply embedded_offset to
14345 rust_enum_variant calculation.
14349 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
14353 * ada-lang.c (cache_symbol): Use obstack_strdup.
14357 * configure: Regenerate.
14361 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
14366 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
14370 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
14371 if GDBSERVER is not defined.
14372 (riscv_tdesc_cache): Likewise, also store const target_desc.
14373 (STATIC_IN_GDB): Define.
14374 (riscv_create_target_description): Update declaration with
14376 (riscv_lookup_target_description): New function, only define if
14377 GDBSERVER is not defined.
14378 * arch/riscv.h (riscv_create_target_description): Declare only
14379 when GDBSERVER is defined.
14380 (riscv_lookup_target_description): New declaration when GDBSERVER
14382 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
14383 (riscv_linux_read_features): ...this, and return
14384 riscv_gdbarch_features instead of target_desc.
14385 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
14386 (riscv_linux_read_description): Rename to...
14387 (riscv_linux_read_features): ...this.
14388 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
14389 Update to use riscv_gdbarch_features and
14390 riscv_lookup_target_description.
14391 * riscv-tdep.c (riscv_find_default_target_description): Use
14392 riscv_lookup_target_description instead of
14393 riscv_create_target_description.
14397 * valprint.c (generic_val_print_enum_1): When printing a flag
14398 enum with value 0 and there is no enumerator with value 0, print
14399 just "0" instead of "(unknown: 0x0)".
14403 * valprint.c (generic_val_print_enum_1): Print unknown part of
14408 * dwarf2/read.c (update_enumeration_type_from_children): Allow
14409 flag enums to contain duplicate enumerators.
14410 * valprint.c (generic_val_print_enum_1): Update comment.
14414 * dwarf2/read.c: Include "count-one-bits.h".
14415 (update_enumeration_type_from_children): If an enumerator has
14416 multiple bits set, don't treat the enumeration as a "flag enum".
14417 * valprint.c (generic_val_print_enum_1): Assert that enumerators
14418 of flag enums have 0 or 1 bit set.
14422 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
14424 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
14425 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
14426 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
14427 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
14428 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
14436 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
14437 displaced_step_closure_up.
14438 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
14439 (struct displaced_step_closure_up):
14440 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
14441 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
14442 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
14444 * gdbarch.sh (displaced_step_copy_insn): Likewise.
14445 * gdbarch.c, gdbarch.h: Re-generate.
14446 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
14447 displaced_step_closure_up.
14448 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
14449 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
14450 * infrun.h (displaced_step_closure_up): New type alias.
14451 (struct displaced_step_inferior_state) <step_closure>: Change
14452 type to displaced_step_closure_up.
14453 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
14454 displaced_step_closure_up.
14455 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
14459 * minidebug.c (gnu_debug_key): New global.
14460 (find_separate_debug_file_in_section): Use it.
14464 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
14466 * gdbarch.c: Re-generate.
14467 * gdbarch.h: Re-generate.
14468 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
14470 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
14471 type to std::unique_ptr.
14472 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
14473 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
14474 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
14475 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
14476 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
14477 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
14478 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
14479 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
14480 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
14484 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
14486 (displaced_step_clear): Rename to...
14487 (displaced_step_reset): ... this. Just call displaced->reset ().
14488 (displaced_step_clear_cleanup): Rename to...
14489 (displaced_step_reset_cleanup): ... this.
14490 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
14491 (displaced_step_fixup): Likewise.
14492 (resume_1): Likewise.
14493 (handle_inferior_event): Restore child's memory before calling
14494 displaced_step_fixup on the parent.
14495 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
14496 to std::unique_ptr.
14497 <step_closure>: Change type to std::unique_ptr.
14501 * arm-tdep.c: Include count-one-bits.h.
14502 (cleanup_block_store_pc): Use count_one_bits.
14503 (cleanup_block_load_pc): Use count_one_bits.
14504 (arm_copy_block_xfer): Use count_one_bits.
14505 (thumb2_copy_block_xfer): Use count_one_bits.
14506 (thumb_copy_pop_pc_16bit): Use count_one_bits.
14507 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
14508 (thumb_get_next_pcs_raw): Use count_one_bits.
14509 (arm_get_next_pcs_raw): Use count_one_bits_l.
14510 * arch/arm.c (bitcount): Remove.
14511 * arch/arm.h (bitcount): Remove.
14515 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
14517 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
14518 * dwarf2/loc.c (call_site_find_chain_1): Return
14519 unique_xmalloc_ptr.
14520 (call_site_find_chain): Likewise.
14524 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
14525 on expression with division operators.
14529 * MAINTAINERS (Write After Approval): Adding myself.
14533 * event-loop.c (event_data, gdb_event, event_handler_func):
14538 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
14539 (dwarf2_frame_objfile_data): Add comment.
14540 (find_comp_unit, set_comp_unit): New functions.
14541 (dwarf2_frame_find_fde): Use find_comp_unit.
14542 (dwarf2_build_frame_info): Use set_comp_unit.
14546 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
14547 (comp_unit): Don't initialize objfile.
14548 (execute_cfa_program): Add text_offset parameter.
14549 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
14550 (dwarf2_frame_cache): Update.
14551 (dwarf2_build_frame_info): Don't set "objfile" member.
14555 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
14556 (decode_frame_entry): Likewise.
14557 (dwarf2_build_frame_info): Update.
14561 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
14562 (decode_frame_entry_1): Use the comp_unit obstack.
14566 * dwarf2/frame.c (struct comp_unit): Add initializers and
14568 (dwarf2_frame_objfile_data): Store a comp_unit.
14569 (dwarf2_frame_find_fde): Update.
14570 (dwarf2_build_frame_info): Use "new".
14574 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
14575 (dwarf2_fde_table): Typedef for std::vector.
14576 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
14577 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
14578 (decode_frame_entry): Update.
14579 (dwarf2_build_frame_info): Use "new".
14583 * arm-tdep.c (arm_gdbarch_init): Update.
14584 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
14585 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
14586 have_neon, is_m>: Change to bool.
14590 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
14594 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
14598 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
14599 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
14603 * psymtab.h: Update comment.
14607 * gdb_obstack.h (struct auto_obstack): Use
14608 DISABLE_COPY_AND_ASSIGN.
14612 * dwarf2/frame.h (struct objfile): Don't forward declare.
14616 * cris-tdep.c (cris_supply_gregset): Change signature to match
14617 what struct regset expects.
14618 (cris_regset): New struct.
14619 (fetch_core_registers): Remove.
14620 (cris_iterate_over_regset_sections): New function.
14621 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
14622 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
14626 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
14631 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
14635 * configure: Re-generate.
14639 * configure: Re-generate.
14643 * acinclude: Update warning.m4 path.
14644 * warning.m4: Move to gdbsupport.
14648 * remote.c (remote_console_output): Update.
14649 * printcmd.c (printf_command): Update.
14650 * event-loop.c (gdb_wait_for_event): Update.
14651 * linux-nat.c (sigchld_handler): Update.
14652 * remote-sim.c (gdb_os_write_stdout): Update.
14653 (gdb_os_flush_stdout): Update.
14654 (gdb_os_flush_stderr): Update.
14655 (gdb_os_write_stderr): Update.
14656 * exceptions.c (print_exception): Update.
14657 * remote-fileio.c (remote_fileio_func_read): Update.
14658 (remote_fileio_func_write): Update.
14659 * tui/tui.c (tui_enable): Update.
14660 * tui/tui-interp.c (tui_interp::init): Update.
14661 * utils.c (init_page_info): Update.
14662 (putchar_unfiltered, fputc_unfiltered): Update.
14663 (gdb_flush): Update.
14664 (emit_style_escape): Update.
14665 (flush_wrap_buffer, fputs_maybe_filtered): Update.
14666 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
14667 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
14668 (stderr_file::write): Update.
14669 (stderr_file::puts): Update.
14670 * ui-file.h (ui_file_isatty, ui_file_write)
14671 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
14672 (ui_file_puts): Don't declare.
14676 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
14677 sentinel to char *.
14681 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
14682 filename if it matches "<artificial>".
14686 * windows-tdep.c (struct enum_value_name): New struct.
14687 (create_enum): New function.
14688 (windows_get_siginfo_type): Create and use enum types.
14692 * NEWS: Mention $_siginfo support for Windows.
14693 * windows-nat.c (handle_exception): Set siginfo_er.
14694 (windows_nat_target::mourn_inferior): Reset siginfo_er.
14695 (windows_xfer_siginfo): New function.
14696 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
14697 * windows-tdep.c (struct windows_gdbarch_data): New struct.
14698 (init_windows_gdbarch_data): New function.
14699 (get_windows_gdbarch_data): New function.
14700 (windows_get_siginfo_type): New function.
14701 (windows_init_abi): Register windows_get_siginfo_type.
14702 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
14706 * dwarf2/read.c (class cutu_reader) <cutu_reader,
14707 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
14708 <keep>: Declare method.
14709 <m_keep>: Remove member.
14710 <~cutu_reader>: Remove.
14711 (cutu_reader::init_tu_and_read_dwo_dies): Update.
14712 (cutu_reader::cutu_reader): Update.
14713 (cutu_reader::keep): Rename from ~cutu_reader.
14714 (process_psymtab_comp_unit, build_type_psymtabs_1)
14715 (process_skeletonless_type_unit, load_partial_comp_unit)
14716 (load_full_comp_unit, dwarf2_read_addr_index)
14717 (read_signatured_type): Update.
14721 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
14722 "want_partial_unit" parameter.
14723 (process_psymtab_comp_unit): Change want_partial_unit to bool.
14724 Inline check for DW_TAG_partial_unit.
14725 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
14729 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
14731 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
14736 * dwarf2/read.c (read_address): Move to comp-unit.c.
14737 (dwarf2_rnglists_process, dwarf2_ranges_process)
14738 (read_attribute_value, dwarf_decode_lines_1)
14739 (var_decode_location, decode_locdesc): Update.
14740 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
14741 read.c. Remove "cu" parameter.
14742 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
14747 * dwarf2/read.c (read_attribute_value, read_indirect_string)
14748 (read_indirect_line_string): Update.
14749 * dwarf2/comp-unit.c (read_offset): Remove.
14750 (read_comp_unit_head): Update.
14751 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
14753 (read_offset): Don't declare.
14757 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
14758 * dwarf2/read.c (struct comp_unit_head): Move to
14759 dwarf2/comp-unit.h.
14760 (enum class rcuh_kind): Move to comp-unit.h.
14761 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
14762 (read_comp_unit_head, error_check_comp_unit_head)
14763 (read_and_check_comp_unit_head): Move to comp-unit.c.
14764 (read_offset, dwarf_unit_type_name): Likewise.
14765 (create_debug_type_hash_table, read_cutu_die_from_dwo)
14766 (cutu_reader::cutu_reader, read_call_site_scope)
14767 (find_partial_die, follow_die_offset): Update.
14768 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
14772 * dwarf2/read.c (read_offset_1): Move to leb.c.
14773 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
14774 (dwarf_decode_macro_bytes): Update.
14775 * dwarf2/leb.c (read_offset): Rename; move from read.c.
14776 * dwarf2/leb.h (read_offset): Declare.
14780 * dwarf2/read.c (dwarf2_section_size): Remove.
14781 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
14783 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
14787 * dwarf2/read.c (read_initial_length): Move to leb.c.
14788 * dwarf2/leb.h (read_initial_length): Declare.
14789 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
14790 handle_nonstd parameter.
14791 * dwarf2/frame.c (read_initial_length): Remove.
14792 (decode_frame_entry_1): Update.
14796 * dwarf2/loc.c (dwarf2_find_location_expression)
14797 (dwarf_evaluate_loc_desc::get_tls_address)
14798 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
14799 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
14800 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
14801 (dwarf2_compile_property_to_c)
14802 (dwarf2_loc_desc_get_symbol_read_needs)
14803 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
14804 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
14805 (loclist_describe_location, loclist_tracepoint_var_ref)
14806 (loclist_generate_c_location): Update.
14807 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
14808 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
14809 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
14810 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
14811 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
14812 (dwarf2_per_cu_data::addr_size)
14813 (dwarf2_per_cu_data::ref_addr_size)
14814 (dwarf2_per_cu_data::text_offset)
14815 (dwarf2_per_cu_data::addr_type): Now methods.
14816 (per_cu_header_read_in): Make per_cu "const".
14817 (dwarf2_version): Remove.
14818 (dwarf2_per_cu_data::int_type): Now a method.
14819 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
14820 (set_die_type, read_array_type, read_subrange_index_type)
14821 (read_tag_string_type, read_subrange_type): Update.
14822 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
14823 offset_size, ref_addr_size, text_offset, addr_type, version,
14824 objfile, int_type, addr_sized_int_type>: Declare methods.
14828 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
14833 * dwarf2/read.h (dwarf_line_debug): Declare.
14834 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
14835 * dwarf2/read.c: Move line_header code to new files.
14836 (dwarf_line_debug): No longer static.
14837 * dwarf2/line-header.c: New file.
14838 * dwarf2/line-header.h: New file.
14842 * dwarf2/read.c (struct line_header) <file_full_name,
14843 file_file_name>: Return unique_xmalloc_ptr.
14844 (line_header::file_file_name): Update.
14845 (line_header::file_full_name): Update.
14846 (dw2_get_file_names_reader): Update.
14847 (macro_start_file): Update.
14851 * dwarf2/read.c (struct line_header) <file_full_name,
14852 file_file_name>: Declare methods.
14853 (dw2_get_file_names_reader): Update.
14854 (file_file_name): Now a method.
14855 (file_full_name): Likewise.
14856 (macro_start_file): Update.
14860 * dwarf2/read.c (dwarf_always_disassemble)
14861 (show_dwarf_always_disassemble): Move to loc.c.
14862 (_initialize_dwarf2_read): Move "always-disassemble" registration
14864 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
14865 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
14867 (show_dwarf_always_disassemble): Move from read.c.
14868 (_initialize_dwarf2loc): Move always-disassemble from read.c.
14872 * dwarf2/read.c (~dwarf2_per_objfile): Update.
14873 (create_quick_file_names_table): Return htab_up.
14874 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
14876 * dwarf2/read.h (struct dwarf2_per_objfile)
14877 <quick_file_names_table>: Now htab_up.
14881 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
14885 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
14887 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
14888 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
14889 (abbrev_table::abbrev_table): No longer inline.
14890 (ABBREV_HASH_SIZE): Remove.
14891 (abbrev_table::m_abbrevs): Now an htab_up.
14895 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
14896 (cutu_reader): Update.
14897 (build_type_psymtabs_1): Update.
14898 * dwarf2/abbrev.c (abbrev_table::read): Rename.
14899 (abbrev_table::alloc_abbrev): Update.
14900 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
14901 (abbrev_table::read): New static method, renamed from
14902 abbrev_table_read_table.
14903 (abbrev_table::alloc_abbrev)
14904 (abbrev_table::add_abbrev): Now private.
14905 (abbrev_table::abbrev_table): Now private.
14906 (abbrev_table::m_abbrev_obstack): Now private. Rename.
14910 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
14911 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
14916 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
14918 (lookup_dwo_unit_in_dwp): Update.
14919 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
14924 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
14929 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
14931 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
14932 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
14933 Change type to htab_up.
14937 * dwarf2/read.c (allocate_type_unit_groups_table): Return
14938 htab_up. Don't allocate on obstack.
14939 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
14940 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
14941 Change type to htab_up.
14945 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
14946 Change type to htab_up.
14947 * dwarf2/read.c (create_signatured_type_table_from_index)
14948 (create_signatured_type_table_from_debug_names)
14949 (create_all_type_units, add_type_unit)
14950 (lookup_dwo_signatured_type, lookup_signatured_type)
14951 (process_skeletonless_type_unit): Update.
14952 (create_debug_type_hash_table, create_debug_types_hash_table):
14953 Change type of types_htab.
14954 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
14955 htab_up. Don't allocate on obstack.
14956 (create_cus_hash_table): Change type of cus_htab parameter.
14957 (struct dwo_file) <cus, tus>: Now htab_up.
14958 (lookup_dwo_signatured_type, lookup_dwo_cutu)
14959 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
14960 (queue_and_load_all_dwo_tus): Update.
14961 * dwarf2/index-write.c (write_gdbindex): Update.
14962 (write_debug_names): Update.
14966 * dwarf2/read.h (struct dwarf2_queue_item): Move from
14967 dwarf2/read.c. Remove "next" member. Add constructor ntad
14969 (struct dwarf2_per_objfile) <queue>: New member.
14970 * dwarf2/read.c (struct dwarf2_queue_item): Move to
14972 (dwarf2_queue, dwarf2_queue_tail): Remove.
14973 (class dwarf2_queue_guard): Add parameter to constructor. Use
14974 DISABLE_COPY_AND_ASSIGN.
14975 <m_per_objfile>: New member.
14976 <~dwarf2_queue_guard>: Rewrite.
14977 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
14979 (~dwarf2_queue_item): New.
14983 * dwarf2/read.c (struct die_info) <has_children>: New member.
14984 (dw2_get_file_names_reader): Remove has_children.
14985 (dw2_get_file_names): Update.
14986 (read_cutu_die_from_dwo): Remove has_children.
14987 (cutu_reader::init_tu_and_read_dwo_dies)
14988 (cutu_reader::cutu_reader): Update.
14989 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
14990 Remove has_children.
14991 (build_type_psymtabs_1, process_skeletonless_type_unit)
14992 (load_partial_comp_unit, load_full_comp_unit): Update.
14993 (create_dwo_cu_reader): Remove has_children.
14994 (create_cus_hash_table, read_die_and_children): Update.
14995 (read_full_die_1,read_full_die): Remove has_children.
14996 (read_signatured_type): Update.
14997 (class cutu_reader) <has_children>: Remove.
15001 * dwarf2/expr.c: Rename from dwarf2expr.c.
15002 * dwarf2/expr.h: Rename from dwarf2expr.h.
15003 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
15004 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
15005 * dwarf2/frame.c: Rename from dwarf2-frame.c.
15006 * dwarf2/frame.h: Rename from dwarf2-frame.h.
15007 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
15008 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
15009 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
15010 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
15011 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
15012 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
15013 * dwarf2/loc.c: Rename from dwarf2loc.c.
15014 * dwarf2/loc.h: Rename from dwarf2loc.h.
15015 * dwarf2/read.c: Rename from dwarf2read.c.
15016 * dwarf2/read.h: Rename from dwarf2read.h.
15017 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
15018 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
15019 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
15020 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
15021 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
15022 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
15023 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
15024 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
15025 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
15026 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
15027 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
15028 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
15029 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
15031 * Makefile.in (COMMON_SFILES): Update.
15032 (HFILES_NO_SRCDIR): Update.
15036 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
15037 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
15041 * dwarf2read.h (struct die_info): Don't declare.
15045 * dwarf2read.h (die_info_ptr): Remove typedef.
15049 * dwarf2read.c (read_call_site_scope)
15050 (handle_data_member_location, dwarf2_add_member_fn)
15051 (mark_common_block_symbol_computed, read_common_block)
15052 (attr_to_dynamic_prop, partial_die_info::read)
15053 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
15054 (dwarf2_symbol_mark_computed, set_die_type): Update.
15055 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
15057 (attr_form_is_block): Don't declare.
15058 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
15062 * dwarf2read.c (dwarf2_find_base_address, )
15063 (read_call_site_scope, rust_containing_type)
15064 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
15065 (handle_data_member_location, dwarf2_add_member_fn)
15066 (get_alignment, read_structure_type, process_structure_scope)
15067 (mark_common_block_symbol_computed, read_common_block)
15068 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
15069 (partial_die_info::read, read_attribute_value, new_symbol)
15070 (lookup_die_type, dwarf2_get_ref_die_offset)
15071 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
15072 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
15073 (dwarf2_symbol_mark_computed): Update.
15074 * dwarf2/attribute.h (struct attribute) <value_as_address,
15075 form_is_section_offset, form_is_constant, form_is_ref>: Declare
15077 (value_as_address, attr_form_is_section_offset)
15078 (attr_form_is_constant, attr_form_is_ref): Don't declare.
15079 * dwarf2/attribute.c (attribute::value_as_address)
15080 (attribute::form_is_section_offset, attribute::form_is_constant)
15081 (attribute::form_is_ref): Now methods.
15085 * dwarf2read.c (struct attribute, DW_STRING)
15086 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
15087 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
15088 (attr_form_is_block, attr_form_is_section_offset)
15089 (attr_form_is_constant, attr_form_is_ref): Move.
15090 * dwarf2/attribute.h: New file.
15091 * dwarf2/attribute.c: New file, from dwarf2read.c.
15092 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
15096 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
15097 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
15099 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
15100 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
15101 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
15103 * dwarf2/abbrev.h: New file.
15104 * dwarf2/abbrev.c: New file, from dwarf2read.c.
15105 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
15109 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
15110 (dwarf2_section_size, dwarf2_get_section_info)
15111 (create_signatured_type_table_from_debug_names)
15112 (create_addrmap_from_aranges, read_debug_names_from_section)
15113 (get_gdb_index_contents_from_section, read_comp_unit_head)
15114 (error_check_comp_unit_head, read_abbrev_offset)
15115 (create_debug_type_hash_table, init_cu_die_reader)
15116 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
15117 (read_comp_units_from_section, create_cus_hash_table)
15118 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
15119 (create_dwp_v2_section, dwarf2_rnglists_process)
15120 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
15121 (abbrev_table_read_table, read_indirect_string_at_offset_from)
15122 (read_indirect_string_from_dwz, read_addr_index_1)
15123 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
15124 (dwarf_decode_macro_bytes, dwarf_decode_macros)
15125 (fill_in_loclist_baton): Update.
15126 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
15127 get_containing_section, get_bfd_owner, get_bfd_section,
15128 get_file_name, get_id, get_flags, empty, read>: Declare methods.
15129 (dwarf2_read_section, get_section_name, get_section_file_name)
15130 (get_containing_section, get_section_bfd_owner)
15131 (get_section_bfd_section, get_section_name, get_section_file_name)
15132 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
15134 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
15135 (dwarf2_section_info::get_bfd_owner)
15136 (dwarf2_section_info::get_bfd_section)
15137 (dwarf2_section_info::get_name)
15138 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
15139 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
15140 (dwarf2_section_info::read): Now methods.
15141 * dwarf-index-write.c (class debug_names): Update.
15145 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
15146 Move to dwarf2/section.h.
15147 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
15148 (get_section_bfd_section, get_section_name)
15149 (get_section_file_name, get_section_id, get_section_flags)
15150 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
15152 * dwarf2/section.h: New file.
15153 * dwarf2/section.c: New file, from dwarf2read.c.
15154 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
15158 * dwarf2read.h (read_unsigned_leb128): Don't declare.
15159 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
15160 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
15161 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
15162 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
15163 * dwarf2/leb.h: New file, from dwarf2read.c.
15164 * dwarf2/leb.c: New file, from dwarf2read.c.
15165 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
15167 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
15168 (COMMON_SFILES): Add dwarf2/leb.c.
15177 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
15178 * gdb/remote.c (remote_console_output): Update.
15179 * gdb/ui-file.c (fputs_unfiltered): Rename to...
15180 (ui_file_puts): ...this.
15181 * gdb/ui-file.h (ui_file_puts): Add declaration.
15182 * gdb/utils.c (emit_style_escape): Update.
15183 (flush_wrap_buffer): Update.
15184 (fputs_maybe_filtered): Update.
15185 (fputs_unfiltered): Add function.
15189 * gdb/event-loop.c (gdb_wait_for_event): Update.
15190 * gdb/printcmd.c (printf_command): Update.
15191 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
15192 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
15193 (gdb_os_flush_stderr): Update.
15194 * gdb/remote.c (remote_console_output): Update.
15195 * gdb/ui-file.c (gdb_flush): Rename to...
15196 (ui_file_flush): ...this.
15197 (stderr_file::write): Update.
15198 (stderr_file::puts): Update.
15199 * gdb/ui-file.h (gdb_flush): Rename to...
15200 (ui_file_flush): ...this.
15201 * gdb/utils.c (gdb_flush): Add function.
15202 * gdb/utils.h (gdb_flush): Add declaration.
15206 PR breakpoints/24915:
15207 * source.c (find_and_open_source): Do not check basenames_may_differ.
15211 * README: Update gdbserver documentation.
15212 * gdbserver: Move to top level.
15213 * configure.tgt (build_gdbserver): Remove.
15214 * configure.ac: Remove --enable-gdbserver.
15215 * configure: Rebuild.
15216 * Makefile.in (distclean): Don't mention gdbserver.
15220 * source-cache.c (source_cache::ensure): Surround
15221 get_plain_source_lines with a try/catch.
15222 (source_cache::get_line_charpos): Get rid of try/catch
15223 and only check for the return value of "ensure".
15224 * tui/tui-source.c (tui_source_window::set_contents):
15225 Simplify "nlines" calculation.
15229 * MAINTAINERS (Write After Approval): Add myself.
15233 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
15238 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
15242 * nat/riscv-linux-tdesc.h: New file.
15243 * nat/riscv-linux-tdesc.c: New file, taking code from...
15244 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
15246 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
15251 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
15252 we don't set the fake simulator ptid to the null_ptid.
15256 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
15257 * gdbthread.h (class thread_info) <resumed>: Likewise.
15258 * infrun.c (resume_1): Likewise.
15259 (proceed): Likewise.
15260 (infrun_thread_stop_requested): Likewise.
15261 (stop_all_threads): Likewise.
15262 (handle_inferior_event): Likewise.
15263 (restart_threads): Likewise.
15264 (finish_step_over): Likewise.
15265 (keep_going_stepped_thread): Likewise.
15266 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
15267 (linux_handle_extended_wait): Likewise.
15268 * record-btrace.c (get_thread_current_frame_id): Likewise.
15269 * record-full.c (record_full_wait_1): Likewise.
15270 * remote.c (remote_target::process_initial_stop_replies): Likewise.
15271 * target.c (target_resume): Likewise.
15272 * thread.c (set_running_thread): Likewise.
15276 * f-valprint.c (f77_print_array_1): Changed datatype of index
15277 variable to LONGEST from int to enable it to contain bound
15282 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
15283 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
15284 offsets according to FLEN determined.
15285 (riscv_linux_nat_target::read_description): Determine FLEN
15287 (riscv_linux_nat_target::fetch_registers): Size regset buffer
15288 according to FLEN determined.
15289 (riscv_linux_nat_target::store_registers): Likewise.
15293 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
15294 when reg->group is empty and reggroup is not.
15298 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
15299 Call beneath target's mourn_inferior after unpushing.
15304 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
15305 have enough lines to fill the screen, still return the lowest
15310 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
15311 '-', '<', and '>' commands.
15316 * infcmd.c (construct_inferior_arguments): Assert that
15317 'argc' is greater than 0.
15321 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
15322 (BRK_INSN_MASK): Define to 0xd4200000.
15323 (aarch64_program_breakpoint_here_p): New function.
15324 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
15325 * arch-utils.c (default_program_breakpoint_here_p): Moved from
15327 * arch-utils.h (default_program_breakpoint_here_p): Moved from
15329 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
15330 call gdbarch_program_breakpoint_here_p.
15331 (program_breakpoint_here): Moved to arch-utils.c, renamed to
15332 default_program_breakpoint_here_p, changed return type to bool and
15334 * breakpoint.h (program_breakpoint_here): Moved prototype to
15335 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
15336 return type to bool.
15337 * gdbarch.c: Regenerate.
15338 * gdbarch.h: Regenerate.
15339 * gdbarch.sh (program_breakpoint_here_p): New method.
15340 * infrun.c (handle_signal_stop): Call
15341 gdbarch_program_breakpoint_here_p.
15345 * ctfread.c (struct ctf_fp_info): Reindent.
15346 (_initialize_ctfread): Remove.
15350 * psymtab.c (partial_map_expand_apply)
15351 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
15352 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
15353 (psym_print_stats, psym_expand_symtabs_for_function)
15354 (psym_map_symbol_filenames, psym_map_matching_symbols)
15355 (psym_expand_symtabs_matching)
15356 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
15357 (maintenance_check_psymtabs): Use new methods.
15358 * psympriv.h (struct partial_symtab) <readin_p,
15359 get_compunit_symtab>: New methods.
15360 <readin, compunit_symtab>: Remove members.
15361 (struct standard_psymtab): New.
15362 (struct legacy_psymtab): Derive from standard_psymtab.
15363 * dwarf2read.h (struct dwarf2_psymtab): Derive from
15365 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
15369 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
15370 read_dependencies. Add assert.
15371 * psymtab.c (partial_symtab::read_dependencies): New method.
15372 * psympriv.h (struct partial_symtab) <read_dependencies>: New
15374 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
15375 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
15377 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
15382 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
15383 Call expand_psymtab.
15384 (xcoff_read_symtab): Call expand_psymtab.
15385 (xcoff_start_psymtab, xcoff_end_psymtab): Set
15386 legacy_expand_psymtab.
15387 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
15389 (struct legacy_psymtab) <expand_psymtab>: Implement.
15390 <legacy_expand_psymtab>: New member.
15391 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
15392 (parse_partial_symbols): Set legacy_expand_psymtab.
15393 (psymtab_to_symtab_1): Change argument order. Call
15395 (new_psymtab): Set legacy_expand_psymtab.
15396 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
15397 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
15399 (dwarf2_psymtab::expand_psymtab): Rename from
15400 psymtab_to_symtab_1. Call expand_psymtab.
15401 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
15402 (dbx_end_psymtab): Likewise.
15403 (dbx_psymtab_to_symtab_1): Change argument order. Call
15405 (dbx_read_symtab): Call expand_psymtab.
15406 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
15407 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
15408 (ctf_psymtab::read_symtab): Call expand_psymtab.
15412 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
15413 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
15415 * mdebugread.c (mdebug_read_symtab): Remove prints.
15416 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
15418 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
15422 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
15423 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
15424 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
15426 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
15427 * psymtab.c (psymtab_to_symtab): Call method.
15428 (dump_psymtab): Update.
15429 * psympriv.h (struct partial_symtab): Add virtual destructor.
15430 <read_symtab>: New method.
15431 (struct legacy_symtab): New.
15432 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
15433 (struct pst_map) <pst>: Now a legacy_psymtab.
15434 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
15435 (new_psymtab): Use legacy_psymtab.
15436 * dwarf2read.h (struct dwarf2_psymtab): New.
15437 (struct dwarf2_per_cu_data) <psymtab>: Use it.
15438 * dwarf2read.c (dwarf2_create_include_psymtab)
15439 (dwarf2_build_include_psymtabs, create_type_unit_group)
15440 (create_partial_symtab, process_psymtab_comp_unit_reader)
15441 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
15442 (set_partial_user): Use dwarf2_psymtab.
15443 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
15444 (psymtab_to_symtab_1, process_full_comp_unit)
15445 (process_full_type_unit, dwarf2_ranges_read)
15446 (dwarf2_get_pc_bounds, psymtab_include_file_name)
15447 (dwarf_decode_lines): Use dwarf2_psymtab.
15448 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
15449 (add_address_entry_worker, write_one_signatured_type)
15450 (recursively_count_psymbols, recursively_write_psymbols)
15451 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
15452 (write_debug_names): Likewise.
15453 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
15454 <pst>: Now a legacy_psymtab.
15455 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
15456 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
15457 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
15458 * ctfread.c (struct ctf_psymtab): New.
15459 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
15461 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
15462 (create_partial_symtab): Return a ctf_psymtab.
15463 (scan_partial_symbols): Update.
15467 * xcoffread.c (xcoff_start_psymtab): Use new.
15468 * psymtab.c (partial_symtab::partial_symtab): New constructor,
15469 renamed from start_psymtab_common.
15470 * psympriv.h (struct partial_symtab): Add new constructor.
15471 (start_psymtab_common): Don't declare.
15472 * mdebugread.c (parse_partial_symbols): Use new.
15473 * dwarf2read.c (create_partial_symtab): Use new.
15474 * dbxread.c (start_psymtab): Use new.
15475 * ctfread.c (create_partial_symtab): Use new.
15479 * xcoffread.c (xcoff_end_psymtab): Use new.
15480 * psymtab.c (start_psymtab_common): Use new.
15481 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
15483 * psympriv.h (struct partial_symtab): Add parameters to
15484 constructor. Don't inline.
15485 (allocate_psymtab): Don't declare.
15486 * mdebugread.c (new_psymtab): Use new.
15487 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
15488 * dbxread.c (dbx_end_psymtab): Use new.
15492 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
15493 allocate_psymtab. Update documentation.
15494 * psymtab.c (psymtab_storage::install_psymtab): Rename from
15495 allocate_psymtab. Do not use new.
15496 (allocate_psymtab): Use new. Update.
15500 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
15501 * psymtab.c (psym_print_stats): Update.
15502 * psympriv.h (struct partial_symtab) <readin,
15503 psymtabs_addrmap_supported, anonymous>: Now bool.
15504 * mdebugread.c (psymtab_to_symtab_1): Update.
15505 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
15506 (build_type_psymtabs_reader, psymtab_to_symtab_1)
15507 (process_full_comp_unit, process_full_type_unit): Update.
15508 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
15509 * ctfread.c (psymtab_to_symtab): Update.
15513 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
15514 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
15515 * psymtab.c (psymtab_storage): Delete psymtabs.
15516 (psymtab_storage::allocate_psymtab): Use new.
15517 (psymtab_storage::discard_psymtab): Use delete.
15518 * psympriv.h (struct partial_symtab): Add constructor and
15523 * machoread.c: Do not include psympriv.h.
15527 * NEWS: Mention the new option and the set/show commands.
15531 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
15532 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
15533 (validate_exec_file): New variables, enums, functions.
15534 (exec_file_locate_attach, print_section_info): Style the filenames.
15535 (_initialize_exec): Install show_exec_file_mismatch_command and
15536 set_exec_file_mismatch_command.
15537 * gdbcore.h (validate_exec_file): Declare.
15538 * infcmd.c (attach_command): Call validate_exec_file.
15539 * remote.c ( remote_target::remote_add_inferior): Likewise.
15543 * frame.c (find_frame_sal): Move call to get_next_frame into more
15545 * inline-frame.c (inilne_state) <inline_state>: Update argument
15547 (inilne_state) <skipped_symbol>: Rename to...
15548 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
15549 (skip_inline_frames): Build vector of skipped symbols and use this
15550 to reate the inline_state.
15551 (inline_skipped_symbol): Add a comment and some assertions, fetch
15552 skipped symbol from the list.
15556 * buildsym.c (lte_is_less_than): Delete.
15557 (buildsym_compunit::end_symtab_with_blockvector): Create local
15558 lambda function to sort line table entries, and use
15559 std::stable_sort instead of std::sort.
15560 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
15561 markers when looking for a previous line.
15565 * dwarf2read.c (lnp_state_machine::record_line): Include
15566 end_sequence parameter in debug print out. Record the line if we
15567 are at an end_sequence marker even if it's not the start of a
15569 * symmisc.c (maintenance_print_one_line_table): Print end of
15570 sequence markers with 'END' not '0'.
15575 * thread.c (scoped_restore_current_thread::restore): Use
15576 switch_to_inferior_no_thread.
15577 * exec.c: Include "progspace-and-thread.h".
15578 (add_target_sections, remove_target_sections):
15579 scoped_restore_current_pspace_and_thread instead of
15580 scoped_restore_current_thread.
15581 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
15582 and aspace to the inferior before calling clone_program_space.
15583 Remove stale comment.
15587 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
15588 (arm_netbsd_nat_target::fetch_registers): ...this.
15589 (arm_nbsd_nat_target::store_registers): Rename to...
15590 (arm_netbsd_nat_target::store_registers): ...this.
15594 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
15599 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
15601 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
15603 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
15604 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
15605 the correct replacement (iterate_over_regset_sections).
15606 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
15612 * gdb/python/python.c (execute_gdb_command): Call
15613 async_enable_stdin in catch block.
15617 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
15618 SWITCH_THRU_ALL_UIS.
15623 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
15624 comment, add extra parameter, and update to store previous symbol
15626 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
15627 add extra parameter.
15628 * tui/tui-disasm.c (tui_disassemble): Update header comment,
15629 remove unneeded parameter, add try/catch around gdb_print_insn,
15630 rewrite to add items to asm_lines vector.
15631 (tui_find_backward_disassembly_start_address): New function.
15632 (tui_find_disassembly_address): Updated throughout.
15633 (tui_disasm_window::set_contents): Update for changes to
15635 (tui_disasm_window::do_scroll_vertical): No need to adjust the
15636 number of lines to scroll.
15640 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
15641 (SECT_OFF_DATA): Likewise.
15642 (SECT_OFF_RODATA): Likewise.
15643 (SECT_OFF_TEXT): Likewise.
15644 (SECT_OFF_BSS): Likewise.
15645 (struct objfile) <text_section_offset, data_section_offset>: New
15647 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
15648 objfile::text_section_offset.
15649 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
15650 * coffread.c (coff_symtab_read): Likewise.
15651 (enter_linenos): Likewise.
15652 (process_coff_symbol): Likewise.
15653 * ctfread.c (get_objfile_text_range): Likewise.
15654 * dtrace-probe.c (dtrace_probe::get_relocated_address):
15655 Use objfile::data_section_offset.
15656 * dwarf2-frame.c (execute_cfa_program): Use
15657 objfile::text_section_offset.
15658 (dwarf2_frame_find_fde): Likewise.
15659 * dwarf2read.c (create_addrmap_from_index): Likewise.
15660 (create_addrmap_from_aranges): Likewise.
15661 (dw2_find_pc_sect_compunit_symtab): Likewise.
15662 (process_psymtab_comp_unit_reader): Likewise.
15663 (add_partial_symbol): Likewise.
15664 (add_partial_subprogram): Likewise.
15665 (process_full_comp_unit): Likewise.
15666 (read_file_scope): Likewise.
15667 (read_func_scope): Likewise.
15668 (read_lexical_block_scope): Likewise.
15669 (read_call_site_scope): Likewise.
15670 (dwarf2_rnglists_process): Likewise.
15671 (dwarf2_ranges_process): Likewise.
15672 (dwarf2_ranges_read): Likewise.
15673 (dwarf_decode_lines_1): Likewise.
15674 (new_symbol): Likewise.
15675 (dwarf2_fetch_die_loc_sect_off): Likewise.
15676 (dwarf2_per_cu_text_offset): Likewise.
15677 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
15678 * hppa-tdep.c (read_unwind_info): Likewise.
15679 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
15680 * psympriv.h (struct partial_symtab): Likewise.
15681 * psymtab.c (find_pc_sect_psymtab): Likewise.
15682 * solib-svr4.c (enable_break): Likewise.
15683 * stap-probe.c (relocate_address): Use
15684 objfile::data_section_offset.
15685 * xcoffread.c (enter_line_range): Use
15686 objfile::text_section_offset.
15687 (read_xcoff_symtab): Likewise.
15691 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
15692 declaration to narrower scopes.
15696 * darwin-nat.h (struct darwin_exception_msg, enum
15697 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
15699 (class darwin_nat_target) <wait_1, check_new_threads,
15700 decode_exception_message, decode_message, stop_inferior,
15701 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
15702 * darwin-nat.c (darwin_check_new_threads): Rename to...
15703 (darwin_nat_target::check_new_threads): ... this.
15704 (darwin_suspend_inferior_it): Remove.
15705 (darwin_decode_exception_message): Rename to...
15706 (darwin_nat_target::decode_exception_message): ... this.
15707 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
15708 (darwin_decode_message): Rename to...
15709 (darwin_nat_target::decode_message): ... this.
15710 (cancel_breakpoint): Rename to...
15711 (darwin_nat_target::cancel_breakpoint): ... this.
15712 (darwin_wait): Rename to...
15713 (darwin_nat_target::wait_1): ... this. Use range-based for loop
15714 instead of iterate_over_inferiors.
15715 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
15716 (darwin_stop_inferior): Rename to...
15717 (darwin_nat_target::stop_inferior): ... this.
15718 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
15719 (darwin_init_thread_list): Rename to...
15720 (darwin_nat_target::init_thread_list): ... this.
15721 (darwin_ptrace_him): Rename to...
15722 (darwin_nat_target::ptrace_him): ... this.
15723 (darwin_nat_target::create_inferior): Pass lambda function to
15725 (darwin_nat_target::detach): Call stop_inferior instead of
15726 darwin_stop_inferior.
15727 * fork-inferior.h (fork_inferior): Change init_trace_fun
15728 parameter to gdb::function_view.
15729 * fork-inferior.c (fork_inferior): Likewise.
15733 * i386-cygwin-tdep.c (core_process_module_section): Update.
15734 * windows-nat.c (struct lm_info_windows): Add text_offset.
15735 (windows_xfer_shared_libraries): Update.
15736 * windows-tdep.c (windows_xfer_shared_library):
15737 Add text_offset_cached argument.
15738 * windows-tdep.h (windows_xfer_shared_library): Update.
15742 * gdbarch.sh: Add declaration for _initialize_gdbarch.
15746 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
15747 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
15748 replace with range-based for.
15749 (gdbsim_interrupt_inferior): Remove.
15750 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
15751 with a range-based for. Inline code from
15752 gdbsim_interrupt_inferior.
15756 * infrun.c (proceed): Fix indentation.
15760 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
15761 * python/python.c (python_extension_ops): Update.
15762 (gdbpy_colorize): New function.
15763 * python/lib/gdb/__init__.py (colorize): New function.
15764 * extension.h (ext_lang_colorize): Declare.
15765 * extension.c (ext_lang_colorize): New function.
15766 * extension-priv.h (struct extension_language_ops) <colorize>: New
15768 * cli/cli-style.c (_initialize_cli_style): Update help text.
15772 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
15773 <cond>: Change type to bool.
15774 (aarch64_displaced_step_b_cond): Update cond to use bool type.
15775 (aarch64_displaced_step_cb): Likewise.
15776 (aarch64_displaced_step_tb): Likewise.
15780 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
15785 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
15786 <pc_adjust>: Adjust the documentation.
15787 (aarch64_displaced_step_fixup): Check if PC really moved before
15792 * disasm.c (~gdb_disassembler): New destructor.
15793 (gdb_buffered_insn_length): Call disassemble_free_target.
15794 * disasm.h (class gdb_disassembler): Declare destructor. Use
15795 DISABLE_COPY_AND_ASSIGN.
15799 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
15800 (die_reader_func_ftype): Remove.
15801 (cutu_reader): New class.
15802 (dw2_get_file_names_reader): Remove "data" parameter.
15803 (dw2_get_file_names): Use cutu_reader.
15804 (create_debug_type_hash_table): Update.
15805 (read_cutu_die_from_dwo): Update comment.
15806 (lookup_dwo_unit): Add dwo_name parameter.
15807 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
15808 die_reader_func_ftype and data parameters.
15809 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
15810 Remove die_reader_func_ftype and data parameters.
15811 (~cutu_reader): New; from init_cutu_and_read_dies.
15812 (cutu_reader::cutu_reader): Rename from
15813 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
15814 and data parameters.
15815 (init_cutu_and_read_dies_simple): Remove.
15816 (struct process_psymtab_comp_unit_data): Remove.
15817 (process_psymtab_comp_unit_reader): Remove data parameter; add
15818 want_partial_unit and pretend_language parameters.
15819 (process_psymtab_comp_unit): Use cutu_reader.
15820 (build_type_psymtabs_reader): Remove data parameter.
15821 (build_type_psymtabs_1): Use cutu_reader.
15822 (process_skeletonless_type_unit): Likewise.
15823 (load_partial_comp_unit_reader): Remove.
15824 (load_partial_comp_unit): Use cutu_reader.
15825 (load_full_comp_unit_reader): Remove.
15826 (load_full_comp_unit): Use cutu_reader.
15827 (struct create_dwo_cu_data): Remove.
15828 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
15829 dwo_unit parameters.
15830 (create_cus_hash_table): Use cutu_reader.
15831 (struct dwarf2_read_addr_index_data): Remove.
15832 (dwarf2_read_addr_index_reader): Remove.
15833 (dwarf2_read_addr_index): Use cutu_reader.
15834 (read_signatured_type_reader): Remove.
15835 (read_signatured_type): Use cutu_reader.
15839 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
15840 * tui/tui-wingeneral.h (class tui_suppress_output): New.
15841 (tui_wrefresh): Declare.
15842 * tui/tui-wingeneral.c (suppress_output): New global.
15843 (tui_suppress_output, ~tui_suppress_output): New constructor and
15845 (tui_wrefresh): New function.
15846 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
15847 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
15848 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
15850 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
15852 (tui_data_window::no_refresh): New method.
15853 (tui_data_item_window::refresh_window): Call tui_wrefresh.
15854 (tui_reg_command): Use tui_suppress_output
15855 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
15856 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
15858 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
15862 * tui/tui-winsource.c (tui_update_source_windows_with_line):
15863 Handle case where symtab is null.
15867 * linux-fork.c (one_fork_p): Simplify.
15871 * top.c (struct qt_args): Remove.
15872 (kill_or_detach): Change return type to void, replace `void *`
15873 parameter with a proper one.
15874 (print_inferior_quit_action): Likewise.
15875 (quit_confirm): Use range-based for loop to iterate over inferiors.
15876 (quit_force): Likewise.
15880 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
15881 `void *` parameter with proper parameters.
15882 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
15883 (print_one_inferior): Change return type to void, replace `void *`
15884 parameter with proper parameters.
15885 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
15887 (get_other_inferior): Remove.
15888 (mi_cmd_remove_inferior): Use range-based loop to iterate over
15893 * mi/mi-interp.c (report_initial_inferior): Remove.
15894 (mi_interp::init): Use range-based for to iterate over inferiors.
15898 * python/py-inferior.c (build_inferior_list): Remove.
15899 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
15903 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
15904 (btrace_stitch_trace): Likewise.
15905 * charset.c (intermediate_encoding): Likewise (vaild).
15906 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
15907 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
15908 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
15912 * windows-tdep.c (windows_get_tlb_type):
15913 Add rtl_user_process_parameters type.
15919 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
15920 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
15921 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
15922 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
15923 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
15924 (ps_plog): Redeclare exported functions with default visibility.
15928 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
15929 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
15933 * infcmd.c (post_create_inferior): Use get_thread_regcache
15934 instead of get_current_regcache.
15939 * python/python.c (gdbpy_decode_line): Treat empty string the same
15944 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
15948 * nat/linux-btrace.c: Don't include <config.h>.
15949 * nat/linux-ptrace.c: Don't include <config.h>.
15950 * nat/x86-linux-dregs.c: Don't include <config.h>.
15954 * configure: Rebuild.
15955 * configure.ac: Move many checks to ../gdbsupport/common.m4.
15959 * nat/x86-linux-dregs.c: Include configh.h.
15960 * nat/linux-ptrace.c: Include configh.h.
15961 * nat/linux-btrace.c: Include configh.h.
15962 * defs.h: Include config.h, bfd.h.
15963 * configure.ac: Don't source common.host.
15964 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
15965 * configure: Rebuild.
15966 * acinclude.m4: Update path.
15967 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
15968 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
15969 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
15970 (CLIBS): Add LIBSUPPORT.
15972 (COMMON_SFILES): Remove gdbsupport files.
15973 (HFILES_NO_SRCDIR): Likewise.
15974 (stamp-version): Update path to create-version.sh.
15975 (ALLDEPFILES): Remove gdbsupport files.
15979 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
15980 USE_WIN32API when needed.
15981 * configure.ac (USE_WIN32API): Don't define.
15982 (WIN32LIBS): Use WIN32APILIBS.
15983 * configure: Rebuild.
15987 * configure: Rebuild.
15988 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
15992 * skip.c (skip_function_command): Make skip w/o arguments use the
15993 name of the inlined function if pc is inside any inlined function.
15997 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
15998 * infrun.c (resume_1): Likewise.
15999 (handle_inferior_event): Remove stale comment.
16000 * linux-nat.c (linux_nat_target::resume): Update comments.
16001 (save_stop_reason): Likewise.
16002 (linux_nat_filter_event): Likewise.
16003 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
16007 * elfread.c (record_minimal_symbol): Set section index to 0 for
16008 non-allocatable sections.
16013 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
16014 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
16015 to gdb::optional. Update comments.
16016 (dwo_file): Update comments.
16017 (read_attribute): Update API to take an additional out parameter,
16018 need_reprocess. This is used to mark attributes that need other
16019 attributes (e.g. str_offsets_base) for correct computation which may not
16020 have been read yet.
16021 (read_attribute_reprocess): New function declaration.
16022 (read_addr_index): Likewise.
16023 (read_dwo_str_index): Likewise.
16024 (read_stub_str_index): Likewise.
16025 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
16026 (lookup_addr_base): New function definition.
16027 (lookup_ranges_base): Likewise.
16028 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
16029 lookup_ranges_base.
16030 (init_cutu_and_read_dies): Update comments.
16031 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
16032 unit. This is used to inherit parent's str_offsets_base and addr_base.
16034 (init_cutu_and_read_dies_simple): Reflect API changes.
16035 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
16036 (create_cus_hash_table): Change API to take parent compile unit.
16037 Reflect API changes.
16038 (open_and_init_dwo_file): Reflect API changes.
16039 (dwarf2_get_pc_bounds): Update comments.
16040 (dwarf2_record_block_ranges): Likewise.
16041 (read_full_die_1): Change implementation to reprocess attributes that
16042 need str_offsets_base and addr_base.
16043 (partial_die_info::read): Likewise.
16044 (read_attribute_reprocess): New function definition.
16045 (read_attribute_value): Change API to take an additional out parameter,
16046 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
16047 when a non-dwo compile unit has index based attributes.
16048 (read_attribute): Reflect API changes.
16049 (read_addr_index_1): Reflect API changes. Update comments.
16050 (dwarf2_read_addr_index_data): Reflect API changes.
16051 (dwarf2_read_addr_index): Likewise.
16052 (read_str_index): Change API and implementation. This becomes a helper
16053 to be used by the new string index related methods. Update error
16054 message and comments.
16055 (read_dwo_str_index): New function definition.
16056 (read_stub_str_index): Likewise.
16057 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
16058 * symfile.h (dwarf2_debug_sections): Likewise.
16059 * xcoffread.c (dwarf2_debug_sections): Likewise.
16063 * gdbcore.h (struct core_fns) <core_read_registers>: Change
16064 core_reg_sect type to gdb_byte *.
16065 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
16066 * cris-tdep.c (fetch_core_registers): Likewise.
16067 * corelow.c (core_target::get_core_register_section): Change
16068 type of `contents` to gdb::byte_vector.
16072 * tui/tui-wingeneral.c (box_win): Position the title in the center
16077 * corelow.c (core_target::get_core_register_section): Use
16078 std::vector instead of alloca.
16082 * warning.m4: Add -Wmissing-declarations to build_warnings.
16083 * configure: Re-generate.
16087 * python/python.c (init__gdb_module): Add declaration.
16091 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
16092 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
16093 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
16094 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
16095 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
16096 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
16097 * ada-exp.y (_initialize_ada_exp): Add declaration.
16098 * ada-lang.c (_initialize_ada_language): Add declaration.
16099 * ada-tasks.c (_initialize_tasks): Add declaration.
16100 * agent.c (_initialize_agent): Add declaration.
16101 * aix-thread.c (_initialize_aix_thread): Add declaration.
16102 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
16103 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
16104 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
16105 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
16106 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
16107 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
16108 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
16109 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
16110 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
16111 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
16112 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
16113 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
16114 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
16115 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
16116 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
16117 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
16118 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
16119 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
16120 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
16121 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
16122 * annotate.c (_initialize_annotate): Add declaration.
16123 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
16124 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
16125 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
16126 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
16127 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
16128 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
16129 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
16130 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
16131 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
16132 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
16133 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
16134 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
16135 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
16136 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
16137 * auto-load.c (_initialize_auto_load): Add declaration.
16138 * auxv.c (_initialize_auxv): Add declaration.
16139 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
16140 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
16141 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
16142 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
16143 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
16144 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
16145 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
16146 * breakpoint.c (_initialize_breakpoint): Add declaration.
16147 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
16148 * btrace.c (_initialize_btrace): Add declaration.
16149 * charset.c (_initialize_charset): Add declaration.
16150 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
16151 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
16152 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
16153 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
16154 * cli/cli-script.c (_initialize_cli_script): Add declaration.
16155 * cli/cli-style.c (_initialize_cli_style): Add declaration.
16156 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
16157 * coffread.c (_initialize_coffread): Add declaration.
16158 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
16159 * compile/compile.c (_initialize_compile): Add declaration.
16160 * complaints.c (_initialize_complaints): Add declaration.
16161 * completer.c (_initialize_completer): Add declaration.
16162 * copying.c (_initialize_copying): Add declaration.
16163 * corefile.c (_initialize_core): Add declaration.
16164 * corelow.c (_initialize_corelow): Add declaration.
16165 * cp-abi.c (_initialize_cp_abi): Add declaration.
16166 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
16167 * cp-support.c (_initialize_cp_support): Add declaration.
16168 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
16169 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
16170 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
16171 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
16172 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
16173 * ctfread.c (_initialize_ctfread): Add declaration.
16174 * d-lang.c (_initialize_d_language): Add declaration.
16175 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
16176 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
16177 * dbxread.c (_initialize_dbxread): Add declaration.
16178 * dcache.c (_initialize_dcache): Add declaration.
16179 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
16180 * disasm.c (_initialize_disasm): Add declaration.
16181 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
16182 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
16183 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
16184 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
16185 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
16186 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
16187 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
16188 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
16189 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
16190 * elfread.c (_initialize_elfread): Add declaration.
16191 * exec.c (_initialize_exec): Add declaration.
16192 * extension.c (_initialize_extension): Add declaration.
16193 * f-lang.c (_initialize_f_language): Add declaration.
16194 * f-valprint.c (_initialize_f_valprint): Add declaration.
16195 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
16196 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
16197 * filesystem.c (_initialize_filesystem): Add declaration.
16198 * findcmd.c (_initialize_mem_search): Add declaration.
16199 * findvar.c (_initialize_findvar): Add declaration.
16200 * fork-child.c (_initialize_fork_child): Add declaration.
16201 * frame-base.c (_initialize_frame_base): Add declaration.
16202 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
16203 * frame.c (_initialize_frame): Add declaration.
16204 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
16205 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
16206 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
16207 * gcore.c (_initialize_gcore): Add declaration.
16208 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
16209 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
16210 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
16211 * gdbarch.c (_initialize_gdbarch): Add declaration.
16212 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
16213 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
16214 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
16215 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
16216 * go-lang.c (_initialize_go_language): Add declaration.
16217 * go32-nat.c (_initialize_go32_nat): Add declaration.
16218 * guile/guile.c (_initialize_guile): Add declaration.
16219 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
16220 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
16221 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
16222 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
16223 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
16224 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
16225 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
16226 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
16227 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
16228 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
16229 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
16230 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
16231 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
16232 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
16233 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
16234 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
16235 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
16236 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
16237 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
16238 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
16239 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
16240 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
16241 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
16242 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
16243 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
16244 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
16245 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
16246 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
16247 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
16248 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
16249 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
16250 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
16251 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
16252 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
16253 * infcall.c (_initialize_infcall): Add declaration.
16254 * infcmd.c (_initialize_infcmd): Add declaration.
16255 * inflow.c (_initialize_inflow): Add declaration.
16256 * infrun.c (_initialize_infrun): Add declaration.
16257 * interps.c (_initialize_interpreter): Add declaration.
16258 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
16259 * jit.c (_initialize_jit): Add declaration.
16260 * language.c (_initialize_language): Add declaration.
16261 * linux-fork.c (_initialize_linux_fork): Add declaration.
16262 * linux-nat.c (_initialize_linux_nat): Add declaration.
16263 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
16264 * linux-thread-db.c (_initialize_thread_db): Add declaration.
16265 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
16266 * m2-lang.c (_initialize_m2_language): Add declaration.
16267 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
16268 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
16269 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
16270 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
16271 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
16272 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
16273 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
16274 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
16275 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
16276 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
16277 * machoread.c (_initialize_machoread): Add declaration.
16278 * macrocmd.c (_initialize_macrocmd): Add declaration.
16279 * macroscope.c (_initialize_macroscope): Add declaration.
16280 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
16281 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
16282 * maint.c (_initialize_maint_cmds): Add declaration.
16283 * mdebugread.c (_initialize_mdebugread): Add declaration.
16284 * memattr.c (_initialize_mem): Add declaration.
16285 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
16286 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
16287 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
16288 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
16289 * mi/mi-main.c (_initialize_mi_main): Add declaration.
16290 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
16291 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
16292 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
16293 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
16294 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
16295 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
16296 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
16297 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
16298 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
16299 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
16300 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
16301 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
16302 * mipsread.c (_initialize_mipsread): Add declaration.
16303 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
16304 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
16305 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
16306 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
16307 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
16308 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
16309 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
16310 * nto-procfs.c (_initialize_procfs): Add declaration.
16311 * objc-lang.c (_initialize_objc_language): Add declaration.
16312 * observable.c (_initialize_observer): Add declaration.
16313 * opencl-lang.c (_initialize_opencl_language): Add declaration.
16314 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
16315 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
16316 * osabi.c (_initialize_gdb_osabi): Add declaration.
16317 * osdata.c (_initialize_osdata): Add declaration.
16318 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
16319 * parse.c (_initialize_parse): Add declaration.
16320 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
16321 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
16322 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
16323 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
16324 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
16325 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
16326 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
16327 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
16328 * printcmd.c (_initialize_printcmd): Add declaration.
16329 * probe.c (_initialize_probe): Add declaration.
16330 * proc-api.c (_initialize_proc_api): Add declaration.
16331 * proc-events.c (_initialize_proc_events): Add declaration.
16332 * proc-service.c (_initialize_proc_service): Add declaration.
16333 * procfs.c (_initialize_procfs): Add declaration.
16334 * producer.c (_initialize_producer): Add declaration.
16335 * psymtab.c (_initialize_psymtab): Add declaration.
16336 * python/python.c (_initialize_python): Add declaration.
16337 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
16338 * record-btrace.c (_initialize_record_btrace): Add declaration.
16339 * record-full.c (_initialize_record_full): Add declaration.
16340 * record.c (_initialize_record): Add declaration.
16341 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
16342 * regcache.c (_initialize_regcache): Add declaration.
16343 * reggroups.c (_initialize_reggroup): Add declaration.
16344 * remote-notif.c (_initialize_notif): Add declaration.
16345 * remote-sim.c (_initialize_remote_sim): Add declaration.
16346 * remote.c (_initialize_remote): Add declaration.
16347 * reverse.c (_initialize_reverse): Add declaration.
16348 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
16349 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
16350 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
16351 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
16352 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
16353 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
16354 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
16355 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
16357 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
16358 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
16359 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
16360 * rust-exp.y (_initialize_rust_exp): Add declaration.
16361 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
16362 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
16363 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
16364 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
16365 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
16366 * score-tdep.c (_initialize_score_tdep): Add declaration.
16367 * ser-go32.c (_initialize_ser_dos): Add declaration.
16368 * ser-mingw.c (_initialize_ser_windows): Add declaration.
16369 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
16370 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
16371 * ser-uds.c (_initialize_ser_socket): Add declaration.
16372 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
16373 * serial.c (_initialize_serial): Add declaration.
16374 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
16375 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
16376 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
16377 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
16378 * skip.c (_initialize_step_skip): Add declaration.
16379 * sol-thread.c (_initialize_sol_thread): Add declaration.
16380 * solib-aix.c (_initialize_solib_aix): Add declaration.
16381 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
16382 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
16383 * solib-frv.c (_initialize_frv_solib): Add declaration.
16384 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
16385 * solib-target.c (_initialize_solib_target): Add declaration.
16386 * solib.c (_initialize_solib): Add declaration.
16387 * source-cache.c (_initialize_source_cache): Add declaration.
16388 * source.c (_initialize_source): Add declaration.
16389 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
16390 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
16391 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
16392 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
16393 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
16394 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
16395 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
16396 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
16397 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
16398 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
16399 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
16400 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
16401 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
16402 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
16403 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
16404 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
16405 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
16406 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
16407 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
16408 * stabsread.c (_initialize_stabsread): Add declaration.
16409 * stack.c (_initialize_stack): Add declaration.
16410 * stap-probe.c (_initialize_stap_probe): Add declaration.
16411 * std-regs.c (_initialize_frame_reg): Add declaration.
16412 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
16413 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
16414 * symfile.c (_initialize_symfile): Add declaration.
16415 * symmisc.c (_initialize_symmisc): Add declaration.
16416 * symtab.c (_initialize_symtab): Add declaration.
16417 * target.c (_initialize_target): Add declaration.
16418 * target-connection.c (_initialize_target_connection): Add
16420 * target-dcache.c (_initialize_target_dcache): Add declaration.
16421 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
16422 * thread.c (_initialize_thread): Add declaration.
16423 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
16424 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
16425 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
16426 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
16427 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
16428 * tracectf.c (_initialize_ctf): Add declaration.
16429 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
16430 * tracefile.c (_initialize_tracefile): Add declaration.
16431 * tracepoint.c (_initialize_tracepoint): Add declaration.
16432 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
16433 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
16434 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
16435 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
16436 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
16437 * tui/tui-win.c (_initialize_tui_win): Add declaration.
16438 * tui/tui.c (_initialize_tui): Add declaration.
16439 * typeprint.c (_initialize_typeprint): Add declaration.
16440 * ui-style.c (_initialize_ui_style): Add declaration.
16441 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
16442 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
16443 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
16444 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
16445 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
16446 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
16447 * unittests/filtered_iterator-selftests.c
16448 (_initialize_filtered_iterator_selftests): Add declaration.
16449 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
16450 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
16451 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
16452 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
16453 * unittests/main-thread-selftests.c
16454 (_initialize_main_thread_selftests): Add declaration.
16455 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
16456 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
16457 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
16458 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
16459 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
16460 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
16461 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
16462 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
16463 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
16464 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
16465 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
16466 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
16467 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
16468 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
16469 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
16471 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
16472 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
16473 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
16474 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
16475 * user-regs.c (_initialize_user_regs): Add declaration.
16476 * utils.c (_initialize_utils): Add declaration.
16477 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
16478 * valops.c (_initialize_valops): Add declaration.
16479 * valprint.c (_initialize_valprint): Add declaration.
16480 * value.c (_initialize_values): Add declaration.
16481 * varobj.c (_initialize_varobj): Add declaration.
16482 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
16483 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
16484 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
16485 * windows-nat.c (_initialize_windows_nat): Add declaration.
16486 (_initialize_check_for_gdb_ini): Add declaration.
16487 (_initialize_loadable): Add declaration.
16488 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
16489 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
16490 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
16491 * xcoffread.c (_initialize_xcoffread): Add declaration.
16492 * xml-support.c (_initialize_xml_support): Add declaration.
16493 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
16494 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
16495 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
16496 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
16500 * regformats/regdat.sh: Generate declaration for init function.
16504 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
16506 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
16507 close_one_inferior>: New methods.
16508 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
16509 pass down target to find_inferior_pid.
16510 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
16511 Pass down target to find_inferior_ptid.
16512 (gdbsim_target::create_inferior): Pass down target to
16514 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
16515 target down to find_inferior_ptid and switch_to_thread.
16516 (gdbsim_target::close): Update to call close_one_inferior.
16517 (struct resume_data): Remove.
16518 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
16519 directly, rather than through a void pointer.
16520 (gdbsim_target::resume): Update to call resume_one_inferior.
16524 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
16528 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
16529 directly for the current inferior instead of
16530 discard_all_inferiors.
16531 (discard_all_inferiors): Delete.
16535 * tui/tui-wingeneral.c (box_win): Check cli_styling.
16536 * tui/tui-winsource.c (tui_source_window_base::refill): Use
16537 deprecated_safe_get_selected_frame.
16541 * inferior.c (print_inferior): Switch inferior before printing it.
16546 * progspace-and-thread.c (switch_to_program_space_and_thread):
16547 Assert there's an inferior for PSPACE. Use
16548 switch_to_inferior_no_thread to switch the inferior too.
16549 * progspace.c (program_space::~program_space): Call
16550 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
16551 (program_space::free_all_objfiles): Don't call clear_symtab_users
16553 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
16557 * NEWS: Mention multi-target debugging, "info connections", and
16558 "add-inferior -no-connection".
16562 * infrun.c: Include "target-connection.h".
16563 (check_multi_target_resumption): New.
16564 (proceed): Call it.
16565 * target-connection.c (make_target_connection_string): Make
16567 * target-connection.h (make_target_connection_string): Declare.
16571 * Makefile.in (COMMON_SFILES): Add target-connection.c.
16572 * inferior.c (uiout_field_connection): New function.
16573 (print_inferior): Add new "connection-id" column.
16574 (add_inferior_command): Show connection number/string of added
16576 * process-stratum-target.h
16577 (process_stratum_target::connection_string): New virtual method.
16578 (process_stratum_target::connection_number): New field.
16579 * remote.c (remote_target::connection_string): New override.
16580 * target-connection.c: New file.
16581 * target-connection.h: New file.
16582 * target.c (decref_target): Remove process_stratum targets from
16583 the connection list.
16584 (target_stack::push): Add process_stratum targets to the
16591 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
16592 Remove references to name.
16593 * serial.h (struct serial) <name>: Delete.
16597 * gdbarch-selftests.c (register_to_value_test): Remove "target
16598 already pushed" check.
16603 * aarch64-linux-nat.c
16604 (aarch64_linux_nat_target::thread_architecture): Adjust.
16605 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
16606 (task_command_1): Likewise.
16607 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
16608 (aix_thread_target::wait, aix_thread_target::fetch_registers)
16609 (aix_thread_target::store_registers)
16610 (aix_thread_target::thread_alive): Adjust.
16611 * amd64-fbsd-tdep.c: Include "inferior.h".
16612 (amd64fbsd_get_thread_local_address): Pass down target.
16613 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
16614 thread's gdbarch instead of target_gdbarch.
16615 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
16616 get_last_target_status.
16617 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
16618 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
16620 (update_inserted_breakpoint_locations): Skip if inferiors with no
16622 (update_global_location_list): When handling moribund locations,
16623 find representative inferior for location's pspace, and use thread
16624 count of its process_stratum target.
16625 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
16626 * bsd-uthread.c (bsd_uthread_target::wait): Use
16627 as_process_stratum_target and adjust thread_change_ptid and
16629 (bsd_uthread_target::update_thread_list): Use
16630 as_process_stratum_target and adjust find_thread_ptid,
16631 thread_change_ptid and add_thread calls.
16632 * btrace.c (maint_btrace_packet_history_cmd): Adjust
16633 find_thread_ptid call.
16634 * corelow.c (add_to_thread_list): Adjust add_thread call.
16635 (core_target_open): Adjust add_thread_silent and thread_count
16637 (core_target::pid_to_str): Adjust find_inferior_ptid call.
16638 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
16639 * event-top.c (async_disconnect): Pop targets from all inferiors.
16640 * exec.c (add_target_sections): Push exec target on all inferiors
16641 sharing the program space.
16642 (remove_target_sections): Remove the exec target from all
16643 inferiors sharing the program space.
16644 (exec_on_vfork): New.
16645 * exec.h (exec_on_vfork): Declare.
16646 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
16648 (fbsd_nat_target::update_thread_list): Adjust.
16649 (fbsd_nat_target::resume): Adjust.
16650 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
16652 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
16653 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
16654 get_thread_arch_regcache call.
16655 * fork-child.c (gdb_startup_inferior): Pass target down to
16656 startup_inferior and set_executing.
16657 * gdbthread.h (struct process_stratum_target): Forward declare.
16658 (add_thread, add_thread_silent, add_thread_with_info)
16659 (in_thread_list): Add process_stratum_target parameter.
16660 (find_thread_ptid(inferior*, ptid_t)): New overload.
16661 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
16663 (all_threads()): Delete overload.
16664 (all_threads, all_non_exited_threads): Add process_stratum_target
16666 (all_threads_safe): Use brace initialization.
16667 (thread_count): Add process_stratum_target parameter.
16668 (set_resumed, set_running, set_stop_requested, set_executing)
16669 (threads_are_executing, finish_thread_state): Add
16670 process_stratum_target parameter.
16671 (switch_to_thread): Use is_current_thread.
16672 * i386-fbsd-tdep.c: Include "inferior.h".
16673 (i386fbsd_get_thread_local_address): Pass down target.
16674 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
16675 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
16676 have_inferiors check.
16677 * inf-ptrace.c (inf_ptrace_target::create_inferior)
16678 (inf_ptrace_target::attach): Adjust.
16679 * infcall.c (run_inferior_call): Adjust.
16680 * infcmd.c (run_command_1): Pass target to
16681 scoped_finish_thread_state.
16682 (proceed_thread_callback): Skip inferiors with no execution.
16683 (continue_command): Rename 'all_threads' local to avoid hiding
16684 'all_threads' function. Adjust get_last_target_status call.
16685 (prepare_one_step): Adjust set_running call.
16686 (signal_command): Use user_visible_resume_target. Compare thread
16687 pointers instead of inferior_ptid.
16688 (info_program_command): Adjust to pass down target.
16689 (attach_command): Mark target's 'thread_executing' flag.
16690 (stop_current_target_threads_ns): New, factored out from ...
16691 (interrupt_target_1): ... this. Switch inferior before making
16694 (struct all_inferiors_iterator, struct all_inferiors_range)
16695 (struct all_inferiors_safe_range)
16696 (struct all_non_exited_inferiors_range): Filter on
16697 process_stratum_target too. Remove explicit.
16698 * inferior.c (inferior::inferior): Push dummy target on target
16700 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
16701 Add process_stratum_target parameter, and pass it down.
16702 (have_live_inferiors): Adjust.
16703 (switch_to_inferior_and_push_target): New.
16704 (add_inferior_command, clone_inferior_command): Handle
16705 "-no-connection" parameter. Use
16706 switch_to_inferior_and_push_target.
16707 (_initialize_inferior): Mention "-no-connection" option in
16708 the help of "add-inferior" and "clone-inferior" commands.
16709 * inferior.h: Include "process-stratum-target.h".
16710 (interrupt_target_1): Use bool.
16711 (struct inferior) <push_target, unpush_target, target_is_pushed,
16712 find_target_beneath, top_target, process_target, target_at,
16714 (discard_all_inferiors): Delete.
16715 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
16716 (all_inferiors, all_non_exited_inferiors): Add
16717 process_stratum_target parameter.
16718 * infrun.c: Include "gdb_select.h" and <unordered_map>.
16719 (target_last_proc_target): New global.
16720 (follow_fork_inferior): Push target on new inferior. Pass target
16721 to add_thread_silent. Call exec_on_vfork. Handle target's
16723 (follow_fork): Adjust get_last_target_status call. Also consider
16725 (follow_exec): Push target on new inferior.
16726 (struct execution_control_state) <target>: New field.
16727 (user_visible_resume_target): New.
16728 (do_target_resume): Call target_async.
16729 (resume_1): Set target's threads_executing flag. Consider resume
16731 (commit_resume_all_targets): New.
16732 (proceed): Also consider resume target. Skip threads of inferiors
16733 with no execution. Commit resumtion in all targets.
16734 (start_remote): Pass current inferior to wait_for_inferior.
16735 (infrun_thread_stop_requested): Consider target as well. Pass
16736 thread_info pointer to clear_inline_frame_state instead of ptid.
16737 (infrun_thread_thread_exit): Consider target as well.
16738 (random_pending_event_thread): New inferior parameter. Use it.
16739 (do_target_wait): Rename to ...
16740 (do_target_wait_1): ... this. Add inferior parameter, and pass it
16742 (threads_are_resumed_pending_p, do_target_wait): New.
16743 (prepare_for_detach): Adjust calls.
16744 (wait_for_inferior): New inferior parameter. Handle it. Use
16745 do_target_wait_1 instead of do_target_wait.
16746 (fetch_inferior_event): Adjust. Switch to representative
16747 inferior. Pass target down.
16748 (set_last_target_status): Add process_stratum_target parameter.
16749 Save target in global.
16750 (get_last_target_status): Add process_stratum_target parameter and
16752 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
16753 (context_switch): Check inferior_ptid == null_ptid before calling
16755 (get_inferior_stop_soon): Pass down target.
16756 (wait_one): Rename to ...
16757 (poll_one_curr_target): ... this.
16758 (struct wait_one_event): New.
16760 (stop_all_threads): Adjust.
16761 (handle_no_resumed, handle_inferior_event): Adjust to consider the
16763 (switch_back_to_stepped_thread): Also consider target.
16764 (print_stop_event): Update.
16765 (normal_stop): Update. Also consider the resume target.
16766 * infrun.h (wait_for_inferior): Remove declaration.
16767 (user_visible_resume_target): New declaration.
16768 (get_last_target_status, set_last_target_status): New
16769 process_stratum_target parameter.
16770 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
16771 process_stratum_target parameter, and use it.
16772 (clear_inline_frame_state (thread_info*)): New.
16773 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
16774 process_stratum_target parameter.
16775 (clear_inline_frame_state (thread_info*)): Declare.
16776 * linux-fork.c (delete_checkpoint_command): Pass target down to
16778 (checkpoint_command): Adjust.
16779 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
16780 instead of just tweaking inferior_ptid.
16781 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
16782 (exit_lwp): Pass target down to find_thread_ptid.
16783 (attach_proc_task_lwp_callback): Pass target down to
16784 add_thread/set_running/set_executing.
16785 (linux_nat_target::attach): Pass target down to
16786 thread_change_ptid.
16787 (get_detach_signal): Pass target down to find_thread_ptid.
16788 Consider last target status's target.
16789 (linux_resume_one_lwp_throw, resume_lwp)
16790 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
16791 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
16792 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
16793 (linux_nat_target::async_wait_fd): New.
16794 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
16796 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
16797 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
16798 * linux-thread-db.c (struct thread_db_info::process_target): New
16800 (add_thread_db_info): Save target.
16801 (get_thread_db_info): New process_stratum_target parameter. Also
16803 (delete_thread_db_info): New process_stratum_target parameter.
16805 (thread_from_lwp): Adjust to pass down target.
16806 (thread_db_notice_clone): Pass down target.
16807 (check_thread_db_callback): Pass down target.
16808 (try_thread_db_load_1): Always push the thread_db target.
16809 (try_thread_db_load, record_thread): Pass target down.
16810 (thread_db_target::detach): Pass target down. Always unpush the
16812 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
16813 target down. Always unpush the thread_db target.
16814 (find_new_threads_callback, thread_db_find_new_threads_2)
16815 (thread_db_target::update_thread_list): Pass target down.
16816 (thread_db_target::pid_to_str): Pass current inferior down.
16817 (thread_db_target::get_thread_local_address): Pass target down.
16818 (thread_db_target::resume, maintenance_check_libthread_db): Pass
16820 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
16821 * procfs.c (procfs_target::procfs_init_inferior): Declare.
16822 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
16823 (procfs_init_inferior): Rename to ...
16824 (procfs_target::procfs_init_inferior): ... this and adjust.
16825 (procfs_target::create_inferior, procfs_notice_thread)
16826 (procfs_do_thread_registers): Adjust.
16827 * ppc-fbsd-tdep.c: Include "inferior.h".
16828 (ppcfbsd_get_thread_local_address): Pass down target.
16829 * proc-service.c (ps_xfer_memory): Switch current inferior and
16830 program space as well.
16831 (get_ps_regcache): Pass target down.
16832 * process-stratum-target.c
16833 (process_stratum_target::thread_address_space)
16834 (process_stratum_target::thread_architecture): Pass target down.
16835 * process-stratum-target.h
16836 (process_stratum_target::threads_executing): New field.
16837 (as_process_stratum_target): New.
16838 * ravenscar-thread.c
16839 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
16840 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
16842 * record-btrace.c (record_btrace_target::info_record): Adjust.
16843 (record_btrace_target::record_method)
16844 (record_btrace_target::record_is_replaying)
16845 (record_btrace_target::fetch_registers)
16846 (get_thread_current_frame_id, record_btrace_target::resume)
16847 (record_btrace_target::wait, record_btrace_target::stop): Pass
16849 * record-full.c (record_full_wait_1): Switch to event thread.
16851 * regcache.c (regcache::regcache)
16852 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
16853 process_stratum_target parameter and handle it.
16854 (current_thread_target): New global.
16855 (get_thread_regcache): Add process_stratum_target parameter and
16856 handle it. Switch inferior before calling target method.
16857 (get_thread_regcache): Pass target down.
16858 (get_thread_regcache_for_ptid): Pass target down.
16859 (registers_changed_ptid): Add process_stratum_target parameter and
16861 (registers_changed_thread, registers_changed): Pass target down.
16862 (test_get_thread_arch_aspace_regcache): New.
16863 (current_regcache_test): Define a couple local test_target_ops
16864 instances and use them for testing.
16865 (readwrite_regcache): Pass process_stratum_target parameter.
16866 (cooked_read_test, cooked_write_test): Pass mock_target down.
16867 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
16868 (get_thread_arch_aspace_regcache): Add process_stratum_target
16870 (regcache::target): New method.
16871 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
16872 (regcache::registers_changed_ptid): Add process_stratum_target
16874 (regcache::m_target): New field.
16875 (registers_changed_ptid): Add process_stratum_target parameter.
16876 * remote.c (remote_state::supports_vCont_probed): New field.
16877 (remote_target::async_wait_fd): New method.
16878 (remote_unpush_and_throw): Add remote_target parameter.
16879 (get_current_remote_target): Adjust.
16880 (remote_target::remote_add_inferior): Push target.
16881 (remote_target::remote_add_thread)
16882 (remote_target::remote_notice_new_inferior)
16883 (get_remote_thread_info): Pass target down.
16884 (remote_target::update_thread_list): Skip threads of inferiors
16885 bound to other targets. (remote_target::close): Don't discard
16886 inferiors. (remote_target::add_current_inferior_and_thread)
16887 (remote_target::process_initial_stop_replies)
16888 (remote_target::start_remote)
16889 (remote_target::remote_serial_quit_handler): Pass down target.
16890 (remote_target::remote_unpush_target): New remote_target
16891 parameter. Unpush the target from all inferiors.
16892 (remote_target::remote_unpush_and_throw): New remote_target
16893 parameter. Pass it down.
16894 (remote_target::open_1): Check whether the current inferior has
16895 execution instead of checking whether any inferior is live. Pass
16897 (remote_target::remote_detach_1): Pass down target. Use
16898 remote_unpush_target.
16899 (extended_remote_target::attach): Pass down target.
16900 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
16901 (remote_target::append_resumption): Pass down target.
16902 (remote_target::append_pending_thread_resumptions)
16903 (remote_target::remote_resume_with_hc, remote_target::resume)
16904 (remote_target::commit_resume): Pass down target.
16905 (remote_target::remote_stop_ns): Check supports_vCont_probed.
16906 (remote_target::interrupt_query)
16907 (remote_target::remove_new_fork_children)
16908 (remote_target::check_pending_events_prevent_wildcard_vcont)
16909 (remote_target::remote_parse_stop_reply)
16910 (remote_target::process_stop_reply): Pass down target.
16911 (first_remote_resumed_thread): New remote_target parameter. Pass
16913 (remote_target::wait_as): Pass down target.
16914 (unpush_and_perror): New remote_target parameter. Pass it down.
16915 (remote_target::readchar, remote_target::remote_serial_write)
16916 (remote_target::getpkt_or_notif_sane_1)
16917 (remote_target::kill_new_fork_children, remote_target::kill): Pass
16919 (remote_target::mourn_inferior): Pass down target. Use
16920 remote_unpush_target.
16921 (remote_target::core_of_thread)
16922 (remote_target::remote_btrace_maybe_reopen): Pass down target.
16923 (remote_target::pid_to_exec_file)
16924 (remote_target::thread_handle_to_thread_info): Pass down target.
16925 (remote_target::async_wait_fd): New.
16926 * riscv-fbsd-tdep.c: Include "inferior.h".
16927 (riscv_fbsd_get_thread_local_address): Pass down target.
16928 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
16929 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
16930 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
16932 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
16933 * solib-svr4.c (enable_break): Pass down target.
16934 * spu-multiarch.c (parse_spufs_run): Pass down target.
16935 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
16936 * target-delegates.c: Regenerate.
16937 * target.c (g_target_stack): Delete.
16938 (current_top_target): Return the current inferior's top target.
16939 (target_has_execution_1): Refer to the passed-in inferior's top
16941 (target_supports_terminal_ours): Check whether the initial
16942 inferior was already created.
16943 (decref_target): New.
16944 (target_stack::push): Incref/decref the target.
16945 (push_target, push_target, unpush_target): Adjust.
16946 (target_stack::unpush): Defref target.
16947 (target_is_pushed): Return bool. Adjust to refer to the current
16948 inferior's target stack.
16949 (dispose_inferior): Delete, and inline parts ...
16950 (target_preopen): ... here. Only dispose of the current inferior.
16951 (target_detach): Hold strong target reference while detaching.
16953 (target_thread_name): Add assertion.
16954 (target_resume): Pass down target.
16955 (target_ops::beneath, find_target_at): Adjust to refer to the
16956 current inferior's target stack.
16957 (get_dummy_target): New.
16958 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
16959 has a thread running.
16960 (initialize_targets): Rename to ...
16961 (_initialize_target): ... this.
16962 * target.h: Include "gdbsupport/refcounted-object.h".
16963 (struct target_ops): Inherit refcounted_object.
16964 (target_ops::shortname, target_ops::longname): Make const.
16965 (target_ops::async_wait_fd): New method.
16966 (decref_target): Declare.
16967 (struct target_ops_ref_policy): New.
16968 (target_ops_ref): New typedef.
16969 (get_dummy_target): Declare function.
16970 (target_is_pushed): Return bool.
16971 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
16972 (all_matching_threads_iterator::all_matching_threads_iterator):
16973 Handle filter target.
16974 * thread-iter.h (struct all_matching_threads_iterator, struct
16975 all_matching_threads_range, class all_non_exited_threads_range):
16976 Filter by target too. Remove explicit.
16977 * thread.c (threads_executing): Delete.
16978 (inferior_thread): Pass down current inferior.
16979 (clear_thread_inferior_resources): Pass down thread pointer
16981 (add_thread_silent, add_thread_with_info, add_thread): Add
16982 process_stratum_target parameter. Use it for thread and inferior
16984 (is_current_thread): New.
16985 (thread_info::deletable): Use it.
16986 (find_thread_ptid, thread_count, in_thread_list)
16987 (thread_change_ptid, set_resumed, set_running): New
16988 process_stratum_target parameter. Pass it down.
16989 (set_executing): New process_stratum_target parameter. Pass it
16990 down. Adjust reference to 'threads_executing'.
16991 (threads_are_executing): New process_stratum_target parameter.
16992 Adjust reference to 'threads_executing'.
16993 (set_stop_requested, finish_thread_state): New
16994 process_stratum_target parameter. Pass it down.
16995 (switch_to_thread): Also match inferior.
16996 (switch_to_thread): New process_stratum_target parameter. Pass it
16998 (update_threads_executing): Reimplement.
16999 * top.c (quit_force): Pop targets from all inferior.
17000 (gdb_init): Don't call initialize_targets.
17001 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
17003 (windows_add_thread, windows_delete_thread): Adjust.
17004 (get_windows_debug_event): Rename to ...
17005 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
17006 * tracefile-tfile.c (tfile_target_open): Pass down target.
17007 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
17009 (switch_to_thread): Add process_stratum_target parameter.
17010 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
17012 (mi_on_resume): Pass target down.
17013 * nat/fork-inferior.c (startup_inferior): Add
17014 process_stratum_target parameter. Pass it down.
17015 * nat/fork-inferior.h (startup_inferior): Add
17016 process_stratum_target parameter.
17017 * python/py-threadevent.c (py_get_event_thread): Pass target down.
17021 * remote.c (remote_target::start_remote): Don't set inferior_ptid
17022 directly. Instead find the first thread in the thread list and
17023 use switch_to_thread.
17027 * remote.c (remote_target::remote_add_inferior): Don't bind a
17028 process to the current inferior if the current inferior is already
17029 bound to a process.
17034 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
17035 If no process is specified, return null_ptid instead of
17037 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
17038 TARGET_WAITKIND_SIGNALLED with no pid.
17042 * remote.c (first_remote_resumed_thread): New.
17043 (remote_target::wait_as): Use it as default event_ptid instead of
17048 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
17052 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
17057 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
17058 ptid to get_last_target_status.
17059 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
17060 ptid to get_last_target_status.
17061 * infcmd.c (continue_command): Don't pass a target_waitstatus to
17062 get_last_target_status.
17063 (info_program_command): Don't pass a target_waitstatus to
17064 get_last_target_status.
17065 * infrun.c (init_wait_for_inferior): Use
17066 nullify_last_target_wait_ptid.
17067 (get_last_target_status): Handle nullptr arguments.
17068 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
17069 (print_stop_event): Don't pass a ptid to get_last_target_status.
17070 (normal_stop): Don't pass a ptid to get_last_target_status.
17071 * infrun.h (get_last_target_status, set_last_target_status): Move
17072 comments here and update.
17073 (nullify_last_target_wait_ptid): Declare.
17074 * linux-fork.c (fork_load_infrun_state): Remove local extern
17075 declaration of nullify_last_target_wait_ptid.
17076 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
17077 to get_last_target_status.
17081 * gdbthread.h (scoped_restore_current_thread)
17082 <dont_restore, restore, m_dont_restore>: Declare.
17083 * thread.c (thread_alive): Add assertion. Return bool.
17084 (switch_to_thread_if_alive): New.
17085 (prune_threads): Switch inferior/thread.
17086 (print_thread_info_1): Switch thread before calling target methods.
17087 (scoped_restore_current_thread::restore): New, factored out from
17089 (scoped_restore_current_thread::~scoped_restore_current_thread):
17091 (scoped_restore_current_thread::scoped_restore_current_thread):
17093 (thread_apply_all_command, thread_select): Use
17094 switch_to_thread_if_alive.
17095 * infrun.c (proceed, restart_threads, handle_signal_stop)
17096 (switch_back_to_stepped_thread): Switch current thread before
17097 calling target methods.
17101 * inferior.c (switch_to_inferior_no_thread): New function,
17102 factored out from ...
17103 (inferior_command): ... here.
17104 * inferior.h (switch_to_inferior_no_thread): Declare.
17105 * mi/mi-main.c (run_one_inferior): Use
17106 switch_to_inferior_no_thread.
17110 * infcmd.c (kill_command): Remove dead code.
17114 * remote.c (remote_target::mourn_inferior): No longer check
17115 whether the target is running.
17119 * corelow.c (core_target::has_execution): Change parameter type to
17121 * inferior.c (number_of_live_inferiors): Use
17122 inferior::has_execution instead of target_has_execution_1.
17123 * inferior.h (inferior::has_execution): New.
17124 * linux-thread-db.c (thread_db_target::update_thread_list): Use
17125 inferior::has_execution instead of target_has_execution_1.
17126 * process-stratum-target.c
17127 (process_stratum_target::has_execution): Change parameter type to
17128 inferior pointer. Check the inferior's PID instead of
17130 * process-stratum-target.h
17131 (process_stratum_target::has_execution): Change parameter type to
17133 * record-full.c (record_full_core_target::has_execution): Change
17134 parameter type to inferior pointer.
17135 * target.c (target_has_execution_1): Change parameter type to
17137 (target_has_execution_current): Adjust.
17138 * target.h (target_ops::has_execution): Change parameter type to
17140 (target_has_execution_1): Change parameter type to inferior
17141 pointer. Change return type to bool.
17142 * tracefile.h (tracefile_target::has_execution): Change parameter
17143 type to inferior pointer.
17147 * exceptions.c (print_flush): Remove current_top_target() check.
17151 * remote.c (show_remote_exec_file): Show the current inferior's
17152 exec-file instead of the command variable's value.
17156 * record-full.c (record_full_resume_ptid): New global.
17157 (record_full_target::resume): Set it.
17158 (record_full_wait_1): Use record_full_resume_ptid instead of
17163 * gdbthread.h (scoped_restore_current_thread)
17164 <dont_restore, restore, m_dont_restore>: Declare.
17165 * thread.c (thread_alive): Add assertion. Return bool.
17166 (switch_to_thread_if_alive): New.
17167 (prune_threads): Switch inferior/thread.
17168 (print_thread_info_1): Switch thread before calling target methods.
17169 (scoped_restore_current_thread::restore): New, factored out from
17171 (scoped_restore_current_thread::~scoped_restore_current_thread):
17173 (scoped_restore_current_thread::scoped_restore_current_thread):
17175 (thread_apply_all_command, thread_select): Use
17176 switch_to_thread_if_alive.
17180 * stap-probe.c (stap_modify_semaphore): Don't check for null
17182 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
17183 for null semaphores.
17187 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
17188 all source windows, and maintain horizontal scroll status while
17194 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
17195 update_source_window, not print_source_lines.
17199 * tui/tui.c (tui_enable): Register tui hooks after calling
17204 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
17208 * thread.c (print_thread_info_1): Fix indentation.
17212 * symtab.c (general_symbol_info::compute_and_set_names): Move the
17213 unique_xmalloc_ptr outside the if to always free the demangled name.
17217 * xcoffread.c (enter_line_range, read_xcoff_symtab)
17218 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
17219 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
17220 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
17222 (section_offsets): New typedef.
17223 * symtab.c (fixup_section, get_msymbol_address): Update.
17224 * symmisc.c (dump_msymbols): Update.
17225 * symfile.h (relative_addr_info_to_section_offsets)
17226 (symfile_map_offsets_to_segments): Update.
17227 * symfile.c (build_section_addr_info_from_objfile)
17228 (init_objfile_sect_indices): Update.
17229 (struct place_section_arg): Change type of "offsets".
17230 (place_section): Update.
17231 (relative_addr_info_to_section_offsets): Change type of
17232 "section_offsets". Remove "num_sections" parameter.
17233 (default_symfile_offsets, syms_from_objfile_1)
17234 (set_objfile_default_section_offset): Update.
17235 (reread_symbols): No need to preserve section offsets by hand.
17236 (symfile_map_offsets_to_segments): Change type of "offsets".
17237 * stap-probe.c (relocate_address): Update.
17238 * stabsread.h (process_one_symbol): Update.
17239 * solib-target.c (struct lm_info_target) <offsets>: Change type.
17240 (solib_target_relocate_section_addresses): Update.
17241 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
17243 * solib-frv.c (frv_relocate_main_executable): Update.
17244 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
17245 * solib-aix.c (solib_aix_get_section_offsets): Change return
17247 (solib_aix_solib_create_inferior_hook): Update.
17248 * remote.c (remote_target::get_offsets): Update.
17249 * psymtab.c (find_pc_sect_psymtab): Update.
17250 * psympriv.h (struct partial_symbol) <address, text_low,
17251 text_high>: Update.
17252 * objfiles.h (obj_section_offset): Update.
17253 (struct objfile) <section_offsets>: Change type.
17254 <num_sections>: Remove.
17255 (objfile_relocate): Update.
17256 * objfiles.c (entry_point_address_query): Update
17257 (relocate_one_symbol): Change type of "section_offsets".
17258 (objfile_relocate1, objfile_relocate1): Change type of
17260 (objfile_rebase1): Update.
17261 * mipsread.c (mipscoff_symfile_read): Update.
17262 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
17264 * mdebugread.c (parse_symbol): Change type of "section_offsets".
17265 (parse_external, psymtab_to_symtab_1): Update.
17266 * machoread.c (macho_symfile_offsets): Update.
17267 * ia64-tdep.c (ia64_find_unwind_table): Update.
17268 * hppa-tdep.c (read_unwind_info): Update.
17269 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
17270 * dwarf2read.c (create_addrmap_from_index)
17271 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
17272 (process_psymtab_comp_unit_reader, add_partial_symbol)
17273 (add_partial_subprogram, process_full_comp_unit)
17274 (read_file_scope, read_func_scope, read_lexical_block_scope)
17275 (read_call_site_scope, dwarf2_rnglists_process)
17276 (dwarf2_ranges_process, dwarf2_ranges_read)
17277 (dwarf_decode_lines_1, var_decode_location, new_symbol)
17278 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
17280 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
17282 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
17283 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
17284 (process_one_symbol): Change type of "section_offsets".
17285 * ctfread.c (get_objfile_text_range): Update.
17286 * coffread.c (coff_symtab_read, enter_linenos)
17287 (process_coff_symbol): Update.
17288 * coff-pe-read.c (add_pe_forwarded_sym): Update.
17289 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
17293 * dwarf2read.c (parse_macro_definition): Use std::string.
17294 (parse_macro_definition): Likewise.
17298 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
17299 (ATTR_ALLOC_CHUNK): Remove.
17303 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
17307 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
17308 (dwarf2_compute_name, open_dwo_file): Likewise.
17309 (process_enumeration_scope): Use std::vector.
17310 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
17311 (partial_die_info::fixup, dwarf2_start_subfile)
17312 (guess_full_die_structure_name, dwarf2_name): Likewise.
17313 (determine_prefix): Update.
17314 (guess_full_die_structure_name): Make return type const.
17315 (partial_die_full_name): Return unique_xmalloc_ptr.
17316 (DW_FIELD_ALLOC_CHUNK): Remove.
17321 * stap-probe.c (class stap_static_probe_ops): Add constructor.
17325 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
17329 * stack.c (print_frame_info): Move disassemble_next_line code
17330 inside source_print block.
17334 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
17335 gdb/signals.h, as we are now using native signal symbols.
17339 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
17340 overflow by an early check of content vs threshold.
17341 * tui/tui-source.c (tui_source_window::line_is_displayed):
17346 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
17350 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
17351 export table if no section contains it's RVA.
17355 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
17359 * source.c (print_source_lines_base): Set last_line_listed.
17363 * tui/tui-disasm.c: Remove trailing spaces.
17368 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
17369 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
17370 (windows_gdb_signal_to_target): New function, uses the above
17371 enumeration to convert GDB internal signal codes to equivalent
17373 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
17374 * windows-nat.c: Include "gdb_wait.h".
17375 (get_windows_debug_event): Extract the fatal exception from the
17376 exit status and convert to the equivalent Posix signal number.
17377 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
17378 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
17379 * gdbsupport/gdb_wait.c: New file, implements
17380 windows_status_to_termsig.
17381 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
17382 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
17386 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
17391 * aarch64-linux-nat.c
17392 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
17393 and bfd_mach_aarch64.
17397 * ui-file.c (stdio_file::can_emit_style_escape)
17398 (tee_file::can_emit_style_escape): Ensure style is used also on
17399 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
17401 * main.c (set_gdb_data_directory): Use file style to output the
17402 warning that the given pathname is not a directory.
17403 * top.c (show_history_filename, gdb_safe_append_history)
17404 (show_gdb_datadir): Use file style.
17408 * solib-target.c (struct lm_info_target):
17409 Change offsets to be a unique_xmalloc_ptr.
17410 (solib_target_relocate_section_addresses): Update.
17414 * windows-nat.c (windows_clear_solib): Free so_list linked list.
17418 * MAINTAINERS (Write After Approval): Add myself.
17422 * proc-service.c (get_ps_regcache): Remove reference to obsolete
17423 Cell BE architecture.
17424 * target.h (struct target_ops) <thread_architecture>: Likewise.
17428 * Makefile.in: Use INSTALL_PROGRAM_ENV.
17432 * MAINTAINERS (Write After Approval): Add myself.
17436 * gdbarch.sh: Update copyright year range of generated files.
17440 Update copyright year range in all GDB files.
17444 * copyright.py: Convert to Python 3.
17448 * copyright.py: Adapt after move of gnulib directory from gdb
17449 directory to toplevel directory.
17453 * copyright.py (main): Exit if run from the wrong directory.
17457 * top.c (print_gdb_version): Change copyright year to 2020.
17461 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
17463 For older changes see ChangeLog-2019.
17469 version-control: never