1 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3 * target-descriptions.c (struct xml_test_tdesc): New.
4 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
5 (record_xml_tdesc): Update.
6 (maintenance_check_xml_descriptions): Update.
7 * target-descriptions.h (record_xml_tdesc): Update comment.
9 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
11 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
12 checking array bounds are defined.
14 2018-07-30 Tom Tromey <tom@tromey.com>
16 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
17 irreflexivity violation.
19 2018-07-30 Tom Tromey <tom@tromey.com>
21 * cli/cli-decode.c (lookup_cmd): Remove lint code.
22 * value.c (unpack_long): Remove lint code.
23 * valops.c (value_ind): Remove lint code.
24 * valarith.c (value_x_binop, value_x_unop, value_equal)
25 (value_pos): Remove lint code.
27 2018-07-28 Tom de Vries <tdevries@suse.de>
29 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
30 with undefined upper bound as <optimized out>.
32 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
34 * gcore.in: Rename variable "name" to "prefix". Expand
37 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
39 * windows-nat.c (windows_nat_target::create_inferior): Update to
40 call close() in global namespace.
42 2018-07-26 Tom Tromey <tom@tromey.com>
44 * dwarf-index-write.c (add_address_entry): Don't add objfile
46 * dbxread.c (find_stab_function): Rename from
47 find_stab_function_addr. Return a bound_minimal_symbol.
48 (read_dbx_symtab): Use raw_text_low, raw_text_high.
49 Don't add objfile offsets.
50 (end_psymtab): Use raw_text_low, raw_text_high,
51 MSYMBOL_VALUE_RAW_ADDRESS.
52 (read_ofile_symtab): Update.
53 (process_one_symbol): Update.
54 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
56 (dw2_relocate): Remove.
57 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
59 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
61 (process_psymtab_comp_unit_reader, add_partial_symbol)
62 (add_partial_subprogram, dwarf2_ranges_read): Update.
63 (load_partial_dies): Update.
64 (add_address_entry): Don't add objfile offsets.
65 (dwarf2_build_include_psymtabs): Update.
66 (create_addrmap_from_aranges): Don't add objfile offsets.
67 (dw2_find_pc_sect_compunit_symtab): Update.
68 * mdebugread.c (parse_symbol): Don't add objfile offsets.
69 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
71 (parse_partial_symbols): Don't add objfile offsets. Use
72 raw_text_low, raw_text_high. Update.
73 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
74 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
75 or call 'relocate' quick function. Clear psymbol_map.
76 * psympriv.h (struct partial_symbol) <address>: Add section
78 <set_unrelocated_address>: Rename from set_address.
79 <raw_text_low, raw_text_high>: New methods.
80 <text_low, text_high>: Add objfile parameter.
81 (add_psymbol_to_bcache): Add 'section' parameter. Call
82 set_unrelocated_address.
83 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
84 (find_pc_psymbol): Update.
85 (fixup_psymbol_section, relocate_psymtabs): Remove.
86 (dump_psymtab, psym_functions): Update.
87 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
89 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
90 (start_psymtab_common): Update.
91 * symfile-debug.c (debug_qf_relocate): Remove.
92 (debug_sym_quick_functions): Update.
93 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
94 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
97 2018-07-26 Tom Tromey <tromey@redhat.com>
99 * dbxread.c (end_psymtab): Use text_high_valid and
101 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
102 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
103 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
105 <text_low_valid, text_high_valid>: New fields.
106 <set_text_low, set_text_high>: Update.
107 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
109 2018-07-26 Tom Tromey <tom@tromey.com>
111 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
113 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
114 textlow and texthigh fields.
115 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
117 * mdebugread.c (parse_lines, parse_partial_symbols)
118 (psymtab_to_symtab_1): Update.
119 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
120 Rename fields. Update comment. Now private.
121 <text_low, text_high, set_text_low, set_text_high>: New methods.
122 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
123 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
124 (start_psymtab_common, maintenance_info_psymtabs)
125 (maintenance_check_psymtabs): Update.
126 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
128 (scan_xcoff_symtab): Update.
130 2018-07-26 Tom Tromey <tromey@redhat.com>
132 * psympriv.h (struct partial_symbol) <unrelocated_address,
133 address, set_address>: New methods.
134 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
135 (fixup_psymbol_section, relocate_psymtabs): Update.
136 (print_partial_symbols): Add 'objfile' parameter. Update.
137 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
140 2018-07-26 Tom Tromey <tom@tromey.com>
142 * dwarf-index-write.c (write_psymbols, debug_names::insert)
143 (debug_names::write_psymbols): Update.
144 * psympriv.h (struct partial_symbol): Derive from
146 <obj_section>: New method.
147 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
148 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
149 (find_pc_sect_psymbol, fixup_psymbol_section)
150 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
151 (print_partial_symbols, recursively_search_psymtabs)
152 (compare_psymbols, psymbol_hash, psymbol_compare)
153 (add_psymbol_to_bcache, maintenance_check_psymtabs)
154 (psymbol_name_matches, psym_fill_psymbol_map): Update.
156 2018-07-26 Tom Tromey <tromey@redhat.com>
158 * dbxread.c (end_psymtab): Remove dead code.
160 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
162 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
163 DWARF unwinders are disabled.
164 * dwarf2-frame.c: Add dwarf2read.h include.
165 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
167 (dwarf2_frame_unwinders_enabled_p): Define.
168 (show_dwarf_unwinders_enabled_p): New function.
169 (_initialize_dwarf2_frame): Register switch to control DWARF
171 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
172 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
173 (show_dwarf_cmdlist): Remove static keyword.
174 * dwarf2read.h (set_dwarf_cmdlist): Declare.
175 (show_dwarf_cmdlist): Declare.
176 * NEWS: Document new feature.
178 2018-07-26 Tom de Vries <tdevries@suse.de>
181 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
183 2018-07-26 Tom de Vries <tdevries@suse.de>
185 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
186 DW_AT_count can't be translated to a dynamic prop.
188 2018-07-25 Tom de Vries <tdevries@suse.de>
190 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
193 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
195 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
197 2018-07-25 Joel Brobecker <brobecker@adacore.com>
199 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
201 2018-07-24 Keith Seitz <keiths@redhat.comt
204 * dwarf2read.c (dw2_add_symbol_to_list): New function.
205 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
206 instead of add_symbol_to_list.
207 (read_file_scope): Call prepare_one_comp_unit before reading
210 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
212 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
214 2018-07-24 Tom Tromey <tom@tromey.com>
216 * utils.c (malloc, realloc, free): Don't declare.
217 * configure, config.in: Rebuild.
218 * configure.ac: Don't check for declarations of free, malloc, or
221 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
223 * aarch64-linux-nat.c
224 (aarch64_linux_nat_target::stopped_data_address): Remove unused
226 * arm-linux-nat.c (fetch_regs): Likewise.
227 (store_regs): Likewise.
228 (fetch_vfp_regs): Likewise.
229 (store_vfp_regs): Likewise.
230 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
231 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
232 (arm_linux_nat_target::insert_watchpoint): Likewise.
233 (arm_linux_nat_target::remove_watchpoint): Likewise.
234 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
236 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
238 * ppc-linux-nat.c (fetch_register): Likewise.
239 (fetch_all_gp_regs): Likewise.
240 (fetch_ppc_registers): Likewise.
241 (store_all_gp_regs): Likewise.
242 (store_ppc_registers): Likewise.
243 (hwdebug_insert_point): Likewise.
244 (can_use_watchpoint_cond_accel): Likewise.
245 * remote-sim.c (gdb_os_write_stdout): Likewise.
247 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
248 Tom Tromey <tom@tromey.com>
250 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
252 * configure: Rebuild.
254 2018-07-22 Tom Tromey <tom@tromey.com>
256 * regformats/regdat.sh: Define xmltarget_${name} inside
257 #ifndef IN_PROCESS_AGENT.
259 2018-07-22 Tom Tromey <tom@tromey.com>
261 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
263 2018-07-22 Tom Tromey <tom@tromey.com>
265 * symfile.c (reread_symbols): Notify iter, not objfile.
267 2018-07-22 Tom Tromey <tom@tromey.com>
269 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
271 (ravenscar_thread_target::prepare_to_store): Likewise.
273 2018-07-22 Tom Tromey <tom@tromey.com>
275 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
276 unused variable. Call value_fetch_lazy when needed.
277 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
278 Remove unused variable. Call value_fetch_lazy when needed.
280 2018-07-22 Tom Tromey <tom@tromey.com>
282 * m32c-tdep.c (mark_dma): Return void.
283 (make_regs): Remove unused declarations.
285 2018-07-22 Tom Tromey <tom@tromey.com>
287 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
288 cmdscm_get_valid_command_smob_arg_unsafe for effect.
289 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
290 bkscm_get_valid_block_smob_arg_unsafe for effect.
292 2018-07-22 Tom Tromey <tom@tromey.com>
294 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
297 2018-07-22 Tom Tromey <tom@tromey.com>
299 * windows-nat.c (saved_context): Conditionally define.
300 * remote.c (remote_target::remote_btrace_maybe_reopen):
301 Conditionally declare "warned".
302 * inflow.c (sigquit_ours): Conditionally define.
303 (new_tty): Move "tty" declaration inside #if.
304 * guile/guile.c (guile_datadir): Conditionally define.
305 * charset.c (set_be_le_names): Move some declarations inside #if.
306 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
308 (parse_xml_btrace_conf): Likewise.
310 2018-07-22 Tom Tromey <tom@tromey.com>
312 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
314 2018-07-22 Tom Tromey <tom@tromey.com>
316 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
317 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
318 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
319 * buildsym-legacy.c (get_macro_table): Remove unused variable.
320 * stack.c (frame_apply_level_command): Remove unused variable.
321 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
322 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
323 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
325 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
326 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
327 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
329 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
330 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
332 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
333 Remove unused variable.
334 * cli/cli-script.c (recurse_read_control_structure): Remove unused
336 * common/tdesc.c (print_xml_feature::visit): Remove unused
338 * compile/compile-object-load.c (store_regs): Remove unused
340 * complaints.c (clear_complaints): Remove unused variable.
341 * corelow.c (core_target_open): Remove unused variable.
342 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
344 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
346 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
348 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
350 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
352 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
354 * ia64-tdep.c (examine_prologue): Remove unused variable.
355 * infcall.c (run_inferior_call): Remove unused variable.
356 * inferior.c (exit_inferior): Remove unused variable.
357 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
358 * linespec.c (decode_line_2): Remove unused variable.
359 * linux-nat.c (super_close): Remove.
360 * linux-tdep.c (linux_info_proc): Remove unused variable.
361 * mi/mi-main.c (mi_execute_command): Remove unused variable.
362 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
363 Remove unused variable.
364 * parse.c (find_minsym_type_and_address): Remove unused variable.
365 * printcmd.c (info_symbol_command, printf_floating): Remove unused
367 * python/py-breakpoint.c (bppy_set_commands): Remove unused
369 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
371 * record-btrace.c (record_btrace_target::store_registers): Remove
373 (cmd_show_record_btrace_cpu): Remove unused variable.
374 * riscv-tdep.c (riscv_register_reggroup_p)
375 (riscv_push_dummy_call, riscv_return_value): Remove unused
377 * rust-exp.y (literal): Remove unused variable.
378 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
380 <STRUCTOP_ANONYMOUS>: Likewise.
381 * s390-linux-tdep.c (s390_linux_init_abi_31)
382 (s390_linux_init_abi_64): Remove unused variable.
383 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
384 (file_select_thread, net_windows_open, _initialize_ser_windows):
385 Remove unused variables.
386 * symtab.c (find_pc_sect_line): Remove unused variable.
387 * target-memory.c (compute_garbled_blocks): Remove unused
389 (target_write_memory_blocks): Remove unused variable.
390 * target.c (target_stack::unpush): Remove unused variables.
391 * tracepoint.c (start_tracing, all_tracepoint_actions)
392 (merge_uploaded_trace_state_variables)
393 (print_one_static_tracepoint_marker): Remove unused variable.
394 * unittests/basic_string_view/element_access/char/1.cc (test01):
395 Remove unused variable.
396 * windows-nat.c (windows_continue, windows_add_all_dlls)
397 (do_initial_windows_stuff, windows_nat_target::create_inferior):
398 Remove unused variables.
400 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
402 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
403 attr_profile in HAVE_ELF.
404 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
407 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
409 * frame.c (frame_register_unwind): Change parameter name.
410 (frame_unwind_register): Likewise.
411 (frame_unwind_register_value): Likewise.
412 (frame_unwind_register_signed): Likewise.
413 (frame_unwind_register_unsigned): Likewise.
414 * frame.h (frame_register_unwind): Likewise.
415 (frame_unwind_register): Likewise.
416 (frame_unwind_register_value): Likewise.
417 (frame_unwind_register_signed): Likewise.
418 (frame_unwind_register_unsigned): Likewise.
419 (frame_unwind_arch): Likewise.
421 2018-07-20 Maciej W. Rozycki <macro@mips.com>
423 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
426 2018-07-20 Maciej W. Rozycki <macro@mips.com>
428 * mips-linux-nat.c (mips_linux_nat_target::read_description):
429 Call `get_ptrace_pid' rather than extracting the ptrace PID by
432 2018-07-20 Keith Seitz <keiths@redhat.com>
434 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
435 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
436 m_compunit_symtab, m_language>: Add "m_" prefix.
438 * buildsym.c: Update all uses.
440 2018-07-20 Tom Tromey <tom@tromey.com>
442 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
443 * buildsym.h (record_line_ftype): Remove typedef.
445 2018-07-20 Tom Tromey <tom@tromey.com>
447 * buildsym-legacy.h (augment_type_symtab): Don't declare.
448 (end_expandable_symtab): Likewise.
449 (end_symtab_get_static_block): Likewise.
450 (end_symtab_from_static_block): Likewise.
451 * buildsym-legacy.c (augment_type_symtab): Remove.
452 (end_expandable_symtab): Remove.
453 (end_symtab_get_static_block): Remove.
454 (end_symtab_from_static_block): Remove.
456 2018-07-20 Tom Tromey <tom@tromey.com>
458 * dwarf2read.c: Include buildsym.h.
459 (struct dwarf2_cu) <builder>: New method.
460 (fixup_go_packaging): Update.
461 (process_full_comp_unit, process_full_type_unit): Update. Don't
462 use scoped_free_pendings.
463 (using_directives): Add "cu" parameter, remove "language".
464 (read_import_statement, setup_type_unit_groups, )
465 (read_func_scope, read_lexical_block_scope)
466 (dwarf2_record_block_ranges, read_namespace): Update.
467 (lnp_state_machine::lnp_state_machine): Add cu parameter.
468 (lnp_state_machine::handle_end_sequence): Update.
469 (class lnp_state_machine) <m_cu>: New member.
470 <m_record_line_callback>: Remove.
471 <m_currently_recording_lines>: New member.
472 (lnp_state_machine::handle_set_file): Update.
473 (noop_record_line): Remove.
474 (dwarf_record_line_p): Add cu parameter.
475 (dwarf_record_line_1, dwarf_finish_line): Likewise.
476 (lnp_state_machine::record_line)
477 (lnp_state_machine::lnp_state_machine)
478 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
479 (dwarf_decode_lines): Update.
480 (dwarf2_start_subfile): Add cu parameter.
481 (dwarf2_start_symtab, new_symbol): Update.
482 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
483 Remove dwarf2_per_objfile parameter.
484 (dwarf_decode_macros): Update.
486 2018-07-20 Tom Tromey <tom@tromey.com>
488 * stabsread.c (define_symbol): Update.
489 * buildsym-legacy.h (get_buildsym_compunit): Declare.
490 * dwarf2read.c (new_symbol): Update.
491 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
492 * cp-namespace.c: Include buildsym.h.
493 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
494 * buildsym-legacy.c (get_buildsym_compunit): New function.
496 2018-07-20 Tom Tromey <tom@tromey.com>
498 * xcoffread.c: Include buildsym-legacy.h.
499 * windows-nat.c: Include buildsym-legacy.h.
500 * stabsread.c: Include buildsym-legacy.h.
501 * mdebugread.c: Include buildsym-legacy.h.
502 * buildsym-legacy.h: New file.
503 * buildsym-legacy.c: New file, from buildsym.c.
504 * go32-nat.c: Include buildsym-legacy.h.
505 * dwarf2read.c: Include buildsym-legacy.h.
506 * dbxread.c: Include buildsym-legacy.h.
507 * cp-namespace.c: Include buildsym-legacy.h.
508 * coffread.c: Include buildsym-legacy.h.
509 * buildsym.h: Move some contents to buildsym-legacy.h.
510 * buildsym.c: Include buildsym-legacy.h. Move many functions to
512 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
514 2018-07-20 Tom Tromey <tom@tromey.com>
516 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
517 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
518 (buildsym_compunit::buildsym_compunit)
519 (buildsym_compunit::~buildsym_compunit)
520 (buildsym_compunit::get_macro_table): Define.
522 2018-07-20 Tom Tromey <tom@tromey.com>
524 * buildsym.c (reset_symtab_globals): Remove.
525 (buildsym_compunit::end_symtab_from_static_block): Update.
526 (buildsym_compunit::augment_type_symtab): Update.
527 (end_symtab_from_static_block): Call free_buildsym_compunit.
528 (augment_type_symtab, end_symtab, end_expandable_symtab):
531 2018-07-20 Tom Tromey <tom@tromey.com>
533 * arch-utils.c: Do not include buildsym.h.
534 * mipsread.c: Do not include buildsym.h.
535 * machoread.c: Do not include buildsym.h.
536 * elfread.c: Do not include buildsym.h.
538 2018-07-20 Tom Tromey <tom@tromey.com>
540 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
542 (buildsym_compunit): Add new constructor.
543 (struct buildsym_compunit) <get_last_source_file, finish_block,
544 record_block_range, start_subfile, patch_subfile_names,
545 push_subfile, pop_subfile, record_line, get_compunit_symtab,
546 set_last_source_start_addr, get_last_source_start_addr,
547 get_local_using_directives, set_local_using_directives,
548 get_global_using_directives, outermost_context_p,
549 get_current_context_stack, get_context_stack_depth,
550 get_current_subfile, get_local_symbols, get_file_symbols,
551 get_global_symbols, record_debugformat, record_producer,
552 push_context, pop_context, end_symtab_get_static_block,
553 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
555 <record_pending_block, finish_block_internal, make_blockvector,
556 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
560 2018-05-22 Tom Tromey <tom@tromey.com>
562 * buildsym.c (record_pending_block): Move earlier. Remove objfile
564 (finish_block_internal): Update.
566 2018-07-20 Tom Tromey <tom@tromey.com>
568 * buildsym.c (record_pending_block): Move earlier. Remove objfile
570 (finish_block_internal): Update.
572 2018-07-20 Tom Tromey <tom@tromey.com>
574 * buildsym.h (EXTERN): Don't define or undef.
575 * buildsym.c (EXTERN): Don't define.
577 2018-07-20 Tom Tromey <tom@tromey.com>
579 * buildsym.c: Remove TODO comment.
581 2018-07-20 Tom Tromey <tom@tromey.com>
583 * coffread.c (coff_symtab_read): Update.
584 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
585 (xcoff_new_init): Update.
586 * mipsread.c (mipscoff_new_init): Update.
587 * mdebugread.c (mdebug_build_psymtabs): Update.
588 * elfread.c (elf_new_init): Update.
589 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
591 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
592 (coffstab_build_psymtabs, elfstab_build_psymtabs)
593 (stabsect_build_psymtabs): Update.
594 * buildsym.h (buildsym_init): Don't declare.
595 * buildsym.c: Update comment.
596 (prepare_for_building): Remove.
597 (start_symtab, restart_symtab): Update.
598 (reset_symtab_globals): Update comment.
599 (buildsym_init): Remove.
601 2018-07-20 Tom Tromey <tom@tromey.com>
603 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
604 * stabsread.c (patch_block_stabs, define_symbol, read_type)
605 (read_enum_type, common_block_start, common_block_end)
606 (cleanup_undefined_types_1, finish_global_stabs): Update.
607 * mdebugread.c (psymtab_to_symtab_1): Update.
608 * dwarf2read.c (fixup_go_packaging, read_func_scope)
609 (read_lexical_block_scope, new_symbol): Update.
610 * dbxread.c (process_one_symbol): Update.
611 * coffread.c (coff_symtab_read, process_coff_symbol)
612 (coff_read_enum_type): Update.
613 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
615 (get_local_symbols, get_file_symbols, get_global_symbols): New
617 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
619 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
620 (~scoped_free_pendings): Update.
621 (finish_block, prepare_for_building, reset_symtab_globals)
622 (end_symtab_get_static_block, end_symtab_with_blockvector)
623 (augment_type_symtab, push_context): Update.
624 (get_local_symbols, get_file_symbols, get_global_symbols): New
626 (buildsym_init): Update.
628 2018-07-20 Tom Tromey <tom@tromey.com>
630 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
631 (process_full_type_unit): Likewise.
632 (dwarf2_start_symtab): Set list_in_scope.
634 2018-07-20 Tom Tromey <tom@tromey.com>
636 * dwarf2read.c (process_psymtab_comp_unit_reader)
637 (build_type_psymtabs_reader): Do not set list_in_scope.
639 2018-07-20 Tom Tromey <tom@tromey.com>
641 * buildsym.c (free_pendings): Remove.
642 (add_symbol_to_list, scoped_free_pendings)
643 (finish_block_internal, buildsym_init): Update.
645 2018-07-20 Tom Tromey <tom@tromey.com>
647 * xcoffread.c (read_xcoff_symtab): Update.
648 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
650 * dbxread.c (process_one_symbol): Update.
651 * coffread.c (coff_symtab_read): Update.
652 * buildsym.h (finish_block): Update.
653 * buildsym.c (finish_block): Remove "listhead" argument.
654 (end_symtab_get_static_block): Update.
656 2018-07-20 Tom Tromey <tom@tromey.com>
658 * buildsym.h (class scoped_free_pendings): Remove constructor.
659 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
661 <m_pending_block_obstack, m_pending_blocks>: New members.
662 (pending_block_obstack, pending_blocks): Remove.
663 (scoped_free_pendings::scoped_free_pendings): Default.
664 (~scoped_free_pendings): Update.
665 (free_pending_blocks): Remove.
666 (finish_block_internal, record_pending_block, make_blockvector)
667 (end_symtab_get_static_block, augment_type_symtab, push_context)
668 (buildsym_init): Update.
670 2018-07-20 Tom Tromey <tom@tromey.com>
672 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
673 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
675 (pending_addrmap, pending_addrmap_obstack)
676 (pending_addrmap_interesting): Remove.
677 (scoped_free_pendings, record_block_range, make_blockvector)
678 (prepare_for_building, reset_symtab_globals, buildsym_init):
681 2018-07-20 Tom Tromey <tom@tromey.com>
683 * xcoffread.c (process_linenos): Update.
684 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
685 * mdebugread.c (psymtab_to_symtab_1): Update.
686 * dwarf2read.c (setup_type_unit_groups)
687 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
688 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
689 * dbxread.c (process_one_symbol): Update.
690 * coffread.c (coff_symtab_read, enter_linenos)
691 (process_coff_symbol): Update.
692 * buildsym.h (current_subfile): Don't declare.
693 (get_current_subfile): Declare.
694 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
696 (start_subfile, free_buildsym_compunit, push_subfile)
697 (prepare_for_building, start_symtab): Update.
698 (get_current_subfile): New function.
700 2018-07-20 Tom Tromey <tom@tromey.com>
702 * coffread.c (coff_symtab_read): Update.
703 * xcoffread.c (read_xcoff_symtab): Update.
704 * dwarf2read.c (new_symbol): Update.
705 (read_func_scope, read_lexical_block_scope): Update.
706 * dbxread.c (process_one_symbol): Update.
707 * buildsym.h (context_stack, context_stack_depth): Don't declare.
708 (outermost_context_p): Remove macro.
709 (outermost_context_p, get_current_context_stack)
710 (get_context_stack_depth): Declare.
711 (pop_context): Return struct context_stack.
712 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
714 (context_stack_size): Remove.
715 (INITIAL_CONTEXT_STACK_SIZE): Remove.
716 (prepare_for_building, end_symtab_get_static_block)
717 (augment_type_symtab, push_context): Update.
718 (pop_context): Return struct context_stack.
719 (outermost_context_p, get_current_context_stack)
720 (get_context_stack_depth): New functions.
721 (buildsym_init): Update.
723 2018-07-20 Tom Tromey <tom@tromey.com>
725 * rust-exp.y: Now a pure parser. Update all rules.
726 (%union): Move earlier.
727 (current_parser, work_obstack): Remove globals.
728 (rust_parser, ~rust_parser): Update.
729 (class rust_parser) <copy_name, concat3, crate_name, super_name,
730 lex_character, lex_number, lex_string, lex_identifier,
731 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
732 convert_name, convert_params_to_expression,
733 convert_ast_to_expression, ast_basic_type, ast_operation,
734 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
735 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
736 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
737 ast_array_type, ast_slice_type, ast_reference_type,
738 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
739 (rust_parse): Update.
740 (rustyyerror, rustyylex): Add parser parameter.
741 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
742 (rust_lex_stringish_test, rust_lex_test_sequence)
743 (rust_lex_test_trailing_dot, rust_lex_test_completion)
744 (rust_lex_test_push_back, rust_lex_tests): Update.
746 2018-07-19 Pedro Alves <palves@redhat.com>
748 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
749 gdb::unique_xmalloc_ptr.
750 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
751 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
752 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
754 * guile/scm-pretty-print.c (ppscm_print_children): Use
755 gdb::unique_xmalloc_ptr instead of cleanups.
756 (gdbscm_apply_val_pretty_printer): Remove cleanups.
757 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
758 gdb::unique_xmalloc_ptr.
759 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
760 Adjust to use gdb::unique_xmalloc_ptr.
761 * guile/scm-utils.c (extract_arg): Adjust.
762 * guile/scm-value.c (gdbscm_value_field): Adjust to use
763 gdb::unique_xmalloc_ptr instead of a cleanup.
765 2018-07-19 Tom Tromey <tom@tromey.com>
767 * utils.c (do_value_free_to_mark)
768 (make_cleanup_value_free_to_mark): Remove.
769 * utils.h (make_cleanup_value_free_to_mark): Remove.
771 2018-07-19 Pedro Alves <palves@redhat.com>
773 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
774 forwarding reference.
776 2018-07-18 Pedro Alves <palves@redhat.com>
778 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
779 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
782 2018-07-18 Pedro Alves <palves@redhat.com>
784 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
786 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
788 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
789 directly instead of a cleanup.
790 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
791 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
792 (vlscm_binop_gdbthrow): New, factored out from ...
793 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
794 (vlscm_rich_compare): Use gdbscm_wrap.
795 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
796 instead of a cleanup.
797 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
799 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
800 Use xfree directly instead of a cleanup.
801 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
802 Adjust to use gdbscm_wrap and scoped_value_mark.
803 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
804 (gdbscm_value_address, gdbscm_value_dereference)
805 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
807 (gdbscm_value_dynamic_type): Use scoped_value_mark.
808 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
810 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
811 gdbscm_wrap and scoped_value_mark.
812 (gdbscm_value_to_string): Use xfree directly instead of a
813 cleanup. Move 'buffer' unique_ptr to TRY scope.
814 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
815 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
817 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
818 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
820 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
823 2018-07-18 Tom de Vries <tdevries@suse.de>
825 * findvar.c (default_read_var_value): Also resolve dynamic type for
826 LOC_OPTIMIZED_OUT vars.
828 2018-07-18 Maciej W. Rozycki <macro@mips.com>
830 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
833 2018-07-17 Tom Tromey <tom@tromey.com>
835 * guile/scm-param.c (pascm_set_func, pascm_show_func)
836 (compute_enum_list, pascm_set_param_value_x)
837 (gdbscm_parameter_value): Update.
838 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
839 (gdbscm_scm_to_host_string): Update.
840 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
842 * guile/scm-cmd.c (cmdscm_add_completion): Update.
843 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
844 * guile/scm-string.c (gdbscm_scm_to_string): Return
846 (gdbscm_scm_to_host_string): Likewise.
848 2018-07-17 Tom Tromey <tom@tromey.com>
850 * guile/guile.c (gdbscm_eval_from_control_command): Update.
851 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
852 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
853 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
856 2018-07-17 Tom Tromey <tom@tromey.com>
858 * guile/scm-param.c (pascm_signal_setshow_error): Update.
859 * guile/guile-internal.h (gdbscm_exception_message_to_string):
861 * guile/scm-cmd.c (cmdscm_function): Update.
862 * guile/scm-pretty-print.c
863 (ppscm_print_exception_unless_memory_error): Update.
864 * guile/scm-exception.c (gdbscm_exception_message_to_string):
865 Return unique_xmalloc_ptr.
867 2018-07-17 Tom Tromey <tom@tromey.com>
869 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
872 2018-07-17 Jim Wilson <jimw@sifive.com>
874 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
875 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
876 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
877 unecessary braces after EF_RISCV_RVC test. Delete call to
878 set_gdbarch_decr_pc_after_break.
880 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
881 RISCV_LAST_FP_REGNUM + 1.
882 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
884 2018-07-17 Tom Tromey <tom@tromey.com>
886 * configure.ac: Remove --disable-gdbcli.
887 * configure: Rebuild.
888 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
889 (SUBDIR_CLI_CFLAGS): Remove.
890 (SFILES): Use SUBDIR_CLI_SRCS.
891 (COMMON_OBS): Use SUBDIR_CLI_OBS.
893 2018-07-17 Tom Tromey <tom@tromey.com>
896 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
898 2018-07-16 Jim Wilson <jimw@sifive.com>
900 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
902 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
904 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
906 (libunwind_frame_sniffer): Likewise.
907 (libunwind_frame_prev_register): Likewise.
908 (libunwind_sigtramp_frame_sniffer): Likewise.
909 * ia64-tdep.c (ia64_access_reg): Likewise.
910 (ia64_access_rse_reg): Likewise.
911 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
912 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
914 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
916 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
918 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
920 * remote-sim.c (gdbsim_target::close,
921 gdbsim_target::mourn_inferior): Remove unused variables.
923 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
925 * ia64-tdep.c (ktab_buf): New global.
926 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
927 (get_kernel_table): Adjust.
929 2018-07-16 Tom Tromey <tom@tromey.com>
931 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
932 * dwarf2read.c (using_directives, new_symbol): Use
934 * dbxread.c (process_one_symbol): Use outermost_context_p.
935 * coffread.c (coff_symtab_read): Use outermost_context_p.
937 2018-07-16 Tom Tromey <tom@tromey.com>
939 * dwarf2read.c (using_directives, read_func_scope)
940 (read_lexical_block_scope): Update.
941 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
942 * buildsym.h (local_using_directives, global_using_directives):
944 (get_local_using_directives, set_local_using_directives)
945 (get_global_using_directives): Declare.
946 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
947 m_global_using_directives>: New members.
948 (finish_block_internal, prepare_for_building)
949 (reset_symtab_globals, end_symtab_get_static_block)
950 (push_context): Update.
951 (get_local_using_directives, set_local_using_directives)
952 (get_global_using_directives): New functions.
953 (buildsym_init): Update.
955 2018-07-16 Tom Tromey <tom@tromey.com>
957 * xcoffread.c (xcoff_initial_scan): Don't call
959 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
960 * buildsym.h (class scoped_free_pendings): Add constructor.
961 (free_pending_blocks): Don't declare.
962 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
963 (free_pending_blocks): Now static.
965 2018-07-16 Tom Tromey <tom@tromey.com>
967 * buildsym.h (push_subfile, pop_subfile): Update declarations.
968 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
970 (struct subfile_stack): Remove.
971 (subfile_stack): Remove.
972 (push_subfile, pop_subfile, buildsym_init): Update.
974 2018-07-16 Tom Tromey <tom@tromey.com>
976 * buildsym.c (push_subfile): Use gdb_assert.
977 (pop_subfile): Use gdb_assert.
979 2018-07-16 Tom Tromey <tom@tromey.com>
981 * buildsym.h (merge_symbol_lists): Remove.
982 * buildsym.c (merge_symbol_lists): Remove.
984 2018-07-16 Tom Tromey <tom@tromey.com>
986 * stabsread.c (scan_file_globals): Update comment.
987 * stabsread.h (scan_file_globals): Move from buildsym.h.
988 * buildsym.h (scan_file_globals): Move to stabsread.h.
990 2018-07-16 Tom Tromey <tom@tromey.com>
992 * xcoffread.c (xcoff_new_init): Update.
993 * mipsread.c (mipscoff_new_init): Update.
994 * mdebugread.c (mdebug_build_psymtabs): Update.
995 * elfread.c (elf_new_init): Update.
996 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
997 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
998 * buildsym.h (buildsym_new_init): Don't declare.
999 * buildsym.c (buildsym_new_init): Remove.
1001 2018-07-16 Tom Tromey <tom@tromey.com>
1003 * stabsread.h (within_function): Move from buildsym.h.
1004 * stabsread.c (start_stabs): Clear within_function.
1005 * coffread.c (coff_start_symtab): Clear within_function.
1006 * buildsym.h (within_function): Move to stabsread.h.
1007 * buildsym.c (prepare_for_building): Update.
1009 2018-07-16 Tom Tromey <tom@tromey.com>
1011 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
1012 * dwarf2read.c (dwarf2_start_symtab): Don't set
1013 processing_gcc_compilation.
1014 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
1016 2018-07-16 Tom Tromey <tom@tromey.com>
1018 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
1019 (next_symbol_text_func): Move from buildsym.h.
1020 * stabsread.c (hashname): Move from buildsym.c.
1021 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
1022 (next_symbol_text_func, hashname): Move to stabsread.h.
1023 * buildsym.c: Don't include bcache.h
1024 (hashname): Move to stasbread.c.
1026 2018-07-16 Tom Tromey <tom@tromey.com>
1028 * buildsym.h (context_stack_size): Don't declare.
1029 * buildsym.c (context_stack_size): New global.
1031 2018-07-16 Tom Tromey <tom@tromey.com>
1033 * dbxread.c (processing_acc_compilation): New global.
1034 * buildsym.h (processing_acc_compilation): Don't declare.
1036 2018-07-16 Tom Tromey <tom@tromey.com>
1038 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
1039 * dbxread.c (read_ofile_symtab): Update.
1040 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
1041 * buildsym.h (last_source_start_addr): Remove.
1042 (set_last_source_start_addr, get_last_source_start_addr):
1044 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
1046 (struct buildsym_compunit) <m_last_source_start_addr>: New
1048 (prepare_for_building): Remove start_addr parameter.
1049 (start_symtab, restart_symtab, end_symtab_get_static_block)
1050 (end_symtab_with_blockvector): Update.
1051 (set_last_source_start_addr, get_last_source_start_addr): New
1054 2018-07-16 Tom Tromey <tom@tromey.com>
1056 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
1058 (have_line_numbers): Remove.
1059 (record_line, prepare_for_building, end_symtab_get_static_block)
1060 (augment_type_symtab): Update.
1062 2018-07-16 Tom Tromey <tom@tromey.com>
1064 * buildsym.c (~buildsym_compunit): Free the macro table.
1065 (struct buildsym_compunit) <get_macro_table, release_macros>: New
1067 <m_pending_macros>: New member.
1068 (pending_macros): Remove.
1069 (~scoped_free_pendings, get_macro_table, prepare_for_building)
1070 (reset_symtab_globals, end_symtab_get_static_block)
1071 (end_symtab_with_blockvector, augment_type_symtab)
1072 (buildsym_init): Update.
1074 2018-07-16 Tom Tromey <tom@tromey.com>
1076 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
1078 (buildsym_compunit::set_last_source_file): New method.
1079 <m_last_source_file>: New member.
1080 (prepare_for_building): Remove "name" parameter.
1081 (start_symtab, restart_symtab, reset_symtab_globals): Update.
1082 (last_source_file): Remove.
1083 (set_last_source_file, get_last_source_file): Update.
1085 2018-07-16 Tom Tromey <tom@tromey.com>
1087 * buildsym.c (prepare_for_building): Add assert.
1089 2018-07-16 Tom Tromey <tom@tromey.com>
1091 * buildsym.c (~buildsym_compunit): Update.
1092 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
1093 (start_subfile, patch_subfile_names)
1094 (end_symtab_with_blockvector): Update.
1096 2018-07-16 Tom Tromey <tom@tromey.com>
1098 * buildsym.c (struct buildsym_compunit): Add constructor,
1099 destructor, initializers.
1100 (start_buildsym_compunit): Remove.
1101 (free_buildsym_compunit): Use "delete".
1102 (start_symtab, restart_symtab): Use "new".
1104 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
1106 * symfile.c (set_objfile_default_section_offset): Remove struct
1109 2018-07-14 Stafford Horne <shorne@gmail.com>
1111 * (Responsible Maintainers): Add myself as or1k maintainer.
1113 2018-07-13 Tom Tromey <tom@tromey.com>
1115 * symfile.c (set_objfile_default_section_offset): Use extra braces
1118 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
1120 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
1123 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1125 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1126 unittests/cli-utils-selftests.c
1127 * unittests/cli-utils-selftests.c: New file.
1129 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1131 * NEWS: Mention new commands. Mention change to 'thread apply'.
1133 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1135 * thread.c (thr_try_catch_cmd): New function.
1136 (thread_apply_all_command): Handle qcs flags.
1137 (thread_apply_command): Handle qcs flags.
1138 (taas_command): New function.
1139 (tfaas_command): New function.
1140 (_initialize_thread): Update to setup the new commands 'taas
1141 and 'tfaas'. Change doc string for 'thread apply'.
1143 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1145 * stack.c: (trailing_outermost_frame): New function, mostly
1146 extracted from backtrace_command_1.
1147 (leading_innermost_frame): New function.
1148 (backtrace_command_1): Update to call trailing_outermost_frame.
1149 (frame_apply_command_count): New function.
1150 (frame_apply_level_command): New function.
1151 (frame_apply_all_command): New function.
1152 (frame_apply_command): New function.
1153 (faas_command): New function.
1154 (frame_cmd_list): New variable.
1155 (_initialize_stack): Update to setup the new commands 'frame apply'
1158 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1160 * cli-utils.c (number_or_range_parser::get_number): Only handle
1161 numbers or convenience var as numbers.
1162 (parse_flags): New function.
1163 (parse_flags_qcs): New function.
1164 (number_or_range_parser::finished): Ensure parsing end is detected
1165 before end of string.
1166 * cli-utils.h (parse_flags): New function.
1167 (parse_flags_qcs): New function.
1168 (number_or_range_parser): Remove m_finished bool.
1169 (number_or_range_parser::skip_range): Set m_in_range to false.
1171 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
1173 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
1176 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1177 Jan Kratochvil <jan.kratochvil@redhat.com>
1178 Paul Fertser <fercerpav@gmail.com>
1179 Tsutomu Seki <sekiriki@gmail.com>
1180 Pedro Alves <palves@redhat.com>
1182 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1183 'unittests/parse-connection-spec-selftests.c'.
1184 (COMMON_SFILES): Add 'common/netstuff.c'.
1185 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
1186 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
1187 * common/netstuff.c: New file.
1188 * common/netstuff.h: New file.
1189 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
1190 (wait_for_connect): Update comment. New parameter
1191 'gdb::optional<int> sock' instead of 'struct serial *scb'.
1192 Use 'sock' directly instead of 'scb->fd'.
1193 (try_connect): New function, with code from 'net_open'.
1194 (net_open): Rewrite main loop to deal with multiple
1195 sockets/addresses. Handle IPv6-style hostnames; implement
1196 support for IPv6 connections.
1197 * unittests/parse-connection-spec-selftests.c: New file.
1199 2018-07-11 Pedro Alves <palves@redhat.com>
1202 * remote.c (remote_target::remote_detach_pid): Call
1203 set_current_process.
1205 2018-07-11 Pedro Alves <palves@redhat.com>
1207 * h8300-tdep.c (h8300_gdbarch_init): Remove
1208 set_gdbarch_ecoff_reg_to_regnum calls.
1210 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1213 * c-typeprint.c (c_type_print_base_struct_union): Don't print
1214 offsets/sizes for static members of a class/struct.
1216 2018-07-11 Alan Hayward <alan.hayward@arm.com>
1218 * target-descriptions.c (tdesc_register_bitsize): Rename.
1219 * target-descriptions.h (tdesc_register_bitsize): Likewise.
1220 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
1221 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
1223 2018-07-10 Tom Tromey <tom@tromey.com>
1225 * breakpoint.c (moribund_locations): Now static and a
1227 (breakpoint_init_inferior, moribund_breakpoint_here_p)
1228 (build_bpstat_chain, update_global_location_list)
1229 (breakpoint_retire_moribund): Update.
1230 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
1233 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1235 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
1236 (riscv_register_reggroup_p): Use new function, remove unneeded
1238 (riscv_push_dummy_call): Extend assert to compare against xlen or
1239 flen based on register type.
1241 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1243 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
1245 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
1247 * remote.c (show_hardware_watchpoint_limit): New function.
1248 (show_hardware_watchpoint_length_limit): New function.
1249 (show_hardware_breakpoint_limit): New function.
1250 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
1251 where appropriate, update help text.
1253 2018-07-09 Tom Tromey <tom@tromey.com>
1255 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
1256 (CLIBS): Don't mention NAT_CLIBS.
1258 2018-07-09 Tom Tromey <tom@tromey.com>
1260 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
1261 (LIBGDB_OBS, clean mostlyclean): Update.
1262 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
1264 2018-07-09 Tom Tromey <tom@tromey.com>
1266 * Makefile.in (%.c: %.y): Use ECHO_YACC.
1267 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
1268 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
1270 2018-07-09 Tom Tromey <tom@tromey.com>
1272 * Makefile.in (ALLDEPFILES): Remove exec.c.
1273 (COMMON_OBS): Remove exec.o.
1274 (COMMON_SFILES): Add exec.c.
1276 2018-07-09 Tom Tromey <tom@tromey.com>
1278 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
1280 2018-07-09 Tom Tromey <tom@tromey.com>
1282 * Makefile.in (clean mostlyclean): Remove stamp-version.
1283 (version.c): Depend on stamp-version.
1284 (stamp-version): New rule, from version.c rule.
1286 2018-07-09 Tom Tromey <tom@tromey.com>
1288 * Makefile.in (init.c): Depend on stamp-init.
1289 (stamp-init): New rule, from init.c rule.
1290 (clean mostlyclean): Remove stamp-init.
1292 2018-07-09 Tom Tromey <tom@tromey.com>
1294 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
1295 SUBDIR_GCC_COMPILE_SRCS.
1297 2018-07-09 Tom Tromey <tom@tromey.com>
1299 * Makefile.in (init.c): Remove some unused sed rules.
1301 2018-07-09 Tom Tromey <tom@tromey.com>
1303 * Makefile.in (TSOBS): Remove.
1304 (INIT_FILES): Update.
1305 (LIBGDB_OBS): Update.
1306 (COMMON_SFILES): Add inflow.c.
1307 (SFILES): Remove inflow.c.
1309 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
1311 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
1313 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
1315 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
1316 get_saveloc_name, is_signal_frame_name, step_name,
1317 init_remote_name, create_addr_space_name,
1318 destroy_addr_space_name, search_unwind_table_name,
1319 find_dyn_list_name): Constify.
1321 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
1323 * darwin-nat.c (darwin_pthread_kill): New function.
1324 (darwin_resume_thread): Use darwin_pthread_kill.
1326 2018-07-05 Tom de Vries <tdevries@suse.de>
1328 * macroexp.c (macro_buffer) <operator=>: New member function.
1330 2018-07-04 Tom Tromey <tom@tromey.com>
1332 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
1334 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
1336 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
1337 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
1338 * maint.c: Likewise.
1341 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1343 * NEWS: Create a new section for the next release branch.
1344 Rename the section of the current branch, now that it has
1347 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1349 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
1350 * version.in: Bump version to 8.2.50.DATE-git.
1352 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1353 Pedro Alves <palves@redhat.com>
1355 * linux-nat.c (linux_init_ptrace): Rename to ...
1356 (linux_init_ptrace_procfs): ... this. Call
1357 linux_proc_init_warnings.
1358 (linux_nat_target::post_attach)
1359 (linux_nat_target::post_startup_inferior): Adjust.
1360 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
1361 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
1363 2018-07-04 Tom de Vries <tdevries@suse.de>
1365 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
1367 (read_comp_unit_head): ... here.
1369 2018-07-03 Tom Tromey <tom@tromey.com>
1371 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
1372 (stop_tracing, tstatus_command)
1373 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
1374 (print_one_static_tracepoint_marker): Update.
1375 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
1377 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
1379 (all_tracepoints, static_tracepoints_here): Return std::vector.
1381 2018-07-03 Tom Tromey <tom@tromey.com>
1383 * common/ptid.c (ptid_equal): Remove.
1384 * common/ptid.h (ptid_equal): Don't declare.
1385 * ada-tasks.c: Update.
1386 * breakpoint.c: Update.
1387 * common/agent.c: Update.
1388 * corelow.c: Update.
1389 * darwin-nat-info.c: Update.
1390 * darwin-nat.c: Update.
1392 * dtrace-probe.c: Update.
1393 * dummy-frame.c: Update.
1394 * fbsd-nat.c: Update.
1396 * gdbthread.h: Update.
1397 * gnu-nat.c: Update.
1398 * go32-nat.c: Update.
1399 * inf-loop.c: Update.
1400 * inf-ptrace.c: Update.
1401 * infcall.c: Update.
1405 * linux-fork.c: Update.
1406 * linux-nat.c: Update.
1407 * linux-thread-db.c: Update.
1408 * mi/mi-cmd-var.c: Update.
1409 * mi/mi-interp.c: Update.
1410 * mi/mi-main.c: Update.
1411 * nto-procfs.c: Update.
1412 * ppc-linux-tdep.c: Update.
1414 * python/py-inferior.c: Update.
1415 * python/py-record-btrace.c: Update.
1416 * python/py-record.c: Update.
1417 * ravenscar-thread.c: Update.
1418 * regcache.c: Update.
1419 * remote-sim.c: Update.
1421 * sol-thread.c: Update.
1424 * tui/tui-stack.c: Update.
1426 * windows-nat.c: Update.
1427 * windows-tdep.c: Update.
1429 2018-07-03 Tom Tromey <tom@tromey.com>
1431 * common/ptid.c (ptid_match): Remove.
1432 * common/ptid.h (ptid_match): Don't declare.
1433 * fbsd-nat.c: Update.
1436 * linux-nat.c: Update.
1437 * record-btrace.c: Update.
1438 * regcache.c: Update.
1441 2018-07-03 Tom Tromey <tom@tromey.com>
1443 * common/ptid.c (ptid_tid_p): Remove.
1444 * common/ptid.h (ptid_tid_p): Don't declare.
1445 * sol-thread.c: Update.
1447 2018-07-03 Tom Tromey <tom@tromey.com>
1449 * common/ptid.c (ptid_lwp_p): Remove.
1450 * common/ptid.h (ptid_lwp_p): Don't declare.
1451 * fbsd-nat.c: Update.
1452 * linux-nat.c: Update.
1453 * nat/linux-procfs.c: Update.
1454 * nat/x86-linux-dregs.c: Update.
1455 * sol-thread.c: Update.
1457 2018-07-03 Tom Tromey <tom@tromey.com>
1459 * common/ptid.c (ptid_is_pid): Remove.
1460 * common/ptid.h (ptid_is_pid): Don't declare.
1462 * linux-nat.c: Update.
1463 * mi/mi-interp.c: Update.
1467 2018-07-03 Tom Tromey <tom@tromey.com>
1469 * common/ptid.c (ptid_get_tid): Remove.
1470 * common/ptid.h (ptid_get_tid): Don't declare.
1471 * ada-tasks.c: Update.
1472 * aix-thread.c: Update.
1473 * bsd-uthread.c: Update.
1474 * darwin-nat.c: Update.
1475 * fbsd-nat.c: Update.
1476 * i386-darwin-nat.c: Update.
1478 * linux-tdep.c: Update.
1479 * nto-procfs.c: Update.
1480 * ppc-ravenscar-thread.c: Update.
1481 * python/py-infthread.c: Update.
1482 * ravenscar-thread.c: Update.
1483 * sol-thread.c: Update.
1484 * sparc-ravenscar-thread.c: Update.
1485 * windows-nat.c: Update.
1487 2018-07-03 Tom Tromey <tom@tromey.com>
1489 * common/ptid.c (ptid_get_lwp): Remove.
1490 * common/ptid.h (ptid_get_lwp): Don't declare.
1491 * aarch64-linux-nat.c: Update.
1492 * ada-tasks.c: Update.
1493 * aix-thread.c: Update.
1494 * amd64-linux-nat.c: Update.
1495 * arm-linux-nat.c: Update.
1496 * corelow.c: Update.
1497 * fbsd-nat.c: Update.
1498 * fbsd-tdep.c: Update.
1499 * gnu-nat.c: Update.
1500 * i386-cygwin-tdep.c: Update.
1501 * i386-gnu-nat.c: Update.
1502 * i386-linux-nat.c: Update.
1503 * ia64-linux-nat.c: Update.
1504 * inf-ptrace.c: Update.
1506 * linux-fork.c: Update.
1507 * linux-nat.c: Update.
1508 * linux-tdep.c: Update.
1509 * linux-thread-db.c: Update.
1510 * mips-linux-nat.c: Update.
1511 * nat/aarch64-linux-hw-point.c: Update.
1512 * nat/aarch64-linux.c: Update.
1513 * nat/linux-btrace.c: Update.
1514 * nat/linux-osdata.c: Update.
1515 * nat/linux-procfs.c: Update.
1516 * nat/x86-linux-dregs.c: Update.
1517 * obsd-nat.c: Update.
1518 * ppc-fbsd-nat.c: Update.
1519 * ppc-linux-nat.c: Update.
1521 * python/py-infthread.c: Update.
1522 * ravenscar-thread.c: Update.
1524 * s390-linux-nat.c: Update.
1525 * sol-thread.c: Update.
1526 * sol2-tdep.c: Update.
1527 * spu-linux-nat.c: Update.
1528 * x86-linux-nat.c: Update.
1529 * xtensa-linux-nat.c: Update.
1531 2018-07-03 Tom Tromey <tom@tromey.com>
1533 * common/ptid.c (ptid_get_pid): Remove.
1534 * common/ptid.h (ptid_get_pid): Don't declare.
1535 * aarch64-linux-nat.c: Update.
1536 * ada-lang.c: Update.
1537 * aix-thread.c: Update.
1538 * alpha-bsd-nat.c: Update.
1539 * amd64-fbsd-nat.c: Update.
1540 * amd64-linux-nat.c: Update.
1541 * arm-linux-nat.c: Update.
1542 * arm-nbsd-nat.c: Update.
1544 * break-catch-syscall.c: Update.
1545 * breakpoint.c: Update.
1546 * bsd-uthread.c: Update.
1547 * corelow.c: Update.
1549 * darwin-nat.c: Update.
1550 * fbsd-nat.c: Update.
1551 * fbsd-tdep.c: Update.
1553 * gnu-nat.c: Update.
1554 * hppa-nbsd-nat.c: Update.
1555 * hppa-obsd-nat.c: Update.
1556 * i386-fbsd-nat.c: Update.
1557 * ia64-linux-nat.c: Update.
1558 * inf-ptrace.c: Update.
1560 * inferior.c: Update.
1561 * inferior.h: Update.
1564 * linux-fork.c: Update.
1565 * linux-nat.c: Update.
1566 * linux-tdep.c: Update.
1567 * linux-thread-db.c: Update.
1568 * m68k-bsd-nat.c: Update.
1569 * mi/mi-interp.c: Update.
1570 * mi/mi-main.c: Update.
1571 * mips-linux-nat.c: Update.
1572 * mips-nbsd-nat.c: Update.
1573 * mips64-obsd-nat.c: Update.
1574 * nat/aarch64-linux-hw-point.c: Update.
1575 * nat/aarch64-linux.c: Update.
1576 * nat/linux-btrace.c: Update.
1577 * nat/linux-osdata.c: Update.
1578 * nat/linux-procfs.c: Update.
1579 * nat/x86-linux-dregs.c: Update.
1580 * nto-procfs.c: Update.
1581 * obsd-nat.c: Update.
1582 * ppc-linux-nat.c: Update.
1583 * ppc-nbsd-nat.c: Update.
1584 * ppc-obsd-nat.c: Update.
1585 * proc-service.c: Update.
1587 * python/py-inferior.c: Update.
1588 * python/py-infthread.c: Update.
1589 * ravenscar-thread.c: Update.
1591 * remote-sim.c: Update.
1593 * rs6000-nat.c: Update.
1594 * s390-linux-nat.c: Update.
1595 * sh-nbsd-nat.c: Update.
1596 * sol-thread.c: Update.
1597 * sparc-nat.c: Update.
1598 * sparc64-tdep.c: Update.
1599 * spu-linux-nat.c: Update.
1600 * spu-tdep.c: Update.
1601 * target-debug.h: Update.
1604 * tid-parse.c: Update.
1605 * tracefile-tfile.c: Update.
1606 * vax-bsd-nat.c: Update.
1607 * windows-nat.c: Update.
1608 * x86-linux-nat.c: Update.
1609 * x86-nat.c: Update.
1611 2018-07-03 Tom Tromey <tom@tromey.com>
1613 * common/ptid.c (pid_to_ptid): Remove.
1614 * common/ptid.h (pid_to_ptid): Don't declare.
1615 * aix-thread.c: Update.
1616 * arm-linux-nat.c: Update.
1617 * common/ptid.c: Update.
1618 * common/ptid.h: Update.
1619 * corelow.c: Update.
1621 * darwin-nat.c: Update.
1622 * fbsd-nat.c: Update.
1623 * fork-child.c: Update.
1624 * gnu-nat.c: Update.
1625 * go32-nat.c: Update.
1626 * inf-ptrace.c: Update.
1628 * inferior.c: Update.
1630 * linux-fork.c: Update.
1631 * linux-nat.c: Update.
1632 * nat/aarch64-linux-hw-point.c: Update.
1633 * nat/fork-inferior.c: Update.
1634 * nat/x86-linux-dregs.c: Update.
1635 * nto-procfs.c: Update.
1636 * obsd-nat.c: Update.
1638 * progspace.c: Update.
1640 * rs6000-nat.c: Update.
1641 * s390-linux-nat.c: Update.
1642 * sol-thread.c: Update.
1643 * spu-linux-nat.c: Update.
1646 * tracefile-tfile.c: Update.
1647 * windows-nat.c: Update.
1649 2018-07-03 Tom Tromey <tom@tromey.com>
1651 * common/ptid.h (ptid_build): Don't declare.
1652 * common/ptid.c (ptid_build): Remove.
1653 * aix-thread.c: Update.
1654 * bsd-kvm.c: Update.
1655 * bsd-uthread.c: Update.
1656 * common/agent.c: Update.
1657 * common/ptid.c: Update.
1658 * common/ptid.h: Update.
1659 * corelow.c: Update.
1660 * darwin-nat.c: Update.
1661 * fbsd-nat.c: Update.
1662 * gnu-nat.c: Update.
1663 * linux-fork.c: Update.
1664 * linux-nat.c: Update.
1665 * linux-thread-db.c: Update.
1666 * nat/linux-osdata.c: Update.
1667 * nat/linux-procfs.c: Update.
1668 * nto-procfs.c: Update.
1669 * obsd-nat.c: Update.
1670 * proc-service.c: Update.
1672 * ravenscar-thread.c: Update.
1673 * remote-sim.c: Update.
1675 * sol-thread.c: Update.
1677 * windows-nat.c: Update.
1679 2018-07-03 Tom Tromey <tom@tromey.com>
1681 * infrun.c (follow_exec): Use exit_inferior_silent.
1682 * inferior.c (exit_inferior_num_silent): Remove.
1683 * inferior.h (exit_inferior_num_silent): Don't declare.
1685 2018-07-03 Tom Tromey <tom@tromey.com>
1688 * darwin-nat.c (darwin_attach_pid): Reset inferior and
1689 inferior_ptid on error.
1691 2018-07-02 Maciej W. Rozycki <macro@mips.com>
1692 Simon Marchi <simon.marchi@polymtl.ca>
1695 * disasm.h (gdb_disassembler): Add
1696 `m_disassembler_options_holder'. member
1697 * disasm.c (get_all_disassembler_options): New function.
1698 (gdb_disassembler::gdb_disassembler): Use it.
1699 (gdb_buffered_insn_length_init_dis): Likewise.
1700 (gdb_buffered_insn_length): Adjust accordingly.
1701 (set_disassembler_options): Handle options with arguments.
1702 (show_disassembler_options_sfunc): Likewise. Add a leading new
1703 line if showing options with descriptions.
1704 (disassembler_options_completer): Adapt to using the
1705 `disasm_options_and_args_t' structure.
1706 * mips-tdep.c (mips_disassembler_options): New variable.
1707 (mips_disassembler_options_o32): Likewise.
1708 (mips_disassembler_options_n32): Likewise.
1709 (mips_disassembler_options_n64): Likewise.
1710 (gdb_print_insn_mips): Don't set `disassembler_options'.
1711 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
1713 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
1714 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
1715 `gdbarch_disassembler_options_implicit' and
1716 `gdbarch_valid_disassembler_options'.
1717 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
1718 `disasm_options_and_args_t' structure.
1719 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
1721 (valid_disassembler_options): Switch from `disasm_options_t' to
1722 the `disasm_options_and_args_t' structure.
1723 * NEWS: Document `set disassembler-options' support for the MIPS
1725 * gdbarch.h: Regenerate.
1726 * gdbarch.c: Regenerate.
1728 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
1730 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
1732 2018-06-29 Joel Brobecker <brobecker@adacore.com>
1734 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
1735 parameter in call to amd64_target_description.
1736 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
1737 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
1738 (amd64fbsd_init_abi): Likewise.
1739 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
1740 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
1741 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
1742 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
1744 2018-06-29 Pedro Alves <palves@redhat.com>
1746 * gdb/amd64-tdep.h (amd64_create_target_description): Add
1747 "segments" parameter.
1748 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
1749 (_initialize_amd64_tdep): Update call to
1750 amd64_create_target_description.
1751 (amd64_target_description): Add "segments" parameter. Adjust
1752 the implementation to use it.
1753 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
1754 call to amd64_create_target_description.
1755 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
1756 * gdb/arch/amd64.h (amd64_create_target_description): Add
1757 "segments" register.
1758 * gdb/arch/amd64.c (amd64_create_target_description): Add
1759 "segments" parameter. Call create_feature_i386_64bit_segments
1760 only if SEGMENTS is true.
1761 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
1762 call to amd64_create_target_description.
1764 2018-06-29 Pedro Alves <palves@redhat.com>
1766 * thread.c (thread_target_id_str): New, factored out from ...
1767 (print_thread_info_1): ... here. Use it to compute the max
1768 "Target Id" column width.
1770 2018-06-29 Pedro Alves <palves@redhat.com>
1772 * remote.c (remote_target::extra_thread_info): Delete
1773 'display_buf' and 'n' locals. from the cache, regardless of
1774 packet mechanims is in use. Use cache for qThreadExtra and qP
1777 2018-06-29 Pedro Alves <palves@redhat.com>
1779 * blockframe.c (find_pc_sect_containing_function): New function.
1780 * breakpoint.c (print_breakpoint_location): Don't call
1781 find_pc_sect_function.
1782 * linespec.c (create_sals_line_offset): Record the location's
1784 * linespec.c (convert_address_location_to_sals): Fill in sal's
1785 symbol with find_pc_sect_containing_function.
1786 * symtab.c (find_function_start_sal): Rename to ...
1787 (find_function_start_sal_1): ... this.
1788 (find_function_start_sal): Reimplement as wrapper around
1789 find_function_start_sal_1, and use
1790 find_pc_sect_containing_function to fill in the sal's symbol.
1791 (find_function_start_sal(symbol*, bool)): Adjust.
1792 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
1794 (find_pc_sect_containing_function): Declare.
1796 2018-06-29 Pedro Alves <palves@redhat.com>
1798 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
1799 true if the the location has no symbol.
1801 2018-06-28 Tom Tromey <tom@tromey.com>
1803 * NEWS: Mention --enable-codesign.
1804 * silent-rules.mk (ECHO_SIGN): New variable.
1805 * configure.ac: Add --enable-codesign.
1806 * configure: Rebuild.
1807 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
1808 (gdb$(EXEEXT)): Optionally invoke codesign.
1810 2018-06-28 Pedro Alves <palves@redhat.com>
1812 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
1814 (switch_to_thread_no_regs): Adjust comment.
1815 * infcmd.c (stop_pc): Delete.
1816 (post_create_inferior, info_program_command): Replace references
1817 to stop_pc with references to thread_info->suspend.stop_pc.
1818 * inferior.h (stop_pc): Delete declaration.
1819 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
1820 (handle_inferior_event_1, handle_signal_stop)
1821 (process_event_stop_test, keep_going_stepped_thread)
1822 (handle_step_into_function, handle_step_into_function_backward)
1823 (print_stop_location): Replace references to stop_pc with
1824 references to thread_info->suspend.stop_pc.
1825 (struct infcall_suspend_state) <stop_pc>: Delete field.
1826 (save_infcall_suspend_state, restore_infcall_suspend_state):
1827 Remove references to inf_stat->stop_pc.
1828 * linux-fork.c (fork_load_infrun_state): Likewise.
1829 * record-btrace.c (record_btrace_set_replay): Likewise.
1830 * record-full.c (record_full_goto_entry): Likewise.
1831 * remote.c (print_one_stopped_thread): Likewise.
1832 * target.c (target_resume): Extend comment.
1833 * thread.c (set_executing_thread): New.
1834 (set_executing): Use it.
1835 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
1836 Remove references to stop_pc.
1838 2018-06-28 Pedro Alves <palves@redhat.com>
1840 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
1841 Moving fetching stop_pc until after ecs->event_thread is refreshed.
1843 2018-06-28 Tom Tromey <tom@tromey.com>
1845 * coffread.c (coff_symfile_finish): Update.
1846 * xcoffread.c (xcoff_symfile_finish): Update.
1847 * elfread.c (elf_symfile_finish): Update.
1848 * symfile.h (dwarf2_free_objfile): Don't declare.
1849 * dwarf2read.c (_initialize_dwarf2_read): Use
1850 register_objfile_data_with_cleanup.
1851 (dwarf2_free_objfile): Now static. Change signature.
1853 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
1855 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
1856 option "-o" to add-symbol-file-load to add an offset to each
1857 section's load address.
1858 * symfile.c (set_objfile_default_section_offset): New function.
1860 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
1862 * symfile.c (add_symbol_file_command): Make sure that sections
1863 with the same name are sorted in the same order.
1865 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
1867 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
1868 require the second argument. If omitted, load sections at the
1869 addresses specified in the file.
1871 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
1873 * symfile.c (symbol_file_command, symbol_file_add_main_1)
1874 (_initialize_symfile): Add option "-o" to symbol-file to add an
1875 offset to each section of the symbol file.
1877 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
1879 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
1881 2018-06-27 Tom Tromey <tom@tromey.com>
1883 * stack.c (_initialize_stack): Update "func" help text.
1885 2018-06-27 Tom Tromey <tom@tromey.com>
1887 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
1889 (unwind_infopy_str, pyuw_create_unwind_info)
1890 (unwind_infopy_add_saved_register, pyuw_sniffer)
1891 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
1893 (struct saved_reg): Add constructor.
1894 <value>: Now a gdbpy_ref<>.
1896 2018-06-27 Tom Tromey <tom@tromey.com>
1898 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
1900 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1902 * gdb-gdb.py.in: Format using autopep8.
1904 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1906 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
1907 (type_lookup_function): Recognize CORE_ADDR values.
1909 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1911 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
1914 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1916 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
1919 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1921 * gdb-gdb.py: Move to...
1922 * gdb-gdb.py.in: ... here.
1923 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
1924 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
1926 (distclean): Remove gdb-gdb.py when cleaning.
1927 (gdb-gdb.py, gdb-gdb.gdb): New rules.
1928 * configure: Re-generate.
1930 2018-06-27 Pedro Alves <palves@redhat.com>
1932 * proc-service.c (get_ps_regcache): New.
1933 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
1934 (ps_lsetfpregs): Use it.
1936 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
1939 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
1940 (dwarf_decode_lines_1): Adjust.
1942 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1944 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
1946 <info_proc>: Likewise.
1948 2018-06-26 Joel Brobecker <brobecker@adacore.com>
1950 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
1951 to windows_fetch_one_register, and only handle the case of
1952 fetching one register. Move the code that reloads the context
1953 and iterates over all registers if R is negative to...
1954 (windows_nat_target::fetch_registers): ... here.
1955 (do_windows_store_inferior_registers): Rename to
1956 windows_store_one_register, and only handle the case of storing
1957 one register. Move the code that handles the case where r is
1959 (windows_nat_target::store_registers) ... here.
1961 2018-06-26 Tom Tromey <tom@tromey.com>
1964 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
1965 * rust-lang.c (rust_print_struct_def): Add podata parameter.
1967 (rust_internal_print_type): Add podata parameter.
1968 (rust_print_type): Update.
1970 2018-06-26 Tom Tromey <tom@tromey.com>
1972 * typeprint.h (struct print_offset_data) <update, finish,
1973 maybe_print_hole>: New methods.
1974 <indentation>: New constant.
1975 * typeprint.c (print_offset_data::indentation): Define.
1976 (print_offset_data::maybe_print_hole, print_offset_data::update)
1977 (print_offset_data::finish): Move from c-typeprint.c and rename.
1978 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
1979 (print_spaces_filtered_with_print_options): Update.
1980 (c_print_type_union_field_offset, maybe_print_hole)
1981 (c_print_type_struct_field_offset): Move to typeprint.c and
1983 (c_type_print_base_struct_union): Update.
1985 2018-06-25 Pedro Alves <palves@redhat.com>
1987 * gdbthread.h (thread_info_ref, delete_thread)
1988 (delete_thread_silent, first_thread_of_inferior)
1989 (any_thread_of_inferior, switch_to_thread)
1990 (enable_thread_stack_temporaries)
1991 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1992 (get_last_thread_stack_temporary)
1993 (value_in_thread_stack_temporaries, can_access_registers_thread):
1994 Spell out "struct thread_info" instead of just "thread_info".
1995 * inferior.h (notice_new_inferior): Likewise.
1997 2018-06-25 Pedro Alves <palves@redhat.com>
1999 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2000 pass thread_info pointer to delete_thread.
2001 (windows_nat_target::detach): Pass inferior pointer to
2003 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
2005 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
2006 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
2007 and pass a thread_info pointer to delete_thread.
2008 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
2009 pass thread_info pointer to delete_thread.
2010 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
2011 delete_thread_silent call.
2012 * procfs.c (procfs_target::detach): Pass inferior pointer to
2014 (procfs_target::wait): Pass thread_info pointer to delete_thread.
2015 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
2016 delete_thread_silent call.
2017 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2018 pass thread_info pointer to delete_thread.
2019 (windows_nat_target::detach): Pass inferior pointer to
2022 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2024 * regcache.c (readable_regcache::read_part): Fix asserts.
2025 (reg_buffer::raw_collect_part): New function.
2026 (regcache::write_part): Fix asserts.
2027 (reg_buffer::raw_supply_part): New function.
2028 (regcache::transfer_regset_register): New helper function.
2029 (regcache::transfer_regset): Call new functions.
2030 (regcache_supply_regset): Use gdb_byte*.
2031 (regcache::supply_regset): Likewise.
2032 (regcache_collect_regset): Likewise.
2033 (regcache::collect_regset): Likewise.
2034 * regcache.h (reg_buffer::raw_collect_part): New declaration.
2035 (reg_buffer::raw_supply_part): Likewise.
2036 (regcache::transfer_regset_register): Likewise.
2037 (regcache::transfer_regset): Use gdb_byte*.
2039 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2041 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
2043 2018-06-21 Pedro Alves <palves@redhat.com>
2045 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
2046 instead of a ptid_t. All callers adjusted.
2047 * ada-tasks.c (ada_get_task_number): Likewise. All callers
2049 (print_ada_task_info, display_current_task_id, task_command_1):
2051 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
2053 (breakpoint_kind): Adjust.
2054 (remove_breakpoints_pid): Rename to ...
2055 (remove_breakpoints_inf): ... this. Adjust to take an inferior
2056 pointer. All callers adjusted.
2057 (bpstat_clear_actions): Use inferior_thread.
2058 (get_bpstat_thread): New.
2059 (bpstat_do_actions): Use it.
2060 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
2061 to take a thread_info pointer. All callers adjusted.
2062 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
2063 (breakpoint_re_set_thread): Use inferior_thread.
2064 * breakpoint.h (struct inferior): Forward declare.
2065 (bpstat_stop_status): Update.
2066 (remove_breakpoints_pid): Delete.
2067 (remove_breakpoints_inf): New.
2068 * bsd-uthread.c (bsd_uthread_target::wait)
2069 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
2070 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
2071 (maint_btrace_packet_history_cmd)
2072 (maint_btrace_clear_packet_history_cmd): Adjust.
2073 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
2075 * cli/cli-interp.c: Include "inferior.h".
2076 * common/refcounted-object.h (struct
2077 refcounted_object_ref_policy): New.
2078 * compile/compile-object-load.c: Include gdbthread.h.
2079 (store_regs): Use inferior_thread.
2080 * corelow.c (core_target::close): Use current_inferior.
2081 (core_target_open): Adjust to use first_thread_of_inferior and use
2082 the current inferior.
2083 * ctf.c (ctf_target::close): Adjust to use current_inferior.
2084 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
2085 <thread>: ... this new field. All references adjusted.
2086 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
2087 Take a thread_info pointer instead of a ptid_t.
2088 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
2089 (dummy_frame_discard, register_dummy_frame_dtor): Take a
2090 thread_info pointer instead of a ptid_t.
2091 * elfread.c: Include "inferior.h".
2092 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
2093 Use inferior_thread.
2094 * eval.c (evaluate_subexp): Likewise.
2095 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
2097 * gdb_proc_service.h (struct thread_info): Forward declare.
2098 (struct ps_prochandle) <ptid>: Delete, replaced by ...
2099 <thread>: ... this new field. All references adjusted.
2100 * gdbarch.h, gdbarch.c: Regenerate.
2101 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
2102 'thread' parameter. All implementations and callers adjusted.
2103 * gdbthread.h (thread_info) <set_running>: New method.
2104 (delete_thread, delete_thread_silent): Take a thread_info pointer
2106 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
2107 (first_thread_of_process): Delete, replaced by ...
2108 (first_thread_of_inferior): ... this new function. All callers
2110 (any_live_thread_of_process): Delete, replaced by ...
2111 (any_live_thread_of_inferior): ... this new function. All callers
2113 (switch_to_thread, switch_to_no_thread): Declare.
2114 (is_executing): Delete.
2115 (enable_thread_stack_temporaries): Update comment.
2116 <enable_thread_stack_temporaries>: Take a thread_info pointer
2117 instead of a ptid_t. Incref the thread.
2118 <~enable_thread_stack_temporaries>: Decref the thread.
2121 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2122 (get_last_thread_stack_temporary)
2123 (value_in_thread_stack_temporaries, can_access_registers_thread):
2124 Take a thread_info pointer instead of a ptid_t. All callers
2126 * infcall.c (get_call_return_value): Use inferior_thread.
2127 (run_inferior_call): Work with thread pointers instead of ptid_t.
2128 (call_function_by_hand_dummy): Work with thread pointers instead
2129 of ptid_t. Use thread_info_ref.
2130 * infcmd.c (proceed_thread_callback): Access thread's state
2132 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
2133 access thread's state directly.
2134 (continue_command): Use inferior_thread.
2135 (info_program_command): Use find_thread_ptid and access thread
2137 (proceed_after_attach_callback): Use thread state directly.
2138 (notice_new_inferior): Take a thread_info pointer instead of a
2139 ptid_t. All callers adjusted.
2140 (exit_inferior): Take an inferior pointer instead of a pid. All
2142 (exit_inferior_silent): New.
2143 (detach_inferior): Delete.
2144 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
2145 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
2146 (detach_inferior_command, kill_inferior_command): Use
2147 find_inferior_id instead of valid_gdb_inferior_id and
2148 gdb_inferior_id_to_pid.
2149 (inferior_command): Use inferior and thread pointers.
2150 * inferior.h (struct thread_info): Forward declare.
2151 (notice_new_inferior): Take a thread_info pointer instead of a
2152 ptid_t. All callers adjusted.
2153 (detach_inferior): Delete declaration.
2154 (exit_inferior, exit_inferior_silent): Take an inferior pointer
2155 instead of a pid. All callers adjusted.
2156 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
2157 (valid_gdb_inferior_id): Delete.
2158 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
2159 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
2160 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
2162 <inf>: ... this new field.
2163 <step_ptid>: Delete, replaced by ...
2164 <step_thread>: ... this new field.
2165 (get_displaced_stepping_state): Take an inferior pointer instead
2166 of a pid. All callers adjusted.
2167 (displaced_step_in_progress_any_inferior): Adjust.
2168 (displaced_step_in_progress_thread): Take a thread pointer instead
2169 of a ptid_t. All callers adjusted.
2170 (displaced_step_in_progress, add_displaced_stepping_state): Take
2171 an inferior pointer instead of a pid. All callers adjusted.
2172 (get_displaced_step_closure_by_addr): Adjust.
2173 (remove_displaced_stepping_state): Take an inferior pointer
2174 instead of a pid. All callers adjusted.
2175 (displaced_step_prepare_throw, displaced_step_prepare)
2176 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
2177 All callers adjusted.
2178 (start_step_over): Adjust.
2179 (infrun_thread_ptid_changed): Remove bit updating ptids in the
2180 displaced step queue.
2181 (do_target_resume): Adjust.
2182 (fetch_inferior_event): Use inferior_thread.
2183 (context_switch, get_inferior_stop_soon): Take an
2184 execution_control_state pointer instead of a ptid_t. All callers
2186 (switch_to_thread_cleanup): Delete.
2187 (stop_all_threads): Use scoped_restore_current_thread.
2188 * inline-frame.c: Include "gdbthread.h".
2189 (inline_state) <inline_state>: Take a thread pointer instead of a
2190 ptid_t. All callers adjusted.
2191 <ptid>: Delete, replaced by ...
2192 <thread>: ... this new field.
2193 (find_inline_frame_state): Take a thread pointer instead of a
2194 ptid_t. All callers adjusted.
2195 (skip_inline_frames, step_into_inline_frame)
2196 (inline_skipped_frames, inline_skipped_symbol): Take a thread
2197 pointer instead of a ptid_t. All callers adjusted.
2198 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
2199 (inline_skipped_frames, inline_skipped_symbol): Likewise.
2200 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
2202 * linux-nat.c (get_detach_signal): Likewise.
2203 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
2204 (thread_db_notice_clone): Adjust.
2205 (thread_db_find_new_threads_silently)
2206 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
2207 a thread pointer instead of a ptid_t. All callers adjusted.
2208 * mi/mi-cmd-var.c: Include "inferior.h".
2209 (mi_cmd_var_update_iter): Update to use thread pointers.
2210 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
2212 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
2214 (mi_output_running): ... this new function.
2215 (mi_on_resume_1): Adjust to use it.
2216 (mi_user_selected_context_changed): Adjust to use inferior_thread.
2217 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
2219 (interrupt_thread_callback): : Adjust to use thread and inferior
2221 * proc-service.c: Include "gdbthread.h".
2222 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
2223 * progspace-and-thread.c: Include "inferior.h".
2224 * progspace.c: Include "inferior.h".
2225 * python/py-exitedevent.c (create_exited_event_object): Adjust to
2226 hold a reference to an inferior_object.
2227 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
2229 * python/py-inferior.c (struct inferior_object): Give the type a
2230 tag name instead of a typedef.
2231 (python_on_normal_stop): No need to check if the current thread is
2233 (inferior_to_inferior_object): Change return type to
2234 inferior_object. All callers adjusted.
2235 (find_thread_object): Delete, bits factored out to ...
2236 (thread_to_thread_object): ... this new function.
2237 * python/py-infthread.c (create_thread_object): Use
2238 inferior_to_inferior_object.
2239 (thpy_is_stopped): Use thread pointer directly.
2240 (gdbpy_selected_thread): Use inferior_thread.
2241 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
2242 field, replaced with ...
2243 <thread>: ... this new field. All users adjusted.
2244 (btpy_insn_or_gap_new): Drop const.
2245 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
2247 * python/py-record.c: Include "gdbthread.h".
2248 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2249 a ptid_t. All callers adjusted.
2250 (gdbpy_current_recording): Use inferior_thread.
2251 * python/py-record.h (recpy_record_object) <ptid>: Delete
2252 field, replaced with ...
2253 <thread>: ... this new field. All users adjusted.
2254 (recpy_element_object) <ptid>: Delete
2255 field, replaced with ...
2256 <thread>: ... this new field. All users adjusted.
2257 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2258 a ptid_t. All callers adjusted.
2259 * python/py-threadevent.c: Include "gdbthread.h".
2260 (get_event_thread): Use thread_to_thread_object.
2261 * python/python-internal.h (struct inferior_object): Forward
2263 (find_thread_object, find_inferior_object): Delete declarations.
2264 (thread_to_thread_object, inferior_to_inferior_object): New
2266 * record-btrace.c: Include "inferior.h".
2267 (require_btrace_thread): Use inferior_thread.
2268 (record_btrace_frame_sniffer)
2269 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
2270 (get_thread_current_frame): Use scoped_restore_current_thread and
2272 (get_thread_current_frame): Use thread pointer directly.
2273 (record_btrace_replay_at_breakpoint): Use thread's inferior
2275 * record-full.c: Include "inferior.h".
2276 * regcache.c: Include "gdbthread.h".
2277 (get_thread_arch_regcache): Use the inferior's address space
2279 (get_thread_regcache, registers_changed_thread): New.
2280 * regcache.h (get_thread_regcache(thread_info *thread)): New
2282 (registers_changed_thread): New.
2283 (remote_target) <remote_detach_1>: Swap order of parameters.
2284 (remote_add_thread): <remote_add_thread>: Return the new thread.
2285 (get_remote_thread_info(ptid_t)): New overload.
2286 (remote_target::remote_notice_new_inferior): Use thread pointers
2288 (remote_target::process_initial_stop_replies): Use
2289 thread_info::set_running.
2290 (remote_target::remote_detach_1, remote_target::detach)
2291 (extended_remote_target::detach): Adjust.
2292 * stack.c (frame_show_address): Use inferior_thread.
2293 * target-debug.h (target_debug_print_thread_info_pp): New.
2294 * target-delegates.c: Regenerate.
2295 * target.c (default_thread_address_space): Delete.
2296 (memory_xfer_partial_1): Use current_inferior.
2297 (target_detach): Use current_inferior.
2298 (target_thread_address_space): Delete.
2299 (generic_mourn_inferior): Use current_inferior.
2300 * target.h (struct target_ops) <thread_address_space>: Delete.
2301 (target_thread_address_space): Delete.
2302 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
2304 (delete_thread_1, delete_thread, delete_thread_silent): Take a
2305 thread pointer instead of a ptid_t. Adjust all callers.
2306 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
2307 (first_thread_of_process): Delete, replaced by ...
2308 (first_thread_of_inferior): ... this new function. All callers
2310 (any_thread_of_process): Rename to ...
2311 (any_thread_of_inferior): ... this, and take an inferior pointer.
2312 (any_live_thread_of_process): Rename to ...
2313 (any_live_thread_of_inferior): ... this, and take an inferior
2315 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2316 (value_in_thread_stack_temporaries)
2317 (get_last_thread_stack_temporary): Take a thread pointer instead
2318 of a ptid_t. Adjust all callers.
2319 (thread_info::set_running): New.
2320 (validate_registers_access): Use inferior_thread.
2321 (can_access_registers_ptid): Rename to ...
2322 (can_access_registers_thread): ... this, and take a thread
2324 (print_thread_info_1): Adjust to compare thread pointers instead
2326 (switch_to_no_thread, switch_to_thread): Make extern.
2327 (scoped_restore_current_thread::~scoped_restore_current_thread):
2328 Use m_thread pointer directly.
2329 (scoped_restore_current_thread::scoped_restore_current_thread):
2330 Use inferior_thread.
2331 (thread_command): Use thread pointer directly.
2332 (thread_num_make_value_helper): Use inferior_thread.
2333 * top.c (execute_command): Use inferior_thread.
2334 * tui/tui-interp.c: Include "inferior.h".
2335 * varobj.c (varobj_create): Use inferior_thread.
2336 (value_of_root_1): Use find_thread_global_id instead of
2337 global_thread_id_to_ptid.
2339 2018-06-21 Alan Hayward <alan.hayward@arm.com>
2341 * regcache.c (readable_regcache::read_part): Avoid memcpy when
2343 (regcache::write_part): Likewise.
2344 (readable_regcache::cooked_read_part): Update comment.
2345 (readable_regcache::cooked_write_part): Likewise.
2346 * regcache.h: (readable_regcache::read_part): Likewise.
2347 (regcache::write_part): Likewise.
2349 2018-06-21 Richard Bunt <richard.bunt@arm.com>
2350 Dirk Schubert <dirk.schubert@arm.com>
2352 * aarch64-linux-nat.c (post_attach): New.
2353 (aarch64_linux_nat_target::post_attach): Override post_attach to
2354 record the number of hardware debug registers.
2356 2018-06-20 Tom Tromey <tom@tromey.com>
2358 * python/py-param.c (add_setshow_generic): Make parameters const.
2359 (parmpy_init): Update.
2361 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2363 * regcache.h (regcache_cooked_read_ftype): Rename to...
2364 (register_read_ftype): ...this, change type to function_view.
2365 (class reg_buffer) <save>: Remove src parameter.
2366 (readonly_detached_regcache) <readonly_detached_regcache>: Make
2367 parameter non-const in first overload. Remove src parameter in
2369 * regcache.c (do_cooked_read): Remove.
2370 (readonly_detached_regcache::readonly_detached_regcache): Make
2371 parameter non-const, adjust call to other constructor.
2372 (reg_buffer::save): Remove src parameter.
2373 * frame.c (do_frame_register_read): Remove.
2374 (frame_save_as_regcache): Use lambda function.
2375 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
2376 parameter to ppu2spu_data *.
2377 (ppu2spu_sniffer): Use lambda function.
2379 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2381 * record-full.c (record_full_target::insert_breakpoint): Remove
2382 "struct" keyword, add const.
2384 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2386 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
2387 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
2388 * configure.ac: Remove AC_PREREQ, add missing quoting.
2389 * gnulib/configure.ac: Modernize usage of
2390 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
2391 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
2392 (AUTOMAKE_VERSION): Bump to 1.15.1.
2393 * configure: Re-generate.
2394 * config.in: Re-generate.
2395 * aclocal.m4: Re-generate.
2396 * gnulib/aclocal.m4: Re-generate.
2397 * gnulib/config.in: Re-generate.
2398 * gnulib/configure: Re-generate.
2399 * gnulib/import/Makefile.in: Re-generate.
2401 2018-06-19 Pedro Alves <palves@redhat.com>
2403 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
2404 (lookup_minimal_symbol_by_pc_section): ... here with
2405 gdb_assert_not_reached added.
2407 2018-06-19 Pedro Alves <palves@redhat.com>
2409 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
2410 parameter with a block parameter. Compare location's block symbol
2411 with the frame's block instead of addresses.
2412 (skip_inline_frames): Pass the current block instead of the
2413 frame's address. Break out as soon as we determine the frame
2414 should not be skipped.
2416 2018-06-18 Tom Tromey <tom@tromey.com>
2418 * solib-aix.c (solib_aix_get_section_offsets): Return
2420 (solib_aix_solib_create_inferior_hook): Update.
2422 2018-06-18 Tom Tromey <tom@tromey.com>
2424 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
2426 2018-06-18 Tom Tromey <tom@tromey.com>
2428 * solib-frv.c (frv_relocate_main_executable): Use
2430 * solib-dsbt.c (dsbt_relocate_main_executable): Use
2433 2018-06-18 Tom Tromey <tom@tromey.com>
2435 * objfiles.h (inhibit_section_map_updates): Update.
2436 (resume_section_map_updates, resume_section_map_updates_cleanup):
2438 * solib-svr4.c (svr4_handle_solib_event): Update.
2439 * objfiles.c (inhibit_section_map_updates): Return
2440 scoped_restore_tmpl<int>.
2441 (resume_section_map_updates, resume_section_map_updates_cleanup):
2444 2018-06-18 Tom Tromey <tom@tromey.com>
2446 * valprint.h (read_string): Update.
2447 * valprint.c (read_string): Change type of "buffer".
2448 (val_print_string): Update.
2449 * python/py-value.c (valpy_string): Update.
2450 * language.h (struct language_defn) <la_get_string>: Change
2452 (default_get_string, c_get_string): Update.
2453 * language.c (default_get_string): Change type of "buffer".
2454 * guile/scm-value.c (gdbscm_value_to_string): Update.
2455 * c-lang.c (c_get_string): Change type of "buffer".
2457 2018-06-18 Tom Tromey <tom@tromey.com>
2459 * ser-mingw.c (struct pipe_state_destroyer): New.
2460 (pipe_state_up): New typedef.
2461 (cleanup_pipe_state): Remove.
2462 (pipe_windows_open): Use pipe_state_up. Don't release argv.
2464 2018-06-18 Tom Tromey <tom@tromey.com>
2466 * rust-lang.h (rust_yyerror): Don't declare.
2467 * rust-lang.c (rust_language_defn): Update.
2468 * rust-exp.y (yyerror): Now static.
2469 * parse.c (parse_exp_in_context_1): Update.
2470 * p-lang.h (p_yyerror): Don't declare.
2471 * p-lang.c (p_language_defn): Update.
2472 * p-exp.y (yyerror): Now static.
2473 * opencl-lang.c (opencl_language_defn): Update.
2474 * objc-lang.c (objc_language_defn): Update.
2475 * m2-lang.h (m2_yyerror): Don't declare.
2476 * m2-lang.c (m2_language_defn): Update.
2477 * m2-exp.y (yyerror): Now static.
2478 * language.h (struct language_defn) <la_error>: Remove.
2479 * language.c (unk_lang_error): Remove.
2480 (unknown_language_defn, auto_language_defn): Remove.
2481 * go-lang.h (go_yyerror): Don't declare.
2482 * go-lang.c (go_language_defn): Update.
2483 * go-exp.y (yyerror): Now static.
2484 * f-lang.h (f_yyerror): Don't declare.
2485 * f-lang.c (f_language_defn): Update.
2486 * f-exp.y (yyerror): Now static.
2487 * d-lang.h (d_yyerror): Don't declare.
2488 * d-lang.c (d_language_defn): Update.
2489 * d-exp.y (yyerror): Now static.
2490 * c-lang.h (c_yyerror): Don't declare.
2491 * c-lang.c (c_language_defn, cplus_language_defn)
2492 (asm_language_defn, minimal_language_defn): Update.
2493 * c-exp.y (yyerror): Now static.
2494 * ada-lang.h (ada_yyerror): Don't declare.
2495 * ada-lang.c (ada_language_defn): Update.
2496 * ada-exp.y (yyerror): Now static.
2498 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2500 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
2501 (store_sveregs_to_thread): Likewise.
2502 (aarch64_linux_fetch_inferior_registers): Check for SVE.
2503 (aarch64_linux_store_inferior_registers): Likewise.
2504 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
2506 (aarch64_sve_regs_copy_to_regcache): Likewise.
2507 (aarch64_sve_regs_copy_from_regcache): Likewise.
2508 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
2510 (aarch64_sve_regs_copy_to_regcache): Likewise.
2511 (aarch64_sve_regs_copy_from_regcache): Likewise.
2512 (sve_context): Structure from Linux headers.
2513 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
2514 (SVE_SIG_ZREG_SIZE): Likewise.
2515 (SVE_SIG_PREG_SIZE): Likewise.
2516 (SVE_SIG_FFR_SIZE): Likewise.
2517 (SVE_SIG_REGS_OFFSET): Likewise.
2518 (SVE_SIG_ZREGS_OFFSET): Likewise.
2519 (SVE_SIG_ZREG_OFFSET): Likewise.
2520 (SVE_SIG_ZREGS_SIZE): Likewise.
2521 (SVE_SIG_PREGS_OFFSET): Likewise.
2522 (SVE_SIG_PREG_OFFSET): Likewise.
2523 (SVE_SIG_PREGS_SIZE): Likewise.
2524 (SVE_SIG_FFR_OFFSET): Likewise.
2525 (SVE_SIG_REGS_SIZE): Likewise.
2526 (SVE_SIG_CONTEXT_SIZE): Likewise.
2527 (SVE_PT_REGS_MASK): Likewise.
2528 (SVE_PT_REGS_FPSIMD): Likewise.
2529 (SVE_PT_REGS_SVE): Likewise.
2530 (SVE_PT_VL_INHERIT): Likewise.
2531 (SVE_PT_VL_ONEXEC): Likewise.
2532 (SVE_PT_REGS_OFFSET): Likewise.
2533 (SVE_PT_FPSIMD_OFFSET): Likewise.
2534 (SVE_PT_FPSIMD_SIZE): Likewise.
2535 (SVE_PT_SVE_ZREG_SIZE): Likewise.
2536 (SVE_PT_SVE_PREG_SIZE): Likewise.
2537 (SVE_PT_SVE_FFR_SIZE): Likewise.
2538 (SVE_PT_SVE_FPSR_SIZE): Likewise.
2539 (SVE_PT_SVE_FPCR_SIZE): Likewise.
2540 (__SVE_SIG_TO_PT): Likewise.
2541 (SVE_PT_SVE_OFFSET): Likewise.
2542 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
2543 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
2544 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
2545 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
2546 (SVE_PT_SVE_PREG_OFFSET): Likewise.
2547 (SVE_PT_SVE_PREGS_SIZE): Likewise.
2548 (SVE_PT_SVE_FFR_OFFSET): Likewise.
2549 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
2550 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
2551 (SVE_PT_SVE_SIZE): Likewise.
2552 (SVE_PT_SIZE): Likewise.
2553 (HAS_SVE_STATE): New define.
2555 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2557 * nat/aarch64-sve-linux-sigcontext.h: New file.
2558 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
2560 (SVE_VQ_MIN): Likewise.
2561 (SVE_VQ_MAX): Likewise.
2562 (SVE_VL_MIN): Likewise.
2563 (SVE_VL_MAX): Likewise.
2564 (SVE_NUM_ZREGS): Likewise.
2565 (SVE_NUM_PREGS): Likewise.
2566 (sve_vl_valid): Likewise.
2567 (struct user_sve_header): Likewise.
2569 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
2570 Richard Bunt <Richard.Bunt@arm.com>
2572 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
2573 was requested by GDB.
2575 2018-06-15 Tom de Vries <tdevries@suse.de>
2577 * MAINTAINERS (Write After Approval): Add Tom de Vries.
2579 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
2581 * gnulib/update-gnulib.sh: Print expected versions of
2584 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
2586 * arch-utils.c (default_type_align): Use type_length_units.
2587 * gdbtypes.c (type_align): Use type_length_units.
2589 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2591 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
2592 of 'define' command.
2594 2018-06-14 Tom de Vries <tdevries@suse.de>
2597 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
2598 get_no_prettyformat_print_options.
2600 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
2602 * sparc-nat.h: Include target.h.
2603 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
2604 <fetch_registers>: Remove this argument in function call.
2605 <store_registers>: Remove this argument in function call, remove
2607 <low_forget_process>: Call sparc64_forget_process instead of
2608 sparc_forget_process.
2610 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2612 * procfs.c (_initialize_procfs): Use add_inf_child_target.
2613 (procfs_target::make_corefile_notes): Adjust to new
2614 target_read_alloc return type.
2616 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2617 Stephen Roberts <stephen.roberts@arm.com>
2620 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
2621 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
2622 Move should_notify_stop local into more inner scope.
2624 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2625 Stephen Roberts <stephen.roberts@arm.com>
2628 * infrun.c (resume_1): Add call to mark_async_event_handler.
2630 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2632 * infrun.c (do_target_wait): Change old version of $pc printed.
2634 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
2636 * dwarf2read.c (read_index_from_section): Rename to...
2637 (read_gdb_index_from_section): ... this, update all callers.
2638 (dwarf2_read_index): Rename to...
2639 (dwarf2_read_gdb_index): ... this, update all callers.
2641 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
2643 * gdb/hppa-linux-nat.c
2644 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
2645 hppa_linux_nat_target::fetch_registers.
2647 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2649 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
2650 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
2651 (AARCH64_DWARF_SVE_FFR): Likewise.
2652 (AARCH64_DWARF_SVE_P0): Likewise.
2653 (AARCH64_DWARF_SVE_Z0): Likewise.
2655 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2657 * common/common-regcache.h (raw_compare): New function.
2658 * regcache.c (regcache::raw_compare): Likewise.
2659 * regcache.h (regcache::raw_compare): New declaration.
2661 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2663 * common/common-regcache.h (reg_buffer_common): New structure.
2664 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
2665 (reg_buffer::raw_supply): Likewise.
2666 (reg_buffer::raw_supply_integer): Likewise.
2667 (reg_buffer::raw_supply_zeroed): Likewise.
2668 (reg_buffer::raw_collect): Likewise.
2669 (reg_buffer::raw_collect_integer): Likewise.
2670 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
2671 (reg_buffer::raw_supply): Likewise.
2672 (reg_buffer::raw_supply_integer): Likewise.
2673 (reg_buffer::raw_supply_zeroed): Likewise.
2674 (reg_buffer::raw_collect): Likewise.
2675 (reg_buffer::raw_collect_integer): Likewise.
2677 2018-06-10 Tom Tromey <tom@tromey.com>
2679 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
2680 (class remote_state) <stop_reply_queue>: Now std::vector.
2681 (remote_state::~remote_state)
2682 (remote_target::stop_reply_queue_length): Update.
2683 (struct queue_iter_param, remove_child_of_pending_fork)
2684 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
2685 (check_pending_event_prevents_wildcard_vcont_callback)
2686 (remove_stop_reply_for_inferior)
2687 (remove_stop_reply_of_remote_state)
2688 (remote_notif_remove_once_on_match)
2689 (stop_reply_match_ptid_and_ws)
2690 (remote_kill_child_of_pending_fork): Remove.
2691 (remote_target::remove_new_fork_children)
2692 (remote_target::check_pending_events_prevent_wildcard_vcont)
2693 (remote_target::discard_pending_stop_replies)
2694 (remote_target::discard_pending_stop_replies_in_queue)
2695 (remote_target::remote_notif_remove_queued_reply)
2696 (remote_target::queued_stop_reply)
2697 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
2698 (remote_target::wait, remote_target::kill_new_fork_children)
2699 (remote_target::async): Update.
2701 2018-06-10 Tom Tromey <tom@tromey.com>
2703 * record-full.c (record_full_arch_list_cleanups): Remove.
2704 (record_full_message): Use try/catch.
2705 (record_full_wait_cleanups): Remove.
2706 (record_full_wait_1): Use try/catch.
2707 (record_full_restore): Likewise.
2709 2018-06-10 Tom Tromey <tom@tromey.com>
2711 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
2712 declare VEC. Add constructor.
2713 <in_target_beneath>: Now bool.
2714 (record_full_breakpoints): Now a std::vector, static.
2715 (record_full_sync_record_breakpoints)
2716 (record_full_init_record_breakpoints)
2717 (record_full_target::insert_breakpoint)
2718 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
2720 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
2722 * dwarf2read.c (process_cu_includes): Remove struct keyword.
2723 * serial.c (serial_interface_lookup): Remove struct keyword.
2725 2018-06-10 Tom Tromey <tom@tromey.com>
2727 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
2729 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
2731 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
2733 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
2734 "beneath" as a method.
2735 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
2736 Use "beneath" as a method.
2738 2018-06-10 Tom Tromey <tom@tromey.com>
2740 * tracefile.c (struct trace_file_writer_deleter): New.
2741 <operator()>: Rename from trace_file_writer_xfree.
2742 (trace_file_writer_up): New typedef.
2743 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
2745 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
2747 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
2748 <m_registers, m_register_status>: Change type to
2750 * regcache.c (reg_buffer::reg_buffer): Use new instead of
2753 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
2755 * common/common-regcache.h (enum register_status): Add
2756 underlying type "signed char".
2757 * regcache.h (reg_buffer) <m_register_status>: Change type to
2759 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
2760 register_status instead of signed char.
2761 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
2762 (reg_buffer::get_register_status): Remove cast.
2763 (readable_regcache::raw_read): Remove cast.
2764 (readable_regcache::cooked_read): Remove cast.
2766 2018-06-09 Tom Tromey <tom@tromey.com>
2768 * source.c (reverse_search_command, forward_search_command): Use
2771 2018-06-09 Tom Tromey <tom@tromey.com>
2773 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
2774 (serial_ops_list): Now static, std::vector.
2775 (serial_interface_lookup, serial_add_interface): Update.
2777 2018-06-09 Tom Tromey <tom@tromey.com>
2779 * dwarf2read.c (process_cu_includes): Update.
2780 (process_full_comp_unit): Update.
2781 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
2784 2018-06-08 Paul Koning <paul_koning@dell.com>
2788 * python/python.c (do_start_initialization):
2789 Avoid call to internal Python API.
2790 (init__gdb_module): New function.
2792 2018-06-08 Gary Benson <gbenson@redhat.com>
2794 * linux-thread-db.c (valprint.h): New include.
2795 (struct check_thread_db_info): New structure.
2796 (check_thread_db_on_load, tdb_testinfo): New static globals.
2797 (check_thread_db, check_thread_db_callback): New functions.
2798 (try_thread_db_load_1): Run integrity checks if requested.
2799 (maintenance_check_libthread_db): New function.
2800 (_initialize_thread_db): Register "maint check libthread-db"
2801 and "maint set/show check-libthread-db".
2802 * NEWS: Mention the above new commands.
2804 2018-06-08 Tom Tromey <tom@tromey.com>
2806 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
2809 2018-06-08 Tom Tromey <tom@tromey.com>
2811 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
2813 2018-06-08 Tom Tromey <tom@tromey.com>
2815 * common/btrace-common.h (struct btrace_data): Add constructor,
2816 destructor, move assignment operator.
2817 <empty, clear, fini>: New methods.
2818 <format>: Initialize.
2819 (btrace_data_init, btrace_data_fini, btrace_data_clear)
2820 (btrace_data_empty): Don't declare.
2821 * common/btrace-common.c (btrace_data_init): Remove.
2822 (btrace_data::fini): Rename from btrace_data_fini.
2823 (btrace_data::empty): Rename from btrace_data_empty.
2824 (btrace_data::clear): Rename from btrace_data_clear. Return
2826 * btrace.h (make_cleanup_btrace_data): Don't declare.
2827 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
2828 (parse_xml_btrace): Update.
2829 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
2830 (maint_btrace_clear_packet_history_cmd): Update.
2832 2018-06-07 Pedro Alves <palves@redhat.com>
2834 * target.h (target_ops) <beneath>: Now a method. All references
2836 (class target_stack): New.
2837 * target.c (g_target_stack): New.
2838 (g_current_top_target): Delete.
2839 (current_top_target): Get the top target out of g_target_stack.
2840 (target_stack::push, target_stack::unpush): New.
2841 (push_target, unpush_target): Reimplement.
2842 (target_is_pushed): Reimplement in terms of g_target_stack.
2843 (target_ops::beneath, target_stack::find_beneath): New.
2845 2018-06-07 Pedro Alves <palves@redhat.com>
2847 * target.h (find_target_beneath): Delete declaration.
2848 * target.c (find_target_beneath): Delete definition.
2849 * aix-thread.c: All callers of find_target_beneath adjusted to
2850 call target_ops::beneath instead.
2851 * bsd-uthread.c: Likewise.
2852 * linux-thread-db.c: Likewise.
2853 * ravenscar-thread.c: Likewise.
2854 * sol-thread.c: Likewise.
2855 * spu-multiarch.c: Likewise.
2857 2018-06-07 Pedro Alves <palves@redhat.com>
2859 * target.h (target_ops) <beneath>: Now a method. All references
2861 (target_ops) <m_beneath>: New.
2862 * target.c (target_ops::beneath): New.
2863 * corelow.c: Adjust all references to target_ops::beneath.
2864 * linux-thread-db.c: Likewise.
2865 * make-target-delegates: Likewise.
2866 * record-btrace.c: Likewise.
2867 * record-full.c: Likewise.
2868 * remote.c: Likewise.
2869 * target.c: Likewise.
2870 * target-delegates.c: Regenerate.
2872 2018-06-07 Pedro Alves <palves@redhat.com>
2874 * target.h (target_stack): Delete.
2875 (current_top_target): Declare function.
2876 * target.c (target_stack): Delete.
2877 (g_current_top_target): New.
2878 (current_top_target): New function.
2879 * auxv.c: Use current_top_target instead of target_stack
2881 * avr-tdep.c: Likewise.
2882 * breakpoint.c: Likewise.
2883 * corefile.c: Likewise.
2884 * elfread.c: Likewise.
2886 * exceptions.c: Likewise.
2887 * frame.c: Likewise.
2888 * gdbarch-selftests.c: Likewise.
2889 * gnu-v3-abi.c: Likewise.
2890 * ia64-tdep.c: Likewise.
2891 * ia64-vms-tdep.c: Likewise.
2892 * infcall.c: Likewise.
2893 * infcmd.c: Likewise.
2894 * infrun.c: Likewise.
2895 * linespec.c: Likewise.
2896 * linux-tdep.c: Likewise.
2897 * minsyms.c: Likewise.
2898 * ppc-linux-nat.c: Likewise.
2899 * ppc-linux-tdep.c: Likewise.
2900 * procfs.c: Likewise.
2901 * regcache.c: Likewise.
2902 * remote.c: Likewise.
2903 * rs6000-tdep.c: Likewise.
2904 * s390-linux-nat.c: Likewise.
2905 * s390-tdep.c: Likewise.
2906 * solib-aix.c: Likewise.
2907 * solib-darwin.c: Likewise.
2908 * solib-dsbt.c: Likewise.
2909 * solib-spu.c: Likewise.
2910 * solib-svr4.c: Likewise.
2911 * solib-target.c: Likewise.
2912 * sparc-tdep.c: Likewise.
2913 * sparc64-tdep.c: Likewise.
2914 * spu-tdep.c: Likewise.
2915 * symfile.c: Likewise.
2916 * symtab.c: Likewise.
2917 * target-descriptions.c: Likewise.
2918 * target-memory.c: Likewise.
2919 * target.c: Likewise.
2920 * target.h: Likewise.
2921 * tracefile-tfile.c: Likewise.
2922 * tracepoint.c: Likewise.
2923 * valops.c: Likewise.
2924 * valprint.c: Likewise.
2925 * value.c: Likewise.
2926 * windows-tdep.c: Likewise.
2927 * mi/mi-main.c: Likewise.
2929 2018-06-07 Tom Tromey <tom@tromey.com>
2931 * valprint.h (build_address_symbolic): Declare.
2932 * printcmd.c (print_address_symbolic): Update.
2933 (build_address_symbolic): Change "name" and "filename" to
2935 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
2937 * defs.h (build_address_symbolic): Remove declaration.
2939 2018-06-07 Alan Hayward <alan.hayward@arm.com>
2941 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
2942 (aarch64_vnv_type): Add function.
2943 (aarch64_pseudo_register_name): Add V regs for SVE.
2944 (aarch64_pseudo_register_type): Likewise.
2945 (aarch64_pseudo_register_reggroup_p): Likewise.
2946 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
2947 (aarch64_pseudo_read_value): Add V regs for SVE.
2948 (aarch64_pseudo_write_2): Use V0 offset for SVE
2949 (aarch64_pseudo_write): Add V regs for SVE.
2950 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
2952 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
2954 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
2955 (sve_vl_from_vq): Likewise.
2957 2018-06-05 Tom Tromey <tom@tromey.com>
2959 * cli/cli-cmds.c (show_version): Update.
2960 * top.c (print_gdb_version): Add "interactive" parameter.
2962 * main.c (captured_main_1): Update.
2963 * top.h (print_gdb_version): Add "interactive" parameter and a
2966 2018-06-05 David Malcolm <dmalcolm@redhat.com>
2968 * common/enum-flags.h: Add trailing semicolon to example in
2971 2018-06-05 Tom Tromey <tom@tromey.com>
2974 * NEWS: Add entry about pager.
2975 * utils.c (pagination_disabled_for_command): New global.
2976 (prompt_for_continue): Allow "c" response to prompt.
2977 (reinitialize_more_filter): Clear
2978 pagination_disabled_for_command.
2979 (fputs_maybe_filtered): Check pagination_disabled_for_command.
2981 2018-06-04 Tom Tromey <tom@tromey.com>
2983 * ada-lang.h (ada_lookup_symbol_list): Update.
2984 * ada-lang.c (resolve_subexp): Update.
2985 (symbols_are_identical_enums): Change type of syms. Remove nsyms
2987 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
2988 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
2989 results parameter to std::vector.
2990 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
2992 * ada-exp.y (block_lookup): Update.
2993 (select_possible_type_sym): Change type of syms. Remove nsyms
2995 (write_var_or_type, write_name_assoc): Update.
2997 2018-06-04 Joel Brobecker <brobecker@adacore.com>
2999 * windows-nat.c (windows_nat_target::xfer_partial): Return
3000 TARGET_XFER_E_IO if we need to delegate to the target beneath
3001 but BENEATH is NULL.
3003 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
3005 * Makefile.in (config.status): Add configure.nat as a
3008 2018-06-04 Tom Tromey <tom@tromey.com>
3010 * cp-name-parser.y (cpname_state): Add method declarations.
3011 (HANDLE_QUAL): Update.
3012 (cpname_state::d_grab, cpname_state::fill_comp)
3013 (cpname_state::make_operator, cpname_state::make_dtor)
3014 (cpname_state::make_builtin_type, cpname_state::make_name)
3015 (cpname_state::d_qualify, cpname_state::d_int_type)
3016 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
3017 (%union): Move earlier.
3019 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3021 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
3023 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3025 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
3026 (aarch64_pseudo_write_1): Likewise.
3027 (aarch64_pseudo_read_value): Use helper.
3028 (aarch64_pseudo_write): Likewise.
3030 2018-06-04 Pedro Alves <palves@redhat.com>
3032 * darwin-nat.c (darwin_ops): Delete.
3033 (darwin_attach_pid): Use get_native_target.
3035 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3037 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
3038 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
3040 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3042 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
3043 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
3044 (aarch64_gdbarch_init): Check for SVE.
3045 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
3047 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3049 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
3050 * aarch64-tdep.h (aarch64_read_description): Likewise.
3051 * arch/aarch64.c (aarch64_create_target_description): Likewise.
3052 * arch/aarch64.h (aarch64_create_target_description): Likewise.
3053 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
3054 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
3055 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
3057 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
3059 * value.c (value_fetch_lazy_bitfield): New.
3060 (value_fetch_lazy_memory): New.
3061 (value_fetch_lazy_register): New.
3062 (value_fetch_lazy): Factor out to smaller functions.
3064 2018-06-01 Tom Tromey <tom@tromey.com>
3066 * cp-name-parser.y (backslashable, represented): Now const.
3068 2018-06-01 Tom Tromey <tom@tromey.com>
3070 * cp-name-parser.y: Include parser-defs.h.
3071 (parser_fprintf): Remove declaration.
3073 2018-06-01 Tom Tromey <tom@tromey.com>
3075 * cp-name-parser.y: Use %pure-parser, %lex-param, and
3077 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
3078 (global_result): Remove globals.
3079 (struct cpname_state): New.
3080 (yyparse): Don't declare.
3081 (yylex, yyerror): Move declarations after %union.
3082 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
3083 (make_name): Add state parameter.
3085 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
3087 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
3089 (yylex): Add lvalp, state parameters.
3090 (yyerror): Add state parameter.
3091 (cp_demangled_name_to_comp): Update.
3093 2018-06-01 Tom Tromey <tom@tromey.com>
3095 * cp-name-parser.y (parser_fprintf): Declare.
3096 (GDB_YY_REMAP_PREFIX): Define.
3097 Include yy-remap.h. Don't redefine yy* identifiers.
3099 2018-06-01 Tom Tromey <tom@tromey.com>
3101 * python/py-type.c (typy_legacy_template_argument): Update.
3102 * cp-support.h (cp_demangled_name_to_comp): Update.
3103 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
3104 parameter to be a "std::string *".
3107 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
3109 * ada-lex.l: Include "diagnostics.h" instead of
3110 "common/diagnostics.h".
3111 * unittests/environ-selftests.c: Likewise.
3112 * common/diagnostics.h: Moved to ../include.
3114 2018-06-01 Joel Brobecker <brobecker@adacore.com>
3116 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
3117 to language_mode_manual while calling breakpoint_re_set_one.
3119 2018-06-01 Tom Tromey <tom@tromey.com>
3121 * valops.c (value_cast_structs, destructor_name_p): Update.
3122 * symtab.c (gdb_mangle_name): Update.
3123 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
3125 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
3126 (pascal_object_print_value_fields, pascal_object_print_value):
3128 * p-typeprint.c (pascal_type_print_derivation_info): Update.
3129 * linespec.c (find_methods): Update.
3130 * gdbtypes.h (type_name_no_tag): Remove.
3131 (type_name_or_error): Rename from type_name_no_tag_or_error.
3132 * gdbtypes.c (type_name_no_tag): Remove.
3133 (type_name_or_error): Rename from type_name_no_tag_or_error.
3134 (lookup_struct_elt_type, check_typedef): Update.
3135 * expprint.c (print_subexp_standard): Update.
3136 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
3137 * d-namespace.c (d_lookup_nested_symbol): Update.
3138 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
3139 (cp_print_class_member): Update.
3140 * cp-namespace.c (cp_lookup_nested_symbol): Update.
3141 * completer.c (add_struct_fields): Update.
3142 * c-typeprint.c (cp_type_print_derivation_info)
3143 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
3145 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
3146 (ada_prefer_type, ada_is_exception_sym): Update.
3148 2018-06-01 Tom Tromey <tom@tromey.com>
3150 * valops.c (enum_constant_from_type, value_namespace_elt)
3151 (value_maybe_namespace_elt): Update.
3152 * valarith.c (find_size_for_pointer_math): Update.
3153 * target-descriptions.c (make_gdb_type): Update.
3154 * symmisc.c (print_symbol): Update.
3155 * stabsread.c (define_symbol, read_type)
3156 (complain_about_struct_wipeout, add_undefined_type)
3157 (cleanup_undefined_types_1): Update.
3158 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
3159 (rust_range_type_p, val_print_struct, rust_print_struct_def)
3160 (rust_internal_print_type, rust_composite_type)
3161 (rust_evaluate_funcall, rust_evaluate_subexp)
3162 (rust_inclusive_range_type_p): Update.
3163 * python/py-type.c (typy_get_tag): Update.
3164 * p-typeprint.c (pascal_type_print_base): Update.
3165 * mdebugread.c (parse_symbol, parse_type): Update.
3166 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
3168 * guile/scm-type.c (gdbscm_type_tag): Update.
3169 * go-lang.c (sixg_string_p): Update.
3170 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
3172 * gdbtypes.h (struct main_type) <tag_name>: Remove.
3173 (TYPE_TAG_NAME): Remove.
3174 * gdbtypes.c (type_name_no_tag): Simplify.
3175 (check_typedef, check_types_equal, recursive_dump_type)
3176 (copy_type_recursive, arch_composite_type): Update.
3177 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
3178 in summary mode when needed.
3179 * eval.c (evaluate_funcall): Update.
3180 * dwarf2read.c (fixup_go_packaging, read_structure_type)
3181 (process_structure_scope, read_enumeration_type)
3182 (read_namespace_type, read_module_type, determine_prefix): Update.
3183 * cp-support.c (inspect_type): Update.
3184 * coffread.c (process_coff_symbol, decode_base_type): Update.
3185 * c-varobj.c (c_is_path_expr_parent): Update.
3186 * c-typeprint.c (c_type_print_base_struct_union): Update.
3187 (c_type_print_base_1): Update. Print struct/class/union/enum in
3188 summary when using C language.
3189 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
3190 (gen_maybe_namespace_elt): Update.
3191 * ada-lang.c (ada_type_name): Simplify.
3192 (empty_record, ada_template_to_fixed_record_type_1)
3193 (template_to_static_fixed_type)
3194 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
3196 2018-06-01 Tom Tromey <tom@tromey.com>
3198 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
3200 * c-typeprint.c (c_print_type_1): Add "language" parameter.
3201 (c_print_type): Update.
3202 (c_print_type): New overload.
3203 (c_type_print_varspec_prefix, c_type_print_args)
3204 (c_type_print_varspec_suffix, c_print_type_no_offsets)
3205 (c_type_print_base_struct_union, c_type_print_base_1)
3206 (cp_type_print_method_args): Add "language" parameter.
3207 (c_type_print_base): Update.
3208 * c-lang.h (c_print_type): Add new overload.
3210 2018-06-01 Tom Tromey <tom@tromey.com>
3212 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
3213 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
3215 2018-06-01 Alan Hayward <alan.hayward@arm.com>
3217 * aarch64-tdep.c (aarch64_sve_register_names): New const
3219 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
3220 (AARCH64_SVE_Z_REGS_NUM): New define.
3221 (AARCH64_SVE_P_REGS_NUM): Likewise.
3222 (AARCH64_SVE_NUM_REGS): Likewise.
3224 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
3226 * nat/linux-ptrace.h [__alpha__]
3227 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
3230 2018-05-31 Maciej W. Rozycki <macro@mips.com>
3232 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
3233 the endianness selected.
3234 * NEWS: Document `set endian auto' mode operation update.
3236 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3238 * Makefile.in: Add new header.
3239 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
3240 (sve_vl_from_vg): Likewise.
3241 (sve_vq_from_vl): Likewise.
3242 (sve_vl_from_vq): Likewise.
3243 (sve_vq_from_vg): Likewise.
3244 (sve_vg_from_vq): Likewise.
3245 * configure.nat: Add new c file.
3246 * nat/aarch64-sve-linux-ptrace.c: New file.
3247 * nat/aarch64-sve-linux-ptrace.h: New file.
3249 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3251 * aarch64-linux-nat.c (aarch64_linux_read_description):
3253 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
3255 * aarch64-tdep.c (tdesc_aarch64_list): Add.
3256 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
3257 (aarch64_gdbarch_init): Add parmeter zero.
3258 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
3259 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
3260 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
3262 * doc/gdb.texinfo: Describe SVE feature
3263 * features/aarch64-sve.c: New file.
3265 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
3268 * gdbarch.sh (significant_addr_bit): Default to zero when
3269 not set by target architecture.
3270 * gdbarch.c: Re-generated.
3271 * utils.c (address_significant): Update.
3273 2018-05-30 Joel Brobecker <brobecker@adacore.com>
3275 * stack.c (func_command): Remove trailing newline in call to error.
3277 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3279 * regcache.h (regcache_raw_collect): Remove, update callers to
3280 use regcache::raw_collect.
3281 * regcache.c (regcache_raw_collect): Remove.
3283 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3285 * regcache.h (regcache_raw_supply): Remove, update callers to
3286 use detached_regcache::raw_supply.
3287 * regcache.c (regcache_raw_supply): Remove.
3289 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3291 * regcache.h (regcache_cooked_write_part): Remove, update
3292 callers to use regcache::cooked_write_part.
3293 * regcache.c (regcache_cooked_write_part): Remove.
3295 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3297 * regcache.h (regcache_cooked_read_part): Remove, update callers
3298 to use readable_regcache::cooked_read_part.
3299 * regcache.c (regcache_cooked_read_part): Remove.
3301 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3303 * regcache.h (regcache_cooked_read_value): Remove, update
3304 callers to use readable_regcache::cooked_read_value.
3305 * regcache.c (regcache_cooked_read_value): Remove.
3307 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3309 * regcache.h (regcache_cooked_write): Remove, update callers to
3310 use regcache::cooked_write.
3311 * regcache.c (regcache_cooked_write): Remove.
3313 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3315 * regcache.h (regcache_invalidate): Remove, update callers to
3316 use detached_regcache::invalidate instead.
3317 * regcache.c (regcache_invalidate): Remove.
3319 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3321 * regcache.h (regcache_raw_write_part): Remove, update callers
3322 to use regcache::raw_write_part instead.
3323 * regcache.c (regcache_raw_write_part): Remove.
3325 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3327 * regcache.h (regcache_raw_read_part): Remove, update callers to
3328 use readable_regcache::raw_read_part instead.
3329 * regcache.c (regcache_raw_read_part): Remove.
3331 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3333 * regcache.h (regcache_cooked_read): Remove, update callers to
3334 use readable_regcache::cooked_read instead.
3335 * regcache.c (regcache_cooked_read): Remove.
3337 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3339 * regcache.h (regcache_raw_write): Remove, update callers to use
3340 regcache::raw_write instead.
3341 * regcache.c (regcache_raw_write): Remove.
3343 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3345 * regcache.h (regcache_raw_read): Remove, update callers to use
3346 readable_regcache::raw_read instead.
3347 * regcache.c (regcache_raw_read): Remove.
3349 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3351 * regcache.h (regcache_raw_update): Remove, update callers to
3352 use readable_regcache::raw_update instead.
3353 * regcache.c (regcache_raw_update): Remove.
3355 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3357 * regcache.h (regcache_register_status): Remove, update callers
3358 to use reg_buffer::get_register_status directly instead.
3359 * regcache.c (regcache_register_status): Remove.
3361 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3363 * regcache.h (regcache_get_ptid): Remove, update all callers to
3364 call regcache::ptid instead.
3365 * regcache.c (regcache_get_ptid): Remove.
3367 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3369 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
3371 2018-05-30 Pedro Alves <palves@redhat.com>
3373 * common/common-exceptions.h (exception_rethrow): Use
3376 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
3378 * breakpoint.c (print_solib_event, check_status_catch_solib):
3379 Remove struct keyword in range-based for loops.
3380 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
3381 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
3383 * linespec.c (find_superclass_methods, search_minsyms_for_name):
3385 * symfile.c (addr_info_make_relative): Likewise.
3386 * thread.c (value_in_thread_stack_temporaries): Likewise.
3388 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
3391 * valops.c (value_struct_elt_for_reference): Call check_typedef on
3392 aggregate type to get its real type before accessing it.
3394 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
3396 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
3397 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
3398 * coff-pe-read.c (add_pe_forwarded_sym): Replace
3399 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
3400 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
3401 * jit.c (jit_breakpoint_re_set_internal): Likewise.
3402 * printcmd.c (info_address_command): Likewise.
3404 2018-05-29 Tom Tromey <tom@tromey.com>
3406 * windows-nat.c (handle_exception): Update fall-through comment.
3408 2018-05-29 Tom Tromey <tom@tromey.com>
3410 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
3411 (struct program_space) <added_solibs>: Now a std::vector.
3412 * breakpoint.c (print_solib_event): Update.
3413 (check_status_catch_solib): Update.
3414 * progspace.c (clear_program_space_solib_cache): Update.
3415 * solib.c (update_solib_list): Update.
3417 2018-05-29 Tom Tromey <tom@tromey.com>
3419 * python/py-type.c (typy_richcompare): Update.
3420 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
3421 * gdbtypes.h (types_deeply_equal): Return bool.
3422 (types_equal): Likewise.
3423 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
3425 (check_types_equal): Change worklist to std::vector. Return
3427 (struct type_equality_entry): Add constructor.
3428 (compare_maybe_null_strings): Return bool.
3429 (check_types_worklist): Return bool. Change worklist to
3431 (types_deeply_equal): Use std::vector.
3432 (types_equal): Return bool.
3433 (compare_maybe_null_strings): Simplify.
3435 2018-05-29 Tom Tromey <tom@tromey.com>
3437 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
3439 2018-05-29 Tom Tromey <tom@tromey.com>
3441 * objc-lang.h: Don't include cp-support.h.
3442 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
3445 2018-05-27 Tom Tromey <tom@tromey.com>
3447 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
3449 2018-05-25 Tom Tromey <tom@tromey.com>
3451 * value.c (value::location): Initialize.
3453 2018-05-25 Tom Tromey <tom@tromey.com>
3455 * dbxread.c (init_bincl_list): Remove.
3456 (bincl_list): Now a std::vector.
3457 (bincls_allocated, next_bincl): Remove.
3458 (free_bincl_list, do_free_bincl_list_cleanup)
3459 (make_cleanup_free_bincl_list): Remove.
3460 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
3462 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
3463 (struct header_file_location): Add constructor.
3464 (add_bincl_to_list): Remove.
3466 2018-05-25 Tom Tromey <tom@tromey.com>
3468 * tui/tui.c (tui_enable): Update.
3469 * mi/mi-interp.c (mi_interp::init): Update.
3470 * interps.h (class interp) <name>: New method.
3471 <m_name>: Rename from name.
3472 (~scoped_restore_interp): Update.
3473 * interps.c (interp::interp): Update.
3474 (interp_add, interp_set, interp_lookup_existing)
3475 (current_interp_named_p): Update.
3477 2018-05-25 Tom Tromey <tom@tromey.com>
3479 * interps.c (interp_name): Remove.
3480 * mi/mi-interp.c (mi_interp::init): Update.
3481 * interps.h (interp_name): Remove.
3482 (~scoped_restore_interp): Update.
3483 * tui/tui.c (tui_enable): Update.
3485 2018-05-25 Tom Tromey <tom@tromey.com>
3487 * utils.c (fputs_maybe_filtered): Update.
3488 * linespec.c (decode_line_full): Update.
3489 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
3490 (mi_print_breakpoint_for_event, mi_solib_loaded)
3491 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3492 (mi_user_selected_context_changed): Update.
3493 * mi/mi-main.c (mi_execute_command): Update.
3494 * cli/cli-script.c (execute_control_command): Update.
3495 * python/python.c (execute_gdb_command): Update.
3496 * solib.c (info_sharedlibrary_command): Update.
3497 * interps.c (interp_ui_out): Remove.
3498 * interps.h (interp_ui_out): Remove.
3500 2018-05-25 Tom Tromey <tom@tromey.com>
3502 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
3503 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
3504 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
3506 2018-05-25 Tom Tromey <tom@tromey.com>
3508 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
3509 * interps.c (interp_exec): Use scoped_restore.
3511 2018-05-25 Tom Tromey <tom@tromey.com>
3513 * remote.c (remote_target::remote_file_get): Use
3515 (remote_target::remote_file_put): Likewise.
3517 2018-05-25 Tom Tromey <tom@tromey.com>
3519 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
3521 (get_pe_section_index, add_pe_exported_sym): Update.
3522 (read_pe_exported_syms): Use gdb::def_vector.
3524 2018-05-25 Tom Tromey <tom@tromey.com>
3526 * frame.c (remove_prev_frame): Remove.
3527 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
3529 2018-05-25 Maciej W. Rozycki <macro@mips.com>
3531 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
3533 * mips-linux-nat.c (supply_fpregset): Always call
3534 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
3535 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
3536 `mips_fill_fpregset'.
3537 * mips-linux-tdep.c (mips_supply_fpregset)
3538 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
3539 (mips_fill_fpregset_wrapper): Remove functions.
3540 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
3541 (mips_linux_fpregset): Remove variable.
3542 (mips_linux_iterate_over_regset_sections): Use
3543 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
3544 (mips_linux_o32_sigframe_init): Remove comment.
3546 2018-05-25 Pedro Alves <palves@redhat.com>
3548 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
3549 (struct readahead_cache, struct packet_reg, struct
3550 remote_arch_state, class remote_state): Move higher up in the
3552 (remote_target::m_remote_state): Now an object instead of a pointer.
3553 (remote_target::get_remote_state): Adjust.
3555 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3557 * stack.c (select_and_print_frame): Delete.
3558 (struct function_bounds): Move struct within function.
3559 (func_command): Most content moved into new function
3560 find_frame_for_function, use new function, print result, add
3562 (find_frame_for_function): New function, now returns a result.
3564 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3566 * stack.c (iterate_over_block_arg_vars): Fix comment.
3567 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
3569 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3573 (scoped_restore_selected_frame::scoped_restore_selected_frame):
3575 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
3577 * frame.h (class scoped_restore_selected_frame): New class.
3578 * stack.c (print_frame_local_vars): Remove catching and rethrowing
3579 of any exception, use scoped_restore_selected_frame to restore the
3582 2018-05-24 Pedro Alves <palves@redhat.com>
3584 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
3587 2018-05-23 Tom Tromey <tom@tromey.com>
3589 * complaints.c (struct complaints): Remove.
3590 (symfile_complaint_book): Remove.
3591 (series): New global.
3592 (complaint_internal): Update.
3593 (clear_complaints): Update.
3595 2018-05-23 Tom Tromey <tom@tromey.com>
3597 * complaints.c (counters): New global.
3598 (struct complain): Remove.
3599 (struct complaints) <root>: Remove.
3600 (complaint_sentinel): Remove.
3601 (symfile_complaint_book): Update.
3602 (find_complaint) Remove.
3603 (complaint_internal, clear_complaints): Update.
3605 2018-05-23 Tom Tromey <tom@tromey.com>
3607 * complaints.c (struct complain) <file, line>: Remove.
3608 (find_complaint): Remove file, line parameters.
3609 (complaint_internal): Update.
3611 2018-05-23 Tom Tromey <tom@tromey.com>
3613 * complaints.c (vcomplaint): Remove.
3614 (complaint_internal) Merge in contents of vcomplaint.
3616 2018-05-23 Tom Tromey <tom@tromey.com>
3618 * complaints.c (struct complaints) <explanation>: Remove.
3619 (symfile_explanations): Remove.
3620 (symfile_complaint_book): Update.
3621 (vcomplaint): Update.
3622 (struct explanation): Remove.
3624 2018-05-23 Tom Tromey <tom@tromey.com>
3626 * complaints.c (symfile_complaints): Remove.
3627 (complaint_internal): Remove "complaints" parameter.
3628 (clear_complaints, vcomplaint): Remove "c" parameter.
3629 (get_complaints): Remove.
3630 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
3631 (dwarf2_debug_line_missing_file_complaint)
3632 (dwarf2_debug_line_missing_end_sequence_complaint)
3633 (dwarf2_complex_location_expr_complaint)
3634 (dwarf2_const_value_length_mismatch_complaint)
3635 (dwarf2_section_buffer_overflow_complaint)
3636 (dwarf2_macro_malformed_definition_complaint)
3637 (dwarf2_invalid_attrib_class_complaint)
3638 (create_addrmap_from_index, dw2_symtab_iter_next)
3639 (dw2_expand_marked_cus)
3640 (dw2_debug_names_iterator::find_vec_in_debug_names)
3641 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
3642 (create_debug_type_hash_table, init_cutu_and_read_dies)
3643 (partial_die_parent_scope, add_partial_enumeration)
3644 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
3645 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
3646 (read_import_statement, read_file_scope, create_dwo_cu_reader)
3647 (create_cus_hash_table, create_dwp_hash_table)
3648 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
3649 (dwarf2_rnglists_process, dwarf2_ranges_process)
3650 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
3651 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
3652 (handle_struct_member_die, process_structure_scope)
3653 (read_array_type, read_common_block, read_module_type)
3654 (read_tag_pointer_type, read_typedef, read_base_type)
3655 (read_subrange_type, load_partial_dies, partial_die_info::read)
3656 (partial_die_info::read, partial_die_info::read)
3657 (partial_die_info::read, read_checked_initial_length_and_offset)
3658 (dwarf2_string_attr, read_formatted_entries)
3659 (dwarf_decode_line_header)
3660 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3661 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
3662 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
3663 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3664 (get_signatured_type, get_DW_AT_signature_type)
3665 (decode_locdesc, file_file_name, consume_improper_spaces)
3666 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
3667 (dwarf_decode_macro_bytes, dwarf_decode_macros)
3668 (dwarf2_symbol_mark_computed, set_die_type)
3669 (read_attribute_value): Update.
3670 * stap-probe.c (handle_stap_probe, get_stap_base_address):
3672 * dbxread.c (unknown_symtype_complaint)
3673 (lbrac_mismatch_complaint, repeated_header_complaint)
3674 (set_namestring, function_outside_compilation_unit_complaint)
3675 (read_dbx_symtab, process_one_symbol): Update.
3676 * gdbtypes.c (stub_noname_complaint): Update.
3677 * windows-nat.c (handle_unload_dll): Update.
3678 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
3679 (decode_base_type): Update.
3680 * xcoffread.c (bf_notfound_complaint, ef_complaint)
3681 (eb_complaint, record_include_begin, record_include_end)
3682 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
3683 (process_xcoff_symbol, read_symbol)
3684 (function_outside_compilation_unit_complaint)
3685 (scan_xcoff_symtab): Update.
3686 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
3687 * buildsym.c (finish_block_internal, make_blockvector)
3688 (end_symtab_get_static_block, augment_type_symtab): Update.
3689 * dtrace-probe.c (dtrace_process_dof)
3690 (dtrace_static_probe_ops::get_probes): Update.
3691 * complaints.h (struct complaint): Don't declare.
3692 (symfile_complaints): Remove.
3693 (complaint_internal): Remove "complaints" parameter.
3694 (complaint): Likewise.
3695 (clear_complaints): Likewise.
3696 * symfile.c (syms_from_objfile_1, finish_new_objfile)
3697 (reread_symbols): Update.
3698 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
3699 (dwarf2_frame_cache, decode_frame_entry): Update.
3700 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
3701 * objc-lang.c (lookup_objc_class, lookup_child_selector)
3702 (info_selectors_command): Update.
3703 * macrotab.c (macro_include, check_for_redefinition)
3704 (macro_undef): Update.
3705 * objfiles.c (filter_overlapping_sections): Update.
3706 * stabsread.c (invalid_cpp_abbrev_complaint)
3707 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
3708 (define_symbol, error_type, read_type, rs6000_builtin_type)
3709 (stabs_method_name_from_physname, read_member_functions)
3710 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
3711 (attach_fields_to_type, complain_about_struct_wipeout)
3712 (read_range_type, read_args, common_block_start)
3713 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
3715 * mdebugread.c (index_complaint, unknown_ext_complaint)
3716 (basic_type_complaint, bad_tag_guess_complaint)
3717 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
3718 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
3719 (parse_procedure, parse_lines)
3720 (function_outside_compilation_unit_complaint)
3721 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
3722 (bad_tag_guess_complaint, reg_value_complaint): Update.
3723 * cp-support.c (demangled_name_complaint): Update.
3724 * macroscope.c (sal_macro_scope): Update.
3725 * dwarf-index-write.c (class debug_names): Update.
3727 2018-05-23 Tom Tromey <tom@tromey.com>
3729 * complaints.c (clear_complaints): Remove "noisy" parameter.
3730 * complaints.h (clear_complaints): Update.
3731 * symfile.c (syms_from_objfile_1, finish_new_objfile)
3732 (reread_symbols): Update.
3734 2018-05-23 Tom Tromey <tom@tromey.com>
3736 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
3738 (vcomplaint, clear_complaints): Update.
3739 (symfile_explanations): Remove some messages.
3741 2018-05-23 Tom Tromey <tom@tromey.com>
3743 * complaints.c (internal_complaint): Remove.
3744 * complaints.h (internal_complaint): Remove.
3746 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3748 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
3750 2018-05-22 Pedro Alves <palves@redhat.com>
3752 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
3753 (remote_fileio_badfd, remote_fileio_return_errno)
3754 (remote_fileio_return_success, remote_fileio_func_open)
3755 (remote_fileio_func_open, remote_fileio_func_close)
3756 (remote_fileio_func_read, remote_fileio_func_write)
3757 (remote_fileio_func_lseek, remote_fileio_func_rename)
3758 (remote_fileio_func_unlink, remote_fileio_func_stat)
3759 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
3760 (remote_fileio_func_isatty, remote_fileio_func_system): Add
3761 remote_target parameter.
3762 (remote_fio_func_map) <func>: Add remote_target parameter.
3763 (do_remote_fileio_request, remote_fileio_request):
3764 * remote-fileio.h (remote_fileio_request):
3765 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
3766 remote_target parameter.
3767 (remote_notif_process, handle_notification): Adjust to pass down
3769 (remote_notif_state_allocate): Add remote_target parameter. Save
3771 * remote-notif.h (struct remote_target): Forward declare.
3772 (struct notif_client) <parse, ack, can_get_pending_events>: Add
3773 remote_target parameter.
3774 (struct remote_notif_state) <remote>: New field.
3775 (remote_notif_ack, remote_notif_parse): Add remote_target
3777 (remote_notif_state_allocate, remote_notif_state_allocate): Add
3778 remote_target parameter.
3779 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
3780 (threads_listing_context, rmt_thread_action, protocol_feature)
3781 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
3782 (packet_result, struct threads_listing_context, remote_state):
3783 Move definitions and declarations higher up.
3784 (remote_target) <~remote_target>: Declare.
3785 (remote_download_command_source, remote_file_put, remote_file_get)
3786 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
3787 (remote_hostio_pread_vFile, remote_hostio_send_command)
3788 (remote_hostio_set_filesystem, remote_hostio_open)
3789 (remote_hostio_close, remote_hostio_unlink, remote_state)
3790 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
3791 (get_memory_write_packet_size, get_memory_read_packet_size)
3792 (append_pending_thread_resumptions, remote_detach_1)
3793 (append_resumption, remote_resume_with_vcont)
3794 (add_current_inferior_and_thread, wait_ns, wait_as)
3795 (process_stop_reply, remote_notice_new_inferior)
3796 (process_initial_stop_replies, remote_add_thread)
3797 (btrace_sync_conf, remote_btrace_maybe_reopen)
3798 (remove_new_fork_children, kill_new_fork_children)
3799 (discard_pending_stop_replies, stop_reply_queue_length)
3800 (check_pending_events_prevent_wildcard_vcont)
3801 (discard_pending_stop_replies_in_queue, stop_reply)
3802 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
3803 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
3804 (remote_interrupt_as, remote_interrupt_ns)
3805 (remote_get_noisy_reply, remote_query_attached)
3806 (remote_add_inferior, remote_current_thread, get_current_thread)
3807 (set_thread, set_general_thread, set_continue_thread)
3808 (set_general_process, write_ptid)
3809 (remote_unpack_thread_info_response, remote_get_threadinfo)
3810 (parse_threadlist_response, remote_get_threadlist)
3811 (remote_threadlist_iterator, remote_get_threads_with_ql)
3812 (remote_get_threads_with_qxfer)
3813 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
3814 (get_offsets, remote_check_symbols, remote_supported_packet)
3815 (remote_query_supported, remote_packet_size)
3816 (remote_serial_quit_handler, remote_detach_pid)
3817 (remote_vcont_probe, remote_resume_with_hc)
3818 (send_interrupt_sequence, interrupt_query)
3819 (remote_notif_get_pending_events, fetch_register_using_p)
3820 (send_g_packet, process_g_packet, fetch_registers_using_g)
3821 (store_register_using_P, store_registers_using_G)
3822 (set_remote_traceframe, check_binary_download)
3823 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
3824 (remote_xfer_live_readonly_partial, remote_read_bytes)
3825 (remote_send_printf, remote_flash_write, readchar)
3826 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
3827 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
3828 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
3829 (extended_remote_disable_randomization, extended_remote_run)
3830 (send_environment_packet, extended_remote_environment_support)
3831 (extended_remote_set_inferior_cwd, remote_write_qxfer)
3832 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
3833 (packet_command): Now methods of ...
3834 (remote_target): ... this class.
3835 (m_remote_state) <remote_target>: New field.
3836 (struct remote_state) <stop_reply_queue,
3837 remote_async_inferior_event_token, wait_forever_enabled_p>: New
3839 (remote_state::remote_state): Allocate stop_reply_queue.
3840 (remote_state): Delete global.
3841 (get_remote_state_raw): Delete.
3842 (remote_target::get_remote_state): Allocate m_remote_state on
3844 (get_current_remote_target): New.
3845 (remote_ops, extended_remote_ops): Delete.
3846 (wait_forever_enabled_p, remote_async_inferior_event_token):
3847 Delete, moved to struct remote_state.
3848 (remote_target::close): Delete self. Destruction bits split to
3850 (remote_target::~remote_target): ... this.
3851 (show_memory_packet_size): Adjust to use
3852 get_current_remote_target.
3853 (struct protocol_feature) <func>: Add remote_target parameter.
3854 All callers adjusted.
3855 (curr_quit_handler_target): New.
3856 (remote_serial_quit_handler): Reimplement.
3857 (remote_target::open_1): Adjust to use get_current_remote_target.
3858 Heap-allocate remote_target/extended_remote_target instances.
3859 (vcont_builder::vcont_builder): Add remote_target parameter, and
3860 save it in m_remote. All callers adjusted.
3861 (vcont_builder::m_remote): New field.
3862 (vcont_builder::restart, vcont_builder::flush)
3863 (vcont_builder::push_action): Use it.
3864 (remote_target::commit_resume): Use it.
3865 (struct queue_iter_param) <remote>: New field.
3866 (remote_target::remove_new_fork_children): Fill in 'remote' field.
3867 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
3868 (check_pending_event_prevents_wildcard_vcont_callback)
3869 (remote_target::check_pending_events_prevent_wildcard_vcont)
3870 (remote_target::discard_pending_stop_replies)
3871 (remote_target::discard_pending_stop_replies_in_queue)
3872 (remote_target::remote_notif_remove_queued_reply): Fill in
3874 (remote_notif_get_pending_events): New.
3875 (remote_target::readchar, remote_target::remote_serial_write):
3876 Save/restore curr_quit_handler_target.
3878 (kill_new_fork_children): Fill in 'remote' field.
3879 (packet_command): Use get_current_remote_target, defer to
3880 remote_target method of same name.
3881 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
3882 parameter, and save it in m_remote. All callers adjusted.
3883 (scoped_remote_fd::release): Use m_remote.
3884 (scoped_remote_fd::m_remote): New field.
3885 (remote_file_put, remote_file_get, remote_file_delete): Use
3886 get_current_remote_target, defer to remote_target method of same
3888 (remote_btrace_reset): Add remote_state paremeter. Update all
3890 (remote_async_inferior_event_handler). Pass down 'data'.
3891 (remote_new_objfile): Use get_current_remote_target.
3892 (remote_target::vcont_r_supported): New.
3893 (set_range_stepping): Use get_current_remote_target and
3894 remote_target::vcont_r_supported.
3895 (_initialize_remote): Don't allocate 'remote_state' and
3896 'stop_reply_queue' globals.
3897 * remote.h (struct remote_target): Forward declare.
3898 (getpkt, putpkt, remote_notif_get_pending_events): Add
3899 'remote_target' parameter.
3901 2018-05-22 Pedro Alves <palves@redhat.com>
3903 * remote.c (vcont_builder): Now a class. Make all data members
3905 (vcont_builder) <vcont_builder, restart, flush, push_action>:
3907 (vcont_builder_restart): Rename to ...
3908 (vcont_builder::restart): ... this.
3909 (vcont_builder_flush): Rename to ...
3910 (vcont_builder::flush): ... this.
3911 (vcont_builder_push_action): Rename to ...
3912 (vcont_builder::push_action): ... this.
3913 (remote_target::commit_resume): Adjust.
3915 2018-05-22 Pedro Alves <palves@redhat.com>
3917 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
3918 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
3919 (get_fixed_memory_packet_size): New.
3920 (get_memory_packet_size): Use it.
3921 (set_memory_packet_size): Don't override the config size with
3922 DEFAULT_MAX_MEMORY_PACKET_SIZE.
3923 (show_memory_packet_size): Use get_fixed_memory_packet_size.
3924 Don't refer to get_memory_packet_size if not connected to a remote
3925 target. Show "(default)" if configured size is 0.
3927 2018-05-22 Pedro Alves <palves@redhat.com>
3929 * remote.c (remote_target::mourn_inferior): Move
3930 discard_pending_stop_replies call here from ...
3931 (_initialize_remote): ... here.
3933 2018-05-22 Pedro Alves <palves@redhat.com>
3935 * remote.c (compare_section_command): Remove set_general_process
3938 2018-05-22 Pedro Alves <palves@redhat.com>
3940 * remote.c (struct packet_reg, struct remote_arch_state):
3941 Move higher up in the file.
3942 (remote_state) <m_arch_states>: Store remote_arch_state values
3943 instead of remote_arch_state pointers.
3944 (remote_state::get_remote_arch_state): Adjust.
3946 2018-05-22 Pedro Alves <palves@redhat.com>
3948 * remote.c: Include <unordered_map>.
3949 (remote_state): Now a class.
3950 (remote_state) <get_remote_arch_state>: Declare method.
3951 <get_remote_arch_state>: New field.
3952 (remote_arch_state) <remote_arch_state>: Declare ctor.
3953 <regs>: Now a unique_ptr.
3954 (remote_gdbarch_data_handle): Delete.
3955 (get_remote_arch_state): Delete.
3956 (remote_state::get_remote_arch_state): New.
3957 (get_remote_state): Adjust to call remote_state's
3958 get_remote_arch_state method.
3959 (init_remote_state): Delete, bits factored out to ...
3960 (remote_arch_state::remote_arch_state): ... this new method.
3961 (get_remote_packet_size, get_memory_packet_size)
3962 (process_g_packet, remote_target::fetch_registers)
3963 (remote_target::prepare_to_store, store_registers_using_G)
3964 (remote_target::store_registers, remote_target::get_trace_status):
3965 Adjust to call remote_state's method.
3966 (_initialize_remote): Remove reference to
3967 remote_gdbarch_data_handle.
3969 2018-05-22 Pedro Alves <palves@redhat.com>
3971 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
3972 pread>: New method declarations.
3973 (remote_target::open_1): Adjust.
3974 (readahead_cache_invalidate): Rename to ...
3975 (readahead_cache::invalidate): ... this, and adjust to be a class
3977 (readahead_cache_invalidate_fd): Rename to ...
3978 (readahead_cache::invalidate_fd): ... this, and adjust to be a
3980 (remote_hostio_pwrite): Adjust.
3981 (remote_hostio_pread_from_cache): Rename to ...
3982 (readahead_cache::pread): ... this, and adjust to be a class
3984 (remote_hostio_close): Adjust.
3986 2018-05-22 Pedro Alves <palves@redhat.com>
3988 * remote.c (remote_hostio_close_cleanup): Delete.
3989 (class scoped_remote_fd): New.
3990 (remote_file_put, remote_file_get): Use it.
3992 2018-05-22 Pedro Alves <palves@redhat.com>
3994 (struct vCont_action_support): Use bool and initialize all fields.
3995 (struct readahead_cache): Initialize all fields.
3996 (remote_state): Use bool and initialize all fields.
3997 (remote_state::remote_state, remote_state::~remote_state): New.
3998 (new_remote_state): Delete.
3999 (_initialize_remote): Use new to allocate remote_state.
4001 2018-05-22 Pedro Alves <palves@redhat.com>
4005 * c-exp.y: Include "c-support.h".
4006 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
4007 of tolower. Use c_ident_is_alpha to scan names.
4008 * c-lang.c: Include "c-support.h".
4009 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
4010 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
4011 * c-support.h: New file, with bits factored out from ...
4012 * cp-name-parser.y: ... this file.
4013 Include "c-support.h".
4014 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
4015 c-support.h and renamed.
4016 (symbol_end, yylex): Adjust.
4018 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4020 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
4021 parameter type to CORE_ADDR.
4022 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
4023 parameter type in declaration to CORE_ADDR.
4024 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
4025 target_auxv_search to get AT_HWCAP and use the result to get the
4027 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
4028 to CORE_ADDR. Remove the cast of the return value to unsigned
4029 long. Fix error predicate of target_auxv_search.
4030 (ppc_linux_nat_target::read_description): Change the type of the
4031 hwcap variable to CORE_ADDR.
4033 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4035 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
4036 if the size of fpscr is larger than 32 bits.
4038 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4040 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
4041 (ppc32_linux_vsxregmap): New global.
4042 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
4043 regcache_supply_regset, and regcache_collect_regset.
4044 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
4045 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
4046 (fetch_vsx_register, store_vsx_register): Remove.
4047 (fetch_vsx_registers): Add regno parameter. Get regset using
4048 ppc_linux_vsxregset. Use regset to supply registers.
4049 (store_vsx_registers): Add regno parameter. Get regset using
4050 ppc_linux_vsxregset. Use regset to collect registers.
4051 (fetch_register): Call fetch_vsx_registers instead of
4053 (store_register): Call store_vsx_registers instead of
4055 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
4056 new regno parameter.
4057 (store_ppc_registers): Call store_vsx_registers with -1 for the
4058 new regno parameter.
4059 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
4060 (ppc_collect_vsxregset): Remove.
4062 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4064 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
4066 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
4067 for vector register offset fields.
4068 (ppc64_fbsd_reg_offsets): Likewise.
4069 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4070 to vector register offset fields.
4071 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4072 to vector register offset fields.
4073 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
4074 vector register offset fields.
4075 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
4076 initializers for vector register offset fields.
4077 (rs6000_aix64_reg_offsets): Likewise.
4078 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
4079 (ppc_supply_vrregset): Remove.
4080 (ppc_collect_vrregset): Remove.
4081 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
4082 (ppc_linux_vrregset) : New function.
4083 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
4084 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
4085 (ppc32_linux_vrregset): Remove.
4086 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
4087 and use result instead of ppc32_linux_vrregset.
4088 (ppc32_linux_reg_offsets): Remove initializers for vector register
4090 (ppc64_linux_reg_offsets): Likewise.
4091 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
4092 * ppc-linux-nat.c: Include regset.h.
4093 (gdb_vrregset_t): Adjust comment to account for little-endian
4095 (supply_vrregset, fill_vrregset): Remove.
4096 (fetch_altivec_register, store_altivec_register): Remove.
4097 (fetch_altivec_registers): Add regno parameter. Get regset using
4098 ppc_linux_vrregset. Use regset to supply registers.
4099 (store_altivec_registers): Add regno parameter. Get regset using
4100 ppc_linux_vrregset. Use regset to collect registers.
4101 (fetch_register): Call fetch_altivec_registers instead of
4102 fetch_altivec_register.
4103 (store_register): Call store_altivec_registers instead of
4104 store_altivec_register.
4105 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
4106 the new regno parameter.
4107 (store_ppc_registers): Call store_altivec_registers with -1 for
4108 the new regno parameter.
4110 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4112 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
4113 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
4114 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4115 (gdb_vrregset_t): Change array type size to
4116 PPC_LINUX_SIZEOF_VRREGSET.
4117 (gdb_vsxregset_t): Change array type size to
4118 PPC_LINUX_SIZEOF_VSXREGSET.
4119 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
4120 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
4121 PPC_LINUX_SIZEOF_VSXREGSET.
4123 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4125 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
4126 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
4128 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
4129 ppc_linux_target_wordsize with tid.
4130 (ppc_linux_nat_target::read_description): Call ppc_linux_target
4132 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
4133 (ppc64_64bit_inferior_p): Add static and inline specifiers.
4134 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
4135 tid parameter. Remove static specifier.
4136 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
4137 (ppc_linux_target_wordsize): New declaration.
4139 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4141 * arch/ppc-linux-common.c: New file.
4142 * arch/ppc-linux-common.h: New file.
4143 * arch/ppc-linux-tdesc.h: New file.
4144 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
4145 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
4146 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
4147 arch/ppc-linux-tdesc.h.
4148 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
4149 arch/ppc-linux-tdesc.h.
4150 (ppc_linux_nat_target::read_description): Remove target
4151 description matching code. Fill a ppc_linux_features struct and
4152 call ppc_linux_match_description with it. Move comment about ISA
4153 2.05 to ppc-linux-common.c.
4154 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
4155 arch/ppc-linux-tdesc.h.
4156 (ppc_linux_core_read_description): Remove target description
4157 matching code. Fill a ppc_linux_features struct and call
4158 ppc_linux_match_description with it.
4159 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4160 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4161 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4162 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4163 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4164 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4165 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4166 (tdesc_powerpc_e500l): Remove.
4168 2018-05-22 Joel Brobecker <brobecker@adacore.com>
4170 * ada-lang.c (catch_assert_command): Pass empty string instead
4171 of NULL for excep_string argument.
4173 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4175 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
4176 the width of the requested register exceeds the width of the
4179 2018-05-21 Tom Tromey <tom@tromey.com>
4181 * printcmd.c (output_command): Remove.
4182 (output_command_const): Rename to output_command.
4183 * valprint.h (output_command): Rename from output_command_const.
4184 * tracepoint.c (trace_dump_actions): Call output_command.
4186 2018-05-21 Tom Tromey <tom@tromey.com>
4188 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
4189 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
4190 * ada-lang.h (create_ada_exception_catchpoint): Update.
4191 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
4193 (create_excep_cond_exprs, ~ada_catchpoint)
4194 (should_stop_exception, print_one_exception)
4195 (print_mention_exception, print_recreate_exception): Update.
4196 (ada_get_next_arg): Remove.
4197 (catch_ada_exception_command_split): Use std::string. Change type
4198 of "excep_string", "cond_string".
4199 (catch_ada_exception_command): Update.
4200 (create_ada_exception_catchpoint): Change type of excep_string.
4201 (ada_exception_sal): Remove excep_string parameter.
4202 (~ada_catchpoint): Remove.
4204 2018-05-21 Tom Tromey <tom@tromey.com>
4206 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
4209 2018-05-21 Tom Tromey <tom@tromey.com>
4211 * ada-lang.c (ada_exception_message_1, ada_exception_message):
4212 Return unique_xmalloc_ptr.
4213 (print_it_exception): Update.
4215 2018-05-21 Tom Tromey <tom@tromey.com>
4217 * tracepoint.c (trace_dump_actions): Use std::string.
4219 2018-05-21 Tom Tromey <tom@tromey.com>
4221 * symfile.c (reread_symbols): Use std::string for original_name.
4223 2018-05-21 Tom Tromey <tom@tromey.com>
4225 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
4226 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
4229 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
4231 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
4233 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
4234 * objfiles.c (get_objfile_bfd_data): Allocate
4235 objfile_per_bfd_storage with obstack_new when allocating on
4238 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4240 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
4242 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
4243 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
4244 * mdebugread.c (mdebug_build_psymtabs): Likewise.
4245 (add_pending): Likewise.
4246 (parse_symbol): Likewise.
4247 (parse_partial_symbols): Likewise.
4248 (psymtab_to_symtab_1): Likewise.
4249 (new_psymtab): Likewise.
4250 (elfmdebug_build_psymtabs): Likewise.
4251 * minsyms.c (terminate_minimal_symbol_table): Likewise.
4252 * objfiles.c (get_objfile_bfd_data): Likewise.
4253 (objfile_register_static_link): Likewise.
4254 * psymtab.c (allocate_psymtab): Likewise.
4255 * stabsread.c (read_member_functions): Likewise.
4256 * xcoffread.c (xcoff_end_psymtab): Likewise.
4258 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4260 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
4261 compiler supports std::is_trivially_constructible.
4262 * common/poison.h: Include obstack.h.
4263 (IsMallocable): Define to is_trivially_constructible if the
4264 compiler supports it, define to true_type otherwise.
4268 (XOBNEWVEC): Redefine.
4269 * gdb_obstack.h (obstack_zalloc): New.
4270 (OBSTACK_ZALLOC): Redefine.
4271 (obstack_calloc): New.
4272 (OBSTACK_CALLOC): Redefine.
4274 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
4275 (gdbarch_obstack): New declaration in gdbarch.h, definition in
4277 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
4278 obstack_calloc/obstack_zalloc.
4279 (gdbarch_obstack_zalloc): Remove.
4280 * target-descriptions.c (tdesc_data_init): Use obstack_new.
4282 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4284 * stack.c (backtrace_command_1): Remove useless variable int i.
4286 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4288 * stack.c (print_frame_info): Fix comment.
4290 2018-05-18 Tom Tromey <tom@tromey.com>
4292 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
4293 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
4294 (~dwarf2_per_objfile): Update
4295 (dwarf2_get_dwz_file): Use new.
4296 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
4299 2018-05-18 Tom Tromey <tom@tromey.com>
4301 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
4303 * dwarf2read.c (struct dwp_file): Add constructor and
4305 (open_and_init_dwp_file): Return a unique_ptr.
4306 (dwarf2_per_objfile, create_dwp_hash_table)
4307 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
4308 (lookup_dwo_unit_in_dwp): Update.
4309 (open_and_init_dwp_file, get_dwp_file): Update.
4311 2018-05-18 Tom Tromey <tom@tromey.com>
4313 * dwarf2read.c (dwarf2_per_objfile): Update.
4314 (struct mapped_index): Add initializers.
4315 (dwarf2_read_index): Use new.
4316 (dw2_symtab_iter_init): Update.
4317 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
4320 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4322 * dwarf2read.c (mapped_index) <total_size>: Remove.
4324 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4326 * unittests/format_pieces-selftests.c (test_format_specifier):
4329 2018-05-18 Tom Tromey <tom@tromey.com>
4331 * c-typeprint.c (maybe_print_hole): New function.
4332 (c_print_type_struct_field_offset): Update.
4333 (c_type_print_base_struct_union): Call maybe_print_hole.
4335 2018-05-17 Keith Seitz <keiths@redhat.com>
4337 * breakpoint.c (build_bpstat_chain): New function, moved from
4339 (bpstat_stop_status): Add optional parameter, `stop_chain'.
4340 If no stop chain is passed, call build_bpstat_chain to build it.
4341 * breakpoint.h (build_bpstat_chain): Declare.
4342 (bpstat_stop_status): Move documentation here from breakpoint.c.
4343 * infrun.c (handle_signal_stop): Before eliding inlined frames,
4344 build the stop chain and pass it to skip_inline_frames.
4345 Pass this stop chain to bpstat_stop_status.
4346 * inline-frame.c: Include breakpoint.h.
4347 (stopped_by_user_bp_inline_frame): New function.
4348 (skip_inline_frames): Add parameter `stop_chain'.
4349 Move documention to inline-frame.h.
4350 If non-NULL, use stopped_by_user_bp_inline_frame to determine
4351 whether the frame should be elided.
4352 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
4353 Add moved documentation and update for new parameter.
4355 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4358 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4359 unittests/format_pieces-selftests.c.
4360 * common/format.h (format_piece) <operator==>: New.
4361 (format_pieces) <operator[]>: Remove.
4362 * common/format.c (format_pieces::format_pieces): Handle \e.
4363 * unittests/format_pieces-selftests.c: New.
4365 2018-05-17 Tom Tromey <tom@tromey.com>
4368 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
4369 (dw2_instantiate_symtab): Add skip_partial parameter.
4370 (dw2_find_last_source_symtab, dw2_map_expand_apply)
4371 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
4372 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
4373 (dw2_expand_symtabs_matching_one)
4374 (dw2_find_pc_sect_compunit_symtab)
4375 (dw2_debug_names_lookup_symbol)
4376 (dw2_debug_names_expand_symtabs_for_function): Update.
4377 (init_cutu_and_read_dies): Add skip_partial parameter.
4378 (process_psymtab_comp_unit, build_type_psymtabs_1)
4379 (process_skeletonless_type_unit, load_partial_comp_unit)
4380 (psymtab_to_symtab_1): Update.
4381 (load_full_comp_unit): Add skip_partial parameter.
4382 (process_imported_unit_die, dwarf2_read_addr_index)
4383 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
4384 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
4385 (read_signatured_type): Update.
4387 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4389 * value.c (release_value): Remove unused variable.
4390 (record_latest_value): Likewise.
4391 (access_value_history): Likewise.
4392 (preserve_values): Likewise.
4394 2018-05-17 Tom Tromey <tom@tromey.com>
4396 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
4399 2018-05-16 Maciej W. Rozycki <macro@mips.com>
4402 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
4403 Also handle registers whose width is not a multiple of
4405 (linux_nat_trad_target::store_register): Likewise.
4407 2018-05-16 Tom Tromey <tom@tromey.com>
4409 * gdbcore.h (core_bfd): Redefine.
4410 * corelow.c (core_target::close): Update.
4411 (core_target_open): Update.
4412 * progspace.h (struct program_space) <cbfd>: Now a
4415 2018-05-16 Tom Tromey <tom@tromey.com>
4418 * symfile-add-flags.h (enum symfile_add_flags)
4419 <SYMFILE_NOT_FILENAME>: New constant.
4420 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
4421 objfile name from BFD.
4422 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
4423 * minidebug.c (find_separate_debug_file_in_section): Put
4424 ".gnu_debugdata" into BFD's file name.
4426 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
4428 * regcache.c (regcache_read_ftype, regcache_write_ftype):
4431 2018-05-15 Tamar Christina <tamar.christina@arm.com>
4434 * aarch64-tdep.c (aarch64_analyze_prologue,
4435 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
4436 Indicate not interested in errors.
4438 2018-05-15 Maciej W. Rozycki <macro@mips.com>
4440 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
4441 Supply the MIPS_ZERO_REGNUM register.
4443 2018-05-15 Maciej W. Rozycki <macro@mips.com>
4445 * mips-tdep.c (mask_address_var): Make variable static.
4447 2018-05-14 Tom Tromey <tom@tromey.com>
4449 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
4451 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
4453 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
4454 FXSAVE_ADDR for the mxcsr register.
4456 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
4458 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
4460 2018-05-11 Pedro Alves <palves@redhat.com>
4462 * corelow.c (core_target) <core_target>: No longer inline.
4463 Initialize m_core_gdbarch, m_core_vec and build the section table
4465 <~core_target>: New.
4466 <core_gdbarch, get_core_register_section>: New methods.
4467 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
4468 factored out from ...
4469 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
4471 (sniff_core_bfd): Add gdbarch parameter.
4472 (core_close): Delete, merged into ...
4473 (core_target::close): ... here. Delete self.
4474 (core_close_cleanup): Delete.
4475 (core_target_open): Allocate a core_target on the heap. Use a
4476 unique_ptr instead of a cleanup. Bits moved into the core_target
4477 ctor. Adjust to use core_target methods instead of globals.
4478 (get_core_register_section): Rename to ...
4479 (core_target::get_core_register_section): ... this and adjust.
4480 (struct get_core_registers_cb_data): New.
4481 (get_core_registers_cb): Use it. Use bool.
4482 (core_target::fetch_registers, core_target::files_info)
4483 (core_target::xfer_partial, core_target::read_description)
4484 (core_target::pid_to, core_target::thread_name): Adjust to
4485 reference class fields instead of globals.
4486 * target.h (struct target_ops_deleter, target_ops_up): New.
4488 2018-05-11 Pedro Alves <palves@redhat.com>
4490 * corefile.c (core_file_command): Move to corelow.c.
4491 * corelow.c (the_core_target): Delete.
4492 (core_file_command): Moved from corefile.c. Check exec_bfd
4493 instead of the_core_target. Use target_detach instead of calling
4494 into the_core_target directly.
4495 (maybe_say_no_core_file_now): New.
4496 (core_target::detach): Use it.
4497 (_initialize_corelow): Remove references to the_core_target.
4498 * gdbcore.h (the_core_target): Delete.
4500 2018-05-11 Tom Tromey <tromey@redhat.com>
4501 Pedro Alves <palves@redhat.com>
4503 * corefile.c (core_bfd): Remove.
4504 * gdbcore.h (core_bfd): Now a macro.
4505 * progspace.h (struct program_space) <cbfd>: New field.
4507 2018-05-11 Tom Tromey <tom@tromey.com>
4509 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
4512 2018-05-10 Tom Tromey <tom@tromey.com>
4514 * configure: Rebuild.
4515 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
4517 2018-05-10 Joel Brobecker <brobecker@adacore.com>
4520 * regformats/regdat.sh: Adjust script, following the addition
4521 of the new expedite_regs parameter to init_target_desc.
4523 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
4526 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
4527 set_gdbarch_significant_addr_bit.
4528 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
4529 set_gdbarch_significant_addr_bit.
4530 * utils.c (address_significant): Update to sign extend addr.
4532 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
4534 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
4535 (xtensa_linux_init_abi): Limit tdep->num_regs by
4536 tdep->num_nopriv_regs.
4537 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
4538 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
4541 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
4543 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
4545 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
4547 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
4548 (I387_MXCSR_INIT_VAL): New constant.
4549 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
4550 buffer if it was supplied by the inferior.
4551 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
4552 (i387_xsave_get_clear_bv): New function.
4553 (i387_supply_xsave): Only read x87 control registers from the
4554 xsave buffer if the feature is enabled, and the state will have
4555 been written, otherwise, provide a suitable default.
4556 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
4557 including x87 control registers. Update control registers if they
4558 have changed from the default value, and mark features as enabled
4560 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
4562 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
4564 * spu-tdep.c (info_spu_event_command): Fix output formatting.
4566 2018-05-07 Tom Tromey <tom@tromey.com>
4568 * configure: Rebuild.
4569 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
4571 2018-05-07 Tom Tromey <tom@tromey.com>
4574 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
4575 bit. Use correct value for VDIV.
4577 2018-05-04 Tom Tromey <tom@tromey.com>
4579 * configure: Rebuild.
4580 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
4582 2018-05-04 Tom Tromey <tom@tromey.com>
4584 * linux-record.c (record_linux_system_call) <case
4585 RECORD_SYS_RECVFROM>: Add "break".
4587 2018-05-04 Tom Tromey <tom@tromey.com>
4589 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
4590 Add missing "break".
4591 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
4592 Add missing "break".
4594 2018-05-04 Tom Tromey <tom@tromey.com>
4596 * rs6000-tdep.c (ppc_process_record_op4)
4597 (ppc_process_record_op63): Add fall-through comment.
4599 2018-05-04 Tom Tromey <tom@tromey.com>
4601 * i386-tdep.c (i386_process_record): Add fall-through comment.
4603 2018-05-04 Tom Tromey <tom@tromey.com>
4605 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
4608 2018-05-04 Tom Tromey <tom@tromey.com>
4610 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
4611 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
4612 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
4614 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
4616 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
4619 2018-05-04 Tom Tromey <tom@tromey.com>
4621 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
4623 2018-05-04 Tom Tromey <tom@tromey.com>
4625 * s390-tdep.c (s390_process_record): Fix fall-through comments.
4626 * xcoffread.c (scan_xcoff_symtab): Move comment later.
4627 * symfile.c (section_is_mapped): Fix fall-through comment.
4628 * stabsread.c (define_symbol, read_member_functions): Fix
4629 fall-through comment.
4630 * s390-linux-tdep.c (s390_process_record): Fix fall-through
4632 * remote.c (remote_wait_as): Fix fall-through comment.
4633 * p-exp.y (yylex): Fix fall-through comment.
4634 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
4636 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
4637 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
4638 * jv-exp.y (yylex): Fix fall-through comment.
4639 * go-exp.y (lex_one_token): Fix fall-through comment.
4640 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
4641 fall-through comment.
4642 * f-exp.y (yylex): Fix fall-through comment.
4643 * dwarf2read.c (process_die): Fix fall-through comments.
4644 * dbxread.c (process_one_symbol): Fix fall-through comment.
4645 * d-exp.y (lex_one_token): Fix fall-through comment.
4646 * cp-name-parser.y (yylex): Fix fall-through comment.
4647 * coffread.c (coff_symtab_read): Fix fall-through comment.
4648 * c-exp.y (lex_one_token): Fix fall-through comment.
4649 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
4651 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
4654 2018-05-04 Tom Tromey <tom@tromey.com>
4657 * NEWS: Mention gdb.execute change.
4658 * gdbcmd.h (execute_control_command): Don't declare.
4659 * python/python.c (execute_gdb_command): Use read_command_lines_1,
4660 execute_control_commands, execute_control_commands_to_string.
4661 * cli/cli-script.h (execute_control_commands)
4662 (execute_control_commands_to_string): Declare.
4663 (execute_control_command): Add from_tty parameter.
4664 * cli/cli-script.c (execute_control_commands)
4665 (execute_control_commands_to_string): New functions.
4666 (execute_user_command): Use execute_control_commands.
4667 (execute_control_command_1): Add "from_tty" parameter. Update.
4668 (execute_control_command): Likewise.
4670 2018-05-04 Tom Tromey <tom@tromey.com>
4673 * NEWS: Mention that breakpoint commands are writable.
4674 * python/py-breakpoint.c (bppy_set_commands): New function.
4675 (breakpoint_object_getset) <"commands">: Use it.
4677 2018-05-04 Tom Tromey <tom@tromey.com>
4679 * tracepoint.c (actions_command): Update.
4680 * mi/mi-cmd-break.c (mi_command_line_array)
4681 (mi_command_line_array_cnt, mi_command_line_array_ptr)
4682 (mi_read_next_line): Remove.
4683 (mi_cmd_break_commands): Update.
4684 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
4686 * cli/cli-script.c (get_command_line): Update.
4687 (process_next_line): Use function_view. Constify.
4688 (recurse_read_control_structure, read_command_lines)
4689 (read_command_lines_1): Change argument types to function_view.
4690 (do_define_command, document_command): Update.
4691 * breakpoint.h (check_tracepoint_command): Don't declare.
4692 * breakpoint.c (check_tracepoint_command): Remove.
4693 (commands_command_1, create_tracepoint_from_upload): Update.
4695 2018-05-04 Tom Tromey <tom@tromey.com>
4698 * cli/cli-script.h (enum command_control_type) <define_control>:
4700 * cli/cli-script.c (multi_line_command_p): Handle define_control.
4701 (build_command_line, execute_control_command_1)
4702 (process_next_line): Likewise.
4703 (do_define_command): New function, extracted from define_command.
4704 (define_command): Use it.
4706 2018-05-04 Tom Tromey <tom@tromey.com>
4708 * tracepoint.c (actions_command): Update.
4709 * cli/cli-script.h (read_command_lines): Update.
4710 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
4711 (MAX_TMPBUF): Remove define.
4712 (define_command): Use string_printf.
4713 (document_command): Likewise.
4714 * breakpoint.c (commands_command_1): Update.
4716 2018-05-04 Tom Tromey <tom@tromey.com>
4718 * top.c (execute_command): Update.
4719 * cli/cli-script.h (print_command_lines): Now varargs.
4720 * cli/cli-script.c (print_command_lines): Now varargs.
4721 (execute_control_command_1) <case while_control, case if_control>:
4724 2018-05-04 Tom Tromey <tom@tromey.com>
4726 * tracepoint.c (all_tracepoint_actions): Rename from
4727 all_tracepoint_actions_and_cleanup. Change return type.
4728 (actions_command, encode_actions_1, encode_actions)
4729 (trace_dump_actions, tdump_command): Update.
4730 * remote.c (remote_download_command_source): Update.
4731 * python/python.c (gdbpy_eval_from_control_command)
4732 (python_command, python_interactive_command): Update.
4733 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
4734 * guile/guile.c (guile_command)
4735 (gdbscm_eval_from_control_command, guile_command): Update.
4736 * compile/compile.c (compile_code_command)
4737 (compile_print_command, compile_to_object): Update.
4738 * cli/cli-script.h (struct command_lines_deleter): New.
4739 (counted_command_line): New typedef.
4740 (struct command_line): Add constructor, destructor.
4741 <body_list>: Remove.
4742 <body_list_0, body_list_1>: New members.
4743 (command_line_up): Remove typedef.
4744 (read_command_lines, read_command_lines_1, get_command_line):
4746 (copy_command_lines): Don't declare.
4747 * cli/cli-script.c (build_command_line): Use "new".
4748 (get_command_line): Return counted_command_line.
4749 (print_command_lines, execute_user_command)
4750 (execute_control_command_1, while_command, if_command): Update.
4751 (realloc_body_list): Remove.
4752 (process_next_line, recurse_read_control_structure): Update.
4753 (read_command_lines, read_command_lines_1): Return counted_command_line.
4754 (free_command_lines): Use "delete".
4755 (copy_command_lines): Remove.
4756 (define_command, document_command, show_user_1): Update.
4757 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
4758 a counted_command_line.
4759 * breakpoint.h (counted_command_line): Remove typedef.
4760 (breakpoint_set_commands): Update.
4761 * breakpoint.c (check_no_tracepoint_commands)
4762 (validate_commands_for_breakpoint): Update.
4763 (breakpoint_set_commands): Change commands to be a
4764 counted_command_line.
4765 (commands_command_1, update_dprintf_command_list)
4766 (create_tracepoint_from_upload): Update.
4768 2018-05-04 Tom Tromey <tom@tromey.com>
4770 * cli/cli-decode.h (cmd_list_element): New constructor.
4771 (~cmd_list_element): New destructor.
4772 (struct cmd_list_element): Add initializers.
4773 * cli/cli-decode.c (do_add_cmd): Use "new".
4774 (delete_cmd): Use "delete".
4776 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
4777 Pedro Alves <palves@redhat.com>
4779 PR breakpoints/19806 and support for PR external/20207.
4780 * NEWS: Mention Aarch64 watchpoint improvements.
4781 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
4782 watchpoints and PR external/20207 watchpoints.
4783 * nat/aarch64-linux-hw-point.c
4784 (kernel_supports_any_contiguous_range): New.
4785 (aarch64_watchpoint_offset): New.
4786 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
4787 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
4788 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
4789 (aarch64_align_watchpoint): New parameters aligned_offset_p and
4790 next_addr_orig_p. Support PR external/20207 watchpoints.
4791 (aarch64_downgrade_regs): New.
4792 (aarch64_dr_state_insert_one_point): New parameters offset and
4794 (aarch64_dr_state_remove_one_point): Likewise.
4795 (aarch64_handle_breakpoint): Update caller.
4796 (aarch64_handle_aligned_watchpoint): Likewise.
4797 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
4799 (aarch64_linux_set_debug_regs): Remove const from state. Call
4800 aarch64_downgrade_regs.
4801 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
4802 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
4803 (DR_CONTROL_MASK): ... this.
4804 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
4805 (unsigned int aarch64_watchpoint_offset): New prototype.
4806 (aarch64_linux_set_debug_regs): Remove const from state.
4807 * utils.c (align_up, align_down): Move to ...
4808 * common/common-utils.c (align_up, align_down): ... here.
4809 * utils.h (align_up, align_down): Move to ...
4810 * common/common-utils.h (align_up, align_down): ... here.
4812 2018-05-04 Joel Brobecker <brobecker@adacore.com>
4814 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
4815 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
4816 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
4817 Re-implement to match the ABI as summarized in GCC's
4818 gcc/config/sparc/sparc.c. All callers updated.
4819 (sparc32_store_arguments): Remove assertion.
4821 2018-05-04 Tom Tromey <tom@tromey.com>
4823 * printcmd.c: Don't include tui.h.
4824 (decode_format): Use skip_spaces.
4826 2018-05-04 Tom Tromey <tom@tromey.com>
4829 * printcmd.c (last_count): New global.
4830 (x_command): Use saved count when repeating.
4832 2018-05-04 Tom Tromey <tom@tromey.com>
4834 * nto-procfs.c (do_closedir_cleanup): Remove.
4835 (procfs_pidlist): Use gdb_dir_up.
4836 * procfs.c (do_closedir_cleanup): Remove.
4837 (proc_update_threads): Use gdb_dir_up.
4838 * common/filestuff.h (struct gdb_dir_deleter): New.
4839 (gdb_dir_up): New typedef.
4841 2018-05-04 Tom Tromey <tom@tromey.com>
4843 * ada-lang.c (print_mention_exception): Use std::string.
4845 2018-05-04 Tom Tromey <tom@tromey.com>
4847 * ada-lang.c (create_excep_cond_exprs): Update.
4848 (ada_exception_catchpoint_cond_string): Use std::string.
4850 2018-05-04 Tom Tromey <tom@tromey.com>
4852 * ada-lang.c (xget_renaming_scope): Return std::string.
4853 (old_renaming_is_invisible): Update.
4855 2018-05-04 Tom Tromey <tom@tromey.com>
4857 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
4858 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
4860 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
4862 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
4864 2018-05-04 Tom Tromey <tom@tromey.com>
4866 * remote.c (remote_query_supported_append): Change type.
4867 (remote_check_symbols): Update.
4869 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
4872 * configure.ac: Prepend libpython.
4873 * python/python-config.py: Likewise.
4874 * configure: Regenerate.
4876 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
4878 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
4880 2018-05-03 Pedro Alves <palves@redhat.com>
4883 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
4884 override. Write 'true' instead of '1'.
4885 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
4888 2018-05-02 Pedro Alves <palves@redhat.com>
4890 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
4891 add_inf_child_target.
4892 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
4893 add_inf_child_target.
4894 * aix-thread.c (aix_thread_target_info): New.
4895 (aix_thread_target) <shortname, longname, doc>: Delete.
4897 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
4898 add_inf_child_target.
4899 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
4900 add_inf_child_target.
4901 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
4902 add_inf_child_target.
4903 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
4904 add_inf_child_target.
4905 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
4906 add_inf_child_target.
4907 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
4908 add_inf_child_target.
4909 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
4910 add_inf_child_target.
4911 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
4912 add_inf_child_target.
4913 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
4914 add_inf_child_target.
4915 * bfd-target.c (target_bfd_target_info): New.
4916 (target_bfd) <shortname, longname, doc>: Delete.
4918 * bsd-kvm.c (bsd_kvm_target_info): New.
4919 (bsd_kvm_target) <shortname, longname, doc>: Delete.
4921 (bsd_kvm_target::open): Rename to ...
4922 (bsd_kvm_target_open): ... this. Adjust.
4923 * bsd-uthread.c (bsd_uthread_target_info): New.
4924 (bsd_uthread_target) <shortname, longname, doc>: Delete.
4926 * corefile.c (core_file_command): Adjust.
4927 * corelow.c (core_target_info): New.
4928 (core_target) <shortname, longname, doc>: Delete.
4930 (core_target::open): Rename to ...
4931 (core_target_open): ... this. Adjust.
4932 * ctf.c (ctf_target_info): New.
4933 (ctf_target) <shortname, longname, doc>: Delete.
4935 (ctf_target::open): Rename to ...
4936 (ctf_target_open): ... this.
4937 (_initialize_ctf): Adjust.
4938 * exec.c (exec_target_info): New.
4939 (exec_target) <shortname, longname, doc>: Delete.
4941 (exec_target::open): Rename to ...
4942 (exec_target_open): ... this.
4943 * gdbcore.h (core_target_open): Declare.
4944 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
4945 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
4946 add_inf_child_target.
4947 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
4948 add_inf_child_target.
4949 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
4950 add_inf_child_target.
4951 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
4952 add_inf_child_target.
4953 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
4954 add_inf_child_target.
4955 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
4956 add_inf_child_target.
4957 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
4958 add_inf_child_target.
4959 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
4960 add_inf_child_target.
4961 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
4962 add_inf_child_target.
4963 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
4964 add_inf_child_target.
4965 * inf-child.c (inf_child_target_info): New.
4966 (inf_child_target::info): New.
4967 (inf_child_open_target): Remove 'target' parameter. Use
4968 get_native_target instead.
4969 (inf_child_target::open): Delete.
4970 (add_inf_child_target): New.
4971 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
4974 (add_inf_child_target): Declare.
4975 (inf_child_open_target): Declare.
4976 * linux-thread-db.c (thread_db_target_info): New.
4977 (thread_db_target) <shortname, longname, doc>: Delete.
4979 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
4980 add_inf_child_target.
4981 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
4982 add_inf_child_target.
4983 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
4984 add_inf_child_target.
4985 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
4986 add_inf_child_target.
4987 * make-target-delegates (print_class): Adjust.
4988 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
4989 add_inf_child_target.
4990 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
4991 add_inf_child_target.
4992 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
4993 add_inf_child_target.
4994 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
4995 add_inf_child_target.
4996 * nto-procfs.c (nto_native_target_info): New.
4997 (nto_procfs_target_native) <shortname, longname, doc>:
5000 (nto_procfs_target_info): New.
5001 (nto_procfs_target_procfs) <shortname, longname, doc>:
5004 (init_procfs_targets): Adjust.
5005 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
5006 add_inf_child_target.
5007 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
5008 add_inf_child_target.
5009 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
5010 add_inf_child_target.
5011 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
5012 add_inf_child_target.
5013 * ravenscar-thread.c (ravenscar_target_info): New.
5014 (ravenscar_thread_target) <shortname, longname, doc>:
5017 * record-btrace.c (record_btrace_target_info):
5018 (record_btrace_target) <shortname, longname, doc>: Delete.
5020 (record_btrace_target::open): Rename to ...
5021 (record_btrace_target_open): ... this. Adjust.
5022 * record-full.c (record_longname, record_doc): New.
5023 (record_full_base_target) <shortname, longname, doc>: Delete.
5025 (record_full_target_info): New.
5026 (record_full_target): <shortname>: Delete.
5028 (record_full_core_open_1, record_full_open_1): Update comments.
5029 (record_full_base_target::open): Rename to ...
5030 (record_full_open): ... this.
5031 (cmd_record_full_restore): Update.
5032 (_initialize_record_full): Update.
5033 * remote-sim.c (remote_sim_target_info): New.
5034 (gdbsim_target) <shortname, longname, doc>: Delete.
5036 (gdbsim_target::open): Rename to ...
5037 (gdbsim_target_open): ... this.
5038 (_initialize_remote_sim): Adjust.
5039 * remote.c (remote_doc): New.
5040 (remote_target_info): New.
5041 (remote_target) <shortname, longname, doc>: Delete.
5043 (extended_remote_target_info): New.
5044 (extended_remote_target) <shortname, longname, doc>: Delete.
5046 (remote_target::open_1): Make static. Adjust.
5047 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
5048 * s390-linux-nat.c (_initialize_s390_nat): Use
5049 add_inf_child_target.
5050 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
5051 add_inf_child_target.
5052 * sol-thread.c (thread_db_target_info): New.
5053 (sol_thread_target) <shortname, longname, doc>: Delete.
5055 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
5056 add_inf_child_target.
5057 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
5058 add_inf_child_target.
5059 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
5060 add_inf_child_target.
5061 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
5062 add_inf_child_target.
5063 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
5064 add_inf_child_target.
5065 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
5066 add_inf_child_target.
5067 * spu-linux-nat.c (_initialize_spu_nat): Use
5068 add_inf_child_target.
5069 * spu-multiarch.c (spu_multiarch_target_info): New.
5070 (spu_multiarch_target) <shortname, longname, doc>: Delete.
5072 * target-delegates.c: Regenerate.
5073 * target.c: Include <unordered_map>.
5074 (target_ops_p): Delete.
5075 (DEF_VEC_P(target_ops_p)): Delete.
5076 (target_factories): New.
5077 (test_target_info): New.
5078 (test_target_ops::info): New.
5079 (open_target): Adjust to use target_factories.
5080 (add_target_with_completer): Rename to ...
5081 (add_target): ... this. Change prototype. Register target_info
5082 and open callback in target_factories. Register target_info in
5083 command context instead of target_ops.
5084 (add_target): Delete old implementation.
5085 (add_deprecated_target_alias): Change prototype. Adjust.
5086 (the_native_target): New.
5087 (set_native_target, get_native_target): New.
5088 (find_default_run_target): Use the_native_target.
5089 (find_attach_target, find_run_target): Simplify.
5090 (target_ops::open): Delete.
5091 (dummy_target_info): New.
5092 (dummy_target::shortname, dummy_target::longname)
5093 (dummy_target::doc): Delete.
5094 (dummy_target::info): New.
5095 (debug_target::shortname, debug_target::longname)
5096 (debug_target::doc): Delete.
5097 (debug_target::info): New.
5098 * target.h (struct target_info): New.
5099 (target_ops::~target_ops): Add comment.
5100 (target_ops::info): New.
5101 (target_ops::shortname, target_ops::longname, target_ops::doc): No
5102 longer virtual. Implement in terms of target_info.
5103 (set_native_target, get_native_target): Declare.
5104 (target_open_ftype): New.
5105 (add_target, add_target_with_completer)
5106 (add_deprecated_target_alias): Change prototype.
5107 (test_target) <shortname, longname, doc>: Delete.
5109 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
5110 add_inf_child_target.
5111 * tracefile-tfile.c (tfile_target_info): New.
5112 (tfile_target) <shortname, longname, doc>: Delete.
5114 (tfile_target::open): Rename to ...
5115 (tfile_target_open): ... this.
5116 (_initialize_tracefile_tfile): Adjust.
5117 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
5118 add_inf_child_target.
5119 * windows-nat.c (_initialize_windows_nat): Use
5120 add_inf_child_target.
5121 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
5122 add_inf_child_target.
5124 2018-05-02 Pedro Alves <palves@redhat.com>
5126 * linux-nat.h (linux_nat_target) <low_new_thread,
5127 low_delete_thread, low_new_fork, low_forget_process,
5128 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
5129 New virtual methods.
5130 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5131 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
5132 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
5133 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5134 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
5136 * linux-fork.c (delete_fork): Adjust to call low method.
5137 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
5138 (linux_nat_new_fork, linux_nat_forget_process_hook)
5139 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
5140 (linux_nat_status_is_event):
5141 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
5142 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
5144 (sigtrap_is_event): Rename to ...
5145 (linux_nat_target::low_status_is_event): ... this.
5146 (linux_nat_set_status_is_event): Delete.
5147 (save_stop_reason, linux_nat_wait_1)
5148 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
5150 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5151 (linux_nat_set_new_fork, linux_nat_set_forget_process)
5152 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5153 (linux_nat_set_prepare_to_resume): Delete.
5154 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
5155 low virtual methods.
5156 * amd64-linux-nat.c: Likewise.
5157 * arm-linux-nat.c: Likewise.
5158 * i386-linux-nat.c: Likewise.
5159 * ia64-linux-nat.c: Likewise.
5160 * mips-linux-nat.c: Likewise.
5161 * ppc-linux-nat.c: Likewise.
5162 * s390-linux-nat.c: Likewise.
5163 * sparc64-linux-nat.c: Likewise.
5164 * x86-linux-nat.c: Likewise.
5165 * x86-linux-nat.h: Include "nat/x86-linux.h".
5166 (x86_linux_nat_target) <low_new_fork, low_forget_process,
5167 low_prepare_to_resume, low_new_thread, low_delete_thread>:
5170 2018-05-02 Pedro Alves <palves@redhat.com>
5172 * target.h (target_ops)
5173 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5174 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
5175 stopped_by_watchpoint, have_continuable_watchpoint,
5176 stopped_data_address, watchpoint_addr_within_range,
5177 can_accel_watchpoint_condition, can_run, thread_alive,
5178 has_all_memory, has_memory, has_stack, has_registers,
5179 has_execution, can_async_p, is_async_p, supports_non_stop,
5180 always_non_stop_p, can_execute_reverse, supports_multi_process,
5181 supports_enable_disable_tracepoint,
5182 supports_disable_randomization, supports_string_tracing,
5183 supports_evaluation_of_breakpoint_conditions,
5184 can_run_breakpoint_commands, filesystem_is_local,
5185 can_download_tracepoint, get_trace_state_variable_value,
5186 set_trace_notes, get_tib_address, use_agent, can_use_agent,
5187 record_is_replaying, record_will_replay,
5188 augmented_libraries_svr4_read>: Adjust to return bool.
5189 * aarch64-linux-nat.c: All implementations adjusted.
5190 * aix-thread.c: All implementations adjusted.
5191 * arm-linux-nat.c: All implementations adjusted.
5192 * breakpoint.c: All implementations adjusted.
5193 * bsd-kvm.c: All implementations adjusted.
5194 * bsd-uthread.c: All implementations adjusted.
5195 * corelow.c: All implementations adjusted.
5196 * ctf.c: All implementations adjusted.
5197 * darwin-nat.c: All implementations adjusted.
5198 * darwin-nat.h: All implementations adjusted.
5199 * exec.c: All implementations adjusted.
5200 * fbsd-nat.c: All implementations adjusted.
5201 * fbsd-nat.h: All implementations adjusted.
5202 * gnu-nat.c: All implementations adjusted.
5203 * gnu-nat.h: All implementations adjusted.
5204 * go32-nat.c: All implementations adjusted.
5205 * ia64-linux-nat.c: All implementations adjusted.
5206 * inf-child.c: All implementations adjusted.
5207 * inf-child.h: All implementations adjusted.
5208 * inf-ptrace.c: All implementations adjusted.
5209 * inf-ptrace.h: All implementations adjusted.
5210 * linux-nat.c: All implementations adjusted.
5211 * linux-nat.h: All implementations adjusted.
5212 * mips-linux-nat.c: All implementations adjusted.
5213 * nto-procfs.c: All implementations adjusted.
5214 * ppc-linux-nat.c: All implementations adjusted.
5215 * procfs.c: All implementations adjusted.
5216 * ravenscar-thread.c: All implementations adjusted.
5217 * record-btrace.c: All implementations adjusted.
5218 * record-full.c: All implementations adjusted.
5219 * remote-sim.c: All implementations adjusted.
5220 * remote.c: All implementations adjusted.
5221 * s390-linux-nat.c: All implementations adjusted.
5222 * sol-thread.c: All implementations adjusted.
5223 * spu-multiarch.c: All implementations adjusted.
5224 * target-delegates.c: All implementations adjusted.
5225 * target.c: All implementations adjusted.
5226 * target.h: All implementations adjusted.
5227 * tracefile-tfile.c: All implementations adjusted.
5228 * tracefile.c: All implementations adjusted.
5229 * tracefile.h: All implementations adjusted.
5230 * windows-nat.c: All implementations adjusted.
5231 * x86-linux-nat.h: All implementations adjusted.
5232 * x86-nat.h: All implementations adjusted.
5234 2018-05-02 Pedro Alves <palves@redhat.com>
5236 * make-target-delegates (scan_target_h): Don't trim lines here.
5237 Replace sequences of tabs and/or whitespace with a single
5239 (top level, parsing methods): Trim each line before processing it
5242 2018-05-02 Pedro Alves <palves@redhat.com>
5243 John Baldwin <jhb@freebsd.org>
5245 * target.h (enum strata) <debug_stratum>: New.
5246 (struct target_ops) <all delegation methods>: Replace by C++
5247 virtual methods, and drop "to_" prefix. All references updated
5249 <to_shortname, to_longname, to_doc, to_data,
5250 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
5251 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
5252 virtual methods. All references updated throughout.
5253 <can_attach, supports_terminal_ours, can_create_inferior,
5254 get_thread_control_capabilities, attach_no_wait>: New
5256 <insert_breakpoint, remove_breakpoint>: Now
5257 TARGET_DEFAULT_NORETURN methods.
5258 <info_proc>: Now returns bool.
5260 (OPS_MAGIC): Delete.
5261 (current_target): Delete. All references replaced by references
5263 (target_stack): ... this. New.
5264 (target_shortname, target_longname): Adjust.
5265 (target_can_run): Now a function declaration.
5266 (default_child_has_all_memory, default_child_has_memory)
5267 (default_child_has_stack, default_child_has_registers)
5268 (default_child_has_execution): Remove target_ops parameter.
5269 (complete_target_initialization): Delete.
5270 (memory_breakpoint_target): New template class.
5271 (test_target_ops): Refactor as a C++ class with virtual methods.
5272 * make-target-delegates (NAME_PART): Tighten.
5273 (POINTER_PART, CP_SYMBOL): New.
5274 (SIMPLE_RETURN_PART): Reimplement.
5275 (VEC_RETURN_PART): Expect less.
5276 (RETURN_PART, VIRTUAL_PART): New.
5277 (METHOD): Adjust to C++ virtual methods.
5278 (scan_target_h): Remove reference to C99.
5279 (dname): Output "target_ops::" prefix.
5280 (write_function_header): Adjust to output a C++ class method.
5281 (write_declaration): New.
5282 (write_delegator): Adjust to output a C++ class method.
5283 (tdname): Output "dummy_target::" prefix.
5284 (write_tdefault, write_debugmethod): Adjust to output a C++ class
5286 (tdefault_names, debug_names): Delete.
5287 (return_types, tdefaults, styles, argtypes_array): New.
5288 (top level): All methods are delegators.
5290 (top level): Print dummy_target and debug_target classes.
5291 * target-delegates.c: Regenerate.
5292 * target-debug.h (target_debug_print_enum_info_proc_what)
5293 (target_debug_print_thread_control_capabilities)
5294 (target_debug_print_thread_info_p): New.
5295 * target.c (dummy_target): Delete.
5296 (the_dummy_target, the_debug_target): New.
5297 (target_stack): Now extern.
5298 (set_targetdebug): Push/unpush debug target.
5299 (default_child_has_all_memory, default_child_has_memory)
5300 (default_child_has_stack, default_child_has_registers)
5301 (default_child_has_execution): Remove target_ops parameter.
5302 (complete_target_initialization): Delete.
5303 (add_target_with_completer): No longer call
5304 complete_target_initialization.
5305 (target_supports_terminal_ours): Use regular delegation.
5306 (update_current_target): Delete.
5307 (push_target): No longer check magic number. Don't call
5308 update_current_target.
5309 (unpush_target): Don't call update_current_target.
5310 (target_is_pushed): No longer check magic number.
5311 (target_require_runnable): Skip for all stratums over
5313 (target_ops::info_proc): New.
5314 (target_info_proc): Use find_target_at and
5315 find_default_run_target.
5316 (target_supports_disable_randomization): Use regular delegation.
5317 (target_get_osdata): Use find_target_at.
5318 (target_ops::open, target_ops::close, target_ops::can_attach)
5319 (target_ops::attach, target_ops::can_create_inferior)
5320 (target_ops::create_inferior, target_ops::can_run)
5321 (target_can_run): New.
5322 (default_fileio_target): Use regular delegation.
5323 (target_ops::fileio_open, target_ops::fileio_pwrite)
5324 (target_ops::fileio_pread, target_ops::fileio_fstat)
5325 (target_ops::fileio_close, target_ops::fileio_unlink)
5326 (target_ops::fileio_readlink): New.
5327 (target_fileio_open_1, target_fileio_unlink)
5328 (target_fileio_readlink): Always call the target method. Handle
5330 (return_zero, return_zero_has_execution): Delete.
5331 (init_dummy_target): Delete.
5332 (dummy_target::dummy_target, dummy_target::shortname)
5333 (dummy_target::longname, dummy_target::doc)
5334 (debug_target::debug_target, debug_target::shortname)
5335 (debug_target::longname, debug_target::doc): New.
5336 (target_supports_delete_record): Use regular delegation.
5337 (setup_target_debug): Delete.
5338 (maintenance_print_target_stack): Skip debug_stratum.
5339 (initialize_targets): Instantiate the_dummy_target and
5341 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
5343 (target_auxv_search, fprint_target_auxv): Adjust.
5344 (info_auxv_command): Adjust to use target_stack.
5345 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
5346 * exceptions.c (print_flush): Handle a NULL target_stack.
5347 * regcache.c (target_ops_no_register): Refactor as class with
5350 * exec.c (exec_target): New class.
5351 (exec_ops): Now an exec_target.
5352 (exec_open, exec_close_1, exec_get_section_table)
5353 (exec_xfer_partial, exec_files_info, exec_has_memory)
5354 (exec_make_note_section): Refactor as exec_target methods.
5355 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
5357 (exec_target::find_memory_regions): New.
5358 (_initialize_exec): Don't call init_exec_ops.
5359 * gdbcore.h (exec_file_clear): Delete.
5361 * corefile.c (core_target): Delete.
5362 (core_file_command): Adjust.
5363 * corelow.c (core_target): New class.
5364 (the_core_target): New.
5365 (core_close): Remove target_ops parameter.
5366 (core_close_cleanup): Adjust.
5367 (core_target::close): New.
5368 (core_open, core_detach, get_core_registers, core_files_info)
5369 (core_xfer_partial, core_thread_alive, core_read_description)
5370 (core_pid_to_str, core_thread_name, core_has_memory)
5371 (core_has_stack, core_has_registers, core_info_proc): Rework as
5372 core_target methods.
5373 (ignore, core_remove_breakpoint, init_core_ops): Delete.
5374 (_initialize_corelow): Initialize the_core_target.
5375 * gdbcore.h (core_target): Delete.
5376 (the_core_target): New.
5378 * ctf.c: (ctf_target): New class.
5379 (ctf_ops): Now a ctf_target.
5380 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
5381 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
5382 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
5384 (init_ctf_ops): Delete.
5385 (_initialize_ctf): Don't call it.
5386 * tracefile-tfile.c (tfile_target): New class.
5387 (tfile_ops): Now a tfile_target.
5388 (tfile_open, tfile_close, tfile_files_info)
5389 (tfile_get_tracepoint_status, tfile_trace_find)
5390 (tfile_fetch_registers, tfile_xfer_partial)
5391 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
5392 Refactor as tfile_target methods.
5393 (tfile_xfer_partial_features): Remove target_ops parameter.
5394 (init_tfile_ops): Delete.
5395 (_initialize_tracefile_tfile): Don't call it.
5396 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
5397 (tracefile_has_stack, tracefile_has_registers)
5398 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
5399 tracefile_target methods.
5400 (init_tracefile_ops): Delete.
5401 (tracefile_target::tracefile_target): New.
5402 * tracefile.h: Include "target.h".
5403 (tracefile_target): New class.
5404 (init_tracefile_ops): Delete.
5406 * spu-multiarch.c (spu_multiarch_target): New class.
5407 (spu_ops): Now a spu_multiarch_target.
5408 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
5409 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
5410 (spu_search_memory, spu_mourn_inferior): Refactor as
5411 spu_multiarch_target methods.
5412 (init_spu_ops): Delete.
5413 (_initialize_spu_multiarch): Remove references to init_spu_ops,
5414 complete_target_initialization.
5416 * ravenscar-thread.c (ravenscar_thread_target): New class.
5417 (ravenscar_ops): Now a ravenscar_thread_target.
5418 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
5419 (ravenscar_thread_alive, ravenscar_pid_to_str)
5420 (ravenscar_fetch_registers, ravenscar_store_registers)
5421 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
5422 (ravenscar_stopped_by_hw_breakpoint)
5423 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
5424 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
5425 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
5427 (init_ravenscar_thread_ops): Delete.
5428 (_initialize_ravenscar): Remove references to
5429 init_ravenscar_thread_ops and complete_target_initialization.
5431 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
5432 (bsd_uthread_target): New class.
5433 (bsd_uthread_ops): Now a bsd_uthread_target.
5434 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
5435 (bsd_uthread_close, bsd_uthread_mourn_inferior)
5436 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
5437 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
5438 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
5439 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
5440 (bsd_uthread_target): Delete function.
5441 (_initialize_bsd_uthread): Remove reference to
5442 complete_target_initialization.
5444 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
5445 (target_bfd): ... this new class.
5446 (target_bfd_xfer_partial, target_bfd_get_section_table)
5447 (target_bfd_close): Refactor as target_bfd methods.
5448 (target_bfd::~target_bfd): New.
5449 (target_bfd_reopen): Adjust.
5450 (target_bfd::close): New.
5452 * record-btrace.c (record_btrace_target): New class.
5453 (record_btrace_ops): Now a record_btrace_target.
5454 (record_btrace_open, record_btrace_stop_recording)
5455 (record_btrace_disconnect, record_btrace_close)
5456 (record_btrace_async, record_btrace_info)
5457 (record_btrace_insn_history, record_btrace_insn_history_range)
5458 (record_btrace_insn_history_from, record_btrace_call_history)
5459 (record_btrace_call_history_range)
5460 (record_btrace_call_history_from, record_btrace_record_method)
5461 (record_btrace_is_replaying, record_btrace_will_replay)
5462 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
5463 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
5464 (record_btrace_store_registers, record_btrace_prepare_to_store)
5465 (record_btrace_to_get_unwinder)
5466 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
5467 (record_btrace_commit_resume, record_btrace_wait)
5468 (record_btrace_stop, record_btrace_can_execute_reverse)
5469 (record_btrace_stopped_by_sw_breakpoint)
5470 (record_btrace_supports_stopped_by_sw_breakpoint)
5471 (record_btrace_stopped_by_hw_breakpoint)
5472 (record_btrace_supports_stopped_by_hw_breakpoint)
5473 (record_btrace_update_thread_list, record_btrace_thread_alive)
5474 (record_btrace_goto_begin, record_btrace_goto_end)
5475 (record_btrace_goto, record_btrace_stop_replaying_all)
5476 (record_btrace_execution_direction)
5477 (record_btrace_prepare_to_generate_core)
5478 (record_btrace_done_generating_core): Refactor as
5479 record_btrace_target methods.
5480 (init_record_btrace_ops): Delete.
5481 (_initialize_record_btrace): Remove reference to
5482 init_record_btrace_ops.
5483 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
5484 the execution_direction global.
5485 (record_full_base_target, record_full_target)
5486 (record_full_core_target): New classes.
5487 (record_full_ops): Now a record_full_target.
5488 (record_full_core_ops): Now a record_full_core_target.
5489 (record_full_target::detach, record_full_target::disconnect)
5490 (record_full_core_target::disconnect)
5491 (record_full_target::mourn_inferior, record_full_target::kill):
5493 (record_full_open, record_full_close, record_full_async): Refactor
5494 as methods of the record_full_base_target class.
5495 (record_full_resume, record_full_commit_resume): Refactor
5496 as methods of the record_full_target class.
5497 (record_full_wait, record_full_stopped_by_watchpoint)
5498 (record_full_stopped_data_address)
5499 (record_full_stopped_by_sw_breakpoint)
5500 (record_full_supports_stopped_by_sw_breakpoint)
5501 (record_full_stopped_by_hw_breakpoint)
5502 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
5503 methods of the record_full_base_target class.
5504 (record_full_store_registers, record_full_xfer_partial)
5505 (record_full_insert_breakpoint, record_full_remove_breakpoint):
5506 Refactor as methods of the record_full_target class.
5507 (record_full_can_execute_reverse, record_full_get_bookmark)
5508 (record_full_goto_bookmark, record_full_execution_direction)
5509 (record_full_record_method, record_full_info, record_full_delete)
5510 (record_full_is_replaying, record_full_will_replay)
5511 (record_full_goto_begin, record_full_goto_end, record_full_goto)
5512 (record_full_stop_replaying): Refactor as methods of the
5513 record_full_base_target class.
5514 (record_full_core_resume, record_full_core_kill)
5515 (record_full_core_fetch_registers)
5516 (record_full_core_prepare_to_store)
5517 (record_full_core_store_registers, record_full_core_xfer_partial)
5518 (record_full_core_insert_breakpoint)
5519 (record_full_core_remove_breakpoint)
5520 (record_full_core_has_execution): Refactor
5521 as methods of the record_full_core_target class.
5522 (record_full_base_target::supports_delete_record): New.
5523 (init_record_full_ops): Delete.
5524 (init_record_full_core_ops): Delete.
5525 (record_full_save): Refactor as method of the
5526 record_full_base_target class.
5527 (_initialize_record_full): Remove references to
5528 init_record_full_ops and init_record_full_core_ops.
5530 * remote.c (remote_target, extended_remote_target): New classes.
5531 (remote_ops): Now a remote_target.
5532 (extended_remote_ops): Now an extended_remote_target.
5533 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
5534 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
5535 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
5536 (remote_pass_signals, remote_set_syscall_catchpoint)
5537 (remote_program_signals, )
5538 (remote_thread_always_alive): Remove target_ops parameter.
5539 (remote_thread_alive, remote_thread_name)
5540 (remote_update_thread_list, remote_threads_extra_info)
5541 (remote_static_tracepoint_marker_at)
5542 (remote_static_tracepoint_markers_by_strid)
5543 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
5544 (remote_open): Refactor as methods of remote_target.
5545 (extended_remote_open, extended_remote_detach)
5546 (extended_remote_attach, extended_remote_post_attach):
5547 (extended_remote_supports_disable_randomization)
5548 (extended_remote_create_inferior): : Refactor as method of
5549 extended_remote_target.
5550 (remote_set_permissions, remote_open_1, remote_detach)
5551 (remote_follow_fork, remote_follow_exec, remote_disconnect)
5552 (remote_resume, remote_commit_resume, remote_stop)
5553 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
5554 (remote_terminal_ours, remote_wait, remote_fetch_registers)
5555 (remote_prepare_to_store, remote_store_registers)
5556 (remote_flash_erase, remote_flash_done, remote_files_info)
5557 (remote_kill, remote_mourn, remote_insert_breakpoint)
5558 (remote_remove_breakpoint, remote_insert_watchpoint)
5559 (remote_watchpoint_addr_within_range)
5560 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
5561 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
5562 (remote_supports_stopped_by_sw_breakpoint)
5563 (remote_stopped_by_hw_breakpoint)
5564 (remote_supports_stopped_by_hw_breakpoint)
5565 (remote_stopped_by_watchpoint, remote_stopped_data_address)
5566 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
5567 (remote_verify_memory): Refactor as methods of remote_target.
5568 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
5570 (remote_xfer_partial, remote_get_memory_xfer_limit)
5571 (remote_search_memory, remote_rcmd, remote_memory_map)
5572 (remote_pid_to_str, remote_get_thread_local_address)
5573 (remote_get_tib_address, remote_read_description): Refactor as
5574 methods of remote_target.
5575 (remote_target::fileio_open, remote_target::fileio_pwrite)
5576 (remote_target::fileio_pread, remote_target::fileio_close): New.
5577 (remote_hostio_readlink, remote_hostio_fstat)
5578 (remote_filesystem_is_local, remote_can_execute_reverse)
5579 (remote_supports_non_stop, remote_supports_disable_randomization)
5580 (remote_supports_multi_process, remote_supports_cond_breakpoints)
5581 (remote_supports_enable_disable_tracepoint)
5582 (remote_supports_string_tracing)
5583 (remote_can_run_breakpoint_commands, remote_trace_init)
5584 (remote_download_tracepoint, remote_can_download_tracepoint)
5585 (remote_download_trace_state_variable, remote_enable_tracepoint)
5586 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
5587 (remote_trace_start, remote_get_trace_status)
5588 (remote_get_tracepoint_status, remote_trace_stop)
5589 (remote_trace_find, remote_get_trace_state_variable_value)
5590 (remote_save_trace_data, remote_get_raw_trace_data)
5591 (remote_set_disconnected_tracing, remote_core_of_thread)
5592 (remote_set_circular_trace_buffer, remote_traceframe_info)
5593 (remote_get_min_fast_tracepoint_insn_len)
5594 (remote_set_trace_buffer_size, remote_set_trace_notes)
5595 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
5596 (remote_disable_btrace, remote_teardown_btrace)
5597 (remote_read_btrace, remote_btrace_conf)
5598 (remote_augmented_libraries_svr4_read, remote_load)
5599 (remote_pid_to_exec_file, remote_can_do_single_step)
5600 (remote_execution_direction, remote_thread_handle_to_thread_info):
5601 Refactor as methods of remote_target.
5602 (init_remote_ops, init_extended_remote_ops): Delete.
5603 (remote_can_async_p, remote_is_async_p, remote_async)
5604 (remote_thread_events, remote_upload_tracepoints)
5605 (remote_upload_trace_state_variables): Refactor as methods of
5607 (_initialize_remote): Remove references to init_remote_ops and
5608 init_extended_remote_ops.
5610 * remote-sim.c (gdbsim_target): New class.
5611 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
5612 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
5613 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
5614 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
5615 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
5616 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
5617 Refactor as methods of gdbsim_target.
5618 (gdbsim_ops): Now a gdbsim_target.
5619 (init_gdbsim_ops): Delete.
5620 (gdbsim_cntrl_c): Adjust.
5621 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
5623 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
5624 (the_amd64_linux_nat_target): New.
5625 (amd64_linux_fetch_inferior_registers)
5626 (amd64_linux_store_inferior_registers): Refactor as methods of
5627 amd64_linux_nat_target.
5628 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
5629 * i386-linux-nat.c: Don't include "linux-nat.h".
5630 (i386_linux_nat_target): New class.
5631 (the_i386_linux_nat_target): New.
5632 (i386_linux_fetch_inferior_registers)
5633 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
5634 as methods of i386_linux_nat_target.
5635 (_initialize_i386_linux_nat): Adjust. Set linux_target.
5636 * inf-child.c (inf_child_ops): Delete.
5637 (inf_child_fetch_inferior_registers)
5638 (inf_child_store_inferior_registers): Delete.
5639 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
5640 methods of inf_child_target.
5641 (inf_child_target::supports_terminal_ours)
5642 (inf_child_target::terminal_init)
5643 (inf_child_target::terminal_inferior)
5644 (inf_child_target::terminal_ours_for_output)
5645 (inf_child_target::terminal_ours, inf_child_target::interrupt)
5646 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
5648 (inf_child_open, inf_child_disconnect, inf_child_close)
5649 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
5650 (inf_child_post_startup_inferior, inf_child_can_run)
5651 (inf_child_pid_to_exec_file): Refactor as methods of
5653 (inf_child_follow_fork): Delete.
5654 (inf_child_target::can_create_inferior)
5655 (inf_child_target::can_attach): New.
5656 (inf_child_target::has_all_memory, inf_child_target::has_memory)
5657 (inf_child_target::has_stack, inf_child_target::has_registers)
5658 (inf_child_target::has_execution): New.
5659 (inf_child_fileio_open, inf_child_fileio_pwrite)
5660 (inf_child_fileio_pread, inf_child_fileio_fstat)
5661 (inf_child_fileio_close, inf_child_fileio_unlink)
5662 (inf_child_fileio_readlink, inf_child_use_agent)
5663 (inf_child_can_use_agent): Refactor as methods of
5665 (return_zero, inf_child_target): Delete.
5666 (inf_child_target::inf_child_target): New.
5667 * inf-child.h: Include "target.h".
5668 (inf_child_target): Delete function prototype.
5669 (inf_child_target): New class.
5670 (inf_child_open_target, inf_child_mourn_inferior)
5671 (inf_child_maybe_unpush_target): Delete.
5672 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
5673 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
5674 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
5675 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
5676 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
5677 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
5678 (inf_ptrace_wait, inf_ptrace_xfer_partial)
5679 (inf_ptrace_thread_alive, inf_ptrace_files_info)
5680 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
5681 methods of inf_ptrace_target.
5682 (inf_ptrace_target): Delete function.
5683 * inf-ptrace.h: Include "inf-child.h".
5684 (inf_ptrace_target): Delete function declaration.
5685 (inf_ptrace_target): New class.
5686 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
5687 * linux-nat.c (linux_target): New.
5688 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
5689 (linux_nat_target::~linux_nat_target): New.
5690 (linux_child_post_attach, linux_child_post_startup_inferior)
5691 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
5692 (linux_child_remove_fork_catchpoint)
5693 (linux_child_insert_vfork_catchpoint)
5694 (linux_child_remove_vfork_catchpoint)
5695 (linux_child_insert_exec_catchpoint)
5696 (linux_child_remove_exec_catchpoint)
5697 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
5698 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
5699 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
5700 (linux_nat_stopped_data_address)
5701 (linux_nat_stopped_by_sw_breakpoint)
5702 (linux_nat_supports_stopped_by_sw_breakpoint)
5703 (linux_nat_stopped_by_hw_breakpoint)
5704 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
5705 (linux_nat_kill, linux_nat_mourn_inferior)
5706 (linux_nat_xfer_partial, linux_nat_thread_alive)
5707 (linux_nat_update_thread_list, linux_nat_pid_to_str)
5708 (linux_nat_thread_name, linux_child_pid_to_exec_file)
5709 (linux_child_static_tracepoint_markers_by_strid)
5710 (linux_nat_is_async_p, linux_nat_can_async_p)
5711 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
5712 (linux_nat_supports_multi_process)
5713 (linux_nat_supports_disable_randomization, linux_nat_async)
5714 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
5715 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
5716 (linux_nat_fileio_open, linux_nat_fileio_readlink)
5717 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
5718 methods of linux_nat_target.
5719 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
5720 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
5722 (check_stopped_by_watchpoint): Adjust.
5723 (linux_xfer_partial): Delete.
5724 (linux_target_install_ops, linux_target, linux_nat_add_target):
5726 (linux_nat_target::linux_nat_target): New.
5727 * linux-nat.h: Include "inf-ptrace.h".
5728 (linux_nat_target): New.
5729 (linux_target, linux_target_install_ops, linux_nat_add_target):
5730 Delete function declarations.
5731 (linux_target): Declare global.
5732 * linux-thread-db.c (thread_db_target): New.
5733 (thread_db_target::thread_db_target): New.
5734 (thread_db_ops): Delete.
5735 (the_thread_db_target): New.
5736 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
5737 (thread_db_update_thread_list, thread_db_pid_to_str)
5738 (thread_db_extra_thread_info)
5739 (thread_db_thread_handle_to_thread_info)
5740 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
5741 (thread_db_resume): Refactor as methods of thread_db_target.
5742 (init_thread_db_ops): Delete.
5743 (_initialize_thread_db): Remove reference to init_thread_db_ops.
5744 * x86-linux-nat.c: Don't include "linux-nat.h".
5745 (super_post_startup_inferior): Delete.
5746 (x86_linux_nat_target::~x86_linux_nat_target): New.
5747 (x86_linux_child_post_startup_inferior)
5748 (x86_linux_read_description, x86_linux_enable_btrace)
5749 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
5750 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
5751 methods of x86_linux_nat_target.
5752 (x86_linux_create_target): Delete. Bits folded ...
5753 (x86_linux_add_target): ... here. Now takes a linux_nat_target
5755 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
5756 (x86_linux_nat_target): New class.
5757 (x86_linux_create_target): Delete.
5758 (x86_linux_add_target): Now takes a linux_nat_target pointer.
5759 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
5760 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
5761 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
5762 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
5763 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
5765 (x86_use_watchpoints): Delete.
5766 * x86-nat.h: Include "breakpoint.h" and "target.h".
5767 (x86_use_watchpoints): Delete.
5768 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
5769 (x86_stopped_by_watchpoint, x86_stopped_data_address)
5770 (x86_insert_watchpoint, x86_remove_watchpoint)
5771 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
5772 (x86_stopped_by_hw_breakpoint): New declarations.
5773 (x86_nat_target): New template class.
5775 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
5776 (the_ppc_linux_nat_target): New.
5777 (ppc_linux_fetch_inferior_registers)
5778 (ppc_linux_can_use_hw_breakpoint)
5779 (ppc_linux_region_ok_for_hw_watchpoint)
5780 (ppc_linux_ranged_break_num_registers)
5781 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
5782 (ppc_linux_insert_mask_watchpoint)
5783 (ppc_linux_remove_mask_watchpoint)
5784 (ppc_linux_can_accel_watchpoint_condition)
5785 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
5786 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
5787 (ppc_linux_watchpoint_addr_within_range)
5788 (ppc_linux_masked_watch_num_registers)
5789 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
5790 (ppc_linux_read_description): Refactor as methods of
5791 ppc_linux_nat_target.
5792 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
5794 * procfs.c (procfs_xfer_partial): Delete forward declaration.
5795 (procfs_target): New class.
5796 (the_procfs_target): New.
5797 (procfs_target): Delete function.
5798 (procfs_auxv_parse, procfs_attach, procfs_detach)
5799 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
5800 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
5801 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
5802 (procfs_create_inferior, procfs_update_thread_list)
5803 (procfs_thread_alive, procfs_pid_to_str)
5804 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
5805 (procfs_stopped_data_address, procfs_insert_watchpoint)
5806 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
5807 (proc_find_memory_regions, procfs_info_proc)
5808 (procfs_make_note_section): Refactor as methods of procfs_target.
5809 (_initialize_procfs): Adjust.
5810 * sol-thread.c (sol_thread_target): New class.
5811 (sol_thread_ops): Now a sol_thread_target.
5812 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
5813 (sol_thread_fetch_registers, sol_thread_store_registers)
5814 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
5815 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
5816 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
5817 (init_sol_thread_ops): Delete.
5818 (_initialize_sol_thread): Adjust. Remove references to
5819 init_sol_thread_ops and complete_target_initialization.
5821 * windows-nat.c (windows_nat_target): New class.
5822 (windows_fetch_inferior_registers)
5823 (windows_store_inferior_registers, windows_resume, windows_wait)
5824 (windows_attach, windows_detach, windows_pid_to_exec_file)
5825 (windows_files_info, windows_create_inferior)
5826 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
5827 (windows_close, windows_pid_to_str, windows_xfer_partial)
5828 (windows_get_tib_address, windows_get_ada_task_ptid)
5829 (windows_thread_name, windows_thread_alive): Refactor as
5830 windows_nat_target methods.
5831 (do_initial_windows_stuff): Adjust.
5832 (windows_target): Delete function.
5833 (_initialize_windows_nat): Adjust.
5835 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
5836 (darwin_mourn_inferior, darwin_kill_inferior)
5837 (darwin_create_inferior, darwin_attach, darwin_detach)
5838 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
5839 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
5840 (darwin_supports_multi_process): Refactor as darwin_nat_target
5842 (darwin_resume_to, darwin_files_info): Delete.
5843 (_initialize_darwin_inferior): Rename to ...
5844 (_initialize_darwin_nat): ... this. Adjust to C++ification.
5845 * darwin-nat.h: Include "inf-child.h".
5846 (darwin_nat_target): New class.
5847 (darwin_complete_target): Delete.
5848 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
5849 (darwin_target): New.
5850 (i386_darwin_fetch_inferior_registers)
5851 (i386_darwin_store_inferior_registers): Refactor as methods of
5853 (darwin_complete_target): Delete, with ...
5854 (_initialize_i386_darwin_nat): ... bits factored out here.
5856 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
5857 (the_alpha_linux_nat_target): New.
5858 (alpha_linux_register_u_offset): Refactor as
5859 alpha_linux_nat_target method.
5860 (_initialize_alpha_linux_nat): Adjust.
5861 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
5862 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
5863 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
5864 methods of linux_nat_trad_target.
5865 (linux_trad_target): Delete.
5866 * linux-nat-trad.h (linux_trad_target): Delete function.
5867 (linux_nat_trad_target): New class.
5868 * mips-linux-nat.c (mips_linux_nat_target): New class.
5869 (super_fetch_registers, super_store_registers, super_close):
5871 (the_mips_linux_nat_target): New.
5872 (mips64_linux_regsets_fetch_registers)
5873 (mips64_linux_regsets_store_registers)
5874 (mips64_linux_fetch_registers, mips64_linux_store_registers)
5875 (mips_linux_register_u_offset, mips_linux_read_description)
5876 (mips_linux_can_use_hw_breakpoint)
5877 (mips_linux_stopped_by_watchpoint)
5878 (mips_linux_stopped_data_address)
5879 (mips_linux_region_ok_for_hw_watchpoint)
5880 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
5881 (mips_linux_close): Refactor as methods of mips_linux_nat.
5882 (_initialize_mips_linux_nat): Adjust to C++ification.
5884 * aix-thread.c (aix_thread_target): New class.
5885 (aix_thread_ops): Now an aix_thread_target.
5886 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
5887 (aix_thread_fetch_registers, aix_thread_store_registers)
5888 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
5889 (aix_thread_thread_alive, aix_thread_pid_to_str)
5890 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
5891 Refactor as methods of aix_thread_target.
5892 (init_aix_thread_ops): Delete.
5893 (_initialize_aix_thread): Remove references to init_aix_thread_ops
5894 and complete_target_initialization.
5895 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
5896 (rs6000_nat_target): New class.
5897 (the_rs6000_nat_target): New.
5898 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
5899 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
5900 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
5901 (super_create_inferior): Delete.
5902 (_initialize_rs6000_nat): Adjust to C++ification.
5904 * arm-linux-nat.c (arm_linux_nat_target): New class.
5905 (the_arm_linux_nat_target): New.
5906 (arm_linux_fetch_inferior_registers)
5907 (arm_linux_store_inferior_registers, arm_linux_read_description)
5908 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
5909 (arm_linux_remove_hw_breakpoint)
5910 (arm_linux_region_ok_for_hw_watchpoint)
5911 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
5912 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
5913 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
5914 arm_linux_nat_target.
5915 (_initialize_arm_linux_nat): Adjust to C++ification.
5917 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
5918 (the_aarch64_linux_nat_target): New.
5919 (aarch64_linux_fetch_inferior_registers)
5920 (aarch64_linux_store_inferior_registers)
5921 (aarch64_linux_child_post_startup_inferior)
5922 (aarch64_linux_read_description)
5923 (aarch64_linux_can_use_hw_breakpoint)
5924 (aarch64_linux_insert_hw_breakpoint)
5925 (aarch64_linux_remove_hw_breakpoint)
5926 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
5927 (aarch64_linux_region_ok_for_hw_watchpoint)
5928 (aarch64_linux_stopped_data_address)
5929 (aarch64_linux_stopped_by_watchpoint)
5930 (aarch64_linux_watchpoint_addr_within_range)
5931 (aarch64_linux_can_do_single_step): Refactor as methods of
5932 aarch64_linux_nat_target.
5933 (super_post_startup_inferior): Delete.
5934 (_initialize_aarch64_linux_nat): Adjust to C++ification.
5936 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
5937 (the_hppa_linux_nat_target): New.
5938 (hppa_linux_fetch_inferior_registers)
5939 (hppa_linux_store_inferior_registers): Refactor as methods of
5940 hppa_linux_nat_target.
5941 (_initialize_hppa_linux_nat): Adjust to C++ification.
5943 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
5944 (the_ia64_linux_nat_target): New.
5945 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
5946 (ia64_linux_stopped_data_address)
5947 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
5948 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
5949 ia64_linux_nat_target methods.
5950 (super_xfer_partial): Delete.
5951 (_initialize_ia64_linux_nat): Adjust to C++ification.
5953 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
5954 (the_m32r_linux_nat_target): New.
5955 (m32r_linux_fetch_inferior_registers)
5956 (m32r_linux_store_inferior_registers): Refactor as
5957 m32r_linux_nat_target methods.
5958 (_initialize_m32r_linux_nat): Adjust to C++ification.
5960 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
5961 (the_m68k_linux_nat_target): New.
5962 (m68k_linux_fetch_inferior_registers)
5963 (m68k_linux_store_inferior_registers): Refactor as
5964 m68k_linux_nat_target methods.
5965 (_initialize_m68k_linux_nat): Adjust to C++ification.
5967 * s390-linux-nat.c (s390_linux_nat_target): New class.
5968 (the_s390_linux_nat_target): New.
5969 (s390_linux_fetch_inferior_registers)
5970 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
5971 (s390_insert_watchpoint, s390_remove_watchpoint)
5972 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
5973 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
5974 (s390_auxv_parse, s390_read_description): Refactor as methods of
5975 s390_linux_nat_target.
5976 (_initialize_s390_nat): Adjust to C++ification.
5978 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
5979 (the_sparc_linux_nat_target): New.
5980 (_initialize_sparc_linux_nat): Adjust to C++ification.
5981 * sparc-nat.c (sparc_fetch_inferior_registers)
5982 (sparc_store_inferior_registers): Remove target_ops parameter.
5983 * sparc-nat.h (sparc_fetch_inferior_registers)
5984 (sparc_store_inferior_registers): Remove target_ops parameter.
5985 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
5986 (the_sparc64_linux_nat_target): New.
5987 (_initialize_sparc64_linux_nat): Adjust to C++ification.
5989 * spu-linux-nat.c (spu_linux_nat_target): New class.
5990 (the_spu_linux_nat_target): New.
5991 (spu_child_post_startup_inferior, spu_child_post_attach)
5992 (spu_child_wait, spu_fetch_inferior_registers)
5993 (spu_store_inferior_registers, spu_xfer_partial)
5994 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
5996 (_initialize_spu_nat): Adjust to C++ification.
5998 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
5999 (the_tilegx_linux_nat_target): New.
6000 (fetch_inferior_registers, store_inferior_registers):
6001 Refactor as methods.
6002 (_initialize_tile_linux_nat): Adjust to C++ification.
6004 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
6005 (the_xtensa_linux_nat_target): New.
6006 (xtensa_linux_fetch_inferior_registers)
6007 (xtensa_linux_store_inferior_registers): Refactor as
6008 xtensa_linux_nat_target methods.
6009 (_initialize_xtensa_linux_nat): Adjust to C++ification.
6011 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
6012 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
6013 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
6014 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
6015 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
6016 (fbsd_stopped_by_sw_breakpoint)
6017 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
6018 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
6019 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
6020 (fbsd_post_startup_inferior, fbsd_post_attach)
6021 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
6022 (fbsd_set_syscall_catchpoint)
6023 (super_xfer_partial, super_resume, super_wait)
6024 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
6025 (fbsd_handle_debug_trap): Remove target_ops parameter.
6026 (fbsd_nat_add_target): Delete.
6027 * fbsd-nat.h: Include "inf-ptrace.h".
6028 (fbsd_nat_add_target): Delete.
6029 (USE_SIGTRAP_SIGINFO): Define.
6030 (fbsd_nat_target): New class.
6032 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
6033 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
6034 (amd64bsd_target): Delete.
6035 * amd64-bsd-nat.h: New file.
6036 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
6038 (amd64_fbsd_nat_target): New class.
6039 (the_amd64_fbsd_nat_target): New.
6040 (amd64fbsd_read_description): Refactor as method of
6041 amd64_fbsd_nat_target.
6042 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6043 (_initialize_amd64fbsd_nat): Adjust to C++ification.
6044 * amd64-nat.h (amd64bsd_target): Delete function declaration.
6045 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
6046 (i386bsd_store_inferior_registers): Remove target_ops parameter.
6047 (i386bsd_target): Delete.
6048 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
6049 (i386bsd_fetch_inferior_registers)
6050 (i386bsd_store_inferior_registers): Declare.
6051 (i386_bsd_nat_target): New class.
6052 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
6053 (the_i386_fbsd_nat_target): New.
6054 (i386fbsd_resume, i386fbsd_read_description): Refactor as
6055 i386_fbsd_nat_target methods.
6056 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6057 (_initialize_i386fbsd_nat): Adjust to C++ification.
6058 * x86-bsd-nat.c (super_mourn_inferior): Delete.
6059 (x86bsd_mourn_inferior, x86bsd_target): Delete.
6060 (_initialize_x86_bsd_nat): Adjust to C++ification.
6061 * x86-bsd-nat.h: Include "x86-nat.h".
6062 (x86bsd_target): Delete declaration.
6063 (x86bsd_nat_target): New class.
6065 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
6066 (the_aarch64_fbsd_nat_target): New.
6067 (aarch64_fbsd_fetch_inferior_registers)
6068 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
6069 aarch64_fbsd_nat_target.
6070 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
6071 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
6072 (the_alpha_bsd_nat_target): New.
6073 (alphabsd_fetch_inferior_registers)
6074 (alphabsd_store_inferior_registers): Refactor as
6075 alpha_bsd_nat_target methods.
6076 (_initialize_alphabsd_nat): Refactor as methods of
6077 alpha_bsd_nat_target.
6078 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
6079 (the_amd64_nbsd_nat_target): New.
6080 (_initialize_amd64nbsd_nat): Adjust to C++ification.
6081 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
6082 (the_amd64_obsd_nat_target): New.
6083 (_initialize_amd64obsd_nat): Adjust to C++ification.
6084 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
6085 (the_arm_fbsd_nat_target): New.
6086 (arm_fbsd_fetch_inferior_registers)
6087 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
6088 (_initialize_arm_fbsd_nat): Refactor as methods of
6089 arm_fbsd_nat_target.
6090 (_initialize_arm_fbsd_nat): Adjust to C++ification.
6091 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
6092 (the_arm_netbsd_nat_target): New.
6093 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
6094 arm_netbsd_nat_target.
6095 (_initialize_arm_netbsd_nat): Adjust to C++ification.
6096 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
6097 (the_hppa_nbsd_nat_target): New.
6098 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
6099 hppa_nbsd_nat_target methods.
6100 (_initialize_hppanbsd_nat): Adjust to C++ification.
6101 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
6102 (the_hppa_obsd_nat_target): New.
6103 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
6104 methods of hppa_obsd_nat_target.
6105 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
6107 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
6108 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
6110 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
6111 (_initialize_i386obsd_nat): Use add_target.
6112 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
6113 (the_m68k_bsd_nat_target): New.
6114 (m68kbsd_fetch_inferior_registers)
6115 (m68kbsd_store_inferior_registers): Refactor as methods of
6116 m68k_bsd_nat_target.
6117 (_initialize_m68kbsd_nat): Adjust to C++ification.
6118 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
6119 (the_mips_fbsd_nat_target): New.
6120 (mips_fbsd_fetch_inferior_registers)
6121 (mips_fbsd_store_inferior_registers): Refactor as methods of
6122 mips_fbsd_nat_target.
6123 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
6125 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
6126 (the_mips_nbsd_nat_target): New.
6127 (mipsnbsd_fetch_inferior_registers)
6128 (mipsnbsd_store_inferior_registers): Refactor as methods of
6129 mips_nbsd_nat_target.
6130 (_initialize_mipsnbsd_nat): Adjust to C++ification.
6131 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
6132 (the_mips64_obsd_nat_target): New.
6133 (mips64obsd_fetch_inferior_registers)
6134 (mips64obsd_store_inferior_registers): Refactor as methods of
6135 mips64_obsd_nat_target.
6136 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
6138 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
6140 * nbsd-nat.h: Include "inf-ptrace.h".
6141 (nbsd_nat_target): New class.
6142 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
6143 (obsd_wait): Refactor as methods of obsd_nat_target.
6144 (obsd_add_target): Delete.
6145 * obsd-nat.h: Include "inf-ptrace.h".
6146 (obsd_nat_target): New class.
6147 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
6148 (the_ppc_fbsd_nat_target): New.
6149 (ppcfbsd_fetch_inferior_registers)
6150 (ppcfbsd_store_inferior_registers): Refactor as methods of
6151 ppc_fbsd_nat_target.
6152 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
6154 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
6155 (the_ppc_nbsd_nat_target): New.
6156 (ppcnbsd_fetch_inferior_registers)
6157 (ppcnbsd_store_inferior_registers): Refactor as methods of
6158 ppc_nbsd_nat_target.
6159 (_initialize_ppcnbsd_nat): Adjust to C++ification.
6160 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
6161 (the_ppc_obsd_nat_target): New.
6162 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
6163 methods of ppc_obsd_nat_target.
6164 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
6166 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
6167 (the_sh_nbsd_nat_target): New.
6168 (shnbsd_fetch_inferior_registers)
6169 (shnbsd_store_inferior_registers): Refactor as methods of
6171 (_initialize_shnbsd_nat): Adjust to C++ification.
6172 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
6173 (inf_ptrace_xfer_partial): Delete.
6174 (sparc_xfer_partial, sparc_target): Delete.
6175 * sparc-nat.h (sparc_fetch_inferior_registers)
6176 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
6177 (sparc_target): Delete function declaration.
6178 (sparc_target): New template class.
6179 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
6180 (_initialize_sparcnbsd_nat): Adjust to C++ification.
6181 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
6182 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
6184 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
6185 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
6186 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
6187 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
6189 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
6190 (the_vax_bsd_nat_target): New.
6191 (vaxbsd_fetch_inferior_registers)
6192 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
6194 (_initialize_vaxbsd_nat): Adjust to C++ification.
6196 * bsd-kvm.c (bsd_kvm_target): New class.
6197 (bsd_kvm_ops): Now a bsd_kvm_target.
6198 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
6199 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
6200 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
6202 (bsd_kvm_return_one): Delete.
6203 (bsd_kvm_add_target): Adjust to C++ification.
6205 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
6206 (nto_procfs_target_procfs): New classes.
6207 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
6208 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
6209 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
6210 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
6211 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
6212 (procfs_remove_hw_breakpoint, procfs_resume)
6213 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
6214 (procfs_kill_inferior, procfs_store_registers)
6215 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
6216 as methods of nto_procfs_target.
6217 (nto_procfs_ops): Now an nto_procfs_target_procfs.
6218 (nto_native_ops): Delete.
6219 (procfs_open, procfs_native_open): Delete.
6220 (nto_native_ops): Now an nto_procfs_target_native.
6221 (init_procfs_targets): Adjust to C++ification.
6222 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
6223 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
6224 Refactor as methods of nto_procfs_target.
6226 * go32-nat.c (go32_nat_target): New class.
6227 (the_go32_nat_target): New.
6228 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
6229 (go32_store_registers, go32_xfer_partial, go32_files_info)
6230 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
6231 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
6232 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
6233 (go32_pid_to_str): Refactor as methods of go32_nat_target.
6234 (go32_target): Delete.
6235 (_initialize_go32_nat): Adjust to C++ification.
6237 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
6238 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
6239 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
6240 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
6242 (gnu_target): Delete.
6243 * gnu-nat.h (gnu_target): Delete.
6244 (gnu_nat_target): New class.
6245 * i386-gnu-nat.c (gnu_base_target): New.
6246 (i386_gnu_nat_target): New class.
6247 (the_i386_gnu_nat_target): New.
6248 (_initialize_i386gnu_nat): Adjust to C++ification.
6250 2018-05-02 Pedro Alves <palves@redhat.com>
6252 * bfd-target.c (target_bfd_xclose): Rename to ...
6253 (target_bfd_close): ... this.
6254 (target_bfd_reopen): Adjust.
6255 * target.c (target_close): Remove references to to_xclose.
6256 * target.h (target_ops::to_xclose): Delete.
6257 (target_ops::to_close): Update comments.
6259 2018-05-02 Pedro Alves <palves@redhat.com>
6261 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
6263 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
6264 * inf-ptrace.c (inf_ptrace_register_u_offset)
6265 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6266 (inf_ptrace_store_register, inf_ptrace_store_registers)
6267 (inf_ptrace_trad_target): Move to ...
6268 * linux-nat-trad.c: ... this new file.
6269 * linux-nat-trad.h: New file.
6270 * linux-nat.c (linux_target_install_ops): Make extern.
6271 (linux_trad_target): Delete.
6272 * linux-nat.h (linux_trad_target): Delete declaration.
6273 (linux_target_install_ops): Declare.
6274 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
6277 2018-05-02 Pedro Alves <palves@redhat.com>
6279 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6280 procfs_target/add_target here.
6281 * procfs.c (procfs_target): Make static.
6282 (_initialize_procfs): Call add_target here.
6283 * procfs.h (struct target_ops): Remove forward declaration.
6284 (procfs_target): Remove declaration.
6285 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
6287 2018-05-02 Pedro Alves <palves@redhat.com>
6289 * procfs.c (procfs_stopped_by_watchpoint)
6290 (procfs_insert_watchpoint, procfs_remove_watchpoint)
6291 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
6293 (procfs_use_watchpoints): Delete, move contents...
6294 (procfs_target): ... here.
6295 * procfs.h (procfs_use_watchpoints): Delete declaration.
6296 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6297 procfs_use_watchpoints.
6298 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
6299 procfs_use_watchpoints.
6301 2018-05-02 Tom Tromey <tom@tromey.com>
6304 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
6305 and var_zuinteger_unlimited.
6306 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
6307 and PARAM_ZUINTEGER_UNLIMITED.
6308 (set_parameter_value): Handle var_zuinteger and
6309 var_zuinteger_unlimited.
6310 (add_setshow_generic): Likewise.
6311 (parmpy_init): Likewise.
6313 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
6316 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
6317 pointer is not null before dereferencing it.
6319 2018-04-30 Tom Tromey <tom@tromey.com>
6321 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
6324 2018-04-30 Tom Tromey <tom@tromey.com>
6326 * breakpoint.c (mention): Remove use of is_mi_like_p.
6327 (print_mention_ranged_breakpoint): Likewise.
6328 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
6331 2018-04-30 Tom Tromey <tom@tromey.com>
6333 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
6335 2018-04-30 Tom Tromey <tom@tromey.com>
6337 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
6338 (info_spu_event_command): Remove some uses of is_mi_like_p.
6340 2018-04-30 Tom Tromey <tom@tromey.com>
6342 * python/py-framefilter.c (py_print_single_arg)
6343 (enumerate_locals, py_print_args, py_print_frame): Remove some
6344 uses of is_mi_like_p.
6346 2018-04-30 Tom Tromey <tom@tromey.com>
6349 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
6350 * ui-out.h (ui_out::is_mi_like_p): Now const.
6351 (ui_out::do_is_mi_like_p): Now const.
6352 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
6354 2018-04-30 Tom Tromey <tom@tromey.com>
6356 * varobj.c (varobj_set_visualizer): Use new_reference.
6357 * python/python.c (gdbpy_decode_line): Use new_reference.
6358 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
6361 2018-04-30 Tom Tromey <tom@tromey.com>
6363 * varobj.c (install_new_value): Use new_reference.
6364 * value.h (value_incref): Return void. Swap intro comment with
6366 * value.c (set_value_parent): Use new_reference.
6367 (value_incref): Return void. Update intro comment.
6368 (release_value): Use new_reference.
6369 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
6371 2018-04-30 Tom Tromey <tom@tromey.com>
6373 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
6374 * gdb_bfd.h (new_bfd_ref): Remove.
6375 (gdb_bfd_open): Update comment.
6376 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
6377 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
6378 (gdb_bfd_fdopenr): Use new_reference.
6379 * exec.c (exec_file_attach): Use new_reference.
6381 2018-04-30 Tom Tromey <tom@tromey.com>
6383 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
6386 2018-04-30 Tom Tromey <tom@tromey.com>
6388 * jit.c (jit_read_code_entry): Use type_align.
6389 * i386-tdep.c (i386_gdbarch_init): Don't call
6390 set_gdbarch_long_long_align_bit.
6391 * gdbarch.sh: Remove long_long_align_bit.
6392 * gdbarch.c, gdbarch.h: Rebuild.
6393 * arc-tdep.c (arc_type_align): New function.
6394 (arc_gdbarch_init): Use arc_type_align. Don't call
6395 set_gdbarch_long_long_align_bit.
6397 2018-04-30 Tom Tromey <tom@tromey.com>
6399 * rust-lang.c (rust_type_alignment): Remove.
6400 (rust_composite_type): Use type_align.
6402 2018-04-30 Tom Tromey <tom@tromey.com>
6404 * NEWS: Mention Type.align.
6405 * python/py-type.c (typy_get_alignof): New function.
6406 (type_object_getset): Add "alignof".
6408 2018-04-30 Tom Tromey <tom@tromey.com>
6412 * std-operator.def (UNOP_ALIGNOF): New operator.
6413 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
6415 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
6416 * c-lang.c (c_op_print_tab): Add alignof.
6417 * c-exp.y (ALIGNOF): New token.
6418 (exp): Add "ALIGNOF" production.
6419 (ident_tokens): Add _Alignof and alignof.
6421 2018-04-30 Tom Tromey <tom@tromey.com>
6423 * i386-tdep.c (i386_type_align): New function.
6424 (i386_gdbarch_init): Update.
6425 * gdbarch.sh (type_align): New method.
6426 * gdbarch.c, gdbarch.h: Rebuild.
6427 * arch-utils.h (default_type_align): Declare.
6428 * arch-utils.c (default_type_align): New function.
6429 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
6430 (struct type) <align_log2>: New field.
6431 <instance_flags>: Now a bitfield.
6432 (TYPE_RAW_ALIGN): New macro.
6433 (type_align, type_raw_align, set_type_align): Declare.
6434 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
6436 * dwarf2read.c (quirk_rust_enum): Set type alignment.
6437 (get_alignment, maybe_set_alignment): New functions.
6438 (read_structure_type, read_enumeration_type, read_array_type)
6439 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
6440 (read_subrange_type, read_base_type): Set type alignment.
6442 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
6444 * dwarf2read.c (read_index_from_section): Use bool.
6446 2018-04-29 Fabian Groffen <grobian@gentoo.org>
6449 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
6452 2018-04-29 John Reiser <jreiser@BitWagon.com>
6455 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
6456 last step, and do it atomically.
6458 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
6460 * compile/compile-c-types.c (convert_int, convert_float):
6463 2018-04-27 Tom Tromey <tom@tromey.com>
6466 * rust-lang.c (rust_inclusive_range_type_p): New function.
6467 (rust_range): Handle inclusive ranges.
6468 (rust_compute_range): Likewise.
6469 * rust-exp.y (struct rust_op) <inclusive>: New field.
6470 (DOTDOTEQ): New constant.
6471 (range_expr): Add "..=" productions.
6472 (operator_tokens): Add "..=" token.
6473 (ast_range): Add "inclusive" parameter.
6474 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
6476 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
6478 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
6479 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
6481 * expprint.c (print_subexp_standard): Handle new bounds values.
6482 (dump_subexp_body_standard): Likewise.
6484 2018-04-27 Tom Tromey <tom@tromey.com>
6486 * configure: Rebuild.
6487 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
6488 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
6490 (class symbol_needs_eval_context): Likewise.
6491 * dwarf2read.c (mock_mapped_index::symbol_name_count)
6492 (mock_mapped_index::symbol_name_at): Use "override". Remove
6494 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
6496 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
6497 * aarch64-tdep.c (instruction_reader::read): Use "override".
6498 (instruction_reader_test::read): Likewise.
6499 * arm-tdep.c (instruction_reader::read): Use "override".
6500 (instruction_reader_thumb::read): Likewise.
6502 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
6505 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
6506 instead of remote_send.
6507 (remote_send): Remove.
6509 2018-04-26 Pedro Alves <palves@redhat.com>
6511 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
6512 find_function_start_sal instead of find_pc_line.
6514 2018-04-26 Pedro Alves <palves@redhat.com>
6516 * breakpoint.c (set_breakpoint_location_function): Handle
6518 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
6519 * elfread.c (elf_symtab_read): Give data symbols with
6520 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
6521 (elf_rel_plt_read): Update comment.
6522 * linespec.c (convert_linespec_to_sals): Handle
6524 (minsym_found): Handle mst_data_gnu_ifunc.
6525 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
6526 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
6527 * parse.c (find_minsym_type_and_address): Handle
6529 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
6530 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
6531 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
6533 <mst_data_gnu_ifunc>: New enumerator.
6535 2018-04-26 Pedro Alves <palves@redhat.com>
6537 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
6538 (lookup_minimal_symbol_by_pc_section): ... this. Replace
6539 'want_trampoline' parameter by a lookup_msym_prefer parameter.
6541 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
6542 (lookup_minimal_symbol_by_pc): Adjust.
6543 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
6544 (lookup_solib_trampoline_symbol_by_pc): Adjust.
6545 * minsyms.h (lookup_msym_prefer): New enum.
6546 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6547 parameter by a lookup_msym_prefer parameter.
6549 2018-04-26 Pedro Alves <palves@redhat.com>
6551 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
6552 ends in "@plt" instead of looking at the symbol's section.
6554 2018-04-26 Pedro Alves <palves@redhat.com>
6556 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
6558 (find_pc_partial_function_gnu_ifunc): Rename to ...
6559 (find_pc_partial_function): ... this, and remove references to
6561 (find_pc_partial_function): Delete old implementation.
6562 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
6564 2018-04-26 Pedro Alves <palves@redhat.com>
6566 * linespec.c (struct bound_minimal_symbol_search_key): New.
6567 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
6568 skip first line if we found a GNU ifunc minimal symbol by name.
6569 (compare_msymbols): Change parameters to work with a destructured
6571 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
6574 2018-04-26 Pedro Alves <palves@redhat.com>
6576 * breakpoint.c (set_breakpoint_location_function): Don't resolve
6577 ifunc targets here. Instead, if we have an ifunc minsym, use its
6579 (add_location_to_breakpoint): Store the minsym and the objfile in
6580 the breakpoint location.
6581 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
6582 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
6583 Record the minsym in the sal.
6584 * symtab.h (symtab_and_line) <msymbol>: New field.
6586 2018-04-26 Pedro Alves <palves@redhat.com>
6588 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
6589 unless we actually resolved the ifunc.
6591 2018-04-26 Pedro Alves <palves@redhat.com>
6593 * c-exp.y (variable production): Prefer ifunc minsyms over
6594 regular function symbols.
6595 * symtab.c (find_gnu_ifunc): New function.
6596 * minsyms.h (lookup_msym_prefer): New enum.
6597 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6598 parameter by a lookup_msym_prefer parameter.
6599 * symtab.h (find_gnu_ifunc): New declaration.
6601 2018-04-26 Pedro Alves <palves@redhat.com>
6603 * blockframe.c (find_gnu_ifunc_target_type): New function.
6604 (find_function_type): New.
6605 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
6606 return a value with a memory address.
6607 (eval_call): For calls to GNU ifunc functions, try to find the
6608 type of the target function from the type that the resolver
6610 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
6612 * infcall.c (find_function_return_type): Delete.
6613 (find_function_addr): Add 'function_type' parameter. For calls to
6614 GNU ifunc functions, try to find the type of the target function
6615 from the type that the resolver returns, and return it via
6617 (call_function_by_hand_dummy): Adjust to use the function type
6618 returned by find_function_addr.
6619 (find_function_addr): Add 'function_type' parameter and move
6621 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
6624 2018-04-26 Pedro Alves <palves@redhat.com>
6626 * c-exp.y (variable production): Skip finding an alias for ifunc
6629 2018-04-26 Pedro Alves <palves@redhat.com>
6631 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
6633 2018-04-25 Pedro Alves <palves@redhat.com>
6635 * infcmd.c (kill_command): Print the pid as string, not the whole
6636 thread's ptid. Add comment. s/has been killed/killed/ in output
6638 * remote.c (remote_detach_1): Print the pid as string, not the
6639 whole thread's ptid.
6641 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6642 Sergio Durigan Junior <sergiodj@redhat.com>
6643 Pedro Alves <palves@redhat.com>
6645 * infcmd.c (kill_command): Print message when inferior has
6647 * inferior.c (print_inferior_events): Remove 'static'. Set as
6649 (add_inferior): Improve message printed when
6650 'print_inferior_events' is on.
6651 (exit_inferior): Remove message printed when
6652 'print_inferior_events' is on.
6653 (detach_inferior): Improve message printed when
6654 'print_inferior_events' is on.
6655 (initialize_inferiors): Use 'add_inferior_silent' to set
6656 'current_inferior_'.
6657 * inferior.h (print_inferior_events): Declare here as
6659 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
6660 '[Detaching...]' messages when 'print_inferior_events' is on.
6661 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
6662 as prefix/suffix for messages. Remove periods. Fix erroneous
6663 'Detaching after fork from child...', replace it by '... from
6665 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
6666 prefix/suffix when printing 'Detaching...' messages. Print
6667 them when 'print_inferior_events' is on.
6668 * remote.c (remote_detach_1): Print message when detaching
6669 from inferior and '!is_fork_parent'.
6671 2018-04-24 Tom Tromey <tom@tromey.com>
6673 * cli-out.h: Reindent.
6675 2018-04-24 Tom Tromey <tom@tromey.com>
6677 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
6678 (cli_ui_out::do_field_string): Use fputs_filtered.
6679 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
6681 2018-04-23 Tom Tromey <tom@tromey.com>
6683 * guile/scm-frame.c (gdbscm_frame_read_var): Use
6684 gdb::unique_xmalloc_ptr.
6686 2018-04-23 Tom Tromey <tom@tromey.com>
6688 * configure: Rebuild.
6690 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
6693 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
6694 prepare_for_testing. Set normal_bp to r_debug_state if target
6697 2018-04-21 Pedro Alves <palves@redhat.com>
6698 Rajendra SY <rajendra.sy@gmail.com>
6700 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
6701 * remote.c (extended_remote_attach): In all-stop mode, mark the
6702 thread as executing.
6704 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6706 * thread.c (thread_apply_all_command): Fix comment.
6707 (thread_command): Fix comment.
6709 2018-04-10 Alan Hayward <alan.hayward@arm.com>
6711 * common/tdesc.h (tdesc_create_feature): Remove xml filename
6713 * features/aarch64-core.c (create_feature_aarch64_core):
6715 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
6717 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
6719 * features/i386/32bit-avx512.c
6720 (create_feature_i386_32bit_avx512): Likewise.
6721 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
6723 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
6725 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
6727 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
6729 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
6731 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
6733 * features/i386/64bit-avx512.c
6734 (create_feature_i386_64bit_avx512): Likewise.
6735 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
6737 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
6739 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
6741 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
6743 * features/i386/64bit-segments.c
6744 (create_feature_i386_64bit_segments): Likewise.
6745 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
6747 * features/i386/x32-core.c
6748 (create_feature_i386_x32_core): Likewise.
6749 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
6750 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
6751 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
6752 * target-descriptions.c: In generated code, don't pass xml
6755 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6757 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
6758 (print_xml_feature::visit_post): Likewise.
6759 (print_xml_feature::visit): Likewise.
6760 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
6761 (print_xml_feature): Add new class.
6762 * regformats/regdat.sh: Null xmltarget on feature targets.
6763 * target-descriptions.c (struct target_desc): Add xmltarget.
6764 (maintenance_check_tdesc_xml_convert): Add unittest function.
6765 (tdesc_get_features_xml): Add function to get xml.
6766 (maintenance_check_xml_descriptions): Test xml generation.
6767 * xml-tdesc.c (string_read_description_xml): Add function.
6768 * xml-tdesc.h (string_read_description_xml): Add declaration.
6770 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6772 * features/Makefile: Add feature marker to targets with new style
6773 target descriptions.
6774 * regformats/aarch64.dat: Regenerate.
6775 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
6776 * regformats/i386/amd64-avx-linux.dat: Likewise.
6777 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
6778 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
6779 * regformats/i386/amd64-linux.dat: Likewise.
6780 * regformats/i386/amd64-mpx-linux.dat: Likewise.
6781 * regformats/i386/amd64.dat: Likewise.
6782 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
6783 * regformats/i386/i386-avx-linux.dat: Likewise.
6784 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
6785 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
6786 * regformats/i386/i386-linux.dat: Likewise.
6787 * regformats/i386/i386-mmx-linux.dat: Likewise.
6788 * regformats/i386/i386-mpx-linux.dat: Likewise.
6789 * regformats/i386/i386.dat: Likewise.
6790 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
6791 * regformats/i386/x32-avx-linux.dat: Likewise.
6792 * regformats/i386/x32-linux.dat: Likewise.
6793 * regformats/tic6x-c62x-linux.dat: Likewise.
6794 * regformats/tic6x-c64x-linux.dat: Likewise.
6795 * regformats/tic6x-c64xp-linux.dat: Likewise.
6796 * regformats/regdat.sh: Parse feature marker.
6798 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6800 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
6801 (tdesc_osabi_name): Likewise.
6802 * target-descriptions.c (tdesc_architecture_name): Add new
6804 (tdesc_osabi_name): Likewise.
6806 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6808 * common/tdesc.c (tdesc_predefined_type): Move to here.
6809 (tdesc_named_type): Likewise.
6810 (tdesc_create_vector): Likewise.
6811 (tdesc_create_struct): Likewise.
6812 (tdesc_set_struct_size): Likewise.
6813 (tdesc_create_union): Likewise.
6814 (tdesc_create_flags): Likewise.
6815 (tdesc_create_enum): Likewise.
6816 (tdesc_add_field): Likewise.
6817 (tdesc_add_typed_bitfield): Likewise.
6818 (tdesc_add_bitfield): Likewise.
6819 (tdesc_add_flag): Likewise.
6820 (tdesc_add_enum_value): Likewise.
6821 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
6822 (struct tdesc_type_vector): Likewise.
6823 (struct tdesc_type_field): Likewise.
6824 (struct tdesc_type_with_fields): Likewise.
6825 (tdesc_create_enum): Add declaration.
6826 (tdesc_add_typed_bitfield): Likewise.
6827 (tdesc_add_enum_value): Likewise.
6828 * target-descriptions.c (tdesc_type_field): Move from here.
6829 (tdesc_type_builtin): Likewise.
6830 (tdesc_type_vector): Likewise.
6831 (tdesc_type_with_fields): Likewise.
6832 (tdesc_predefined_types): Likewise.
6833 (tdesc_named_type): Likewise.
6834 (tdesc_create_vector): Likewise.
6835 (tdesc_create_struct): Likewise.
6836 (tdesc_set_struct_size): Likewise.
6837 (tdesc_create_union): Likewise.
6838 (tdesc_create_flags): Likewise.
6839 (tdesc_create_enum): Likewise.
6840 (tdesc_add_field): Likewise.
6841 (tdesc_add_typed_bitfield): Likewise.
6842 (tdesc_add_bitfield): Likewise.
6843 (tdesc_add_flag): Likewise.
6844 (tdesc_add_enum_value): Likewise.
6845 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
6846 (tdesc_add_typed_bitfield): Likewise.
6847 (tdesc_add_enum_value): Likewise.
6849 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6851 * common/tdesc.c (tdesc_feature::accept): Move to here.
6852 (tdesc_feature::operator==): Likewise.
6853 (tdesc_create_reg): Likewise.
6854 * common/tdesc.h (tdesc_type_kind): Likewise.
6855 (struct tdesc_type): Likewise.
6856 (struct tdesc_feature): Likewise.
6857 * regformats/regdat.sh: Create a feature.
6858 * target-descriptions.c (tdesc_type_kind): Move from here.
6859 (tdesc_type): Likewise.
6860 (tdesc_type_up): Likewise.
6861 (tdesc_feature): Likewise.
6862 (tdesc_create_reg): Likewise.
6864 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6866 * Makefile.in: Add arch/tdesc.c
6867 * common/tdesc.c: New file.
6868 * common/tdesc.h (tdesc_element_visitor): Move to here.
6869 (tdesc_element): Likewise.
6870 (tdesc_reg): Likewise.
6871 (tdesc_reg_up): Likewise.
6872 * regformats/regdef.h (reg): Add offset to constructors.
6873 * target-descriptions.c (tdesc_element_visitor): Move from here.
6874 (tdesc_element): Likewise.
6875 (tdesc_reg): Likewise.
6876 (tdesc_reg_up): Likewise.
6878 2018-04-17 Tom Tromey <tom@tromey.com>
6880 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
6883 2018-04-17 Tom Tromey <tom@tromey.com>
6885 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
6887 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
6889 * symtab.c (print_symbol_info): Skip printing filename and line
6890 number when `last' is NULL.
6891 (symtab_symbol_info): Use empty string instead of NULL for first
6892 invocation of print_symbol_info.
6893 (rbreak_command): Pass NULL to `last' parameter of
6896 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
6898 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
6901 2018-04-16 Pedro Alves <palves@redhat.com>
6903 * MAINTAINERS (sh): Remove.
6904 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
6905 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
6906 (ALLDEPFILES): Remove sh64-tdep.c.
6907 * NEWS: Mentions that support for SH-5/SH64 is removed.
6908 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
6909 (sh*-*-openbsd*): Ditto.
6910 (sh64-*-elf*): Remove.
6912 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
6913 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
6914 * sh-tdep.c: No longer include "sh64-tdep.h".
6915 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
6916 * sh64-tdep.c, sh64-tdep.h: Remove files.
6918 2018-04-16 Pedro Alves <palves@redhat.com>
6920 * MAINTAINERS: Remove m88k.
6921 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
6922 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
6923 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
6924 * NEWS: Mention that support for m88k was removed.
6925 * configure.host (m88*-*-*): Remove support.
6926 * configure.nat (m88k-*-*): Remove support.
6927 * configure.tgt (m88*-*-openbsd*): Remove.
6928 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
6930 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
6932 * configure.tgt (x86_tobjs): New variable.
6933 (amd64_tobjs, i386_tobjs): Use it.
6935 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6937 * symtab.c (print_symbol_info): Precede the symbol definition by
6938 the line number when available.
6939 * NEWS: Advertise this enhancement.
6941 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6943 * NEWS (New options): announce set/show record btrace cpu.
6944 * btrace.c: Include record-btrace.h.
6945 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
6946 the vendor is unknown.
6947 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
6948 Maybe overwrite the btrace configuration's cpu.
6949 (btrace_compute_ftrace): Add cpu parameter. Update callers.
6950 (btrace_fetch): Add cpu parameter. Update callers.
6951 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
6952 Maybe overwrite the btrace configuration's cpu. Skip enabling
6953 errata workarounds if the vendor is unknown.
6954 * python/py-record-btrace.c: Include record-btrace.h.
6955 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
6956 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
6957 * record-btrace.c (record_btrace_cpu_state_kind): New.
6958 (record_btrace_cpu): New.
6959 (set_record_btrace_cpu_cmdlist): New.
6960 (record_btrace_get_cpu): New.
6961 (require_btrace_thread, record_btrace_info)
6962 (record_btrace_resume_thread): Call record_btrace_get_cpu.
6963 (cmd_set_record_btrace_cpu_none): New.
6964 (cmd_set_record_btrace_cpu_auto): New.
6965 (cmd_set_record_btrace_cpu): New.
6966 (cmd_show_record_btrace_cpu): New.
6967 (_initialize_record_btrace): Initialize set/show record btrace cpu
6969 * record-btrace.h (record_btrace_get_cpu): New.
6971 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6973 * record.c (set_record_command): Fix typo in message.
6975 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6977 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
6979 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6981 * infrun.c (process_event_stop_test): Call
6982 gdbarch_in_indirect_branch_thunk.
6983 * gdbarch.sh (in_indirect_branch_thunk): New.
6984 * gdbarch.c: Regenerated.
6985 * gdbarch.h: Regenerated.
6988 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
6989 (HFILES_NO_SRCDIR): Add x86-tdep.h.
6990 (ALLDEPFILES): Add x86-tdep.c.
6991 * arch-utils.h (default_in_indirect_branch_thunk): New.
6992 * arch-utils.c (default_in_indirect_branch_thunk): New.
6993 * i386-tdep: Include x86-tdep.h.
6994 (i386_in_indirect_branch_thunk): New.
6995 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
6997 * amd64-tdep: Include x86-tdep.h.
6998 (amd64_in_indirect_branch_thunk): New.
6999 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
7001 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7004 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
7005 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
7006 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
7009 2018-04-12 Tom Tromey <tom@tromey.com>
7011 * rust-lang.c (rust_print_struct_def): Remove univariant code.
7012 (rust_evaluate_subexp): Likewise.
7014 2018-04-12 Pedro Alves <palves@redhat.com>
7016 * procfs.c (procfs_detach): Make forward declaration's prototype
7017 match definition's protototype.
7018 (proc_get_LDT_entry): Remove stale do_cleanups call.
7020 2018-04-12 Pedro Alves <palves@redhat.com>
7022 * target.h (target_ops::to_has_exited): Delete.
7023 (target_has_exited): Delete.
7024 * target-delegates.c: Regenerate.
7026 2018-04-11 Pedro Alves <palves@redhat.com>
7028 * target.c (fileio_fh_t::t): Add comment.
7029 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7030 (target_fileio_close): Handle a NULL target.
7031 (invalidate_fileio_fh): New.
7032 (target_close): Call it.
7033 * remote.c (remote_hostio_send_command): No longer check whether
7034 remote_desc is open.
7036 2018-04-11 Pedro Alves <palves@redhat.com>
7038 * target.c (fileio_fh_t): Make it a named struct instead of a
7040 (fileio_fh_t::is_closed): New method.
7041 (DEF_VEC_O (fileio_fh_t)): Remove.
7042 (fileio_fhandles): Now a std::vector.
7043 (is_closed_fileio_fh): Delete.
7044 (acquire_fileio_fd): Adjust. Rename parameters.
7045 (release_fileio_fd): Adjust.
7046 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
7047 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7048 (target_fileio_close): Adjust.
7050 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
7052 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
7055 2018-04-10 Pedro Alves <palves@redhat.com>
7057 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
7058 (scoped_finish_thread_state): New class.
7059 * infcmd.c (run_command_1): Use it instead of finish_thread_state
7061 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
7062 (fetch_inferior_event, normal_stop): Likewise.
7063 * thread.c (finish_thread_state_cleanup): Delete.
7065 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7066 Pedro Alves <palves@redhat.com>
7068 * value.c: Include "selftest.h" and "common/array-view.h".
7069 (struct range) <operator ==>: New.
7070 (test_ranges_contain): New.
7071 (check_ranges_vector): New.
7072 (test_insert_into_bit_range_vector): New.
7073 (_initialize_values): Register selftests.
7074 * common/array-view.h (operator==, operator!=): New.
7076 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7078 * common/gdb_vecs.h (unordered_remove): Add overload that takes
7080 * inline-frame.c: Include <algorithm>.
7081 (struct inline_state): Add constructor.
7082 (inline_state_s): Remove.
7083 (DEF_VEC_O(inline_state_s)): Remove.
7084 (inline_states): Change type to std::vector.
7085 (find_inline_frame_state): Adjust to std::vector.
7086 (allocate_inline_frame_state): Remove.
7087 (clear_inline_frame_state): Adjust to std::vector.
7088 (skip_inline_frames): Adjust to std::vector.
7090 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7092 * tracepoint.h (struct trace_state_variable): Add constructor.
7093 <name>: Change type to std::string.
7094 * tracepoint.c (tsv_s): Remove.
7095 (DEF_VEC_O(tsv_s)): Remove.
7096 (tvariables): Change to std::vector.
7097 (create_trace_state_variable): Adjust to std::vector.
7098 (find_trace_state_variable): Likewise.
7099 (find_trace_state_variable_by_number): Likewise.
7100 (delete_trace_state_variable): Likewise.
7101 (trace_variable_command): Adjust to std::string.
7102 (delete_trace_variable_command): Likewise.
7103 (tvariables_info_1): Adjust to std::vector.
7104 (save_trace_state_variables): Likewise.
7105 (start_tracing): Likewise.
7106 (merge_uploaded_trace_state_variables): Adjust to std::vector
7108 * target.h (struct target_ops)
7109 <to_download_trace_state_variable>: Pass reference to
7110 trace_state_variable.
7111 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
7112 * target-delegates.c: Re-generate.
7113 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
7114 (mi_tsv_deleted): Likewise.
7115 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
7116 * remote.c (remote_download_trace_state_variable): Change
7117 pointer to reference and adjust.
7118 * make-target-delegates (parse_argtypes): Handle references.
7119 (write_function_header): Likewise.
7120 (munge_type): Likewise.
7122 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7124 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7125 string_view-selftests.c.
7126 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
7128 * unittests/basic_string_view/cons/char/1.cc: Likewise.
7129 * unittests/basic_string_view/cons/char/2.cc: Likewise.
7130 * unittests/basic_string_view/cons/char/3.cc: Likewise.
7131 * unittests/basic_string_view/element_access/char/1.cc:
7133 * unittests/basic_string_view/element_access/char/empty.cc:
7135 * unittests/basic_string_view/element_access/char/front_back.cc:
7137 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
7138 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
7140 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
7142 * unittests/basic_string_view/modifiers/swap/char/1.cc:
7144 * unittests/basic_string_view/operations/compare/char/1.cc:
7146 * unittests/basic_string_view/operations/compare/char/13650.cc:
7148 * unittests/basic_string_view/operations/copy/char/1.cc:
7150 * unittests/basic_string_view/operations/data/char/1.cc:
7152 * unittests/basic_string_view/operations/find/char/1.cc:
7154 * unittests/basic_string_view/operations/find/char/2.cc:
7156 * unittests/basic_string_view/operations/find/char/3.cc:
7158 * unittests/basic_string_view/operations/find/char/4.cc:
7160 * unittests/basic_string_view/operations/rfind/char/1.cc:
7162 * unittests/basic_string_view/operations/rfind/char/2.cc:
7164 * unittests/basic_string_view/operations/rfind/char/3.cc:
7166 * unittests/basic_string_view/operations/substr/char/1.cc:
7168 * unittests/basic_string_view/operators/char/2.cc: Likewise.
7169 * unittests/string_view-selftests.c: New file.
7171 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7173 * unittests/basic_string_view/capacity/1.cc: New file.
7174 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
7175 * unittests/basic_string_view/cons/char/1.cc: New file.
7176 * unittests/basic_string_view/cons/char/2.cc: New file.
7177 * unittests/basic_string_view/cons/char/3.cc: New file.
7178 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
7179 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
7180 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
7181 * unittests/basic_string_view/element_access/char/1.cc: New file.
7182 * unittests/basic_string_view/element_access/char/2.cc: New file.
7183 * unittests/basic_string_view/element_access/char/empty.cc: New file.
7184 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
7185 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
7186 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
7187 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
7188 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
7189 * unittests/basic_string_view/include.cc: New file.
7190 * unittests/basic_string_view/inserters/char/1.cc: New file.
7191 * unittests/basic_string_view/inserters/char/2.cc: New file.
7192 * unittests/basic_string_view/inserters/char/3.cc: New file.
7193 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
7194 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
7195 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
7196 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
7197 * unittests/basic_string_view/literals/types.cc: New file.
7198 * unittests/basic_string_view/literals/values.cc: New file.
7199 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
7200 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
7201 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
7202 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
7203 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
7204 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
7205 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
7206 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
7207 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
7208 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
7209 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
7210 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
7211 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
7212 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
7213 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
7214 * unittests/basic_string_view/operations/data/char/1.cc: New file.
7215 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
7216 * unittests/basic_string_view/operations/find/char/1.cc: New file.
7217 * unittests/basic_string_view/operations/find/char/2.cc: New file.
7218 * unittests/basic_string_view/operations/find/char/3.cc: New file.
7219 * unittests/basic_string_view/operations/find/char/4.cc: New file.
7220 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
7221 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
7222 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
7223 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
7224 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
7225 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
7226 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
7227 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
7228 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
7229 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
7230 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
7231 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
7232 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
7233 * unittests/basic_string_view/operators/char/2.cc: New file.
7234 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
7235 * unittests/basic_string_view/range_access/char/1.cc: New file.
7236 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
7237 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
7238 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
7239 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
7240 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
7241 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
7242 * unittests/basic_string_view/requirements/typedefs.cc: New file.
7243 * unittests/basic_string_view/typedefs.cc: New file.
7244 * unittests/basic_string_view/types/1.cc: New file.
7246 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7248 * common/gdb_string_view.h: Remove libstdc++ implementation
7249 details, adjust to gdb reality.
7250 * common/gdb_string_view.tcc: Likewise.
7251 * cli/cli-script.c (struct string_view): Remove.
7252 (user_args) <m_args>: Change element type to gdb::string_view.
7253 (user_args::insert_args): Adjust.
7255 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7257 * common/gdb_string_view.h: New file.
7258 * common/gdb_string_view.tcc: New file.
7260 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7262 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
7263 * configure: Re-generate.
7265 2018-04-09 Pedro Alves <palves@redhat.com>
7267 * gdbarch.sh: Include "observable.h" instead of "observer.h".
7268 (set_target_gdbarch): Call
7269 gdb::observers::architecture_changed.notify instead of
7270 observer_notify_architecture_changed.
7272 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7274 * tracepoint.c (struct current_traceframe_cleanup): Remove.
7275 (do_restore_current_traceframe_cleanup): Remove.
7276 (restore_current_traceframe_cleanup_dtor): Remove.
7277 (make_cleanup_restore_current_traceframe): Remove.
7278 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
7280 * tracepoint.h (struct scoped_restore_current_traceframe): New.
7281 * infrun.c (fetch_inferior_event): Use
7282 scoped_restore_current_traceframe.
7284 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7286 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
7288 <n_allocated_type_units>: Remove.
7289 <all_type_units>: Change to std::vector.
7290 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7291 to std::vector change.
7292 (dwarf2_per_objfile::get_cutu): Likewise.
7293 (dwarf2_per_objfile::get_tu): Likewise.
7294 (create_signatured_type_table_from_index): Likewise.
7295 (create_signatured_type_table_from_debug_names): Likewise.
7296 (dw2_symtab_iter_next): Likewise.
7297 (dw2_print_stats): Likewise.
7298 (dw2_expand_all_symtabs): Likewise.
7299 (dw2_expand_marked_cus): Likewise.
7300 (dw2_debug_names_iterator::next): Likewise.
7301 (dwarf2_initialize_objfile): Likewise.
7302 (add_signatured_type_cu_to_table): Likewise.
7303 (create_all_type_units): Likewise.
7304 (add_type_unit): Likewise.
7305 (struct tu_abbrev_offset): Add constructor.
7306 (build_type_psymtabs_1): Adjust to std::vector change.
7307 (print_tu_stats): Likewise.
7308 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7309 (write_debug_names): Likewise.
7311 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7313 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
7314 Make an std::vector.
7315 <n_comp_units>: Remove.
7316 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7317 to std::vector change.
7318 (dwarf2_per_objfile::get_cutu): Likewise.
7319 (dwarf2_per_objfile::get_cu): Likewise.
7320 (create_cus_from_index): Likewise.
7321 (create_addrmap_from_index): Likewise.
7322 (create_addrmap_from_aranges): Likewise.
7323 (dwarf2_read_index): Likewise.
7324 (dw2_find_last_source_symtab): Likewise.
7325 (dw2_map_symtabs_matching_filename): Likewise.
7326 (dw2_symtab_iter_next): Likewise.
7327 (dw2_print_stats): Likewise.
7328 (dw2_expand_all_symtabs): Likewise.
7329 (dw2_expand_symtabs_with_fullname): Likewise.
7330 (dw2_expand_marked_cus): Likewise.
7331 (dw2_map_symbol_filenames): Likewise.
7332 (create_cus_from_debug_names): Likewise.
7333 (dwarf2_read_debug_names): Likewise.
7334 (dw2_debug_names_iterator::next): Likewise.
7335 (dwarf2_initialize_objfile): Likewise.
7336 (set_partial_user): Likewise.
7337 (dwarf2_build_psymtabs_hard): Likewise.
7338 (read_comp_units_from_section): Remove arguments, adjust to
7340 (create_all_comp_units): Adjust to std::vector and
7341 read_comp_units_from_section changes.
7342 (dwarf2_find_containing_comp_unit): Adjust to std::vector
7344 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7345 (psyms_seen_size): Likewise.
7346 (write_gdbindex): Likewise.
7347 (write_debug_names): Likewise.
7349 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7351 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
7352 with dwarf2_per_objfile.
7353 (create_cus_from_index): Likewise.
7354 (create_signatured_type_table_from_index): Likewise.
7355 (dwarf2_read_index): Likewise.
7356 (dwarf2_initialize_objfile): Likewise.
7357 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
7358 per_cu rather than get_dwarf2_per_objfile.
7360 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7362 * dwarf2read.h (struct signatured_type): Forward declare.
7363 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
7365 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
7366 (dw2_get_cutu): ...this.
7367 (dwarf2_per_objfile::get_cu): Rename from...
7368 (dw2_get_cu): ...this.
7369 (dwarf2_per_objfile::get_tu): New.
7370 (create_addrmap_from_index): Adjust.
7371 (create_addrmap_from_aranges): Adjust.
7372 (dw2_find_last_source_symtab): Adjust.
7373 (dw2_map_symtabs_matching_filename): Adjust.
7374 (dw2_symtab_iter_next): Adjust.
7375 (dw2_print_stats): Adjust.
7376 (dw2_expand_all_symtabs): Adjust.
7377 (dw2_expand_symtabs_with_fullname): Adjust.
7378 (dw2_expand_marked_cus): Adjust.
7379 (dw_expand_symtabs_matching_file_matcher): Adjust.
7380 (dw2_map_symbol_filenames): Adjust.
7381 (dw2_debug_names_iterator::next): Adjust.
7382 (dwarf2_initialize_objfile): Adjust.
7383 (set_partial_user): Adjust.
7384 (dwarf2_build_psymtabs_hard): Adjust.
7386 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7388 * dwarf2read.c (create_signatured_type_table_from_debug_names):
7389 Remove unused variables.
7390 (dw2_map_symtabs_matching_filename): Likewise.
7391 (dwarf2_record_block_ranges): Likewise.
7392 (dwarf2_read_addr_index): Likewise.
7393 (follow_die_offset): Likewise.
7395 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7397 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
7398 to symbol_file_add_main.
7400 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7403 * mi/mi-console.c (do_fputc_async_safe): New.
7404 (mi_console_file::write_async_safe): New.
7405 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
7406 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
7408 * ui-file.c (ui_file::putstrn): Adjust call to
7409 fputstrn_unfiltered.
7410 * utils.c (printchar): Replace do_fputs and do_fprintf
7411 parameters by do_fputc.
7412 (fputstr_filtered): Adjust call to printchar.
7413 (fputstr_unfiltered): Likewise.
7414 (fputstrn_filtered): Likewise.
7415 (fputstrn_unfiltered): Add do_fputc parameter, pass to
7417 * utils.h (do_fputc_ftype): New typedef.
7418 (fputstrn_unfiltered): Add do_fputc parameter.
7420 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7422 * regformats/i386/i386-avx.dat: Remove.
7424 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7427 * amd64-tdep.c (amd64_none_init_abi): New function.
7428 (amd64_x32_none_init_abi): New function.
7429 (_initialize_amd64_tdep): Register handlers for x86-64 and
7430 x64_32 with GDB_OSABI_NONE.
7431 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
7432 GDB_OSABI_NONE osabi.
7434 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7437 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
7439 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
7440 * osabi.c (gdb_osabi_names): Add "unknown" entry.
7442 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7444 * common/byte-vector.h (char_vector): New type.
7445 * target.h (target_read_alloc): Return
7446 gdb::optional<byte_vector>.
7447 (target_read_stralloc): Return gdb::optional<char_vector>.
7448 (target_get_osdata): Return gdb::optional<char_vector>.
7449 * target.c (target_read_alloc_1): Templatize. Replacement
7450 manual memory management with vector.
7451 (target_read_alloc): Change return type, adjust.
7452 (target_read_stralloc): Change return type, adjust.
7453 (target_get_osdata): Change return type, adjust.
7454 * auxv.c (struct auxv_info) <length>: Remove.
7455 <data>: Change type to gdb::optional<byte_vector>.
7456 (auxv_inferior_data_cleanup): Free auxv_info with delete.
7457 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
7458 (target_auxv_search): Adjust.
7459 (fprint_target_auxv): Adjust.
7460 * avr-tdep.c (avr_io_reg_read_command): Adjust.
7461 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
7462 (linux_make_corefile_notes): Adjust.
7463 * osdata.c (get_osdata): Adjust.
7464 * remote.c (remote_get_threads_with_qxfer): Adjust.
7465 (remote_memory_map): Adjust.
7466 (remote_traceframe_info): Adjust.
7467 (btrace_read_config): Adjust.
7468 (remote_read_btrace): Adjust.
7469 (remote_pid_to_exec_file): Adjust.
7470 * solib-aix.c (solib_aix_get_library_list): Adjust.
7471 * solib-dsbt.c (decode_loadmap): Don't free buf.
7472 (dsbt_get_initial_loadmaps): Adjust.
7473 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
7474 * solib-target.c (solib_target_current_sos): Adjust.
7475 * tracepoint.c (sdata_make_value): Adjust.
7476 * xml-support.c (xinclude_start_include): Adjust.
7477 (xml_fetch_content_from_file): Adjust.
7478 * xml-support.h (xml_fetch_another): Change return type.
7479 (xml_fetch_content_from_file): Change return type.
7480 * xml-syscall.c (xml_init_syscalls_info): Adjust.
7481 * xml-tdesc.c (file_read_description_xml): Adjust.
7482 (fetch_available_features_from_target): Change return type.
7483 (target_fetch_description_xml): Adjust.
7484 (target_read_description_xml): Adjust.
7486 2018-04-06 Tom Tromey <tom@tromey.com>
7488 * value.c (~value): Update.
7489 (struct value) <contents>: Now unique_xmalloc_ptr.
7490 (value_contents_bits_eq, allocate_value_contents)
7491 (value_contents_raw, value_contents_all_raw)
7492 (value_contents_for_printing, value_contents_for_printing_const)
7493 (set_value_enclosing_type): Update.
7495 2018-04-06 Tom Tromey <tom@tromey.com>
7497 * value.c (range_s): Remove typedef, VEC.
7498 (struct range): Add operator<.
7499 (range_lessthan): Remove.
7500 (ranges_contain): Change type.
7502 (struct value) <unavailable, optimized_out>: Now std::vector.
7503 (value_entirely_available)
7504 (value_entirely_covered_by_range_vector)
7505 (value_entirely_unavailable, value_entirely_optimized_out):
7507 (insert_into_bit_range_vector): Change argument type.
7508 (find_first_range_overlap): Likewise.
7509 (struct ranges_and_idx, value_contents_bits_eq)
7510 (require_not_optimized_out, require_available): Update.
7511 (ranges_copy_adjusted): Change argument types.
7512 (value_optimized_out, value_copy, value_fetch_lazy): Update.
7514 2018-04-06 Tom Tromey <tom@tromey.com>
7516 * value.c (~value): Update.
7517 (struct value) <parent>: Now a value_ref_ptr.
7518 (value_parent, set_value_parent, value_address, value_copy):
7521 2018-04-06 Tom Tromey <tom@tromey.com>
7523 * value.c (struct value): Add constructor, destructor, and member
7525 (allocate_value_lazy, value_decref): Update.
7527 2018-04-06 Tom Tromey <tom@tromey.com>
7529 * value.c (struct value) <released, next>: Remove.
7530 (all_values): Now a std::vector.
7531 (allocate_value_lazy): Update.
7532 (value_next): Remove.
7533 (value_mark, value_free_to_mark, release_value)
7534 (value_release_to_mark): Update.
7536 2018-04-06 Tom Tromey <tom@tromey.com>
7538 * value.h (fetch_subexp_value, value_release_to_mark): Update.
7539 (free_value_chain): Remove.
7540 * value.c (free_value_chain): Remove.
7541 (value_release_to_mark): Return a std::vector.
7542 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
7544 (check_condition): Update.
7545 * eval.c (fetch_subexp_value): Change "val_chain" to a
7547 * breakpoint.c (update_watchpoint): Update.
7548 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
7550 2018-04-06 Tom Tromey <tom@tromey.com>
7552 * value.h (free_all_values): Remove.
7553 * value.c (free_all_values): Remove.
7555 2018-04-06 Tom Tromey <tom@tromey.com>
7557 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
7558 (value_history_chain, value_history_count): Remove.
7559 (value_history): New global.
7560 (record_latest_value, access_value_history, show_values)
7561 (preserve_values): Update.
7563 2018-04-06 Tom Tromey <tom@tromey.com>
7565 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
7566 * varobj.c (varobj_set_display_format, varobj_set_value)
7567 (install_default_visualizer, construct_visualizer)
7568 (install_new_value, ~varobj, varobj_get_value_type)
7569 (my_value_of_variable, varobj_editable_p): Update.
7570 * c-varobj.c (c_describe_child, c_value_of_variable)
7571 (cplus_number_of_children, cplus_describe_child): Update.
7572 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
7573 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
7574 (ada_value_of_variable, ada_value_is_changeable_p): Update.
7576 2018-04-06 Tom Tromey <tom@tromey.com>
7578 * printcmd.c (last_examine_address): Change type to
7580 (do_examine, x_command): Update.
7582 2018-04-06 Tom Tromey <tom@tromey.com>
7584 * value.c (release_value): Update.
7585 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
7586 (struct bpstats) <val>: Now a value_ref_ptr.
7587 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7588 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7589 (~watchpoint, print_it_watchpoint, watch_command_1)
7590 (invalidate_bp_value_on_memory_change): Update.
7592 2018-04-06 Tom Tromey <tom@tromey.com>
7594 * varobj.c (varobj_clear_saved_item)
7595 (update_dynamic_varobj_children, install_new_value, ~varobj):
7597 * value.h (value_incref): Move declaration earlier.
7598 (value_decref): Rename from value_free.
7599 (struct value_ref_policy): New.
7600 (value_ref_ptr): New typedef.
7601 (struct value_deleter): Remove.
7602 (gdb_value_up): Remove typedef.
7603 (release_value): Change return type.
7604 (release_value_or_incref): Remove.
7605 * value.c (set_value_parent): Update.
7606 (value_incref): Change return type.
7607 (value_decref): Rename from value_free.
7608 (value_free_to_mark, free_all_values, free_value_chain): Update.
7609 (release_value): Return value_ref_ptr.
7610 (release_value_or_incref): Remove.
7611 (record_latest_value, set_internalvar, clear_internalvar):
7613 * stack.c (info_frame_command): Don't call value_free.
7614 * python/py-value.c (valpy_dealloc, valpy_new)
7615 (value_to_value_object): Update.
7616 * printcmd.c (do_examine): Update.
7617 * opencl-lang.c (lval_func_free_closure): Update.
7618 * mi/mi-main.c (register_changed_p): Don't call value_free.
7619 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
7620 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
7621 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
7623 * guile/scm-value.c (vlscm_free_value_smob)
7624 (vlscm_scm_from_value): Update.
7625 * frame.c (frame_register_unwind, frame_unwind_register_signed)
7626 (frame_unwind_register_unsigned, get_frame_register_bytes)
7627 (put_frame_register_bytes): Don't call value_free.
7628 * findvar.c (address_from_register): Don't call value_free.
7629 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
7630 * dwarf2loc.c (entry_data_value_free_closure)
7631 (value_of_dwarf_reg_entry, free_pieced_value_closure)
7632 (dwarf2_evaluate_loc_desc_full): Update.
7633 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7634 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7635 (~watchpoint, watch_command_1)
7636 (invalidate_bp_value_on_memory_change): Update.
7637 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
7639 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
7642 * warning.m4: Add -Wno-error=deprecated-register.
7643 * configure: Re-generate.
7645 2018-04-05 Tom Tromey <tom@tromey.com>
7647 * linespec.h: Remove include of "vec.h".
7649 2018-04-05 Tom Tromey <tom@tromey.com>
7651 * linespec.c (typep): Remove typedef.
7652 (find_methods, find_superclass_methods): Take a std::vector.
7653 (find_method): Use std::vector.
7655 2018-04-05 Tom Tromey <tom@tromey.com>
7657 * utils.c (compare_strings): Remove.
7658 * utils.h (compare_strings): Remove.
7659 * objc-lang.h (find_imps): Update.
7660 * objc-lang.c (find_methods): Take a std::vector.
7661 (uniquify_strings, find_imps): Likewise.
7662 * linespec.c (find_methods): Take a std::vector.
7663 (decode_objc): Use std::vector.
7664 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
7666 (find_method, find_function_symbols): Use std::vector.
7668 2018-04-05 Tom Tromey <tom@tromey.com>
7670 * completer.c (completion_tracker::completion_tracker): Remove
7672 (completion_tracker::discard_completions): Likewise.
7673 * breakpoint.c (ambiguous_names_p): Remove cast.
7674 * ada-lang.c (_initialize_ada_language): Remove cast.
7675 * utils.h (streq): Update.
7676 (streq_hash): Add new declaration.
7677 * utils.c (streq): Return bool.
7678 (streq_hash): New function.
7680 2018-04-05 Tom Tromey <tom@tromey.com>
7682 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
7683 Remove a string copy.
7685 2018-04-05 Tom Tromey <tom@tromey.com>
7687 * linespec.c (filter_results): Use std::vector.
7688 (decode_line_2, decode_line_full): Update.
7690 2018-04-05 Tom Tromey <tom@tromey.com>
7692 * linespec.c (canonical_to_fullform): Return std::string.
7693 (filter_results): Update.
7694 (struct decode_line_2_item): Add constructor.
7695 <fullform, displayform>: Now std::string.
7696 (decode_line_2_compare_items): Now a std::sort comparator.
7697 (decode_line_2): Update.
7699 2018-04-05 Tom Tromey <tom@tromey.com>
7701 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
7702 (unexpected_linespec_error): Update.
7703 (linespec_parse_basic, parse_linespec): Update.
7705 2018-04-05 Tom Tromey <tom@tromey.com>
7707 * linespec.c (linespec_parse_basic): Reindent.
7709 2018-04-05 Tom Tromey <tom@tromey.com>
7711 * minsyms.h (iterate_over_minimal_symbols): Update.
7712 * minsyms.c (iterate_over_minimal_symbols): Take a
7714 * linespec.c (struct collect_minsyms): Remove.
7715 (compare_msyms): Now a std::sort comparator.
7716 (add_minsym): Add parameters.
7717 (search_minsyms_for_name): Update. Use std::vector.
7719 2018-04-03 Tom Tromey <tom@tromey.com>
7721 * mipsread.c (read_alphacoff_dynamic_symtab): Use
7724 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
7726 * MAINTAINERS (Write After Approval): Add Weimin Pan.
7728 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
7731 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
7732 printing static type.
7734 2018-04-01 Tom Tromey <tom@tromey.com>
7736 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
7737 (rs6000_xfer_shared_libraries): Update.
7739 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
7741 * common/gdb_vecs.h (char_ptr): Remove.
7742 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
7744 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
7746 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
7748 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
7750 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
7752 * tracepoint.h (struct uploaded_tp): Initialize fields.
7753 <actions, step_actions, cmd_strings>: Change type to
7754 std::vector<char *>.
7755 * tracepoint.c (get_uploaded_tp): Allocate with new.
7756 (free_uploaded_tps): Free with delete.
7757 (parse_tracepoint_definition): Adjust to std::vector change.
7758 * breakpoint.c (read_uploaded_action): Likewise.
7759 (create_tracepoint_from_upload): Likewise.
7760 * ctf.c (ctf_write_uploaded_tp): Likewise.
7761 (SET_ARRAY_FIELD): Likewise.
7762 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
7764 2018-03-30 Tom Tromey <tom@tromey.com>
7766 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
7768 (svr4_keep_data_in_core): Update.
7769 (svr4_read_so_list): Update.
7771 2018-03-30 Tom Tromey <tom@tromey.com>
7773 * windows-nat.c (handle_output_debug_string, handle_exception):
7775 * target.h (target_read_string): Update.
7776 * target.c (target_read_string): Change "string" to
7778 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
7780 * solib-frv.c (frv_current_sos): Update.
7781 * solib-dsbt.c (dsbt_current_sos): Update.
7782 * solib-darwin.c (darwin_current_sos): Update.
7783 * linux-thread-db.c (inferior_has_bug): Update.
7784 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
7785 Update. Remove alloca.
7786 * ada-lang.c (ada_main_name): Update.
7788 2018-03-30 Tom Tromey <tom@tromey.com>
7790 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
7791 (struct dwo_file_deleter): New.
7792 (dwo_file_up): New typedef.
7793 (open_and_init_dwo_file): Use dwo_file_up.
7794 (free_dwo_file_cleanup): Remove.
7796 2018-03-30 Tom Tromey <tom@tromey.com>
7798 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
7799 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
7801 2018-03-30 Tom Tromey <tom@tromey.com>
7803 * dwarf2read.c (class free_cached_comp_units): New class.
7804 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
7805 (free_cached_comp_units): Remove function.
7807 2018-03-30 Tom Tromey <tom@tromey.com>
7809 * utils.h (make_cleanup_unpush_target): Remove.
7810 * inf-ptrace.c (struct target_unpusher): New.
7811 (target_unpush_up) New typedef.
7812 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
7814 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
7816 2018-03-27 Tom Tromey <tom@tromey.com>
7818 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
7820 2018-03-27 Pedro Alves <palves@redhat.com>
7821 Tom Tromey <tom@tromey.com>
7823 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
7824 destructor. Now a class.
7825 (gdb_readline_wrapper_cleanup): Remove function.
7826 (gdb_readline_wrapper): Remove cleanups.
7828 2018-03-27 Tom Tromey <tom@tromey.com>
7830 * typeprint.h (struct type_print_options) <local_typedefs,
7831 global_typedefs>: Remove "struct" keyword.
7832 (class typedef_hash_table): New class.
7833 (recursively_update_typedef_hash, add_template_parameters)
7834 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
7835 (find_typedef_in_hash): Don't declare.
7836 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
7837 (typedef_hash_table::recursively_update): Rename from
7838 recursively_update_typedef_hash. Now a member.
7839 (typedef_hash_table::add_template_parameters): Rename from
7840 add_template_parameters. Now a member.
7841 (typedef_hash_table::typedef_hash_table): Now a constructor;
7842 rename from create_typedef_hash.
7843 (typedef_hash_table::~typedef_hash_table): Now a destructor;
7844 rename from free_typedef_hash.
7845 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
7846 (do_free_global_table): Remove.
7847 (typedef_hash_table::typedef_hash_table): New constructor; renamed
7848 from copy_type_recursive.
7849 (create_global_typedef_table): Remove.
7850 (typedef_hash_table::find_global_typedef): Now a member of
7852 (typedef_hash_table::find_typedef): Rename from
7853 find_typedef_in_hash; now a member.
7854 (whatis_exp): Update.
7855 * extension.h (struct ext_lang_type_printers): Add constructor and
7857 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
7859 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
7860 Now a constructor; rename from start_ext_lang_type_printers.
7861 (ext_lang_type_printers): Now a destructor; rename from
7862 free_ext_lang_type_printers.
7863 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
7865 (c_type_print_base_struct_union): Update. Remove cleanups.
7867 2018-03-27 Tom Tromey <tom@tromey.com>
7869 * dwarf-index-write.c: Include <cmath>.
7871 2018-03-27 Joel Brobecker <brobecker@adacore.com>
7873 * NEWS: Add entry describing new "set|show varsize-limit" command.
7874 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
7876 * printcmd.c (_initialize_printcmd): Add "set var" alias of
7879 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
7881 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
7883 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
7884 * dwarf-index-common.c: New file.
7885 * dwarf-index-common.h: New file.
7886 * dwarf-index-write.c: New file.
7887 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
7888 (struct dwarf2_section_info): Move from here.
7889 (dwarf2_section_info_def): Likewise.
7890 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
7891 (offset_type): Likewise.
7892 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
7893 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
7894 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
7895 (byte_swap): Likewise.
7896 (MAYBE_SWAP): Likewise.
7897 (dwarf2_per_cu_ptr): Likewise.
7898 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
7899 (struct tu_stats): Likewise.
7900 (struct dwarf2_per_objfile): Likewise.
7901 (struct dwarf2_per_cu_data): Likewise.
7902 (struct signatured_type): Likewise.
7903 (sig_type_ptr): Likewise.
7904 (DEF_VEC_P (sig_type_ptr)): Likewise.
7905 (INDEX4_SUFFIX): Likewise.
7906 (INDEX5_SUFFIX): Likewise.
7907 (DEBUG_STR_SUFFIX): Likewise.
7908 (dwarf2_read_section): Make non-static.
7909 (mapped_index_string_hash): Move from here.
7910 (dwarf5_djb_hash): Likewise.
7911 (file_write): Likewise.
7912 (class data_buf): Likewise.
7913 (struct symtab_index_entry): Likewise.
7914 (struct mapped_symtab): Likewise.
7915 (find_slot): Likewise.
7916 (hash_expand): Likewise.
7917 (add_index_entry): Likewise.
7918 (uniquify_cu_indices): Likewise.
7919 (class c_str_view): Likewise.
7920 (class c_str_view_hasher): Likewise.
7921 (class vector_hasher): Likewise.
7922 (write_hash_table): Likewise.
7923 (psym_index_map): Likewise.
7924 (struct addrmap_index_data): Likewise.
7925 (add_address_entry): Likewise.
7926 (add_address_entry_worker): Likewise.
7927 (write_address_map): Likewise.
7928 (symbol_kind): Likewise.
7929 (write_psymbols): Likewise.
7930 (struct signatured_type_index_data): Likewise.
7931 (write_one_signatured_type): Likewise.
7932 (recursively_count_psymbols): Likewise.
7933 (recursively_write_psymbols): Likewise.
7934 (class debug_names): Likewise.
7935 (check_dwarf64_offsets): Likewise.
7936 (psyms_seen_size): Likewise.
7937 (write_gdbindex): Likewise.
7938 (write_debug_names): Likewise.
7939 (assert_file_size): Likewise.
7940 (write_psymtabs_to_index): Likewise.
7941 (save_gdb_index_command): Likewise.
7942 (_initialize_dwarf2_read): Don't register the "save gdb-index"
7944 * dwarf2read.h: New file.
7946 2018-03-27 Joel Brobecker <brobecker@adacore.com>
7949 * dwarf2read.c (dwarf2_physname): Do not return the demangled
7950 symbol name if the CU's language stores symbol names in linkage
7952 * language.h (struct language_defn)
7953 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
7954 all instances of this struct.
7956 2018-03-26 Tom Tromey <tom@tromey.com>
7958 * stack.c (backtrace_command_1): Remove verbose code.
7960 2018-03-26 Tom Tromey <tom@tromey.com>
7962 * python/py-framefilter.c (py_print_type): Don't catch
7963 exceptions. Return void.
7964 (py_print_value): Likewise.
7965 (py_print_single_arg): Likewise.
7966 (enumerate_args): Don't catch exceptions.
7967 (py_print_args): Likewise.
7968 (py_print_frame): Likewise.
7969 (gdbpy_apply_frame_filter): Catch exceptions here.
7971 2018-03-26 Tom Tromey <tom@tromey.com>
7973 * stack.c (_initialize_stack): Remove trailing newlines from help
7974 text. Add "Usage" line to "backtrace" help.
7976 2018-03-26 Tom Tromey <tom@tromey.com>
7979 * python/py-framefilter.c (py_print_args): Call wrap_hint.
7981 2018-03-26 Tom Tromey <tom@tromey.com>
7983 * python/py-framefilter.c (py_print_single_arg): Return
7984 EXT_LANG_BT_ERROR from catch.
7986 2018-03-26 Tom Tromey <tom@tromey.com>
7989 * stack.c (backtrace_command_1): Move some code into no-filters
7992 2018-03-26 Tom Tromey <tom@tromey.com>
7994 * python/py-framefilter.c (throw_quit_or_print_exception): New
7996 (gdbpy_apply_frame_filter): Use it.
7998 2018-03-26 Tom Tromey <tom@tromey.com>
8001 * python/py-framefilter.c (py_print_type, py_print_value)
8002 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
8005 2018-03-26 Tom Tromey <tom@tromey.com>
8007 * python/py-framefilter.c (enumerate_args): Use
8008 gdb::unique_xmalloc_ptr.
8010 2018-03-26 Tom Tromey <tom@tromey.com>
8012 * python/py-framefilter.c (py_print_frame): Return
8014 (gdbpy_apply_frame_filter): Update comment.
8015 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
8017 <EXT_LANG_BT_NO_FILTERS>: Change value.
8019 2018-03-26 Tom Tromey <tom@tromey.com>
8022 * stack.c (backtrace_command): Parse "hide" argument.
8023 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
8024 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
8027 2018-03-26 Tom Tromey <tom@tromey.com>
8029 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
8031 (backtrace_command): Remove "fulltrace", add "flags".
8033 2018-03-26 Tom Tromey <tom@tromey.com>
8035 * stack.c (backtrace_command): Rewrite command line parsing.
8037 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8039 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
8041 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8043 * filename-seen-cache.h: Add include guard.
8045 2018-03-26 Keith Seitz <keiths@redhat.com>
8047 * symfile.c (place_section): Remove "struct" from section_addr_info
8049 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
8050 "struct" keyword from section_addr_info.
8052 2018-03-26 Alan Hayward <alan.hayward@arm.com>
8054 * regformats/regdef.h (reg): Add constructors.
8056 2018-03-25 Pedro Alves <palves@redhat.com>
8058 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8059 if then/else bodies in var_func_name extraction.
8061 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
8063 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
8064 lookup_minimal_symbol() to find symbol entry.
8065 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
8067 2018-03-23 Keith Seitz <keiths@redhat.com>
8070 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
8071 nested type definitions for C++, too.
8073 2018-03-23 Tom Tromey <tom@tromey.com>
8075 * machoread.c (struct oso_el): Add a constructor. Don't define as
8077 (macho_register_oso): Remove.
8078 (macho_symtab_read): Take a std::vector.
8079 (oso_el_compare_name): Now a std::sort comparator.
8080 (macho_symfile_read_all_oso): Take a std::vector.
8081 (macho_symfile_read): Use std::vector. Remove cleanups.
8083 2018-03-22 Tom Tromey <tom@tromey.com>
8085 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
8086 (record_full_goto_bookmark): Use std::string.
8088 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8091 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
8094 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8096 * rs6000-tdep.c (store_insn_p): New function.
8097 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
8098 and cr_reg to their unshifted values. Use store_insn_p to
8099 match LR saves using either R1 or fdata->alloca_reg. Use
8100 store_insn_p to match CR saves. Set alloca_reg_offset
8101 when alloca_reg and framep are set. Remove lr_reg shift
8102 when assigning to fdata->lr_register.
8104 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
8106 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
8107 command line args instead of emitting a warning.
8109 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8111 * tracepoint.h (struct static_tracepoint_marker): Initialize
8112 fields, define default constructor, move constructor and move
8113 assignment, disable the rest.
8114 <str_id, extra>: Make std::string.
8115 (release_static_tracepoint_marker): Remove.
8116 (free_current_marker): Remove.
8117 * tracepoint.c (free_current_marker): Remove.
8118 (parse_static_tracepoint_marker_definition): Adjust to
8119 std::string, use new hex2str overload.
8120 (release_static_tracepoint_marker): Remove.
8121 (print_one_static_tracepoint_marker): Get marker by reference
8122 and adjust to std::string.
8123 (info_static_tracepoint_markers_command): Adjust to std::vector
8125 * target.h (static_tracepoint_marker_p): Remove typedef.
8126 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
8127 (struct target_ops) <to_static_tracepoint_marker_at>: Return
8129 <to_static_tracepoint_markers_by_strid>: Return std::vector.
8131 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
8132 (target_debug_print_std_vector_static_tracepoint_marker): New.
8133 (target_debug_print_struct_static_tracepoint_marker_p): Rename
8135 (target_debug_print_static_tracepoint_marker_p): ... this.
8136 * target-delegates.c: Re-generate.
8137 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
8139 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
8140 (decode_static_tracepoint_spec): Adjust to std::vector.
8141 (tracepoint_print_one_detail): Adjust to std::string.
8142 (strace_marker_decode_location): Adjust to std::string.
8143 (update_static_tracepoint): Adjust to std::string, remove call
8144 to release_static_tracepoint_marker.
8145 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
8146 Adjust to std::vector.
8147 * remote.c (remote_static_tracepoint_marker_at): Return bool.
8148 (remote_static_tracepoint_markers_by_strid): Adjust to
8150 * common/rsp-low.h (hex2str): New overload with explicit count
8152 * common/rsp-low.c (hex2str): New overload with explicit count
8154 * unittests/rsp-low-selftests.c (test_hex2str): New function.
8155 (_initialize_rsp_low_selftests): Add test_hex2str test.
8156 * unittests/tracepoint-selftests.c
8157 (test_parse_static_tracepoint_marker_definition): Adjust to
8160 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8162 * tracepoint.c (parse_static_tracepoint_marker_definition):
8163 Consider case where the definition is followed by more
8165 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8166 tracepoint-selftests.c.
8167 * unittests/tracepoint-selftests.c: New.
8169 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8171 * MAINTAINERS (Write After Approval): Add Pedro Franco de
8174 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8176 * symtab.c (find_pc_sect_line): fixed indentation.
8178 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8180 * symtab.c (find_pc_sect_line): now uses binary search.
8182 2018-03-19 Tom Tromey <tom@tromey.com>
8184 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
8187 2018-03-19 Pedro Alves <palves@redhat.com>
8188 Tom Tromey <tom@tromey.com>
8190 * unittests/observable-selftests.c: New file.
8191 * common/observable.h: New file.
8192 * observable.h: New file.
8193 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
8194 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
8195 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
8196 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
8197 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
8198 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
8199 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
8200 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
8201 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
8202 python/py-breakpoint.c, python/py-finishbreakpoint.c,
8203 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
8204 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
8205 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
8206 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
8207 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
8208 tui/tui-interp.c, valops.c: Update all users.
8209 * tui/tui-hooks.c (tui_bp_created_observer)
8210 (tui_bp_deleted_observer, tui_bp_modified_observer)
8211 (tui_inferior_exit_observer, tui_before_prompt_observer)
8212 (tui_normal_stop_observer, tui_register_changed_observer):
8214 (tui_observers_token): New global.
8215 (attach_or_detach, tui_attach_detach_observers): New functions.
8216 (tui_install_hooks, tui_remove_hooks): Use
8217 tui_attach_detach_observers.
8218 * record-btrace.c (record_btrace_thread_observer): Remove.
8219 (record_btrace_thread_observer_token): New global.
8220 * observer.sh: Remove.
8221 * observer.c: Rename to observable.c.
8222 * observable.c (namespace gdb_observers): Define new objects.
8223 (observer_debug): Move into gdb_observers namespace.
8224 (struct observer, struct observer_list, xalloc_observer_list_node)
8225 (xfree_observer_list_node, generic_observer_attach)
8226 (generic_observer_detach, generic_observer_notify): Remove.
8227 (_initialize_observer): Update.
8228 Don't include observer.inc.
8229 * Makefile.in (generated_files): Remove observer.h, observer.inc.
8230 (clean mostlyclean): Likewise.
8231 (observer.h, observer.inc): Remove targets.
8232 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
8233 (COMMON_SFILES): Use observable.c, not observer.c.
8234 * .gitignore: Remove observer.h.
8236 2018-03-18 Tom Tromey <tom@tromey.com>
8238 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
8240 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
8242 2018-03-17 Tom Tromey <tom@tromey.com>
8244 * auto-load.c (auto_load_objfile_script_1): Use std::string.
8246 2018-03-17 Tom Tromey <tom@tromey.com>
8248 * target.c (class scoped_target_fd): New.
8249 (target_fileio_close_cleanup): Remove.
8250 (target_fileio_read_alloc_1): Use scoped_target_fd.
8252 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
8254 * silent-rules.mk: New.
8255 * Makefile.in: Include silent-rules.mk
8256 (srcdir, VPATH, top_srcdir): Move up.
8257 (COMPILE): Add ECHO_CXX.
8258 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
8259 (init.c): Add ECHO_INIT_C.
8260 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
8261 (version.c): Add ECHO_GEN.
8262 (printcmd.o): Add ECHO_CXX.
8263 (target-float.o): Add ECHO_CXX.
8264 (ada-exp.o): Add ECHO_CXX.
8265 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
8266 (insight$(EXEEXT)): Add ECHO_CXXLD.
8267 * gnulib/configure.ac: Add AM_SILENT_RULES.
8268 * gnulib/aclocal.m4: Re-generate.
8269 * gnulib/configure: Re-generate.
8270 * gnulib/import/Makefile.in: Re-generate.
8272 2018-03-16 Tom Tromey <tom@tromey.com>
8274 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
8275 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
8276 * utils.c (do_free_section_addr_info)
8277 (make_cleanup_free_section_addr_info): Remove.
8278 * symfile.h (struct other_sections): Add constructor.
8279 (struct section_addr_info): Remove.
8280 (section_addr_info): New typedef.
8281 (struct sym_fns) <sym_offsets>: Change type of parameter.
8282 (build_section_addr_info_from_objfile)
8283 (relative_addr_info_to_section_offsets, addr_info_make_relative)
8284 (default_symfile_offsets, symbol_file_add)
8285 (symbol_file_add_from_bfd)
8286 (build_section_addr_info_from_section_table): Update.
8287 (alloc_section_addr_info, free_section_addr_info): Don't declare.
8288 * symfile.c (alloc_section_addr_info): Remove.
8289 (build_section_addr_info_from_section_table): Change return type.
8291 (build_section_addr_info_from_bfd)
8292 (build_section_addr_info_from_objfile): Likewise.
8293 (free_section_addr_info): Remove.
8294 (relative_addr_info_to_section_offsets): Change type of "addrs".
8295 (addrs_section_compar): Now a std::sort comparator.
8296 (addrs_section_sort): Change return type.
8297 (addr_info_make_relative): Change type of "addrs". Update.
8298 (default_symfile_offsets, syms_from_objfile_1)
8299 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
8300 (symbol_file_add_separate): Update.
8301 (symbol_file_add): Change type of "addrs". Update.
8302 (add_symbol_file_command): Update. Remove cleanups.
8303 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
8305 * symfile-debug.c (debug_sym_offsets): Change type of "info".
8306 * solib.c (solib_read_symbols): Update.
8307 * objfiles.c (objfile_relocate): Update. Remove cleanups.
8308 * machoread.c (macho_symfile_offsets): Update.
8309 * jit.c (jit_bfd_try_read_symtab): Update.
8311 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
8313 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8314 unittests/utils-selftests.c.
8315 * unittests/utils-selftests.c: New file.
8317 2018-03-14 Tom Tromey <tom@tromey.com>
8320 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
8323 2018-03-14 Tom Tromey <tom@tromey.com>
8326 * printcmd.c (printf_pointer): Allow "-" in format.
8328 2018-03-14 Tom Tromey <tom@tromey.com>
8330 * printcmd.c (_initialize_printcmd): Add usage to printf.
8332 2018-03-14 Yao Qi <qiyao@sourceware.org>
8334 * MAINTAINERS: Update my email address.
8336 2018-03-13 Tom Tromey <tom@tromey.com>
8338 * machoread.c (macho_check_dsym): Change filenamep to a
8340 (macho_symfile_read): Update.
8341 * symfile.c (load_command): Use std::string.
8343 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
8345 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
8346 to error message string.
8347 (riscv_register_name): Use xsnprintf instead of sprintf.
8348 (riscv_insn::fetch_instruction): Use gdb_assert instead of
8350 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
8352 (riscv_push_dummy_call): Likewise.
8354 2018-03-12 Tom Tromey <tom@tromey.com>
8356 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
8357 Use gdb::byte_vector.
8358 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
8360 2018-03-12 Yao Qi <yao.qi@linaro.org>
8362 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
8363 parameter type to readable_regcache.
8364 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
8367 2018-03-11 Tom Tromey <tom@tromey.com>
8369 * dwarf2read.c (struct nextfield): Add initializers.
8370 (struct nextfnfield): Remove.
8371 (struct fnfieldlist): Add initializers. Remove "length" and
8372 "head", use std::vector.
8373 (struct decl_field_list): Remove.
8374 (struct field_info): Add initializers.
8375 <fields, baseclasses>: Now std::vector.
8376 <nbaseclasses, nfnfields, typedef_field_list_count,
8377 nested_types_list_count>: Remove.
8378 (dwarf2_add_field, dwarf2_add_type_defn)
8379 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
8380 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
8381 (process_structure_scope): Update.
8383 2018-03-11 Tom Tromey <tom@tromey.com>
8385 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
8386 for use by std::sort.
8387 (build_type_psymtabs_1): Use std::vector.
8389 2018-03-09 Eli Zaretskii <eliz@gnu.org>
8391 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
8392 and LIBMPFR in the printed configuration.
8394 2018-03-08 Tom Tromey <tom@tromey.com>
8396 * source.c (get_filename_and_charpos): Use scoped_fd.
8397 * nto-procfs.c (procfs_open_1): Use scoped_fd.
8398 (procfs_pidlist): Likewise.
8399 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
8400 (iterate_over_mappings): Likewise.
8402 2018-03-08 Tom Tromey <tom@tromey.com>
8404 * infcall.c (struct call_return_meta_info)
8405 <stack_temporaries_enabled>: Remove.
8406 (get_call_return_value, call_function_by_hand_dummy): Update.
8407 * thread.c (disable_thread_stack_temporaries): Remove.
8408 (enable_thread_stack_temporaries): Remove.
8409 (thread_stack_temporaries_enabled_p): Return bool.
8410 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
8411 (get_last_thread_stack_temporary): Update.
8412 * eval.c (evaluate_subexp): Update.
8413 * gdbthread.h (class enable_thread_stack_temporaries): Now a
8414 class, not a function.
8415 (value_ptr, value_vec): Remove typedefs.
8416 (class thread_info) <stack_temporaries_enabled>: Now bool.
8417 <stack_temporaries>: Now a std::vector.
8418 (thread_stack_temporaries_enabled_p)
8419 (value_in_thread_stack_temporaries): Return bool.
8421 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
8423 * remote.c (putpkt_binary): Fix omitted bytes reporting.
8424 (getpkt_or_notif_sane_1): Likewise.
8426 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8428 * build-id.c (build_id_to_debug_bfd): Use std::string.
8430 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8432 * build-id.c (find_separate_debug_file_by_buildid): Return
8434 * build-id.h (find_separate_debug_file_by_buildid): Return
8436 * coffread.c (coff_symfile_read): Adjust to std::string.
8437 * elfread.c (elf_symfile_read): Adjust to std::string.
8438 * symfile.c (separate_debug_file_exists): Change parameter to
8440 (find_separate_debug_file): Return std::string.
8441 (find_separate_debug_file_by_debuglink): Return std::string.
8442 * symfile.h (find_separate_debug_file_by_debuglink): Return
8445 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8447 * common/xml-utils.c (xml_escape_text): Move code to...
8448 (xml_escape_text_append): ... this new function.
8449 * common/xml-utils.h (xml_escape_text_append): New declaration.
8450 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
8452 (_initialize_xml_utils): register test_xml_escape_text_append as
8455 2018-03-07 Alan Hayward <alan.hayward@arm.com>
8457 * defs.h: Remove MAX_REGISTER_SIZE.
8458 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
8460 * python/py-unwind.c (pyuw_sniffer): Likewise.
8462 2018-03-07 Tom Tromey <tom@tromey.com>
8464 * linux-tdep.c (linux_info_proc): Update.
8465 * target.h (struct target_ops) <to_fileio_readlink>: Return
8467 (target_fileio_readlink): Return optional<string>.
8468 * remote.c (remote_hostio_readlink): Return optional<string>.
8469 * inf-child.c (inf_child_fileio_readlink): Return
8471 * target.c (target_fileio_readlink): Return optional<string>.
8473 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
8475 * regcache.c (cooked_read_test): Add riscv to the list of
8476 architectures that have a save_reggroup.
8478 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
8480 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
8481 value is not a dynamic class object.
8483 2018-03-06 Tom Tromey <tom@tromey.com>
8485 * rust-exp.y: Formatting fixes.
8487 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8489 * riscv-tdep.c (riscv_register_name): Remove target description
8491 (riscv_gdbarch_init): Remove target description check.
8493 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8495 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
8497 * riscv-tdep.h: Likewise.
8499 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8501 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
8502 (riscv_pseudo_register_write): Delete.
8503 (riscv_gdbarch_init): Remove all use of pseudo registers.
8505 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8507 * record-btrace.c (btrace_print_lines): Replace cleanup
8508 parameter with RAII equivalents.
8509 (btrace_insn_history): Replace cleanup with RAII equivalents.
8510 * ui-out.h (make_cleanup_ui_out_list_begin_end,
8511 make_cleanup_ui_out_tuple_begin_end): Remove.
8512 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
8513 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
8514 make_cleanup_ui_out_list_begin_end): Remove.
8516 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8518 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
8519 parameter types to std::vector. Use bool.
8520 (record_btrace_wait): Replace VEC(tp_t) with
8521 std::vector<thread_info *>.
8522 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
8524 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8526 * record-btrace.c (record_btrace_disable_callback): Remove.
8527 (struct scoped_btrace_disable): New.
8528 (record_btrace_open): Use scoped_btrace_disable.
8530 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8532 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
8533 reading values from registers.
8535 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8537 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
8540 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8542 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
8543 change parameter type. Use GDB's print functions, and use
8544 core_addr_to_string where appropriate.
8545 (riscv_push_dummy_call): Use core_addr_to_string where
8546 appropriate, update call to riscv_print_arg_location, and reindent
8548 (riscv_return_value): Update call to riscv_print_arg_location.
8550 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8551 Tim Newsome <tim@sifive.com>
8552 Albert Ou <a0u@eecs.berkeley.edu>
8553 Darius Rad <darius@bluespec.com>
8555 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
8556 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
8557 (ALLDEPFILES): Add riscv-tdep.c
8558 * configure.tgt: Add riscv support.
8559 * riscv-tdep.c: New file.
8560 * riscv-tdep.h: New file.
8561 * NEWS: Mention new target.
8562 * MAINTAINERS: Add entry for riscv.
8564 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8566 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
8567 fields within aggregates.
8569 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
8571 * record-btrace.c (btrace_print_lines): Change type of flags to
8572 gdb_disassembly_flags.
8574 2018-03-04 John Baldwin <jhb@FreeBSD.org>
8576 * fbsd-nat.c: Include "inf-ptrace.h".
8577 (USE_SIGTRAP_SIGINFO): Conditionally define.
8578 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
8579 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
8580 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
8582 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
8584 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
8586 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
8587 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
8588 "supports_stopped_by_hw_breakpoint" target methods.
8590 2018-03-04 John Baldwin <jhb@FreeBSD.org>
8592 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
8593 * fbsd-nat.c (debug_fbsd_nat): New variable.
8594 (show_fbsd_nat_debug): New function.
8595 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
8596 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
8598 2018-03-04 John Baldwin <jhb@FreeBSD.org>
8600 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
8601 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
8603 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
8604 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
8607 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8609 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
8610 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
8612 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8614 * charset.c (struct charset_vector): New.
8615 (charsets): Change type to charset_vector.
8616 (find_charset_names): Adjust.
8618 (_initialize_charset): Adjust.
8620 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8622 * progspace.h (struct program_space) <deleted_solibs>: Change
8623 type to std::vector<std::string>.
8624 * progspace.c (clear_program_space_solib_cache): Adjust.
8625 * breakpoint.c (print_solib_event): Adjust.
8626 (check_status_catch_solib): Adjust.
8627 * solib.c (update_solib_list): Adjust.
8628 * ui-out.h (class ui_out) <field_string>: New overload.
8629 * ui-out.c (ui_out::field_string): New overload.
8631 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8633 * progspace.h (struct program_space): Add constructor and
8634 destructor, initialize fields.
8635 (add_program_space): Remove.
8636 * progspace.c (add_program_space): Rename to...
8637 (program_space::program_space): ... this.
8638 (release_program_space): Rename to...
8639 (program_space::~program_space): ... this.
8640 (delete_program_space): Use delete to delete program_space.
8641 (initialize_progspace): Use new to allocate program_space.
8642 * inferior.c (add_inferior_with_spaces): Likewise.
8643 (clone_inferior_command): Likewise.
8644 * infrun.c (follow_fork_inferior): Likewise.
8645 (handle_vfork_child_exec_or_exit): Likewise.
8647 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8649 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
8650 (delim_string_to_char_ptr_vec): Return std::vector of
8651 gdb::unique_xmalloc_ptr.
8652 (dirnames_to_char_ptr_vec_append): Take std::vector of
8653 gdb::unique_xmalloc_ptr.
8654 (dirnames_to_char_ptr_vec): Return std::vector of
8655 gdb::unique_xmalloc_ptr.
8656 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
8657 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
8658 (delim_string_to_char_ptr_vec): Return an std::vector of
8659 gdb::unique_xmalloc_ptr, adjust the code.
8660 (dirnames_to_char_ptr_vec_append): Take an std::vector of
8661 gdb::unique_xmalloc_ptr, adjust the code.
8662 (dirnames_to_char_ptr_vec): Return an std::vector of
8663 gdb::unique_xmalloc_ptr, adjust the code.
8664 * auto-load.c (auto_load_safe_path_vec): Change type to
8665 std::vector of gdb::unique_xmalloc_ptr.
8666 (auto_load_expand_dir_vars): Return an std::vector of
8667 gdb::unique_xmalloc_ptr, adjust the code.
8668 (auto_load_safe_path_vec_update): Adjust.
8669 (filename_is_in_auto_load_safe_path_vec): Adjust.
8670 (auto_load_objfile_script_1): Adjust.
8671 * build-id.c (build_id_to_debug_bfd): Adjust.
8672 * linux-thread-db.c (thread_db_load_search): Adjust.
8673 * source.c (add_path): Adjust.
8675 * symfile.c (find_separate_debug_file): Adjust.
8676 * utils.c (do_free_char_ptr_vec): Remove.
8677 (make_cleanup_free_char_ptr_vec): Remove.
8679 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
8682 * common/pathstuff.c: Conditionally include "<windows.h>".
8684 2018-03-01 Georg Sauthoff <mail@georg.so>
8687 * gcore.in: Quote variables and switch interpreter to bash.
8689 2018-03-01 Tom Tromey <tom@tromey.com>
8691 * dwarf2read.c (alloc_discriminant_info): Fix default_index
8692 assertion. Add assertion for discriminant_index.
8693 (quirk_rust_enum): Use correct base type name in univariant case.
8695 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
8697 * record.c (get_call_history_modifiers): Return a
8699 (cmd_record_call_history): Adjust.
8700 * record-btrace.c (record_btrace_call_history): Adjust.
8701 (record_btrace_call_history_range): Adjust.
8702 (record_btrace_call_history_from): Adjust.
8703 * target-debug.h (target_debug_print_record_print_flags): New.
8704 * target-delegates.c: Re-generate.
8705 * target.c (target_call_history): Change flags type.
8706 (target_call_history_from): Likewise.
8707 (target_call_history_range): Likewise.
8708 * target.h (struct target_ops) <target_call_history>: Likewise.
8709 (target_call_history_from): Likewise.
8710 (target_call_history_range): Likewise.
8712 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
8713 Simon Marchi <simon.marchi@polymtl.ca>
8715 * common/common-utils.c: Include "sys/stat.h".
8716 (is_regular_file): Move here from "source.c"; change return
8718 * common/common-utils.h (is_regular_file): New prototype.
8719 * common/pathstuff.c (contains_dir_separator): New function.
8720 * common/pathstuff.h (contains_dir_separator): New prototype.
8721 * source.c: Don't include "sys/stat.h".
8722 (is_regular_file): Move to "common/common-utils.c".
8724 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
8726 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
8727 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
8728 * auto-load.c: Include "common/pathstuff.h".
8729 * common/common-def.h (current_directory): Move here.
8730 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
8732 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
8734 * common/pathstuff.c: New file.
8735 * common/pathstuff.h: New file.
8736 * compile/compile.c: Include "common/pathstuff.h".
8737 * defs.h (current_directory): Move to "common/common-defs.h".
8738 * dwarf2read.c: Include "common/pathstuff.h".
8740 * guile/scm-safe-call.c: Likewise.
8741 * linux-thread-db.c: Likewise.
8743 * nto-tdep.c: Likewise.
8744 * objfiles.c: Likewise.
8745 * source.c: Likewise.
8746 * symtab.c: Likewise.
8747 * utils.c: Include "common/pathstuff.h".
8748 (gdb_realpath): Move to "common/pathstuff.c".
8749 (gdb_realpath_keepfile): Likewise.
8750 (gdb_abspath): Likewise.
8751 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
8752 (gdb_realpath_keepfile): Likewise.
8753 (gdb_abspath): Likewise.
8755 2018-02-28 John Baldwin <jhb@FreeBSD.org>
8757 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
8758 wildcard process pid for super_resume for kernels with a
8761 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
8763 * compile/compile.c (get_args): Add additional comments
8764 explaining function.
8766 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
8767 Tom Tromey <tom@tromey.com>
8769 * target.h (memory_write_request_s): Remove typedef. Don't define
8771 (target_write_memory_blocks): Change argument to std::vector.
8772 (struct memory_write_request): Add constructor.
8773 * target-memory.c (compare_block_starting_address): Return bool.
8774 Change argument types.
8775 (claim_memory): Change arguments to use std::vector.
8776 (split_regular_and_flash_blocks, blocks_to_erase)
8777 (compute_garbled_blocks): Likewise.
8778 (cleanup_request_data, cleanup_write_requests_vector): Remove.
8779 (target_write_memory_blocks): Change argument to std::vector.
8780 * symfile.c (struct load_section_data): Add constructor and
8781 destructor. Use std::vector for "requests".
8782 (struct load_progress_data): Add initializers.
8783 (load_section_callback): Update. Use "new".
8784 (clear_memory_write_data): Remove.
8785 (generic_load): Update.
8787 2018-02-27 Alan Hayward <alan.hayward@arm.com>
8789 * arch/aarch64.h: Use common/tdesc.h.
8791 2018-02-26 Maciej W. Rozycki <macro@mips.com>
8793 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
8794 architecture with a 64-bit ABI.
8796 2018-02-26 Maciej W. Rozycki <macro@mips.com>
8798 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
8799 ahead of target description loading.
8801 2018-02-26 Tom Tromey <tom@tromey.com>
8803 * stack.c (backtrace_command_1): Update.
8804 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
8806 * python/py-framefilter.c (py_print_frame)
8807 (gdbpy_apply_frame_filter): Change type of "flags".
8808 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
8810 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
8811 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
8812 * extension.h (enum frame_filter_flag): Rename from
8814 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
8815 (apply_ext_lang_frame_filter): Change type of "flags".
8816 * extension.c (apply_ext_lang_frame_filter): Change type of
8818 * extension-priv.h (struct extension_language_ops)
8819 <apply_frame_filter>: Change type of "flags".
8821 2018-02-26 Tom Tromey <tom@tromey.com>
8824 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
8825 off-by-one in py_end computation.
8826 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
8828 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
8831 2018-02-26 Tom Tromey <tom@tromey.com>
8833 * dwarf2read.c (struct variant_field): New.
8834 (struct nextfield) <variant>: New field.
8835 (dwarf2_add_field): Handle DW_TAG_variant_part.
8836 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
8837 discriminated union.
8838 (read_structure_type): Handle DW_TAG_variant_part.
8839 (handle_struct_member_die): New function, extracted from
8840 process_structure_scope. Handle DW_TAG_variant.
8841 (process_structure_scope): Handle discriminated unions. Call
8842 handle_struct_member_die.
8844 2018-02-26 Tom Tromey <tom@tromey.com>
8846 * rust-lang.h (rust_last_path_segment): Declare.
8847 * rust-lang.c (rust_last_path_segment): Now public. Change
8849 (struct disr_info): Remove.
8850 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
8851 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
8852 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
8853 (rust_enum_p, rust_enum_variant): New function.
8854 (rust_underscore_fields): Remove "offset" parameter.
8855 (rust_print_enum): New function.
8856 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
8857 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
8858 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
8860 (rust_internal_print_type): New function, from rust_print_type.
8862 (rust_print_type): Call rust_internal_print_type.
8863 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
8864 Update enum handling.
8865 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
8866 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
8867 (rust_union_quirks): New functions.
8868 (process_full_comp_unit, process_full_type_unit): Call
8870 (process_structure_scope): Update rust_unions if necessary.
8872 2018-02-26 Tom Tromey <tom@tromey.com>
8874 * value.h (value_union_variant): Declare.
8875 * valops.c (value_union_variant): New function.
8876 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
8877 (struct discriminant_info): New.
8878 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
8880 (struct main_type) <flag_discriminated_union>: New field.
8882 2018-02-26 Tom Tromey <tom@tromey.com>
8884 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8885 unittests/unpack-selftests.c.
8886 * unittests/unpack-selftests.c: New file.
8887 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
8889 2018-02-26 Yao Qi <yao.qi@linaro.org>
8891 * dwarf2read.c (struct partial_die_info) <read>: New method.
8892 (read_partial_die): Remove the declaration.
8893 (load_partial_dies): Update.
8894 (partial_die_info::partial_die_info):
8895 (read_partial_die): Change it to partial_die_info::read.
8897 2018-02-26 Yao Qi <yao.qi@linaro.org>
8899 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
8900 (fixup_partial_die): Remove declaration.
8901 (scan_partial_symbols): Update.
8902 (partial_die_parent_scope): Likewise.
8903 (partial_die_full_name): Likewise.
8904 (fixup_partial_die): Change it to partial_die_info::fixup.
8906 2018-02-26 Yao Qi <yao.qi@linaro.org>
8908 * dwarf2read.c (read_partial_die): Update the declaration.
8909 (load_partial_dies): Caller update.
8910 (read_partial_die): Remove one argument abbrev_len.
8912 2018-02-26 Yao Qi <yao.qi@linaro.org>
8914 * dwarf2read.c (struct partial_die_info): Add ctor, delete
8915 assignment operator.
8916 (load_partial_dies): Use ctor and copy ctor.
8917 (read_partial_die): Update.
8918 (dwarf2_cu::find_partial_die): Use ctor.
8920 2018-02-26 Yao Qi <yao.qi@linaro.org>
8922 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
8923 (find_partial_die_in_comp_unit): Change it to
8924 dwarf2_cu::find_partial_die.
8925 (find_partial_die): Update.
8927 2018-02-26 Yao Qi <yao.qi@linaro.org>
8929 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
8932 2018-02-26 Yao Qi <yao.qi@linaro.org>
8934 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
8936 2018-02-26 Alan Hayward <alan.hayward@arm.com>
8938 * arch/amd64.h: Use common/tdesc.h.
8939 * arch/i386.c: Likewise.
8940 * arch/i386.h: Likewise.
8941 * arch/tic6x.c: Likewise.
8942 * arch/tdesc.h: Move file from here...
8943 * common/tdesc.h: ...to here.
8944 * features/aarch64-core.c: Regenerate.
8945 * features/aarch64-fpu.c: Regenerate.
8946 * features/i386/32bit-avx.c: Regenerate.
8947 * features/i386/32bit-avx512.c: Regenerate.
8948 * features/i386/32bit-core.c: Regenerate.
8949 * features/i386/32bit-linux.c: Regenerate.
8950 * features/i386/32bit-mpx.c: Regenerate.
8951 * features/i386/32bit-pkeys.c: Regenerate.
8952 * features/i386/32bit-sse.c: Regenerate.
8953 * features/i386/64bit-avx.c: Regenerate.
8954 * features/i386/64bit-avx512.c: Regenerate.
8955 * features/i386/64bit-core.c: Regenerate.
8956 * features/i386/64bit-linux.c: Regenerate.
8957 * features/i386/64bit-mpx.c: Regenerate.
8958 * features/i386/64bit-pkeys.c: Regenerate.
8959 * features/i386/64bit-segments.c: Regenerate.
8960 * features/i386/64bit-sse.c: Regenerate.
8961 * features/i386/x32-core.c: Regenerate.
8962 * features/tic6x-c6xp.c: Regenerate.
8963 * features/tic6x-core.c: Regenerate.
8964 * features/tic6x-gp.c: Regenerate.
8965 * target-descriptions.c: Use common/tdesc.h.
8966 * target-descriptions.h: Likewise.
8968 2018-02-24 Tom Tromey <tom@tromey.com>
8970 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
8971 (try_thread_db_load_from_dir, thread_db_load_search): Use
8973 (info_auto_load_libthread_db_compare): Return bool. Change
8975 (info_auto_load_libthread_db): Use std::vector, std::string.
8978 2018-02-24 Tom Tromey <tom@tromey.com>
8980 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
8982 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
8984 * gdbarch.c: Rebuild.
8985 * gdbarch.h: Rebuild.
8986 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
8987 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
8988 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
8991 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
8993 * gdbtypes.h (sect_offset): Change type to uint64_t.
8994 (sect_offset_str): New function.
8995 * dwarf2read.c (create_addrmap_from_aranges): Use
8997 (error_check_comp_unit_head): Likewise.
8998 (create_debug_type_hash_table): Likewise.
8999 (read_cutu_die_from_dwo): Likewise.
9000 (init_cutu_and_read_dies): Likewise.
9001 (init_cutu_and_read_dies_no_follow): Likewise.
9002 (process_psymtab_comp_unit_reader): Likewise.
9003 (partial_die_parent_scope): Likewise.
9004 (peek_die_abbrev): Likewise.
9005 (process_queue): Likewise.
9006 (dwarf2_physname): Likewise.
9007 (read_namespace_alias): Likewise.
9008 (read_import_statement): Likewise.
9009 (create_dwo_cu_reader): Likewise.
9010 (create_cus_hash_table): Likewise.
9011 (lookup_dwo_cutu): Likewise.
9012 (inherit_abstract_dies): Likewise.
9013 (read_func_scope): Likewise.
9014 (read_call_site_scope): Likewise.
9015 (dwarf2_add_member_fn): Likewise.
9016 (read_common_block): Likewise.
9017 (read_module_type): Likewise.
9018 (read_typedef): Likewise.
9019 (read_subrange_type): Likewise.
9020 (load_partial_dies): Likewise.
9021 (read_partial_die): Likewise.
9022 (find_partial_die): Likewise.
9023 (read_str_index): Likewise.
9024 (dwarf2_string_attr): Likewise.
9025 (build_error_marker_type): Likewise.
9026 (lookup_die_type): Likewise.
9027 (dump_die_shallow): Likewise.
9028 (follow_die_ref): Likewise.
9029 (dwarf2_fetch_die_loc_sect_off): Likewise.
9030 (dwarf2_fetch_constant_bytes): Likewise.
9031 (follow_die_sig): Likewise.
9032 (get_signatured_type): Likewise.
9033 (get_DW_AT_signature_type): Likewise.
9034 (dwarf2_find_containing_comp_unit): Likewise.
9035 (set_die_type): Likewise.
9037 2018-02-21 John Baldwin <jhb@FreeBSD.org>
9039 * arch/aarch64.c: Include "common-defs.h".
9040 * arch/amd64.c: Likewise.
9041 * arch/i386.c: Likewise.
9043 2018-02-21 Tom Tromey <tom@tromey.com>
9045 * value.h: (extract_field_op): Update.
9046 * eval.c (extract_field_op): Return a const char *.
9047 * expression.h (parse_expression_for_completion): Update.
9048 * completer.c (complete_expression): Update.
9049 (add_struct_fields): Make fieldname const.
9050 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
9051 (mark_completion_tag, parse_exp_in_context_1): Update.
9052 (parse_expression_for_completion): Change "name" to
9053 unique_xmalloc_ptr*.
9055 2018-02-21 Tom Tromey <tom@tromey.com>
9057 * infcall.c (call_function_by_hand_dummy): Use std::vector.
9059 2018-02-21 Yao Qi <yao.qi@linaro.org>
9061 * avr-tdep.c (avr_read_pc): Change parameter type to
9063 * gdbarch.sh (read_pc): Likewise.
9064 * gdbarch.c: Re-generated.
9065 * gdbarch.h: Re-generated.
9066 * hppa-tdep.c (hppa_read_pc): Change parameter type to
9068 * ia64-tdep.c (ia64_read_pc): Likewise.
9069 * mips-tdep.c (mips_read_pc): Likewise.
9070 * spu-tdep.c (spu_read_pc): Likewise.
9072 2018-02-21 Yao Qi <yao.qi@linaro.org>
9074 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
9075 * regcache-dump.c: New file.
9076 * regcache.c: Move register_dump to regcache-dump.c.
9077 (maintenance_print_registers): Likewise.
9078 (maintenance_print_raw_registers): Likewise.
9079 (maintenance_print_cooked_registers): Likewise.
9080 (maintenance_print_register_groups): Likewise.
9081 (maintenance_print_remote_registers): Likewise.
9082 (_initialize_regcache): Likewise.
9083 * regcache.h (register_dump): Moved from regcache.c.
9085 2018-02-21 Yao Qi <yao.qi@linaro.org>
9087 * regcache.c (regcache::regcache): Update.
9088 (regcache::invalidate): Move it to detached_regcache::invalidate.
9089 (get_thread_arch_aspace_regcache): Update.
9090 (regcache::raw_update): Update.
9091 (regcache::cooked_read): Remove some code.
9092 (regcache::cooked_read_value): Likewise.
9093 (regcache::raw_write): Remove assert on m_readonly_p.
9094 (regcache::raw_supply_integer): Move it to
9095 detached_regcache::raw_supply_integer.
9096 (regcache::raw_supply_zeroed): Likewise.
9097 * regcache.h (detached_regcache) <raw_supply_integer>: New
9099 <raw_supply_zeroed, invalidate>: Likewise.
9100 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
9101 <invalidate>: Likewise.
9102 <m_readonly_p>: Removed.
9104 2018-02-21 Yao Qi <yao.qi@linaro.org>
9106 * infcmd.c (get_return_value): Let stop_regs point to
9107 get_current_regcache.
9108 * regcache.c (regcache::regcache): Remove.
9109 (register_dump_reg_buffer): New class.
9110 (regcache_print): Adjust.
9111 * regcache.h (regcache): Remove constructors.
9113 2018-02-21 Yao Qi <yao.qi@linaro.org>
9115 * regcache.c (class register_dump): New class.
9116 (register_dump_regcache, register_dump_none): New class.
9117 (register_dump_remote, register_dump_groups): New class.
9118 (regcache_print): Update.
9119 * regcache.h (regcache_dump_what): Move it to regcache.c.
9120 (regcache) <dump>: Remove.
9122 2018-02-21 Yao Qi <yao.qi@linaro.org>
9124 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
9126 (jit_unwind_reg_set_impl): Call raw_supply.
9127 (jit_frame_sniffer): Use reg_buffer_rw.
9128 * record-full.c (record_full_core_regbuf): Change its type.
9129 (record_full_core_open_1): Use reg_buffer_rw.
9130 (record_full_close): Likewise.
9131 (record_full_core_fetch_registers): Use regcache->raw_supply.
9132 (record_full_core_store_registers): Likewise.
9133 * regcache.c (regcache::get_register_status): Move it to
9135 (regcache_raw_set_cached_value): Remove.
9136 (regcache::raw_set_cached_value): Remove.
9137 (regcache::raw_write): Call raw_supply.
9138 (regcache::raw_supply): Move it to reg_buffer_rw.
9139 * regcache.h (regcache_raw_set_cached_value): Remove.
9140 (reg_buffer_rw): New class.
9142 2018-02-21 Yao Qi <yao.qi@linaro.org>
9144 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
9145 readonly_detached_regcache.
9146 (dummy_frame_prev_register): Use regcache->cooked_read.
9147 * frame.c (frame_save_as_regcache): Change return type.
9148 (frame_pop): Update.
9149 * frame.h (frame_save_as_regcache): Update declaration.
9150 * inferior.h (get_infcall_suspend_state_regcache): Update
9152 * infrun.c (infcall_suspend_state) <registers>: use
9153 readonly_detached_regcache.
9154 (save_infcall_suspend_state): Don't use regcache_dup.
9155 (get_infcall_suspend_state_regcache): Change return type.
9156 * linux-fork.c (struct fork_info) <savedregs>: Change to
9157 readonly_detached_regcache.
9159 (fork_save_infrun_state): Don't use regcache_dup.
9160 (info_checkpoints_command): Adjust.
9161 * mi/mi-main.c (register_changed_p): Update declaration.
9162 (mi_cmd_data_list_changed_registers): Use
9163 readonly_detached_regcache.
9164 (register_changed_p): Change parameter type to
9165 readonly_detached_regcache.
9166 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
9167 readonly_detached_regcache.
9168 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
9169 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
9171 (regcache::save): Move it to reg_buffer.
9172 (regcache::restore): Change parameter type.
9173 (regcache_dup): Remove.
9174 * regcache.h (reg_buffer) <save>: New method.
9175 (readonly_detached_regcache): New class.
9176 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
9177 readonly_detached_regcache.
9178 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
9180 2018-02-21 Yao Qi <yao.qi@linaro.org>
9182 * frame.c (frame_save_as_regcache): Use regcache method save.
9183 (frame_pop): Use regcache method restore.
9184 * infrun.c (restore_infcall_suspend_state): Likewise.
9185 * linux-fork.c (fork_load_infrun_state): Likewise.
9186 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
9188 * regcache.c (regcache_save): Remove.
9189 (regcache::restore): More asserts.
9190 (regcache_cpy): Remove.
9191 * regcache.h (regcache_save): Remove the declaration.
9192 (regcache::restore): Move from private to public.
9193 Remove the friend declaration of regcache_cpy.
9194 (regcache_cpy): Remove declaration.
9196 2018-02-21 Yao Qi <yao.qi@linaro.org>
9198 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
9199 parameter type to 'readable_regcache *'.
9200 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9201 * arm-tdep.c (arm_neon_quad_read): Likewise.
9202 (arm_pseudo_read): Likewise.
9203 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9204 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9205 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9206 * gdbarch.c: Re-generated.
9207 * gdbarch.h: Re-generated.
9208 * gdbarch.sh (pseudo_register_read): Change parameter type to
9209 'readable_regcache *'.
9210 (pseudo_register_read_value): Likewise.
9211 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
9212 (h8300_pseudo_register_read): Likewise.
9213 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
9214 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9215 (i386_pseudo_register_read_into_value): Likewise.
9216 (i386_pseudo_register_read_value): Likewise.
9217 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
9219 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
9220 * m32c-tdep.c (m32c_raw_read): Likewise.
9221 (m32c_read_flg): Likewise.
9222 (m32c_banked_register): Likewise.
9223 (m32c_banked_read): Likewise.
9224 (m32c_sb_read): Likewise.
9225 (m32c_part_read): Likewise.
9226 (m32c_cat_read): Likewise.
9227 (m32c_r3r2r1r0_read): Likewise.
9228 (m32c_pseudo_register_read): Likewise.
9229 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9230 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9231 (mep_pseudo_cr64_read): Likewise.
9232 (mep_pseudo_register_read): Likewise.
9233 * mips-tdep.c (mips_pseudo_register_read): Likewise.
9234 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9235 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9236 * regcache.c (regcache::raw_read): Move it to readable_regcache.
9237 (regcache::cooked_read): Likewise.
9238 (regcache::cooked_read_value): Likewise.
9239 (regcache_cooked_read_signed):
9240 (regcache::cooked_read): Likewise.
9241 * regcache.h (readable_regcache): New class.
9242 (regcache): Inherit readable_regcache. Move some methods to
9244 * rl78-tdep.c (rl78_pseudo_register_read): Change
9245 parameter type to 'readable_regcache *'.
9246 * rs6000-tdep.c (do_regcache_raw_read): Remove.
9247 (e500_pseudo_register_read): Change parameter type to
9248 'readable_regcache *'.
9249 (dfp_pseudo_register_read): Likewise.
9250 (vsx_pseudo_register_read): Likewise.
9251 (efpr_pseudo_register_read): Likewise.
9252 * s390-tdep.c (s390_pseudo_register_read): Likewise.
9253 * sh-tdep.c (sh_pseudo_register_read): Likewise.
9254 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
9255 (sh64_pseudo_register_read): Likewise.
9256 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9257 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9258 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9259 (spu_pseudo_register_read): Likewise.
9260 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9261 (xtensa_pseudo_register_read): Likewise.
9263 2018-02-21 Yao Qi <yao.qi@linaro.org>
9265 * regcache.c (regcache::regcache): Call reg_buffer ctor.
9266 (regcache::arch): Move it to reg_buffer::arch.
9267 (regcache::register_buffer): Likewise.
9268 (regcache::assert_regnum): Likewise.
9269 (regcache::num_raw_registers): Likewise.
9270 * regcache.h (reg_buffer): New class.
9271 (regcache): Inherit reg_buffer.
9273 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
9275 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
9276 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
9278 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
9280 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
9282 2018-02-19 Alan Hayward <alan.hayward@arm.com>
9284 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
9285 (SFILES): Remove common/*.c files.
9286 (COMMON_OBS): Remove some *.o files built from common/*.c files.
9287 * common/common.host: Add common reference.
9288 * configure.ac: Likewise.
9289 * configure: Regenerate.
9291 2018-02-16 Yao Qi <yao.qi@linaro.org>
9293 * block.c (block_namespace_info): Inherit allocate_on_obstack.
9294 (block_initialize_namespace): Use new.
9295 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
9296 (dwarf2_free_objfile): Use delete.
9297 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
9298 (copy_type_recursive): Use new.
9299 * gdb_obstack.h (allocate_on_obstack): New.
9301 2018-02-15 Yao Qi <yao.qi@linaro.org>
9304 * inferior.c (exit_inferior_1): Reset inf->control.
9306 2018-02-15 Joel Brobecker <brobecker@adacore.com>
9308 * ada-lang.c (ada_to_fixed_value_create): Delete advance
9311 2018-02-14 Pedro Alves <palves@redhat.com>
9313 * frame-unwind.c (frame_unwind_try_unwinder): Always call
9314 frame_cleanup_after_sniffer on exception.
9316 2018-02-14 Tom Tromey <tom@tromey.com>
9318 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
9320 (solib_bfd_open): Make pathname const.
9321 * solib.c (solib_bfd_open): Make pathname const.
9322 * solib-spu.c (spu_bfd_fopen): Make name const.
9323 (spu_bfd_open): Make pathname const.
9324 * solib-darwin.c (darwin_bfd_open): Make pathname const.
9325 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
9327 2018-02-14 Tom Tromey <tom@tromey.com>
9329 * symfile.c (symfile_bfd_open): Update.
9330 * source.h (openp, source_full_path_of, find_and_open_source):
9331 Change argument type to unique_xmalloc_ptr.
9332 * source.c (openp): Take a unique_xmalloc_ptr.
9333 (source_full_path_of, find_and_open_source): Likewise.
9334 (open_source_file, symtab_to_fullname): Update.
9335 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
9337 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
9338 (exec_file_find): Update.
9339 * psymtab.c (psymtab_to_fullname): Update.
9340 * nto-tdep.h (nto_find_and_open_solib): Update.
9341 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
9343 * exec.c (exec_file_attach): Update.
9344 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
9345 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
9347 2018-02-14 Tom Tromey <tom@tromey.com>
9349 * solib.c: Include source.h.
9350 * nto-tdep.c: Include source.h.
9351 * mi/mi-cmd-env.c: Include source.h.
9352 * infcmd.c: Include source.h.
9353 * exec.c: Include source.h.
9354 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
9355 (add_path, directory_switch, source_path, init_source_path): Move
9357 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
9358 (add_path, directory_switch, source_path, init_source_path):
9361 2018-02-14 Tom Tromey <tom@tromey.com>
9363 * solist.h (exec_file_find, solib_find): Return
9365 (solib_bfd_fopen): Take a const char *.
9366 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
9367 (exec_file_find, solib_find): Likewise.
9368 (solib_bfd_fopen): Do not take ownership of "pathname".
9369 (solib_bfd_open): Use unique_xmalloc_ptr.
9370 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
9371 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
9372 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
9373 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
9375 2018-02-14 Joel Brobecker <brobecker@adacore.com>
9377 * ada-lang.c (name_match_type_from_name): Remove reference to
9378 ada_name_for_lookup in function's documentation.
9379 * ada-lang.h (ada_name_for_lookup): Delete declaration.
9381 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9383 * defs.h (enum openp_flags): New enum.
9384 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
9385 Move to enum openp_flags.
9386 (openp_flags): New enum flags.
9387 (openp): Change parameter type to openp_flags.
9388 * source.c (openp): Change parameter type to openp_flags.
9389 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
9390 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
9392 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9394 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
9397 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
9399 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
9401 (class dwarf2_queue_guard): ...the destructor of this new class.
9402 (dw2_do_instantiate_symtab): Create instance of the new class
9403 dwarf2_queue_guard, remove cleanup.
9405 2018-02-09 Tom Tromey <tom@tromey.com>
9407 * source.c (find_source_lines): Don't reference past the end of
9410 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9412 * remote.c (remote_btrace_maybe_reopen): Change error message.
9413 * btrace.c (btrace_enable): Likewise.
9414 (parse_xml_btrace): Likewise.
9415 (parse_xml_btrace_conf): Likewise.
9417 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9419 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
9420 (linux_enable_pt, linux_enable_bts): Call
9421 diagnose_perf_event_open_fail.
9423 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9425 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
9426 Remove parameter and change return type. Update callers. Move it.
9427 (linux_enable_bts, linux_enable_pt): Improve error message.
9428 (linux_enable_pt): Remove zero buffer size check.
9429 (linux_enable_btrace): Improve error messages. Remove NULL return
9432 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9434 * btrace.c (btrace_enable): Remove target_supports_btrace call.
9435 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
9436 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
9437 (linux_supports_pt, linux_supports_btrace): Remove.
9438 (linux_enable_bts): Call cpu_supports_bts.
9439 * nat/linux-btrace.h (linux_supports_btrace): Remove.
9440 * remote.c (remote_supports_btrace): Remove.
9441 (init_remote_ops): Remove remote_supports_btrace.
9442 * target-delegates.c: Regenerated.
9443 * target.c (target_supports_btrace): Remove.
9444 * target.h (target_ops) <to_supports_btrace>: Remove
9445 (target_supports_btrace): Remove.
9446 * x86-linux-nat.c (x86_linux_create_target): Remove
9447 linux_supports_btrace.
9449 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9451 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
9453 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
9454 exception and use message in own exception.
9456 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9458 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
9459 (perf_event_pt_event_type): Use gdb_file_up.
9460 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
9461 scoped_fd, and scoped_mmap.
9463 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9465 * common/scoped_mmap.h: New.
9466 * unittests/scoped_mmap-selftest.c: New.
9467 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9468 unittests/scoped_mmap-selftest.c.
9470 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9472 * common/scoped_fd.h: New.
9473 * unittests/scoped_fd-selftest.c: New.
9474 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9475 unittests/scoped_fd-selftest.c.
9477 2018-02-09 Tom Tromey <tom@tromey.com>
9479 * auto-load.c (auto_load_section_scripts): Use
9480 gdb::unique_xmalloc_ptr.
9482 2018-02-09 Tom Tromey <tom@tromey.com>
9484 * auto-load.c (execute_script_contents): Use std::string.
9486 2018-02-09 Joel Brobecker <brobecker@adacore.com>
9488 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
9489 Python function, rather than a new command.
9491 2018-02-08 Tom Tromey <tom@tromey.com>
9493 * solib.c (solib_find_1): Use std::string.
9494 (solib_bfd_fopen): Use unique_xmalloc_ptr.
9496 2018-02-08 Tom Tromey <tom@tromey.com>
9498 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
9500 2018-02-08 Tom Tromey <tom@tromey.com>
9502 * source.c (find_source_lines): Use gdb::def_vector.
9504 2018-02-08 Tom Tromey <tom@tromey.com>
9506 * macrocmd.c (struct temporary_macro_definition): New.
9507 (macro_define_command): Use temporary_macro_definition. Remove
9509 (free_macro_definition_ptr): Remove.
9511 2018-02-08 Tom Tromey <tom@tromey.com>
9513 * macroexp.c (maybe_expand): Use std::string.
9515 2018-02-08 Tom Tromey <tom@tromey.com>
9517 * macroexp.c (struct macro_buffer): Add initializers for some
9519 (init_buffer, init_shared_buffer, free_buffer)
9520 (free_buffer_return_text): Remove.
9521 (macro_buffer): New constructors.
9522 (~macro_buffer): New destructor.
9523 (macro_buffer::set_shared): New method.
9524 (macro_buffer::resize_buffer, macro_buffer::appendc)
9525 (macro_buffer::appendmem): Now methods, not free functions.
9526 (set_token, append_tokens_without_splicing, stringify)
9527 (macro_stringify): Update.
9528 (gather_arguments): Change return type. Remove argc_p argument,
9529 add args_ptr argument. Use std::vector.
9530 (substitute_args): Remove argc argument. Accept std::vector.
9531 (expand): Update. Use std::vector.
9532 (scan, macro_expand, macro_expand_next): Update.
9534 2018-02-08 Tom Tromey <tom@tromey.com>
9536 * symtab.c (default_collect_symbol_completion_matches_break_on):
9537 Use unique_xmalloc_ptr.
9538 * macroscope.h: (sal_macro_scope, user_macro_scope)
9539 (default_macro_scope): Return unique_xmalloc_ptr.
9540 * macroscope.c (sal_macro_scope, user_macro_scope)
9541 (default_macro_scope): Return unique_xmalloc_ptr.
9542 * macroexp.h (macro_expand, macro_expand_once): Return
9544 * macroexp.c (macro_expand, macro_expand_once): Return
9546 * macrocmd.c (macro_expand_command, macro_expand_once_command)
9547 (info_macro_command, info_macros_command): Use
9549 * compile/compile-c-support.c (write_macro_definitions): Use
9551 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
9553 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
9555 * value.c (value_static_field): Assign field type instead of
9556 containing type when returning an optimized out value.
9558 2018-02-06 Yao Qi <yao.qi@linaro.org>
9560 * ft32-tdep.c (ft32_read_pc): Remove.
9561 (ft32_write_pc): Remove.
9562 (ft32_gdbarch_init): Update.
9563 * m32r-tdep.c (m32r_read_pc): Remove.
9564 (m32r_gdbarch_init): Update.
9565 * mep-tdep.c (mep_read_pc): Remove.
9566 (mep_gdbarch_init): Update.
9567 * microblaze-tdep.c (microblaze_write_pc): Remove.
9568 (microblaze_gdbarch_init): Update.
9569 * mn10300-tdep.c (mn10300_read_pc): Remove.
9570 (mn10300_write_pc): Remove.
9571 (mn10300_gdbarch_init): Update.
9572 * moxie-tdep.c (moxie_read_pc): Remove.
9573 (moxie_write_pc): Remove.
9574 (moxie_gdbarch_init): Update.
9576 2018-02-06 Yao Qi <yao.qi@linaro.org>
9578 * expprint.c (print_subexp_standard): Handle
9579 OP_F77_UNDETERMINED_ARGLIST.
9580 (dump_subexp_body_standard): Likewise.
9582 2018-02-05 Alan Hayward <alan.hayward@arm.com>
9584 * target-descriptions.c (tdesc_element_visitor) Add empty
9586 (tdesc_type): Move make_gdb_type from here.
9587 (tdesc_type_builtin): Likewise.
9588 (tdesc_type_vector): Likewise.
9589 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
9590 (make_gdb_type_struct): Move from tdesc_type_with_fields.
9591 (make_gdb_type_union): Likewise.
9592 (make_gdb_type_flags): Likewise.
9593 (make_gdb_type_enum): Likewise.
9594 (make_gdb_type): New function.
9595 (tdesc_register_type): Use static make_gdb_type.
9597 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
9599 * infcmd.c (default_print_one_register_info): Align natural-format
9600 column values consistently one under another.
9601 (pad_to_column): New function.
9603 2018-02-05 Joel Brobecker <brobecker@adacore.com>
9605 * dwarf2read.c (dwarf2_physname): Move commment.
9607 2018-02-01 Leszek Swirski <leszeks@google.com>
9609 * varobj.c (varobj_formatted_print_options): Allow recursive
9610 pretty printing if pretty printing is enabled.
9612 2018-02-01 Leszek Swirski <leszeks@google.com>
9614 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
9615 names after a structop as a filename.
9617 2018-02-01 Yao Qi <yao.qi@linaro.org>
9619 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
9620 (arm_record_coproc_data_proc): Likewise.
9622 2018-02-01 Yao Qi <yao.qi@linaro.org>
9624 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
9626 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
9628 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
9629 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
9631 2018-01-31 Pedro Alves <palves@redhat.com>
9633 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
9634 * inflow.c (child_terminal_save_inferior): Wrap reference to
9635 tcgetpgrp in HAVE_TERMIOS_H.
9636 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
9638 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
9639 always iterate over all inferiors.
9640 (gdbsim_cntrl_c): Adjust.
9641 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
9643 2018-01-31 Joel Brobecker <brobecker@adacore.com>
9645 * gdbtypes.c (lookup_array_range_type): Make sure the array's
9646 index type is objfile-owned if the element type is as well.
9648 2018-01-31 Joel Brobecker <brobecker@adacore.com>
9652 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
9654 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
9655 "features/s390x-linux64.c".
9656 (_initialize_s390_linux_tdep): Remove initialization of tdescs
9657 s390_linux32 and s390x_linux64.
9658 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
9660 * s390-tdep.c: Include "features/s390-linux32.c" and
9661 "features/s390x-linux64.c".
9662 (s390_tdesc_valid): Add check for tdesc_has_registers.
9663 (s390_gdbarch_init): Make sure there is always a valid tdesc.
9664 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
9665 tdesc_s390x_linux64.
9666 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
9667 tdesc_s390x_linux64 to...
9668 * s390-tdep.h: ...here.
9670 2018-01-30 Pedro Alves <palves@redhat.com>
9673 * config.in, configure: Regenerate.
9674 * configure.ac: Check for getpgid.
9675 * go32-nat.c (go32_pass_ctrlc): New.
9676 (go32_target): Install it.
9677 * inf-child.c (inf_child_target): Install
9678 child_terminal_save_inferior, child_pass_ctrlc and
9680 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
9681 (inf_ptrace_target): No longer install it.
9682 * infcmd.c (interrupt_target_1): Adjust.
9683 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
9684 (child_interrupt): Declare.
9685 (inferior::terminal_state): New.
9686 * inflow.c (struct terminal_info): Update comments.
9687 (inferior_process_group): Delete.
9688 (terminal_is_ours): Delete.
9689 (gdb_tty_state): New.
9690 (child_terminal_init): Adjust.
9691 (is_gdb_terminal, sharing_input_terminal_1)
9692 (sharing_input_terminal): New functions.
9693 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
9694 Set the process's actual process group in the foreground if
9695 possible. Handle is_ours_for_output/is_ours distinction. Don't
9696 mark terminal as the inferior's if not sharing GDB's terminal.
9697 Don't check attach_flag.
9698 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
9699 pass down a target_terminal_state.
9700 (child_terminal_save_inferior): New, factored out from ...
9701 (child_terminal_ours_1): ... this. Handle
9702 target_terminal_state::is_ours_for_output.
9703 (child_interrupt, child_pass_ctrlc): New.
9704 (inflow_inferior_exit): Clear the inferior's terminal_state.
9705 (copy_terminal_info): Copy the inferior's terminal state.
9706 (_initialize_inflow): Remove reference to terminal_is_ours.
9707 * inflow.h (inferior_process_group): Delete.
9708 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
9709 * procfs.c (procfs_target): Don't install procfs_interrupt.
9710 (procfs_interrupt): Delete.
9711 * remote.c (remote_serial_quit_handler): Adjust.
9712 (remote_interrupt): Remove ptid parameter. Adjust.
9713 * target-delegates.c: Regenerate.
9714 * target.c: Include "terminal.h".
9715 (target_terminal::terminal_state): Rename to ...
9716 (target_terminal::m_terminal_state): ... this.
9717 (target_terminal::init): Adjust.
9718 (target_terminal::inferior): Adjust to per-inferior
9720 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
9721 (target_terminal::ours, target_terminal::ours_for_output): Use
9722 target_terminal_is_ours_kind.
9723 (target_interrupt): Remove ptid parameter. Adjust.
9724 (default_target_pass_ctrlc): Adjust.
9725 * target.h (target_ops::to_terminal_save_inferior): New field.
9726 (target_ops::to_interrupt): Remove ptid_t parameter.
9727 (target_interrupt): Remove ptid_t parameter. Update comment.
9728 (target_pass_ctrlc): Update comment.
9729 * target/target.h (target_terminal_state): New scoped enum,
9731 (target_terminal::terminal_state): ... here.
9732 (target_terminal::inferior): Update comments.
9733 (target_terminal::restore_inferior): New.
9734 (target_terminal::is_inferior, target_terminal::is_ours)
9735 (target_terminal::is_ours_for_output): Adjust.
9736 (target_terminal::scoped_restore_terminal_state): Adjust to
9737 rename, and call restore_inferior() instead of inferior().
9738 (target_terminal::scoped_restore_terminal_state::m_state): Change
9740 (target_terminal::terminal_state): Rename to ...
9741 (target_terminal::m_terminal_state): ... this and change type.
9743 2018-01-30 Pedro Alves <palves@redhat.com>
9745 * linux-nat.c (wait_for_signal): New function.
9746 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
9748 (async_terminal_is_ours)
9749 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
9750 (linux_nat_add_target): Don't override
9751 to_terminal_inferior/to_terminal_ours.
9753 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
9755 * remote.c (remote_follow_fork): Don't call "detach_inferior".
9757 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
9759 * dwarf2read.c (free_dwo_files): Add forward-declaration.
9760 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
9761 dwarf2_per_objfile_free here.
9762 (dwarf2_per_objfile_free): Remove.
9763 (_initialize_dwarf2_read): Don't register
9764 dwarf2_per_objfile_free as a registry cleanup.
9766 2018-01-27 Eli Zaretskii <eliz@gnu.org>
9768 Avoid compilation errors in MinGW native builds
9770 The error is triggered by including python-internal.h, and the
9773 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
9774 from build-gnulib/import/math.h:27,
9775 from d:/usr/Python26/include/pyport.h:235,
9776 from d:/usr/Python26/include/Python.h:58,
9777 from python/python-internal.h:94,
9778 from python/py-arch.c:24:
9779 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
9783 This happens because Python headers define 'hypot' to expand t
9784 '_hypot' in the Windows builds.
9785 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
9786 'hypoth'. This avoids a compilation error.
9788 2018-01-26 Alan Hayward <alan.hayward@arm.com>
9790 * MAINTAINERS (Write After Approval): Fix ordering.
9792 2018-01-26 Alan Hayward <alan.hayward@arm.com>
9794 * MAINTAINERS (Write After Approval): Add Alan Hayward.
9796 2018-01-26 Alan Modra <amodra@gmail.com>
9798 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
9799 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
9800 Remove nop. Make const. Comment.
9801 (powerpc32_plt_stub_so_2): New.
9802 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
9803 Correct count. Update uses.
9804 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
9805 Move common code reading PLT entry word. Correct
9806 powerpc32_plt_stub PLT address calculation.
9807 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
9808 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
9809 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
9810 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
9811 (ppc64_standard_linkage8): Likewise.
9812 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
9813 Correct insns description.
9814 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
9816 2018-01-24 Pedro Alves <palves@redhat.com>
9818 GCC PR libstdc++/83906
9819 * gdbtypes.c (operator==(const dynamic_prop &,
9820 const dynamic_prop &)): New.
9821 (operator==(const range_bounds &, const range_bounds &)): New.
9822 (check_types_equal): Use them instead of memcmp.
9823 * gdbtypes.h (operator==(const dynamic_prop &,
9824 const dynamic_prop &)): Declare.
9825 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
9826 (operator==(const range_bounds &, const range_bounds &)): Declare.
9827 (operator!=(const range_bounds &, const range_bounds &)): Declare.
9829 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9831 * s390-linux-tdep.c (s390_record_address_mask)
9832 (s390_record_calc_disp_common, s390_record_calc_disp)
9833 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
9834 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
9835 (s390_process_record): Move to s390-tdep.c.
9836 (s390_linux_init_abi_any): Adjust.
9837 * s390-tdep.c (s390_record_address_mask)
9838 (s390_record_calc_disp_common, s390_record_calc_disp)
9839 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
9840 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
9841 (s390_process_record): Moved from s390-linux-tdep.c
9842 (s390_gdbarch_init): Adjust.
9844 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9846 * s390-linux-nat.c (s390-tdep.h): New include.
9847 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
9848 (HFILES_NO_SRCDIR): Add s390-tdep.h.
9849 (ALLDEPFILES): Add s390-tdep.c.
9850 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
9851 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
9852 * s390-tdep.h: ...this. New file.
9853 * s390-linux-tdep.c (s390-tdep.h): New include.
9854 (_initialize_s390_tdep): Rename to...
9855 (_initialize_s390_linux_tdep): ...this and adjust.
9856 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
9857 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
9859 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
9860 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
9861 (s390_is_partial_instruction, s390_software_single_step)
9862 (is_non_branch_ril, s390_displaced_step_copy_insn)
9863 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
9864 (s390_prologue_data, s390_addr, s390_store, s390_load)
9865 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
9866 (s390_register_call_saved, s390_guess_tracepoint_registers)
9867 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
9868 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
9869 (s390_pseudo_register_name, s390_pseudo_register_type)
9870 (s390_pseudo_register_read, s390_pseudo_register_write)
9871 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
9872 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
9873 (s390_addr_bits_remove, s390_address_class_type_flags)
9874 (s390_address_class_type_flags_to_name)
9875 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
9876 (s390_function_arg_float, s390_function_arg_vector)
9877 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
9878 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
9879 (s390_frame_align, s390_register_return_value, s390_return_value)
9880 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
9881 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
9882 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
9883 (s390_trad_frame_prev_register, s390_unwind_cache)
9884 (s390_prologue_frame_unwind_cache)
9885 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
9886 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
9887 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
9888 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
9889 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
9890 (s390_frame_base_address, s390_local_base_address)
9891 (s390_frame_base, s390_gcc_target_options)
9892 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
9893 (s390_validate_reg_range, s390_tdesc_valid)
9894 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
9895 * s390-tdep.c: ...this. New file.
9897 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9899 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
9900 (s390_process_record, s390_gdbarch_tdep_alloc)
9901 (s390_linux_init_abi_any): Use/set new hook.
9903 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9905 * s390-linux-tdep.c (osabi.h): New include.
9906 (s390_linux_init_abi_31, s390_linux_init_abi_64)
9907 (s390_linux_init_abi_any): New functions.
9908 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
9910 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9912 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
9913 tdesc_has_registers check
9915 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9917 * s390-linux-tdep.c (s390_tdesc_valid): New function.
9918 (s390_validate_reg_range): New macro.
9919 (s390_gdbarch_init): Adjust.
9921 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9923 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
9924 (s390_gdbarch_tdep_alloc): Adjust.
9925 (s390_gdbarch_init): Adjust.
9927 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9929 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
9930 <have_tdb>: Change type to bool.
9931 (s390_gdbarch_tdep_alloc): Adjust.
9932 (s390_gdbarch_init): Adjust.
9934 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9936 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
9937 (gdbarch_tdep) <have_upper, have_vx>: New fields.
9938 (s390_gdbarch_tdep_alloc): New function.
9939 (s390_gdbarch_init): Allocate tdep at start and use its fields
9940 instead of separate variables.
9942 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9944 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
9945 when looking for cached gdbarch and add comment for remaining.
9947 2018-01-22 Pedro Alves <palves@redhat.com>
9948 Sergio Durigan Junior <sergiodj@redhat.com>
9950 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
9953 2018-01-22 Maciej W. Rozycki <macro@mips.com>
9955 * MAINTAINERS: Update my company e-mail address.
9957 2018-01-22 Yao Qi <yao.qi@linaro.org>
9959 * regcache.c (cooked_write_test): New function.
9960 (_initialize_regcache): Register the test.
9962 2018-01-22 Yao Qi <yao.qi@linaro.org>
9964 * ia64-tdep.c (ia64_pseudo_register_read): Call
9965 regcache->cooked_read instead of regcache_cooked_read_unsigned.
9966 * m32c-tdep.c (m32c_cat_read): Likewise.
9967 (m32c_r3r2r1r0_read): Likewise.
9968 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9969 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9971 2018-01-22 Yao Qi <yao.qi@linaro.org>
9973 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
9974 method raw_read instead of regcache_raw_read.
9975 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9976 * arm-tdep.c (arm_neon_quad_read): Likewise.
9977 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9978 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9979 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9980 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
9981 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9982 (i386_pseudo_register_read_into_value): Likewise.
9983 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9984 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9985 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9986 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
9987 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
9988 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9989 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9990 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9991 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
9993 2018-01-22 Yao Qi <yao.qi@linaro.org>
9995 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
9996 * configure.tgt: Remove target mt.
9997 * mt-tdep.c: Remove.
9998 * regcache.c (cooked_read_test): Remove the check for mt.
10000 2018-01-22 Yao Qi <yao.qi@linaro.org>
10002 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
10003 instead of gdbarch_pseudo_register_read_value.
10005 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10007 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
10010 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10012 * linespec.c (create_sals_line_offset): Remove code that preserved
10013 the symtab_and_line's line number.
10015 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10017 * varobj.c (varobj_create): Don't set valid_block when creating a
10020 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10022 * varobj.c (varobj_create): Remove out of date comment.
10024 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10027 * ada-exp.y (write_var_from_sym): Pass extra parameter when
10028 updating innermost block.
10029 * parse.c (innermost_block_tracker::update): Take extra type
10030 parameter, and check types match before updating innermost block.
10031 (write_dollar_variable): Update innermost block for registers.
10032 * parser-defs.h (enum innermost_block_tracker_type): New enum.
10033 (innermost_block_tracker::innermost_block_tracker): Initialise
10035 (innermost_block_tracker::reset): Take type parameter.
10036 (innermost_block_tracker::update): Take type parameter, and pass
10037 type through as needed.
10038 (innermost_block_tracker::m_types): New member.
10039 * varobj.c (varobj_create): Pass type when reseting innermost
10042 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10044 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
10045 * ada-lang.c (resolve_subexp): Likewise.
10046 * breakpoint.c (set_breakpoint_condition) Likewise.
10047 (watch_command_1) Likewise.
10048 * c-exp.y (variable): Likewise.
10049 * d-exp.y (PrimaryExpression): Likewise.
10050 * f-exp.y (variable): Likewise.
10051 * go-exp.y (variable): Likewise.
10052 * m2-exp.y (variable): Likewise.
10053 * objfiles.c (objfile::~objfile): Likewise.
10054 * p-exp.y (variable): Likewise.
10055 * parse.c (innermost_block): Change type.
10056 * parser-defs.h (class innermost_block_tracker): New.
10057 (innermost_block): Change to innermost_block_tracker.
10058 * printcmd.c (display_command): Switch to innermost_block API.
10059 (do_one_display): Likewise.
10060 * rust-exp.y (do_one_display): Likewise.
10061 * symfile.c (clear_symtab_users): Likewise.
10062 * varobj.c (varobj_create): Switch to innermost_block API, replace
10063 use of innermost_block with block stored on varobj object.
10065 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10067 * expression.h (innermost_block): Remove declaration.
10068 * varobj.c: Add 'parser-defs.h' include.
10070 2018-01-19 Tom Tromey <tom@tromey.com>
10072 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
10073 symbols in the static and global blocks.
10075 2018-01-19 James Clarke <jrtc27@jrtc27.com>
10077 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
10078 gdb_ptrace.h, and move including gdb_wait.h ...
10079 * nat/linux-ptrace.h: ... to here.
10081 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10083 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
10084 inf_ptrace_detach_success.
10085 (inf_ptrace_detach_success): Add inferior parameter, use it
10086 instead of inferior_ptid, pass it to detach_inferior.
10087 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
10089 * inferior.c (detach_inferior): Add overload that takes an
10091 * inferior.h (detach_inferior): Likewise.
10092 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
10093 use inferior_ptid, adjust call to inf_ptrace_detach_success.
10094 * linux-thread-db.c (thread_db_detach): Use inf parameter.
10096 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10098 * target.h (struct target_ops) <to_detach>: Add inferior
10100 (target_detach): Likewise.
10101 * target.c (dispose_inferior): Pass inferior down.
10102 (target_detach): Pass inferior down. Assert that it is equal to
10103 the current inferior.
10104 * aix-thread.c (aix_thread_detach): Pass inferior down.
10105 * corefile.c (core_file_command): Pass current_inferior() down.
10106 * corelow.c (core_detach): Add inferior parameter.
10107 * darwin-nat.c (darwin_detach): Likewise.
10108 * gnu-nat.c (gnu_detach): Likewise.
10109 * inf-ptrace.c (inf_ptrace_detach): Likewise.
10110 * infcmd.c (detach_command): Pass current_inferior() down to
10112 * infrun.c (follow_fork_inferior): Pass parent_inf to
10114 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
10116 * linux-nat.c (linux_nat_detach): Add inferior parameter.
10117 * linux-thread-db.c (thread_db_detach): Likewise.
10118 * nto-procfs.c (procfs_detach): Likewise.
10119 * procfs.c (procfs_detach): Likewise.
10120 * record.c (record_detach): Likewise.
10121 * record.h (struct inferior): Forward-declare.
10122 (record_detach): Add inferior parameter.
10123 * remote-sim.c (gdbsim_detach): Likewise.
10124 * remote.c (remote_detach_1): Likewise.
10125 (remote_detach): Likewise.
10126 (extended_remote_detach): Likewise.
10127 * sol-thread.c (sol_thread_detach): Likewise.
10128 * target-debug.h (target_debug_print_inferior_p): New macro.
10129 * target-delegates.c: Re-generate.
10130 * top.c (kill_or_detach): Pass inferior down to target_detach.
10131 * windows-nat.c (windows_detach): Add inferior parameter.
10133 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10135 * target.h (struct target_ops) <to_detach>: Remove args
10137 (target_detach): Likewise.
10138 * target.c (dispose_inferior): Adjust.
10139 (target_detach): Remove args parameter, adjust.
10140 * aix-thread.c (aix_thread_detach): Adjust.
10141 * corefile.c (core_file_command): Adjust.
10142 * corelow.c (core_detach): Adjust.
10143 * darwin-nat.c (darwin_detach): Adjust.
10144 * gnu-nat.c (gnu_detach): Adjust.
10145 * inf-ptrace.c (inf_ptrace_detach): Adjust.
10146 * infcmd.c (detach_command): Adjust
10147 * infrun.c (follow_fork_inferior): Adjust.
10148 (handle_vfork_child_exec_or_exit): Adjust.
10149 * linux-fork.c (linux_fork_detach): Remove args parameter.
10150 * linux-fork.h (linux_fork_detach): Likewise.
10151 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
10152 * linux-thread-db.c (thread_db_detach): Likewise.
10153 * nto-procfs.c (procfs_detach): Likewise.
10154 * procfs.c (procfs_detach): Likewise.
10155 (do_detach): Remove signo parameter.
10156 * record.c (record_detach): Remove args parameter.
10157 * record.h (record_detach): Likewise.
10158 * remote-sim.c (gdbsim_detach): Likewise.
10159 * remote.c (remote_detach_1): Likewise.
10160 (remote_detach): Likewise.
10161 (extended_remote_detach): Likewise.
10162 * sol-thread.c (sol_thread_detach): Likewise.
10163 * target-delegates.c: Re-generate.
10164 * top.c (struct qt_args) <args>: Remove field.
10165 (kill_or_detach): Don't pass args.
10166 (quit_force): Don't set args.
10167 * windows-nat.c (windows_detach): Remove args parameter.
10169 2018-01-19 Yao Qi <yao.qi@linaro.org>
10171 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
10172 (arm_linux_init_abi): Install it.
10174 2018-01-19 Yao Qi <yao.qi@linaro.org>
10176 * osabi.c (gdb_osabi_names): Extend the regexp for
10177 arm-linux-gnueabihf.
10179 2018-01-18 Yao Qi <yao.qi@linaro.org>
10181 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
10183 (abbrev_table::add_abbrev): Update.
10184 (abbrev_table::lookup_abbrev): Update.
10186 2018-01-18 Yao Qi <yao.qi@linaro.org>
10188 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
10190 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
10192 * compile/compile.c (compile_to_object): Convert "triplet_rx"
10195 2018-01-17 Tom Tromey <tom@tromey.com>
10197 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
10199 2018-01-17 Tom Tromey <tom@tromey.com>
10201 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
10202 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
10203 (create_array_type_with_stride): Update.
10204 * dwarf2read.c (set_die_type): Update.
10206 2018-01-17 Tom Tromey <tom@tromey.com>
10208 * dwarf2read.c (delayed_method_info): Remove typedef.
10209 (dwarf2_cu::method_info): Now a std::vector.
10210 (add_to_method_list): Update.
10211 (free_delayed_list): Remove.
10212 (compute_delayed_physnames): Update.
10213 (process_full_comp_unit, process_full_type_unit): Clear the method
10214 list. Remove cleanups.
10215 (psymtab_include_file_name): Add name_holder parameter. Use
10216 unique_xmalloc_ptr.
10217 (dwarf_decode_lines): Update.
10219 2018-01-17 Tom Tromey <tom@tromey.com>
10220 Simon Marchi <simon.marchi@ericsson.com>
10222 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
10223 (dwarf2_per_objfile::free_cached_comp_units)
10224 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10225 (init_cutu_and_read_dies_no_follow): Update.
10226 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
10227 (dwarf2_cu::~dwarf2_cu): New.
10228 (free_heap_comp_unit, free_stack_comp_unit): Remove.
10229 (age_cached_comp_units, free_one_cached_comp_unit): Update.
10231 2018-01-17 Tom Tromey <tom@tromey.com>
10232 Simon Marchi <simon.marchi@ericsson.com>
10234 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
10235 (struct die_reader_specs) <abbrev_table>: New member.
10236 (struct abbrev_table): Add constructor.
10237 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
10238 <abbrev_obstack>: Now an auto_obstack.
10239 (abbrev_table_up): New typedef.
10240 (init_cu_die_reader): Add abbrev_table parameter.
10241 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
10242 Add result_dwo_abbrev_table.
10243 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10244 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
10246 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
10248 (skip_children): Update.
10249 (abbrev_table::alloc_abbrev): Rename from
10250 abbrev_table_alloc_abbrev.
10251 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
10252 (abbrev_table::lookup_abbrev): Rename from
10253 abbrev_table_lookup_abbrev.
10254 (abbrev_table_read_table): Return abbrev_table_up.
10255 (abbrev_table_free, abbrev_table_free_cleanup)
10256 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
10257 (load_partial_dies): Update.
10259 2018-01-17 Tom Tromey <tom@tromey.com>
10261 * dwarf2read.c (dwarf2_compute_name): Update comment.
10262 (read_func_scope, read_variable): Update.
10263 (new_symbol): Remove.
10264 (new_symbol_full): Rename to new_symbol.
10266 2018-01-17 Mike Gulick <mgulick@mathworks.com>
10269 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
10270 a warning instead of throwing an error, set section size to 0 and return
10272 * gdb_bfd.h (gdb_bfd_map_section): Update description.
10274 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10276 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
10278 (linux_ptrace_attach_fail_reason_string): Likewise.
10279 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
10281 (linux_ptrace_attach_fail_reason_string): Likewise.
10282 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
10284 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10286 * linux-nat.c (linux_nat_attach): Remove xstrdup.
10288 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
10291 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
10292 checking for fs_base/gs_base fields in struct user_regs_struct.
10293 * configure: Regenerate.
10295 2018-01-17 Yao Qi <yao.qi@linaro.org>
10297 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
10299 (aarch64_linux_init_abi): Install it to gdbarch hook
10300 gcc_target_options.
10302 2018-01-15 Pedro Alves <palves@redhat.com>
10304 * common/signals-state-save-restore.c
10305 (save_original_signals_state): Fix typos.
10307 2017-01-12 Tom Tromey <tom@tromey.com>
10308 Sergio Durigan Junior <sergiodj@redhat.com>
10310 * Makefile.in (install-only): Install gdb-add-index.
10312 2018-01-12 John Baldwin <jhb@FreeBSD.org>
10314 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
10316 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10318 * infrun.c (keep_going_pass_signal): Clear step-over info when
10319 insert_breakpoints fails.
10321 2018-01-11 Pedro Alves <palves@redhat.com>
10324 * infrun.c (resume): Rename to ...
10325 (resume_1): ... this.
10326 (resume): Reimplement as wrapper around resume_1.
10328 2018-01-11 Pedro Alves <palves@redhat.com>
10331 * remote.c (remote_parse_stop_reply): Default to the last-set
10332 general thread instead of to 'magic_null_ptid'.
10334 2018-01-10 Pedro Alves <palves@redhat.com>
10336 * language.h (language_get_symbol_name_matcher): Rename ...
10337 (get_symbol_name_matcher): ... this.
10338 * language.c (language_get_symbol_name_matcher): Ditto.
10339 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
10342 2018-01-10 Pedro Alves <palves@redhat.com>
10346 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
10347 Adjust to use language_get_symbol_name_matcher instead of
10348 language_defn::la_get_symbol_name_matcher.
10349 * language.c (language_get_symbol_name_matcher): If in Ada mode
10350 and the lookup name is a verbatim match, return Ada's matcher.
10351 * language.h (language_get_symbol_name_matcher): Adjust comment.
10352 (ada_lookup_name_info::verbatim_p):: New method.
10354 2018-01-10 Pedro Alves <palves@redhat.com>
10357 * ada-lang.c (ada_collect_symbol_completion_matches): If the
10358 minsym's language is language_auto or language_cplus, pass down
10359 language_ada instead.
10360 * symtab.c (compare_symbol_name): Don't frob symbol language here.
10362 2018-01-10 Pedro Alves <palves@redhat.com>
10365 * minsyms.c (linkage_name_str): New function.
10366 (iterate_over_minimal_symbols): Use it.
10368 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10370 * NEWS: Document that 'info proc' now works on FreeBSD.
10372 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10374 * configure.ac: Check for kinfo_getfile in libutil.
10375 * configure: Regenerate.
10376 * config.in: Regenerate.
10377 * fbsd-nat.c: Include "fbsd-tdep.h".
10378 (fbsd_fetch_cmdline): New.
10379 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
10380 rather than calling error.
10381 (fbsd_info_proc): New.
10382 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
10383 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
10384 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
10386 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10388 * fbsd-nat.c (struct free_deleter): Remove.
10389 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
10391 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10393 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
10394 NULL for an empty pathname.
10396 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10398 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
10399 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
10400 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
10401 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
10402 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
10403 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
10404 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
10405 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
10406 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
10407 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
10408 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
10409 (fbsd_core_fetch_timeval, fbsd_print_sigset)
10410 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
10411 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
10412 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
10414 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
10416 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
10417 (gnu_xfer_auxv): New function.
10418 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
10419 TARGET_OBJECT_AUXV.
10421 2018-01-08 Yao Qi <yao.qi@linaro.org>
10422 Simon Marchi <simon.marchi@ericsson.com>
10424 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
10426 (COMMON_OBS): Remove selftest.o.
10427 * configure.ac: Append selftest-arch.c and common/selftest.c to
10428 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
10429 * configure: Re-generated.
10430 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
10432 (maintenance_info_selftests): Likewise.
10434 2018-01-08 Xavier Roirand <roirand@adacore.com>
10436 * ada-valprint.c (val_print_packed_array_elements): Use
10437 proper number of elements when printing an array indexed
10438 by an enumeration type.
10440 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10442 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
10443 (dw2_get_file_names_reader): Adjust.
10444 (lookup_dwo_signatured_type): Adjust.
10445 (lookup_dwp_signatured_type): Adjust.
10446 (lookup_signatured_type): Adjust.
10447 (create_type_unit_group): Adjust.
10448 (get_type_unit_group): Adjust.
10449 (process_psymtab_comp_unit_reader): Adjust.
10450 (build_type_psymtabs_reader): Adjust.
10451 (scan_partial_symbols): Adjust.
10452 (add_partial_symbol): Adjust.
10453 (add_partial_subprogram): Adjust.
10454 (peek_die_abbrev): Adjust.
10455 (fixup_go_packaging): Adjust.
10456 (process_imported_unit_die): Adjust.
10457 (dwarf2_compute_name): Adjust.
10458 (dwarf2_physname): Adjust.
10459 (read_import_statement): Adjust.
10460 (handle_DW_AT_stmt_list): Adjust.
10461 (read_file_scope): Adjust.
10462 (read_func_scope): Adjust.
10463 (read_lexical_block_scope): Adjust.
10464 (read_call_site_scope): Adjust.
10465 (read_variable): Adjust.
10466 (dwarf2_rnglists_process): Adjust.
10467 (dwarf2_ranges_process): Adjust.
10468 (dwarf2_ranges_read): Adjust.
10469 (dwarf2_get_pc_bounds): Adjust.
10470 (dwarf2_record_block_ranges): Adjust.
10471 (dwarf2_add_field): Adjust.
10472 (dwarf2_add_member_fn): Adjust.
10473 (read_structure_type): Adjust.
10474 (process_structure_scope): Adjust.
10475 (read_enumeration_type): Adjust.
10476 (read_array_type): Adjust.
10477 (mark_common_block_symbol_computed): Adjust.
10478 (read_common_block): Adjust.
10479 (read_namespace_type): Adjust.
10480 (read_namespace): Adjust.
10481 (read_module_type): Adjust.
10482 (read_tag_pointer_type): Adjust.
10483 (read_tag_ptr_to_member_type): Adjust.
10484 (read_tag_string_type): Adjust.
10485 (read_subroutine_type): Adjust.
10486 (read_typedef): Adjust.
10487 (read_base_type): Adjust.
10488 (attr_to_dynamic_prop): Adjust.
10489 (read_subrange_type): Adjust.
10490 (read_unspecified_type): Adjust.
10491 (dwarf2_read_abbrevs): Adjust.
10492 (load_partial_dies): Adjust.
10493 (read_partial_die): Adjust.
10494 (find_partial_die): Adjust.
10495 (guess_partial_die_structure_name): Adjust.
10496 (fixup_partial_die): Adjust.
10497 (read_attribute_value): Adjust.
10498 (read_addr_index): Adjust.
10499 (read_addr_index_from_leb128): Adjust.
10500 (read_str_index): Adjust.
10501 (dwarf2_string_attr): Adjust.
10502 (get_debug_line_section): Adjust.
10503 (dwarf_decode_line_header): Adjust.
10504 (lnp_state_machine::check_line_address): Adjust.
10505 (dwarf_decode_lines_1): Adjust.
10506 (dwarf_decode_lines): Adjust.
10507 (dwarf2_start_symtab): Adjust.
10508 (var_decode_location): Adjust.
10509 (new_symbol_full): Adjust.
10510 (dwarf2_const_value_data): Adjust.
10511 (dwarf2_const_value_attr): Adjust.
10512 (dwarf2_const_value): Adjust.
10513 (die_type): Adjust.
10514 (die_containing_type): Adjust.
10515 (build_error_marker_type): Adjust.
10516 (lookup_die_type): Adjust.
10517 (guess_full_die_structure_name): Adjust.
10518 (anonymous_struct_prefix): Adjust.
10519 (determine_prefix): Adjust.
10520 (dwarf2_name): Adjust.
10521 (follow_die_ref_or_sig): Adjust.
10522 (follow_die_offset): Adjust.
10523 (follow_die_ref): Adjust.
10524 (follow_die_sig_1): Adjust.
10525 (follow_die_sig): Adjust.
10526 (get_signatured_type): Adjust.
10527 (get_DW_AT_signature_type): Adjust.
10528 (decode_locdesc): Adjust.
10529 (dwarf_decode_macros): Adjust.
10530 (cu_debug_loc_section): Adjust.
10531 (fill_in_loclist_baton): Adjust.
10532 (dwarf2_symbol_mark_computed): Adjust.
10533 (init_one_comp_unit): Don't assign
10534 dwarf2_cu::dwarf2_per_objfile.
10535 (set_die_type): Adjust.
10537 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10539 * dwarf2read.c (struct mapped_debug_names): Add constructor.
10540 <dwarf2_per_objfile>: New field.
10541 (dwarf2_per_objfile): Remove global.
10542 (get_dwarf2_per_objfile): New function.
10543 (set_dwarf2_per_objfile): New function.
10544 (dwarf2_build_psymtabs_hard): Change objfile parameter to
10545 dwarf2_per_objfile.
10546 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10547 (read_abbrev_offset): Likewise.
10548 (read_indirect_string): Likewise.
10549 (read_indirect_line_string): Likewise.
10550 (read_indirect_string_at_offset): Likewise.
10551 (read_indirect_string_from_dwz): Likewise.
10552 (dwarf2_find_containing_comp_unit): Change objfile parameter to
10553 dwarf2_per_objfile.
10554 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
10555 (create_all_comp_units): Change objfile parameter to
10556 dwarf2_per_objfile.
10557 (create_all_type_units): Likewise.
10558 (process_queue): Add dwarf2_per_objfile parameter.
10559 (read_and_check_comp_unit_head): Likewise.
10560 (lookup_dwo_unit_in_dwp): Likewise.
10561 (get_dwp_file): Likewise.
10562 (process_cu_includes): Likewise.
10563 (struct free_dwo_file_cleanup_data): New struct.
10564 (dwarf2_has_info): Use get_dwarf2_per_objfile and
10565 set_dwarf2_per_objfile.
10566 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
10567 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
10568 context, adjust calls.
10569 (dw2_instantiate_symtab): Likewise.
10570 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
10571 (dw2_get_cu): Likewise.
10572 (create_cu_from_index_list): Change objfile parameter to
10573 dwarf2_per_objfile.
10574 (create_cus_from_index_list): Get dwarf2_per_objfile from
10575 context, adjust calls.
10576 (create_cus_from_index): Likewise.
10577 (create_signatured_type_table_from_index): Change objfile
10578 parameter to dwarf2_per_objfile.
10579 (create_signatured_type_table_from_debug_names): Change objfile
10580 parameter to dwarf2_per_objfile.
10581 (create_addrmap_from_index): Likewise.
10582 (create_addrmap_from_aranges): Likewise.
10583 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
10584 (dw2_setup): Remove.
10585 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
10587 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
10588 get_dwarf2_per_objfile.
10589 (dw2_forget_cached_source_info): Likewise.
10590 (dw2_map_symtabs_matching_filename): Likewise.
10591 (struct dw2_symtab_iterator) <index>: Remove.
10592 <dwarf2_per_objfile>: New field.
10593 (dw2_symtab_iter_init): Replace index parameter with
10594 dwarf2_per_objfile.
10595 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
10596 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
10597 (dw2_print_stats): Likewise.
10598 (dw2_dump): Likewise.
10599 (dw2_expand_symtabs_for_function): Likewise.
10600 (dw2_expand_all_symtabs): Likewise.
10601 (dw2_expand_symtabs_with_fullname): Likewise.
10602 (dw2_expand_marked_cus): Replace index and objfile parameters
10603 with dwarf2_per_objfile.
10604 (dw_expand_symtabs_matching_file_matcher): Add
10605 dwarf2_per_objfile parameter and adjust calls.
10606 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
10608 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
10609 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
10611 (create_cus_from_debug_names_list): Replace objfile parameter
10612 with dwarf2_per_objfile and adjust calls.
10613 (create_cus_from_debug_names): Likewise.
10614 (dwarf2_read_debug_names): Likewise.
10615 (mapped_debug_names::namei_to_name): Adjust call.
10616 (dw2_debug_names_iterator::next): Likewise.
10617 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
10618 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
10619 (dw2_debug_names_dump): Likewise.
10620 (dw2_debug_names_expand_symtabs_for_function): Likewise.
10621 (dw2_debug_names_expand_symtabs_matching): Likewise.
10622 (dwarf2_initialize_objfile): Likewise.
10623 (dwarf2_build_psymtabs): Likewise.
10624 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
10626 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
10627 (read_and_check_comp_unit_head): Likewise.
10628 (read_abbrev_offset): Likewise.
10629 (create_debug_type_hash_table): Likewise.
10630 (create_debug_types_hash_table): Likewise.
10631 (create_all_type_units): Replace objfile parameter with
10632 dwarf2_per_objfile.
10633 (add_type_unit): Add dwarf2_per_objfile parameter.
10634 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
10635 with dwarf2_per_objfile.
10636 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
10637 (lookup_dwp_signatured_type): Likewise.
10638 (lookup_signatured_type): Likewise.
10639 (read_cutu_die_from_dwo): Likewise.
10640 (init_tu_and_read_dwo_dies): Likewise.
10641 (init_cutu_and_read_dies): Likewise.
10642 (init_cutu_and_read_dies_no_follow): Likewise.
10643 (allocate_type_unit_groups_table): Add objfile parameter.
10644 (create_type_unit_group): Use dwarf2_per_objfile from cu.
10645 (get_type_unit_group): Likewise.
10646 (process_psymtab_comp_unit): Update call.
10647 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
10648 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
10649 (print_tu_stats): Likewise.
10650 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
10651 in void* parameter.
10652 (build_type_psymtabs): Change objfile parameter to
10653 dwarf2_per_objfile.
10654 (process_skeletonless_type_unit): Use dwarf2_per_objfile
10655 passed in void* parameter.
10656 (process_skeletonless_type_units): Change objfile parameter to
10657 dwarf2_per_objfile.
10658 (set_partial_user): Likewise.
10659 (dwarf2_build_psymtabs_hard): Likewise.
10660 (read_comp_units_from_section): Likewise.
10661 (create_all_comp_units): Likewise.
10662 (scan_partial_symbols): Update calls.
10663 (add_partial_symbol): Likewise.
10664 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
10665 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
10666 (process_queue): Add dwarf2_per_objfile parameter.
10667 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
10668 (compute_compunit_symtab_includes): Likewise.
10669 (process_cu_includes): Add dwarf2_per_objfile parameter.
10670 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
10671 (process_full_type_unit): Likewise.
10672 (process_imported_unit_die): Update call.
10673 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
10674 (read_file_scope): Likewise.
10675 (allocate_dwo_file_hash_table): Add objfile parameter.
10676 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
10677 (create_cus_hash_table): Likewise.
10678 (create_dwp_hash_table): Likewise.
10679 (create_dwo_unit_in_dwp_v1): Likewise.
10680 (create_dwp_v2_section): Likewise.
10681 (create_dwo_unit_in_dwp_v2): Likewise.
10682 (lookup_dwo_unit_in_dwp): Likewise.
10683 (try_open_dwop_file): Likewise.
10684 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
10685 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
10686 cleanup to include a reference to dwarf2_per_objfile.
10687 (open_dwp_file): Add dwarf2_per_objfile parameter.
10688 (open_and_init_dwp_file): Likewise.
10689 (get_dwp_file): Likewise.
10690 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
10691 (queue_and_load_all_dwo_tus): Update call.
10692 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
10694 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
10695 (dwarf2_ranges_process): Likewise.
10696 (dwarf2_get_pc_bounds): Likewise.
10697 (mark_common_block_symbol_computed): Likewise.
10698 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10699 (dwarf2_read_abbrevs): Update call.
10700 (read_partial_die): Use dwarf2_per_objfile from cu.
10701 (find_partial_die): Likewise.
10702 (fixup_partial_die): Likewise.
10703 (read_attribute_value): Likewise.
10704 (read_indirect_string_at_offset_from): Add objfile parameter.
10705 (read_indirect_string_at_offset): Add dwarf2_per_objfile
10707 (read_indirect_string_from_dwz): Add objfile parameter.
10708 (read_indirect_string): Add objfile parameter.
10709 (read_addr_index_1): Add dwarf2_per_objfile parameter.
10710 (read_addr_index): Use dwarf2_per_objfile from cu.
10711 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
10713 (read_str_index): Use dwarf2_per_objfile from cu.
10714 (get_debug_line_section): Likewise.
10715 (read_formatted_entries): Add dwarf2_per_objfile parameter.
10716 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
10717 (new_symbol_full): Use dwarf2_per_objfile from cu.
10718 (build_error_marker_type): Likewise.
10719 (lookup_die_type): Likewise.
10720 (determine_prefix): Likewise.
10721 (follow_die_offset): Likewise.
10722 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
10723 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
10724 (dwarf2_fetch_die_type_sect_off): Likewise.
10725 (dwarf2_get_die_type): Likewise.
10726 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
10727 (get_signatured_type): Likewise.
10728 (get_DW_AT_signature_type): Likewise.
10729 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
10730 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
10731 (cu_debug_loc_section): Likewise.
10732 (fill_in_loclist_baton): Likewise.
10733 (dwarf2_symbol_mark_computed): Likewise.
10734 (dwarf2_find_containing_comp_unit): Change objfile parameter to
10735 dwarf2_per_objfile.
10736 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
10738 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
10739 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
10740 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
10741 (set_die_type): Use dwarf2_free_objfile from cu.
10742 (get_die_type_at_offset): Likewise.
10743 (dwarf2_per_objfile_free): Don't assign global variable.
10744 (debug_names) <constructor>: Add dwarf2_per_objfile
10745 parameter, update m_debugstrlookup construction.
10746 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
10748 <m_dwarf2_per_objfile>: New field.
10749 <lookup>: Use m_dwarf2_per_objfile.
10750 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
10751 (psyms_seen_size): Likewise.
10752 (write_gdbindex): Replace objfile parameter with
10753 dwarf2_per_objfile.
10754 (write_debug_names): Likewise.
10755 (write_psymtabs_to_index): Likewise.
10756 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
10759 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10761 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
10762 <dwarf2_per_objfile>: New field.
10763 (struct dwarf2_per_cu_data) <objfile>: Remove.
10764 <dwarf2_per_objfile>: New field.
10765 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
10767 (create_signatured_type_table_from_index): Likewise.
10768 (create_debug_type_hash_table): Likewise.
10769 (fill_in_sig_entry_from_dwo_entry): Likewise.
10770 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
10771 (create_type_unit_group): Assign dwarf2_per_objfile instead of
10773 (create_partial_symtab): Access objfile through
10774 dwarf2_per_objfile.
10775 (process_psymtab_comp_unit_reader): Likewise.
10776 (read_comp_units_from_section): Likewise.
10777 (scan_partial_symbols): Likewise.
10778 (add_partial_symbol): Likewise.
10779 (add_partial_subprogram): Likewise.
10780 (peek_die_abbrev): Likewise.
10781 (fixup_go_packaging): Likewise.
10782 (process_full_comp_unit): Likewise.
10783 (process_full_type_unit): Likewise.
10784 (process_imported_unit_die): Likewise.
10785 (dwarf2_compute_name): Likewise.
10786 (dwarf2_physname): Likewise.
10787 (read_import_statement): Likewise.
10788 (create_cus_hash_table): Assign dwarf2_physname instead of
10790 (read_func_scope): Access objfile through dwarf2_per_objfile.
10791 (read_lexical_block_scope): Likewise.
10792 (read_call_site_scope): Likewise.
10793 (read_variable): Likewise.
10794 (dwarf2_rnglists_process): Likewise.
10795 (dwarf2_ranges_process): Likewise.
10796 (dwarf2_ranges_read): Likewise.
10797 (dwarf2_record_block_ranges): Likewise.
10798 (dwarf2_add_field): Likewise.
10799 (dwarf2_add_member_fn): Likewise.
10800 (read_structure_type): Likewise.
10801 (process_structure_scope): Likewise.
10802 (read_enumeration_type): Likewise.
10803 (read_array_type): Likewise.
10804 (read_common_block): Likewise.
10805 (read_namespace_type): Likewise.
10806 (read_namespace): Likewise.
10807 (read_module_type): Likewise.
10808 (read_tag_pointer_type): Likewise.
10809 (read_tag_ptr_to_member_type): Likewise.
10810 (read_tag_string_type): Likewise.
10811 (read_subroutine_type): Likewise.
10812 (read_typedef): Likewise.
10813 (read_base_type): Likewise.
10814 (attr_to_dynamic_prop): Likewise.
10815 (read_subrange_type): Likewise.
10816 (read_unspecified_type): Likewise.
10817 (load_partial_dies): Likewise.
10818 (read_partial_die): Likewise.
10819 (find_partial_die): Likewise.
10820 (guess_partial_die_structure_name): Likewise.
10821 (fixup_partial_die): Likewise.
10822 (read_attribute_value): Likewise.
10823 (read_addr_index_from_leb128): Likewise.
10824 (dwarf2_read_addr_index): Likewise.
10825 (dwarf2_string_attr): Likewise.
10826 (lnp_state_machine::check_line_address): Likewise.
10827 (dwarf_decode_lines_1): Likewise.
10828 (dwarf_decode_lines): Likewise.
10829 (dwarf2_start_symtab): Likewise.
10830 (var_decode_location): Likewise.
10831 (new_symbol_full): Likewise.
10832 (dwarf2_const_value_data): Likewise.
10833 (dwarf2_const_value_attr): Likewise.
10834 (dwarf2_const_value): Likewise.
10835 (die_type): Likewise.
10836 (die_containing_type): Likewise.
10837 (lookup_die_type): Likewise.
10838 (guess_full_die_structure_name): Likewise.
10839 (anonymous_struct_prefix): Likewise.
10840 (dwarf2_name): Likewise.
10841 (follow_die_ref_or_sig): Likewise.
10842 (follow_die_offset): Likewise.
10843 (follow_die_ref): Likewise.
10844 (dwarf2_fetch_die_loc_sect_off): Likewise.
10845 (dwarf2_fetch_constant_bytes): Likewise.
10846 (dwarf2_fetch_die_type_sect_off): Likewise.
10847 (dwarf2_get_die_type): Likewise.
10848 (follow_die_sig): Likewise.
10849 (decode_locdesc): Likewise.
10850 (dwarf2_per_cu_objfile): Likewise.
10851 (dwarf2_per_cu_text_offset): Likewise.
10852 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
10854 (set_die_type): Access objfile through
10855 dwarf2_per_objfile.
10857 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10859 * valprint.c (converted_character_d): Remove typedef.
10860 (DEF_VEC_O (converted_character_d)): Remove.
10861 (count_next_character): Use std::vector.
10862 (print_converted_chars_to_obstack): Likewise.
10863 (generic_printstr): Likewise.
10865 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10867 * xml-support.h (struct gdb_xml_value): Add constructor.
10868 <value>: Change type to unique_xmalloc_ptr.
10869 (gdb_xml_value_s): Remove typedef.
10870 (DEF_VEC_O (gdb_xml_value_s)): Remove.
10871 (gdb_xml_element_start_handler): Change parameter type to
10873 (xml_find_attribute): Likewise.
10874 * xml-support.c (xml_find_attribute): Change parameter type to
10875 std::vector and adjust.
10876 (gdb_xml_values_cleanup): Remove.
10877 (gdb_xml_parser::start_element): Adjust to std::vector.
10878 (xinclude_start_include): Change paraeter type to std::vector
10880 * btrace.c (check_xml_btrace_version): Likewise.
10881 (parse_xml_btrace_block): Likewise.
10882 (parse_xml_btrace_pt_config_cpu): Likewise.
10883 (parse_xml_btrace_pt): Likewise.
10884 (parse_xml_btrace_conf_bts): Likewise.
10885 (parse_xml_btrace_conf_pt): Likewise.
10886 * memory-map.c (memory_map_start_memory): Likewise.
10887 (memory_map_start_property): Likewise.
10888 * osdata.c (osdata_start_osdata): Likewise.
10889 (osdata_start_item): Likewise.
10890 (osdata_start_column): Likewise.
10891 * remote.c (start_thread): Likewise.
10892 * solib-aix.c (library_list_start_library): Likewise.
10893 (library_list_start_list): Likewise.
10894 * solib-svr4.c (library_list_start_library): Likewise.
10895 (svr4_library_list_start_list): Likewise.
10896 * solib-target.c (library_list_start_segment): Likewise.
10897 (library_list_start_section): Likewise.
10898 (library_list_start_library): Likewise.
10899 (library_list_start_list): Likewise.
10900 * tracepoint.c (traceframe_info_start_memory): Likewise.
10901 (traceframe_info_start_tvar): Likewise.
10902 * xml-syscall.c (syscall_start_syscall): Likewise.
10903 * xml-tdesc.c (tdesc_start_target): Likewise.
10904 (tdesc_start_feature): Likewise.
10905 (tdesc_start_reg): Likewise.
10906 (tdesc_start_union): Likewise.
10907 (tdesc_start_struct): Likewise.
10908 (tdesc_start_flags): Likewise.
10909 (tdesc_start_enum): Likewise.
10910 (tdesc_start_field): Likewise.
10911 (tdesc_start_enum_value): Likewise.
10912 (tdesc_start_vector): Likewise.
10914 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10916 * extension.h (struct xmethod_worker) <clone>: Remove.
10917 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
10919 (python_xmethod_worker::clone): Remove.
10920 * valops.c (find_overload_match): Use std::move instead of
10923 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10925 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
10926 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
10927 <free_xmethod_worker_data>: Remove.
10928 <get_matching_xmethod_workers>: Chance VEC to std::vector.
10929 <get_xmethod_arg_types>: Remove.
10930 <get_xmethod_result_type>: Remove.
10931 <invoke_xmethod>: Remove.
10932 * extension.c (new_xmethod_worker): Remove.
10933 (clone_xmethod_worker): Remove.
10934 (get_matching_xmethod_workers): Return void, pass std::vector by
10936 (get_xmethod_arg_types): Rename to...
10937 (xmethod_worker::get_arg_types): ... this, and adjust.
10938 (get_xmethod_result_type): Rename to...
10939 (xmethod_worker::get_result_type): ... this, and adjust.
10940 (invoke_xmethod): Remove.
10941 (free_xmethod_worker): Remove.
10942 (free_xmethod_worker_vec): Remove.
10943 * extension.h (enum ext_lang_rc): Move here from
10945 (struct xmethod_worker): Add constructor and destructor.
10948 <invoke, clone, do_get_result_type, do_get_arg_types>: New
10949 virtual pure methods.
10950 <get_arg_types, get_result_type>: New methods.
10951 (xmethod_worker_ptr): Remove typedef.
10952 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
10953 (xmethod_worker_vec): Remove typedef.
10954 (xmethod_worker_up): New typedef.
10955 (invoke_xmethod): Remove.
10956 (clone_xmethod_worker): Remove.
10957 (free_xmethod_worker): Remove.
10958 (free_xmethod_worker_vec): Remove.
10959 (get_xmethod_arg_types): Remove.
10960 (get_xmethod_result_type): Remove.
10961 * valops.c (find_method_list): Use std::vector, don't use
10962 intermediate vector.
10963 (value_find_oload_method_list): Use std::vector.
10964 (find_overload_match): Use std::vector.
10965 (find_oload_champ): Use std::vector.
10966 * value.c (value_free): Use operator delete.
10967 (value_of_xmethod): Rename to...
10968 (value_from_xmethod): ... this. Don't assign
10969 xmethod_worker::value, take rvalue-reference.
10970 (result_type_of_xmethod): Adjust.
10971 (call_xmethod): Adjust.
10972 * value.h: Include extension.h.
10973 (struct xmethod_worker): Don't forward-declare.
10974 (value_of_xmethod): Rename to...
10975 (value_from_xmethod): ... this, take rvalue-reference.
10976 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
10977 (struct python_xmethod_worker): ... this, add constructor and
10979 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
10980 (gdbpy_free_xmethod_worker_data): Rename to...
10981 (python_xmethod_worker::~python_xmethod_worker): ... this and
10983 (gdbpy_clone_xmethod_worker_data): Rename to...
10984 (python_xmethod_worker::clone): ... this and adjust.
10985 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
10987 (gdbpy_get_xmethod_arg_types): Rename to...
10988 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
10989 (gdbpy_get_xmethod_result_type): Rename to...
10990 (python_xmethod_worker::do_get_result_type): ... this and
10992 (gdbpy_invoke_xmethod): Rename to...
10993 (python_xmethod_worker::invoke): ... this and adjust.
10994 (new_python_xmethod_worker): Rename to...
10995 (python_xmethod_worker::python_xmethod_worker): ... this and
10997 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
10999 (gdbpy_free_xmethod_worker_data): Remove.
11000 (gdbpy_get_matching_xmethod_workers): Use std::vector.
11001 (gdbpy_get_xmethod_arg_types): Remove.
11002 (gdbpy_get_xmethod_result_type): Remove.
11003 (gdbpy_invoke_xmethod): Remove.
11004 * python/python.c (python_extension_ops): Remove obsolete
11007 2018-01-05 Pedro Alves <palves@redhat.com>
11010 * common/signals-state-save-restore.c
11011 (save_original_signals_state): New parameter 'quiet'. Warn if we
11012 find a custom handler preinstalled, instead of internal erroring.
11013 But only warn if !quiet.
11014 * common/signals-state-save-restore.h
11015 (save_original_signals_state): New parameter 'quiet'.
11016 * main.c (captured_main_1): Move save_original_signals_state call
11017 after option handling, and pass QUIET.
11019 2018-01-05 Pedro Alves <palves@redhat.com>
11021 * spu-tdep.c (spu_catch_start): Pass
11022 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
11024 2018-01-05 Pedro Alves <palves@redhat.com>
11027 * ada-lang.c (literal_symbol_name_matcher): New function.
11028 (ada_get_symbol_name_matcher): Use it for
11029 symbol_name_match_type::SEARCH_NAME.
11030 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
11031 it down instead of assuming symbol_name_match_type::FULL.
11032 * block.h (block_lookup_symbol): New parameter 'match_type'.
11033 * c-valprint.c (print_unpacked_pointer): Use
11034 lookup_symbol_search_name instead of lookup_symbol.
11035 * compile/compile-object-load.c (get_out_value_type): Pass down
11036 symbol_name_match_type::SEARCH_NAME.
11037 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
11038 symbol_name_match_type::FULL.
11039 * cp-support.c (cp_get_symbol_name_matcher): Handle
11040 symbol_name_match_type::SEARCH_NAME.
11041 * infrun.c (insert_exception_resume_breakpoint): Use
11042 lookup_symbol_search_name.
11043 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
11044 * psymtab.c (maintenance_check_psymtabs): Use
11045 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
11046 * stack.c (print_frame_args): Use lookup_symbol_search_name and
11047 SYMBOL_SEARCH_NAME.
11048 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
11049 if symbol_name_match_type::SEARCH_NAME.
11050 (lookup_symbol_in_language): Pass down
11051 symbol_name_match_type::FULL.
11052 (lookup_symbol_search_name): New.
11053 (lookup_language_this): Pass down
11054 symbol_name_match_type::SEARCH_NAME.
11055 (lookup_symbol_aux, lookup_local_symbol): New parameter
11056 'match_type'. Pass it down.
11057 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
11058 (lookup_symbol_search_name): New declaration.
11059 (lookup_symbol_in_block): New 'match_type' parameter.
11061 2018-01-05 Pedro Alves <palves@redhat.com>
11064 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
11066 (ada_lookup_symbol): Reimplement in terms of
11067 ada_lookup_symbol_list, bits factored out from
11068 ada_lookup_encoded_symbol.
11070 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11072 * ada-exp.y (write_object_renaming): When subscripting an array
11073 using a symbol as the index, pass the block in call to
11074 ada_lookup_encoded_symbol when looking that symbol up.
11076 2018-01-05 Jerome Guitton <guitton@adacore.com>
11078 * ada-lang.c (ada_array_length): Use ada_index_type instead of
11081 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11083 * ada-lang.c (ada_to_fixed_value_create): Add handling of
11084 the case where VALUE_LVAL (val0) is not lval_memory.
11086 2018-01-05 Xavier Roirand <roirand@adacore.com>
11088 * ada-valprint.c (print_optional_low_bound): Handle
11089 character-indexed array printing like boolean-indexed array
11092 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11094 * NEWS: Create a new section for the next release branch.
11095 Rename the section of the current branch, now that it has
11098 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11100 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
11101 * version.in: Bump version to 8.1.50.DATE-git.
11103 2018-01-03 Xavier Roirand <roirand@adacore.com>
11105 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
11107 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
11109 (default_exception_support_info) <catch_handlers_sym>: Add field.
11110 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
11111 (ada_exception_name_addr_1): Add "catch handlers" handling.
11112 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
11113 Update all callers.
11114 (create_excep_cond_exprs) <ex>: Add parameter.
11115 (re_set_exception): Update create_excep_cond_exprs call.
11116 (print_it_exception, print_one_exception, print_mention_exception)
11117 (print_recreate_exception): Add "catch handler" handling.
11118 (allocate_location_catch_handlers, re_set_catch_handlers)
11119 (check_status_catch_handlers, print_it_catch_handlers)
11120 (print_one_catch_handlers, print_mention_catch_handlers)
11121 (print_recreate_catch_handlers): New function.
11122 (catch_handlers_breakpoint_ops): New variable.
11123 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
11124 Add parameter. Add "catch handler" handling.
11125 (ada_exception_sym_name, ada_exception_breakpoint_ops):
11126 Add "catch handler" handling.
11127 (ada_exception_catchpoint_cond_string): Add "catch handler"
11129 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
11131 (catch_ada_handlers_command): New function.
11132 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
11133 operations structure.
11134 (_initialize_ada_language): Add "catch handlers" command entry.
11135 * NEWS: Document "catch handlers" feature.
11137 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11139 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
11140 account when creating the array type of the slice.
11141 (ada_value_slice): Likewise.
11143 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11145 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
11147 (create_array_type_with_stride): Add byte_stride_prop parameter.
11148 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
11149 New parameter. Update all callers in this file.
11150 (array_type_has_dynamic_stride): New function.
11151 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
11152 of arrays with dynamic byte strides.
11153 * dwarf2read.c (read_array_type): Add support for dynamic
11154 DW_AT_byte_stride attributes.
11156 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11158 * dwarf2read.c (read_unspecified_type): Treat
11159 DW_TAG_enumeration_type DIEs from Ada units as stubs.
11161 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11163 Update copyright year range in all GDB files.
11165 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11167 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
11168 and gdb/testsuite/gdb.base/step-line.c.
11170 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11172 * copyright.py (main): Dump the contents of
11173 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
11174 even if BY_HAND is empty.
11176 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11178 * top.c (print_gdb_version): Update Copyright year in version
11181 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11183 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
11185 For older changes see ChangeLog-2017.
11191 version-control: never