1 2018-12-23 Joel Brobecker <brobecker@adacore.com>
3 * version.in: Set GDB version number to 8.2.1.
6 2018-12-21 Paul Marechal <paul.marechal@ericsson.com>
9 * target.c (target_read_stralloc): Check for empty vector.
11 2018-12-19 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
14 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
15 symtab_start instead of always using language_unknown.
17 2018-11-30 Jan Kratochvil <jan.kratochvil@redhat.com>
18 Keith Seitz <keiths@redhat.com>
19 Tom Tromey <tom@tromey.com>
20 Sergio Durigan Junior <sergiodj@redhat.com>
22 https://bugzilla.redhat.com/show_bug.cgi?id=1613614
24 * dwarf2read.c (dwarf2_find_containing_comp_unit): Add
25 'mid_cu->length' to '*cu_off' when checking if 'sect_off' is
28 2018-11-21 Benno Fünfstück <benno.fuenfstueck@gmail.com>
31 * gdb/python/python.c (execute_gdb_command): Call
32 prevent_dont_repeat earlier to avoid affecting dont_repeat.
34 2018-11-08 Tom Tromey <tom@tromey.com>
38 * target.h (target_supports_terminal_ours): Return bool.
39 * target.c (target_supports_terminal_ours): Handle case where
40 current_top_target returns nullptr. Return bool.
42 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
45 * breakpoint.c (commands_cmd_element): New.
46 (_initialize_breakpoint): Assign commands_cmd_element.
47 * breakpoint.h (commands_cmd_element): New.
48 * cli/cli-script.c (while_cmd_element, if_command,
49 define_cmd_element): New.
50 (command_name_equals): Remove.
51 (process_next_line): Compare commands by pointer, not by name.
52 (_initialize_cli_script): Assign the various cmd_list_element
54 * compile/compile.c (compile_cmd_element): New.
55 (_initialize_compile): Assign compile_cmd_element.
56 * compile/compile.h (compile_cmd_element): New.
57 * guile/guile.c (guile_cmd_element): New.
58 (install_gdb_commands): Assign guile_cmd_element.
59 * guile/guile.h (guile_cmd_element): New.
60 * python/python.c (python_cmd_element): New.
61 (_initialize_python): Assign python_cmd_element.
62 * python/python.h (python_cmd_element): New.
63 * tracepoint.c (while_stepping_cmd_element): New.
64 (_initialize_tracepoint): Assign while_stepping_cmd_element.
65 * tracepoint.h (while_stepping_cmd_element): New.
67 2018-09-15 Sergio Durigan Junior <sergiodj@redhat.com>
70 * common/common-utils.c: Don't include '<sys/stat.h>'.
71 (is_regular_file): Move to...
72 * common/filestuff.c (is_regular_file): ... here.
73 * common/common-utils.h (is_regular_file): Move to...
74 * common/filestuff.h (is_regular_file): ... here.
76 2018-09-13 Tom Tromey <tom@tromey.com>
79 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
81 2018-09-13 Tom Tromey <tom@tromey.com>
84 * rust-lang.c (rust_enum_variant): Now static.
85 (rust_empty_enum_p): New function.
86 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
89 2018-09-10 Eli Zaretskii <eliz@gnu.org>
91 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
92 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
93 $(EXEEXT) to the script, as it is not a program.
95 2018-09-05 Joel Brobecker <brobecker@adacore.com>
97 * version.in: Set GDB version number to 8.2.0.DATE-git.
100 2018-09-05 Joel Brobecker <brobecker@adacore.com>
104 2018-09-05 Joel Brobecker <brobecker@adacore.com>
106 * version.in: Set GDB version number to 8.2.
107 * PROBLEMS: Likewise.
109 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
112 * gnulib/import/m4/getcwd-path-max.m4: Add handling of Hurd,
113 Linux and kFreeBSD platforms.
114 * gnulib/configure: Regenerate.
116 2018-08-31 Tom Tromey <tom@tromey.com>
118 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
121 2018-08-28 Alan Hayward <alan.hayward@arm.com>
123 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
124 (aarch64_linux_collect_sve_regset): Likewise.
125 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
126 * regcache.h (regcache_map_entry_size): New function.
128 2018-08-13 Alan Hayward <alan.hayward@arm.com>
130 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
131 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
132 (SVE_HEADER_VL_LENGTH): Likewise.
133 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
134 (SVE_HEADER_FLAGS_LENGTH): Likewise.
135 (SVE_HEADER_RESERVED_LENGTH): Likewise.
136 (SVE_HEADER_SIZE_OFFSET): Likewise.
137 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
138 (SVE_HEADER_VL_OFFSET): Likewise.
139 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
140 (SVE_HEADER_FLAGS_OFFSET): Likewise.
141 (SVE_HEADER_RESERVED_OFFSET): Likewise.
142 (SVE_HEADER_SIZE): Likewise.
143 (aarch64_linux_core_read_vq): Add function.
144 (aarch64_linux_core_read_description): Check for SVE section.
146 2018-08-13 Alan Hayward <alan.hayward@arm.com>
148 * aarch64-fbsd-tdep.c
149 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
151 * aarch64-linux-tdep.c
152 (aarch64_linux_iterate_over_regset_sections): Likewise.
154 (alpha_linux_iterate_over_regset_sections):
156 (alphanbsd_iterate_over_regset_sections): Likewise.
158 (amd64fbsd_iterate_over_regset_sections): Likewise.
160 (amd64_linux_iterate_over_regset_sections): Likewise.
162 (armbsd_iterate_over_regset_sections): Likewise.
164 (arm_fbsd_iterate_over_regset_sections): Likewise.
166 (arm_linux_iterate_over_regset_sections): Likewise.
167 * corelow.c (get_core_registers_cb): Likewise.
168 (core_target::fetch_registers): Likewise.
169 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
170 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
171 * gdbarch.h (void): Regenerate.
172 * gdbarch.sh: Add supply_size and collect_size.
173 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
174 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
175 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
176 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
177 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
178 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
179 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
180 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
181 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
182 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
183 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
184 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
185 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
186 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
187 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
188 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
189 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
190 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
191 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
192 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
193 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
194 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
195 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
196 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
197 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
198 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
199 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
200 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
201 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
203 2018-08-28 Alan Hayward <alan.hayward@arm.com>
205 * corelow.c (core_target::get_core_register_section): Rename
206 min_size to section_min_size.
208 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
210 * python/py-threadevent.c (py_get_event_thread): Initialize
213 2018-08-24 Kevin Buettner <kevinb@redhat.com>
216 * block.h (blockrange, blockranges): New struct declarations.
217 (struct block): Add new field named `ranges'.
218 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
219 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
220 macros for accessing ranges in struct block.
221 (make_blockranges): New declaration.
222 block.c (make_blockranges): New function.
223 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
225 * symtab.h (find_pc_partial_function): Add new parameter `block'.
226 * blockframe.c (cache_pc_function_block): New static global.
227 (clear_pc_function_cache): Clear cache_pc_function_block.
228 (find_pc_partial_function): Move comment to symtab.h. Add
229 support for non-contiguous blocks.
230 * cli/cli-cmds.c (block.h): Include.
231 (print_disassembly): Handle printing of non-contiguous blocks.
232 (disassemble_current_function): Likewise.
233 (disassemble_command): Likewise.
235 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
237 * blockframe.c (get_pc_function_start): Likewise.
238 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
239 (gcc_symbol_address): Likewise.
240 * compile/compile-object-run.c (compile_object_run): Likewise.
241 * compile/compile.c (get_expr_block_and_pc): Likewise.
242 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
243 (func_addr_to_tail_call_list): Likewise.
244 * findvar.c (default_read_var_value): Likewise.
245 * inline-frame.c (inline_frame_this_id): Likewise.
246 (skip-inline_frames): Likewise.
247 * infcmd.c (until_next_command): Likewise.
248 * linespec.c (convert_linespec_to_sals): Likewise.
249 * parse.c (parse_exp_in_context_1): Likewise.
250 * printcmd.c (build_address_symbolic): likewise.
251 (info_address_command): Likewise.
252 symtab.c (find_function_start_sal): Likewise.
253 (skip_prologue_sal): Likewise.
254 (find_function_alias_target): Likewise.
255 (find_gnu_ifunc): Likewise.
256 * stack.c (find_frame_funname): Likewise.
257 * symtab.c (fixup_symbol_section): Likewise.
258 (find_function_start_sal): Likewise.
259 (skip_prologue_sal): Likewsie.
260 (find_function_alias_target): Likewise.
261 (find_gnu_ifunc): Likewise.
262 * tracepoint.c (info_scope_command): Likewise.
263 * value.c (value_fn_field): Likewise.
265 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
266 in place of find_pc_partial_function.
267 * blockframe.c (find_function_entry_range_from_pc): New function.
268 * symtab.h (find_function_entry_range_from_pc): Declare and document.
269 * objfiles.c (objfile_relocate1): Relocate start and end addresses
270 for each range in a block.
272 2018-08-24 Pedro Alves <palves@redhat.com>
273 Simon Marchi <simon.marchi@ericsson.com>
276 * python/py-continueevent.c: Include "gdbthread.h".
277 (create_continue_event_object): Add intro comment. Add 'ptid'
278 parameter. Use it to find thread to pass to
279 create_thread_event_object.
280 (emit_continue_event): Pass PTID down to
281 create_continue_event_object.
282 * python/py-event.h (py_get_event_thread): Declare.
283 (create_thread_event_object): Remove default from 'thread'
285 * python/py-stopevent.c (create_stop_event_object): Use
287 * python/py-threadevent.c (get_event_thread): Rename to ...
288 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
289 and use it to find the thread.
290 (create_thread_event_object): Assert that THREAD isn't null.
291 Don't find the event thread here.
293 2018-08-23 Xavier Roirand <roirand@adacore.com>
295 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
298 2018-08-21 Alan Hayward <alan.hayward@arm.com>
300 * arch/aarch64.h (aarch64_regnum): Update comment.
302 2018-08-21 Alan Hayward <alan.hayward@arm.com>
304 * NEWS: Add SVE to 8.2 section.
306 2018-08-16 Tom Tromey <tom@tromey.com>
308 * top.c (read_command_file): Update.
309 (command_line_input): Remove "repeat" argument.
310 * ada-lang.c (get_selections): Update.
311 * linespec.c (decode_line_2): Update.
312 * defs.h (command_line_input): Remove argument.
313 * cli/cli-script.c (read_next_line): Update.
314 * python/py-gdb-readline.c: Update.
316 2018-08-17 Tom Tromey <tom@tromey.com>
318 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
321 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
323 * symfile.c (set_objfile_default_section_offset): Remove struct
326 2018-07-25 Alan Hayward <alan.hayward@arm.com>
328 * target-descriptions.c (tdesc_register_bitsize): Rename.
329 * target-descriptions.h (tdesc_register_bitsize): Likewise.
330 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
331 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
333 2018-07-24 Keith Seitz <keiths@redhat.comt
336 * dwarf2read.c (dw2_add_symbol_to_list): New function.
337 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
338 instead of add_symbol_to_list.
339 (read_file_scope): Call prepare_one_comp_unit before reading
342 2018-07-22 Tom Tromey <tom@tromey.com>
344 * symfile.c (reread_symbols): Notify iter, not objfile.
346 2018-07-22 Tom Tromey <tom@tromey.com>
348 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
350 (ravenscar_thread_target::prepare_to_store): Likewise.
352 2018-07-17 Tom Tromey <tom@tromey.com>
355 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
357 2018-07-11 Pedro Alves <palves@redhat.com>
360 * remote.c (remote_target::remote_detach_pid): Call
363 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
366 * c-typeprint.c (c_type_print_base_struct_union): Don't print
367 offsets/sizes for static members of a class/struct.
369 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
371 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
373 2018-07-04 Joel Brobecker <brobecker@adacore.com>
375 * version.in: Set GDB version number to 8.1.90.DATE-git.
376 * PROBLEMS: Likewise.
378 2018-07-04 Joel Brobecker <brobecker@adacore.com>
382 2018-07-04 Joel Brobecker <brobecker@adacore.com>
384 * version.in: Set GDB version number to 8.1.90.
385 * PROBLEMS: Likewise.
387 2018-07-04 Joel Brobecker <brobecker@adacore.com>
389 * NEWS: Change "Changes since GDB 8.1" into "Changes in GDB 8.2".
391 2018-07-04 Joel Brobecker <brobecker@adacore.com>
393 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
394 * version.in: Bump version to 8.1.90.DATE-git.
396 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
397 Pedro Alves <palves@redhat.com>
399 * linux-nat.c (linux_init_ptrace): Rename to ...
400 (linux_init_ptrace_procfs): ... this. Call
401 linux_proc_init_warnings.
402 (linux_nat_target::post_attach)
403 (linux_nat_target::post_startup_inferior): Adjust.
404 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
405 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
407 2018-07-04 Tom de Vries <tdevries@suse.de>
409 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
411 (read_comp_unit_head): ... here.
413 2018-07-03 Tom Tromey <tom@tromey.com>
415 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
416 (stop_tracing, tstatus_command)
417 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
418 (print_one_static_tracepoint_marker): Update.
419 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
421 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
423 (all_tracepoints, static_tracepoints_here): Return std::vector.
425 2018-07-03 Tom Tromey <tom@tromey.com>
427 * common/ptid.c (ptid_equal): Remove.
428 * common/ptid.h (ptid_equal): Don't declare.
429 * ada-tasks.c: Update.
430 * breakpoint.c: Update.
431 * common/agent.c: Update.
433 * darwin-nat-info.c: Update.
434 * darwin-nat.c: Update.
436 * dtrace-probe.c: Update.
437 * dummy-frame.c: Update.
438 * fbsd-nat.c: Update.
440 * gdbthread.h: Update.
442 * go32-nat.c: Update.
443 * inf-loop.c: Update.
444 * inf-ptrace.c: Update.
449 * linux-fork.c: Update.
450 * linux-nat.c: Update.
451 * linux-thread-db.c: Update.
452 * mi/mi-cmd-var.c: Update.
453 * mi/mi-interp.c: Update.
454 * mi/mi-main.c: Update.
455 * nto-procfs.c: Update.
456 * ppc-linux-tdep.c: Update.
458 * python/py-inferior.c: Update.
459 * python/py-record-btrace.c: Update.
460 * python/py-record.c: Update.
461 * ravenscar-thread.c: Update.
462 * regcache.c: Update.
463 * remote-sim.c: Update.
465 * sol-thread.c: Update.
468 * tui/tui-stack.c: Update.
470 * windows-nat.c: Update.
471 * windows-tdep.c: Update.
473 2018-07-03 Tom Tromey <tom@tromey.com>
475 * common/ptid.c (ptid_match): Remove.
476 * common/ptid.h (ptid_match): Don't declare.
477 * fbsd-nat.c: Update.
480 * linux-nat.c: Update.
481 * record-btrace.c: Update.
482 * regcache.c: Update.
485 2018-07-03 Tom Tromey <tom@tromey.com>
487 * common/ptid.c (ptid_tid_p): Remove.
488 * common/ptid.h (ptid_tid_p): Don't declare.
489 * sol-thread.c: Update.
491 2018-07-03 Tom Tromey <tom@tromey.com>
493 * common/ptid.c (ptid_lwp_p): Remove.
494 * common/ptid.h (ptid_lwp_p): Don't declare.
495 * fbsd-nat.c: Update.
496 * linux-nat.c: Update.
497 * nat/linux-procfs.c: Update.
498 * nat/x86-linux-dregs.c: Update.
499 * sol-thread.c: Update.
501 2018-07-03 Tom Tromey <tom@tromey.com>
503 * common/ptid.c (ptid_is_pid): Remove.
504 * common/ptid.h (ptid_is_pid): Don't declare.
506 * linux-nat.c: Update.
507 * mi/mi-interp.c: Update.
511 2018-07-03 Tom Tromey <tom@tromey.com>
513 * common/ptid.c (ptid_get_tid): Remove.
514 * common/ptid.h (ptid_get_tid): Don't declare.
515 * ada-tasks.c: Update.
516 * aix-thread.c: Update.
517 * bsd-uthread.c: Update.
518 * darwin-nat.c: Update.
519 * fbsd-nat.c: Update.
520 * i386-darwin-nat.c: Update.
522 * linux-tdep.c: Update.
523 * nto-procfs.c: Update.
524 * ppc-ravenscar-thread.c: Update.
525 * python/py-infthread.c: Update.
526 * ravenscar-thread.c: Update.
527 * sol-thread.c: Update.
528 * sparc-ravenscar-thread.c: Update.
529 * windows-nat.c: Update.
531 2018-07-03 Tom Tromey <tom@tromey.com>
533 * common/ptid.c (ptid_get_lwp): Remove.
534 * common/ptid.h (ptid_get_lwp): Don't declare.
535 * aarch64-linux-nat.c: Update.
536 * ada-tasks.c: Update.
537 * aix-thread.c: Update.
538 * amd64-linux-nat.c: Update.
539 * arm-linux-nat.c: Update.
541 * fbsd-nat.c: Update.
542 * fbsd-tdep.c: Update.
544 * i386-cygwin-tdep.c: Update.
545 * i386-gnu-nat.c: Update.
546 * i386-linux-nat.c: Update.
547 * ia64-linux-nat.c: Update.
548 * inf-ptrace.c: Update.
550 * linux-fork.c: Update.
551 * linux-nat.c: Update.
552 * linux-tdep.c: Update.
553 * linux-thread-db.c: Update.
554 * mips-linux-nat.c: Update.
555 * nat/aarch64-linux-hw-point.c: Update.
556 * nat/aarch64-linux.c: Update.
557 * nat/linux-btrace.c: Update.
558 * nat/linux-osdata.c: Update.
559 * nat/linux-procfs.c: Update.
560 * nat/x86-linux-dregs.c: Update.
561 * obsd-nat.c: Update.
562 * ppc-fbsd-nat.c: Update.
563 * ppc-linux-nat.c: Update.
565 * python/py-infthread.c: Update.
566 * ravenscar-thread.c: Update.
568 * s390-linux-nat.c: Update.
569 * sol-thread.c: Update.
570 * sol2-tdep.c: Update.
571 * spu-linux-nat.c: Update.
572 * x86-linux-nat.c: Update.
573 * xtensa-linux-nat.c: Update.
575 2018-07-03 Tom Tromey <tom@tromey.com>
577 * common/ptid.c (ptid_get_pid): Remove.
578 * common/ptid.h (ptid_get_pid): Don't declare.
579 * aarch64-linux-nat.c: Update.
580 * ada-lang.c: Update.
581 * aix-thread.c: Update.
582 * alpha-bsd-nat.c: Update.
583 * amd64-fbsd-nat.c: Update.
584 * amd64-linux-nat.c: Update.
585 * arm-linux-nat.c: Update.
586 * arm-nbsd-nat.c: Update.
588 * break-catch-syscall.c: Update.
589 * breakpoint.c: Update.
590 * bsd-uthread.c: Update.
593 * darwin-nat.c: Update.
594 * fbsd-nat.c: Update.
595 * fbsd-tdep.c: Update.
598 * hppa-nbsd-nat.c: Update.
599 * hppa-obsd-nat.c: Update.
600 * i386-fbsd-nat.c: Update.
601 * ia64-linux-nat.c: Update.
602 * inf-ptrace.c: Update.
604 * inferior.c: Update.
605 * inferior.h: Update.
608 * linux-fork.c: Update.
609 * linux-nat.c: Update.
610 * linux-tdep.c: Update.
611 * linux-thread-db.c: Update.
612 * m68k-bsd-nat.c: Update.
613 * mi/mi-interp.c: Update.
614 * mi/mi-main.c: Update.
615 * mips-linux-nat.c: Update.
616 * mips-nbsd-nat.c: Update.
617 * mips64-obsd-nat.c: Update.
618 * nat/aarch64-linux-hw-point.c: Update.
619 * nat/aarch64-linux.c: Update.
620 * nat/linux-btrace.c: Update.
621 * nat/linux-osdata.c: Update.
622 * nat/linux-procfs.c: Update.
623 * nat/x86-linux-dregs.c: Update.
624 * nto-procfs.c: Update.
625 * obsd-nat.c: Update.
626 * ppc-linux-nat.c: Update.
627 * ppc-nbsd-nat.c: Update.
628 * ppc-obsd-nat.c: Update.
629 * proc-service.c: Update.
631 * python/py-inferior.c: Update.
632 * python/py-infthread.c: Update.
633 * ravenscar-thread.c: Update.
635 * remote-sim.c: Update.
637 * rs6000-nat.c: Update.
638 * s390-linux-nat.c: Update.
639 * sh-nbsd-nat.c: Update.
640 * sol-thread.c: Update.
641 * sparc-nat.c: Update.
642 * sparc64-tdep.c: Update.
643 * spu-linux-nat.c: Update.
644 * spu-tdep.c: Update.
645 * target-debug.h: Update.
648 * tid-parse.c: Update.
649 * tracefile-tfile.c: Update.
650 * vax-bsd-nat.c: Update.
651 * windows-nat.c: Update.
652 * x86-linux-nat.c: Update.
655 2018-07-03 Tom Tromey <tom@tromey.com>
657 * common/ptid.c (pid_to_ptid): Remove.
658 * common/ptid.h (pid_to_ptid): Don't declare.
659 * aix-thread.c: Update.
660 * arm-linux-nat.c: Update.
661 * common/ptid.c: Update.
662 * common/ptid.h: Update.
665 * darwin-nat.c: Update.
666 * fbsd-nat.c: Update.
667 * fork-child.c: Update.
669 * go32-nat.c: Update.
670 * inf-ptrace.c: Update.
672 * inferior.c: Update.
674 * linux-fork.c: Update.
675 * linux-nat.c: Update.
676 * nat/aarch64-linux-hw-point.c: Update.
677 * nat/fork-inferior.c: Update.
678 * nat/x86-linux-dregs.c: Update.
679 * nto-procfs.c: Update.
680 * obsd-nat.c: Update.
682 * progspace.c: Update.
684 * rs6000-nat.c: Update.
685 * s390-linux-nat.c: Update.
686 * sol-thread.c: Update.
687 * spu-linux-nat.c: Update.
690 * tracefile-tfile.c: Update.
691 * windows-nat.c: Update.
693 2018-07-03 Tom Tromey <tom@tromey.com>
695 * common/ptid.h (ptid_build): Don't declare.
696 * common/ptid.c (ptid_build): Remove.
697 * aix-thread.c: Update.
699 * bsd-uthread.c: Update.
700 * common/agent.c: Update.
701 * common/ptid.c: Update.
702 * common/ptid.h: Update.
704 * darwin-nat.c: Update.
705 * fbsd-nat.c: Update.
707 * linux-fork.c: Update.
708 * linux-nat.c: Update.
709 * linux-thread-db.c: Update.
710 * nat/linux-osdata.c: Update.
711 * nat/linux-procfs.c: Update.
712 * nto-procfs.c: Update.
713 * obsd-nat.c: Update.
714 * proc-service.c: Update.
716 * ravenscar-thread.c: Update.
717 * remote-sim.c: Update.
719 * sol-thread.c: Update.
721 * windows-nat.c: Update.
723 2018-07-03 Tom Tromey <tom@tromey.com>
725 * infrun.c (follow_exec): Use exit_inferior_silent.
726 * inferior.c (exit_inferior_num_silent): Remove.
727 * inferior.h (exit_inferior_num_silent): Don't declare.
729 2018-07-03 Tom Tromey <tom@tromey.com>
732 * darwin-nat.c (darwin_attach_pid): Reset inferior and
733 inferior_ptid on error.
735 2018-07-02 Maciej W. Rozycki <macro@mips.com>
736 Simon Marchi <simon.marchi@polymtl.ca>
739 * disasm.h (gdb_disassembler): Add
740 `m_disassembler_options_holder'. member
741 * disasm.c (get_all_disassembler_options): New function.
742 (gdb_disassembler::gdb_disassembler): Use it.
743 (gdb_buffered_insn_length_init_dis): Likewise.
744 (gdb_buffered_insn_length): Adjust accordingly.
745 (set_disassembler_options): Handle options with arguments.
746 (show_disassembler_options_sfunc): Likewise. Add a leading new
747 line if showing options with descriptions.
748 (disassembler_options_completer): Adapt to using the
749 `disasm_options_and_args_t' structure.
750 * mips-tdep.c (mips_disassembler_options): New variable.
751 (mips_disassembler_options_o32): Likewise.
752 (mips_disassembler_options_n32): Likewise.
753 (mips_disassembler_options_n64): Likewise.
754 (gdb_print_insn_mips): Don't set `disassembler_options'.
755 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
757 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
758 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
759 `gdbarch_disassembler_options_implicit' and
760 `gdbarch_valid_disassembler_options'.
761 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
762 `disasm_options_and_args_t' structure.
763 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
765 (valid_disassembler_options): Switch from `disasm_options_t' to
766 the `disasm_options_and_args_t' structure.
767 * NEWS: Document `set disassembler-options' support for the MIPS
769 * gdbarch.h: Regenerate.
770 * gdbarch.c: Regenerate.
772 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
774 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
776 2018-06-29 Joel Brobecker <brobecker@adacore.com>
778 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
779 parameter in call to amd64_target_description.
780 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
781 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
782 (amd64fbsd_init_abi): Likewise.
783 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
784 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
785 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
786 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
788 2018-06-29 Pedro Alves <palves@redhat.com>
790 * gdb/amd64-tdep.h (amd64_create_target_description): Add
791 "segments" parameter.
792 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
793 (_initialize_amd64_tdep): Update call to
794 amd64_create_target_description.
795 (amd64_target_description): Add "segments" parameter. Adjust
796 the implementation to use it.
797 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
798 call to amd64_create_target_description.
799 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
800 * gdb/arch/amd64.h (amd64_create_target_description): Add
802 * gdb/arch/amd64.c (amd64_create_target_description): Add
803 "segments" parameter. Call create_feature_i386_64bit_segments
804 only if SEGMENTS is true.
805 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
806 call to amd64_create_target_description.
808 2018-06-29 Pedro Alves <palves@redhat.com>
810 * thread.c (thread_target_id_str): New, factored out from ...
811 (print_thread_info_1): ... here. Use it to compute the max
812 "Target Id" column width.
814 2018-06-29 Pedro Alves <palves@redhat.com>
816 * remote.c (remote_target::extra_thread_info): Delete
817 'display_buf' and 'n' locals. from the cache, regardless of
818 packet mechanims is in use. Use cache for qThreadExtra and qP
821 2018-06-29 Pedro Alves <palves@redhat.com>
823 * blockframe.c (find_pc_sect_containing_function): New function.
824 * breakpoint.c (print_breakpoint_location): Don't call
825 find_pc_sect_function.
826 * linespec.c (create_sals_line_offset): Record the location's
828 * linespec.c (convert_address_location_to_sals): Fill in sal's
829 symbol with find_pc_sect_containing_function.
830 * symtab.c (find_function_start_sal): Rename to ...
831 (find_function_start_sal_1): ... this.
832 (find_function_start_sal): Reimplement as wrapper around
833 find_function_start_sal_1, and use
834 find_pc_sect_containing_function to fill in the sal's symbol.
835 (find_function_start_sal(symbol*, bool)): Adjust.
836 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
838 (find_pc_sect_containing_function): Declare.
840 2018-06-29 Pedro Alves <palves@redhat.com>
842 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
843 true if the the location has no symbol.
845 2018-06-28 Tom Tromey <tom@tromey.com>
847 * NEWS: Mention --enable-codesign.
848 * silent-rules.mk (ECHO_SIGN): New variable.
849 * configure.ac: Add --enable-codesign.
850 * configure: Rebuild.
851 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
852 (gdb$(EXEEXT)): Optionally invoke codesign.
854 2018-06-28 Pedro Alves <palves@redhat.com>
856 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
858 (switch_to_thread_no_regs): Adjust comment.
859 * infcmd.c (stop_pc): Delete.
860 (post_create_inferior, info_program_command): Replace references
861 to stop_pc with references to thread_info->suspend.stop_pc.
862 * inferior.h (stop_pc): Delete declaration.
863 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
864 (handle_inferior_event_1, handle_signal_stop)
865 (process_event_stop_test, keep_going_stepped_thread)
866 (handle_step_into_function, handle_step_into_function_backward)
867 (print_stop_location): Replace references to stop_pc with
868 references to thread_info->suspend.stop_pc.
869 (struct infcall_suspend_state) <stop_pc>: Delete field.
870 (save_infcall_suspend_state, restore_infcall_suspend_state):
871 Remove references to inf_stat->stop_pc.
872 * linux-fork.c (fork_load_infrun_state): Likewise.
873 * record-btrace.c (record_btrace_set_replay): Likewise.
874 * record-full.c (record_full_goto_entry): Likewise.
875 * remote.c (print_one_stopped_thread): Likewise.
876 * target.c (target_resume): Extend comment.
877 * thread.c (set_executing_thread): New.
878 (set_executing): Use it.
879 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
880 Remove references to stop_pc.
882 2018-06-28 Pedro Alves <palves@redhat.com>
884 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
885 Moving fetching stop_pc until after ecs->event_thread is refreshed.
887 2018-06-28 Tom Tromey <tom@tromey.com>
889 * coffread.c (coff_symfile_finish): Update.
890 * xcoffread.c (xcoff_symfile_finish): Update.
891 * elfread.c (elf_symfile_finish): Update.
892 * symfile.h (dwarf2_free_objfile): Don't declare.
893 * dwarf2read.c (_initialize_dwarf2_read): Use
894 register_objfile_data_with_cleanup.
895 (dwarf2_free_objfile): Now static. Change signature.
897 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
899 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
900 option "-o" to add-symbol-file-load to add an offset to each
901 section's load address.
902 * symfile.c (set_objfile_default_section_offset): New function.
904 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
906 * symfile.c (add_symbol_file_command): Make sure that sections
907 with the same name are sorted in the same order.
909 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
911 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
912 require the second argument. If omitted, load sections at the
913 addresses specified in the file.
915 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
917 * symfile.c (symbol_file_command, symbol_file_add_main_1)
918 (_initialize_symfile): Add option "-o" to symbol-file to add an
919 offset to each section of the symbol file.
921 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
923 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
925 2018-06-27 Tom Tromey <tom@tromey.com>
927 * stack.c (_initialize_stack): Update "func" help text.
929 2018-06-27 Tom Tromey <tom@tromey.com>
931 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
933 (unwind_infopy_str, pyuw_create_unwind_info)
934 (unwind_infopy_add_saved_register, pyuw_sniffer)
935 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
937 (struct saved_reg): Add constructor.
938 <value>: Now a gdbpy_ref<>.
940 2018-06-27 Tom Tromey <tom@tromey.com>
942 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
944 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
946 * gdb-gdb.py.in: Format using autopep8.
948 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
950 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
951 (type_lookup_function): Recognize CORE_ADDR values.
953 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
955 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
958 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
960 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
963 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
965 * gdb-gdb.py: Move to...
966 * gdb-gdb.py.in: ... here.
967 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
968 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
970 (distclean): Remove gdb-gdb.py when cleaning.
971 (gdb-gdb.py, gdb-gdb.gdb): New rules.
972 * configure: Re-generate.
974 2018-06-27 Pedro Alves <palves@redhat.com>
976 * proc-service.c (get_ps_regcache): New.
977 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
978 (ps_lsetfpregs): Use it.
980 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
983 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
984 (dwarf_decode_lines_1): Adjust.
986 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
988 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
990 <info_proc>: Likewise.
992 2018-06-26 Joel Brobecker <brobecker@adacore.com>
994 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
995 to windows_fetch_one_register, and only handle the case of
996 fetching one register. Move the code that reloads the context
997 and iterates over all registers if R is negative to...
998 (windows_nat_target::fetch_registers): ... here.
999 (do_windows_store_inferior_registers): Rename to
1000 windows_store_one_register, and only handle the case of storing
1001 one register. Move the code that handles the case where r is
1003 (windows_nat_target::store_registers) ... here.
1005 2018-06-26 Tom Tromey <tom@tromey.com>
1008 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
1009 * rust-lang.c (rust_print_struct_def): Add podata parameter.
1011 (rust_internal_print_type): Add podata parameter.
1012 (rust_print_type): Update.
1014 2018-06-26 Tom Tromey <tom@tromey.com>
1016 * typeprint.h (struct print_offset_data) <update, finish,
1017 maybe_print_hole>: New methods.
1018 <indentation>: New constant.
1019 * typeprint.c (print_offset_data::indentation): Define.
1020 (print_offset_data::maybe_print_hole, print_offset_data::update)
1021 (print_offset_data::finish): Move from c-typeprint.c and rename.
1022 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
1023 (print_spaces_filtered_with_print_options): Update.
1024 (c_print_type_union_field_offset, maybe_print_hole)
1025 (c_print_type_struct_field_offset): Move to typeprint.c and
1027 (c_type_print_base_struct_union): Update.
1029 2018-06-25 Pedro Alves <palves@redhat.com>
1031 * gdbthread.h (thread_info_ref, delete_thread)
1032 (delete_thread_silent, first_thread_of_inferior)
1033 (any_thread_of_inferior, switch_to_thread)
1034 (enable_thread_stack_temporaries)
1035 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1036 (get_last_thread_stack_temporary)
1037 (value_in_thread_stack_temporaries, can_access_registers_thread):
1038 Spell out "struct thread_info" instead of just "thread_info".
1039 * inferior.h (notice_new_inferior): Likewise.
1041 2018-06-25 Pedro Alves <palves@redhat.com>
1043 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1044 pass thread_info pointer to delete_thread.
1045 (windows_nat_target::detach): Pass inferior pointer to
1047 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
1049 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
1050 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
1051 and pass a thread_info pointer to delete_thread.
1052 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
1053 pass thread_info pointer to delete_thread.
1054 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
1055 delete_thread_silent call.
1056 * procfs.c (procfs_target::detach): Pass inferior pointer to
1058 (procfs_target::wait): Pass thread_info pointer to delete_thread.
1059 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
1060 delete_thread_silent call.
1061 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1062 pass thread_info pointer to delete_thread.
1063 (windows_nat_target::detach): Pass inferior pointer to
1066 2018-06-22 Alan Hayward <alan.hayward@arm.com>
1068 * regcache.c (readable_regcache::read_part): Fix asserts.
1069 (reg_buffer::raw_collect_part): New function.
1070 (regcache::write_part): Fix asserts.
1071 (reg_buffer::raw_supply_part): New function.
1072 (regcache::transfer_regset_register): New helper function.
1073 (regcache::transfer_regset): Call new functions.
1074 (regcache_supply_regset): Use gdb_byte*.
1075 (regcache::supply_regset): Likewise.
1076 (regcache_collect_regset): Likewise.
1077 (regcache::collect_regset): Likewise.
1078 * regcache.h (reg_buffer::raw_collect_part): New declaration.
1079 (reg_buffer::raw_supply_part): Likewise.
1080 (regcache::transfer_regset_register): Likewise.
1081 (regcache::transfer_regset): Use gdb_byte*.
1083 2018-06-22 Alan Hayward <alan.hayward@arm.com>
1085 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
1087 2018-06-21 Pedro Alves <palves@redhat.com>
1089 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
1090 instead of a ptid_t. All callers adjusted.
1091 * ada-tasks.c (ada_get_task_number): Likewise. All callers
1093 (print_ada_task_info, display_current_task_id, task_command_1):
1095 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
1097 (breakpoint_kind): Adjust.
1098 (remove_breakpoints_pid): Rename to ...
1099 (remove_breakpoints_inf): ... this. Adjust to take an inferior
1100 pointer. All callers adjusted.
1101 (bpstat_clear_actions): Use inferior_thread.
1102 (get_bpstat_thread): New.
1103 (bpstat_do_actions): Use it.
1104 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
1105 to take a thread_info pointer. All callers adjusted.
1106 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
1107 (breakpoint_re_set_thread): Use inferior_thread.
1108 * breakpoint.h (struct inferior): Forward declare.
1109 (bpstat_stop_status): Update.
1110 (remove_breakpoints_pid): Delete.
1111 (remove_breakpoints_inf): New.
1112 * bsd-uthread.c (bsd_uthread_target::wait)
1113 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
1114 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
1115 (maint_btrace_packet_history_cmd)
1116 (maint_btrace_clear_packet_history_cmd): Adjust.
1117 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
1119 * cli/cli-interp.c: Include "inferior.h".
1120 * common/refcounted-object.h (struct
1121 refcounted_object_ref_policy): New.
1122 * compile/compile-object-load.c: Include gdbthread.h.
1123 (store_regs): Use inferior_thread.
1124 * corelow.c (core_target::close): Use current_inferior.
1125 (core_target_open): Adjust to use first_thread_of_inferior and use
1126 the current inferior.
1127 * ctf.c (ctf_target::close): Adjust to use current_inferior.
1128 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
1129 <thread>: ... this new field. All references adjusted.
1130 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
1131 Take a thread_info pointer instead of a ptid_t.
1132 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
1133 (dummy_frame_discard, register_dummy_frame_dtor): Take a
1134 thread_info pointer instead of a ptid_t.
1135 * elfread.c: Include "inferior.h".
1136 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
1137 Use inferior_thread.
1138 * eval.c (evaluate_subexp): Likewise.
1139 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
1141 * gdb_proc_service.h (struct thread_info): Forward declare.
1142 (struct ps_prochandle) <ptid>: Delete, replaced by ...
1143 <thread>: ... this new field. All references adjusted.
1144 * gdbarch.h, gdbarch.c: Regenerate.
1145 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
1146 'thread' parameter. All implementations and callers adjusted.
1147 * gdbthread.h (thread_info) <set_running>: New method.
1148 (delete_thread, delete_thread_silent): Take a thread_info pointer
1150 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
1151 (first_thread_of_process): Delete, replaced by ...
1152 (first_thread_of_inferior): ... this new function. All callers
1154 (any_live_thread_of_process): Delete, replaced by ...
1155 (any_live_thread_of_inferior): ... this new function. All callers
1157 (switch_to_thread, switch_to_no_thread): Declare.
1158 (is_executing): Delete.
1159 (enable_thread_stack_temporaries): Update comment.
1160 <enable_thread_stack_temporaries>: Take a thread_info pointer
1161 instead of a ptid_t. Incref the thread.
1162 <~enable_thread_stack_temporaries>: Decref the thread.
1165 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1166 (get_last_thread_stack_temporary)
1167 (value_in_thread_stack_temporaries, can_access_registers_thread):
1168 Take a thread_info pointer instead of a ptid_t. All callers
1170 * infcall.c (get_call_return_value): Use inferior_thread.
1171 (run_inferior_call): Work with thread pointers instead of ptid_t.
1172 (call_function_by_hand_dummy): Work with thread pointers instead
1173 of ptid_t. Use thread_info_ref.
1174 * infcmd.c (proceed_thread_callback): Access thread's state
1176 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
1177 access thread's state directly.
1178 (continue_command): Use inferior_thread.
1179 (info_program_command): Use find_thread_ptid and access thread
1181 (proceed_after_attach_callback): Use thread state directly.
1182 (notice_new_inferior): Take a thread_info pointer instead of a
1183 ptid_t. All callers adjusted.
1184 (exit_inferior): Take an inferior pointer instead of a pid. All
1186 (exit_inferior_silent): New.
1187 (detach_inferior): Delete.
1188 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
1189 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
1190 (detach_inferior_command, kill_inferior_command): Use
1191 find_inferior_id instead of valid_gdb_inferior_id and
1192 gdb_inferior_id_to_pid.
1193 (inferior_command): Use inferior and thread pointers.
1194 * inferior.h (struct thread_info): Forward declare.
1195 (notice_new_inferior): Take a thread_info pointer instead of a
1196 ptid_t. All callers adjusted.
1197 (detach_inferior): Delete declaration.
1198 (exit_inferior, exit_inferior_silent): Take an inferior pointer
1199 instead of a pid. All callers adjusted.
1200 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
1201 (valid_gdb_inferior_id): Delete.
1202 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
1203 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
1204 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
1206 <inf>: ... this new field.
1207 <step_ptid>: Delete, replaced by ...
1208 <step_thread>: ... this new field.
1209 (get_displaced_stepping_state): Take an inferior pointer instead
1210 of a pid. All callers adjusted.
1211 (displaced_step_in_progress_any_inferior): Adjust.
1212 (displaced_step_in_progress_thread): Take a thread pointer instead
1213 of a ptid_t. All callers adjusted.
1214 (displaced_step_in_progress, add_displaced_stepping_state): Take
1215 an inferior pointer instead of a pid. All callers adjusted.
1216 (get_displaced_step_closure_by_addr): Adjust.
1217 (remove_displaced_stepping_state): Take an inferior pointer
1218 instead of a pid. All callers adjusted.
1219 (displaced_step_prepare_throw, displaced_step_prepare)
1220 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
1221 All callers adjusted.
1222 (start_step_over): Adjust.
1223 (infrun_thread_ptid_changed): Remove bit updating ptids in the
1224 displaced step queue.
1225 (do_target_resume): Adjust.
1226 (fetch_inferior_event): Use inferior_thread.
1227 (context_switch, get_inferior_stop_soon): Take an
1228 execution_control_state pointer instead of a ptid_t. All callers
1230 (switch_to_thread_cleanup): Delete.
1231 (stop_all_threads): Use scoped_restore_current_thread.
1232 * inline-frame.c: Include "gdbthread.h".
1233 (inline_state) <inline_state>: Take a thread pointer instead of a
1234 ptid_t. All callers adjusted.
1235 <ptid>: Delete, replaced by ...
1236 <thread>: ... this new field.
1237 (find_inline_frame_state): Take a thread pointer instead of a
1238 ptid_t. All callers adjusted.
1239 (skip_inline_frames, step_into_inline_frame)
1240 (inline_skipped_frames, inline_skipped_symbol): Take a thread
1241 pointer instead of a ptid_t. All callers adjusted.
1242 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
1243 (inline_skipped_frames, inline_skipped_symbol): Likewise.
1244 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
1246 * linux-nat.c (get_detach_signal): Likewise.
1247 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
1248 (thread_db_notice_clone): Adjust.
1249 (thread_db_find_new_threads_silently)
1250 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
1251 a thread pointer instead of a ptid_t. All callers adjusted.
1252 * mi/mi-cmd-var.c: Include "inferior.h".
1253 (mi_cmd_var_update_iter): Update to use thread pointers.
1254 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
1256 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
1258 (mi_output_running): ... this new function.
1259 (mi_on_resume_1): Adjust to use it.
1260 (mi_user_selected_context_changed): Adjust to use inferior_thread.
1261 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
1263 (interrupt_thread_callback): : Adjust to use thread and inferior
1265 * proc-service.c: Include "gdbthread.h".
1266 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
1267 * progspace-and-thread.c: Include "inferior.h".
1268 * progspace.c: Include "inferior.h".
1269 * python/py-exitedevent.c (create_exited_event_object): Adjust to
1270 hold a reference to an inferior_object.
1271 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
1273 * python/py-inferior.c (struct inferior_object): Give the type a
1274 tag name instead of a typedef.
1275 (python_on_normal_stop): No need to check if the current thread is
1277 (inferior_to_inferior_object): Change return type to
1278 inferior_object. All callers adjusted.
1279 (find_thread_object): Delete, bits factored out to ...
1280 (thread_to_thread_object): ... this new function.
1281 * python/py-infthread.c (create_thread_object): Use
1282 inferior_to_inferior_object.
1283 (thpy_is_stopped): Use thread pointer directly.
1284 (gdbpy_selected_thread): Use inferior_thread.
1285 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
1286 field, replaced with ...
1287 <thread>: ... this new field. All users adjusted.
1288 (btpy_insn_or_gap_new): Drop const.
1289 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
1291 * python/py-record.c: Include "gdbthread.h".
1292 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1293 a ptid_t. All callers adjusted.
1294 (gdbpy_current_recording): Use inferior_thread.
1295 * python/py-record.h (recpy_record_object) <ptid>: Delete
1296 field, replaced with ...
1297 <thread>: ... this new field. All users adjusted.
1298 (recpy_element_object) <ptid>: Delete
1299 field, replaced with ...
1300 <thread>: ... this new field. All users adjusted.
1301 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1302 a ptid_t. All callers adjusted.
1303 * python/py-threadevent.c: Include "gdbthread.h".
1304 (get_event_thread): Use thread_to_thread_object.
1305 * python/python-internal.h (struct inferior_object): Forward
1307 (find_thread_object, find_inferior_object): Delete declarations.
1308 (thread_to_thread_object, inferior_to_inferior_object): New
1310 * record-btrace.c: Include "inferior.h".
1311 (require_btrace_thread): Use inferior_thread.
1312 (record_btrace_frame_sniffer)
1313 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
1314 (get_thread_current_frame): Use scoped_restore_current_thread and
1316 (get_thread_current_frame): Use thread pointer directly.
1317 (record_btrace_replay_at_breakpoint): Use thread's inferior
1319 * record-full.c: Include "inferior.h".
1320 * regcache.c: Include "gdbthread.h".
1321 (get_thread_arch_regcache): Use the inferior's address space
1323 (get_thread_regcache, registers_changed_thread): New.
1324 * regcache.h (get_thread_regcache(thread_info *thread)): New
1326 (registers_changed_thread): New.
1327 (remote_target) <remote_detach_1>: Swap order of parameters.
1328 (remote_add_thread): <remote_add_thread>: Return the new thread.
1329 (get_remote_thread_info(ptid_t)): New overload.
1330 (remote_target::remote_notice_new_inferior): Use thread pointers
1332 (remote_target::process_initial_stop_replies): Use
1333 thread_info::set_running.
1334 (remote_target::remote_detach_1, remote_target::detach)
1335 (extended_remote_target::detach): Adjust.
1336 * stack.c (frame_show_address): Use inferior_thread.
1337 * target-debug.h (target_debug_print_thread_info_pp): New.
1338 * target-delegates.c: Regenerate.
1339 * target.c (default_thread_address_space): Delete.
1340 (memory_xfer_partial_1): Use current_inferior.
1341 (target_detach): Use current_inferior.
1342 (target_thread_address_space): Delete.
1343 (generic_mourn_inferior): Use current_inferior.
1344 * target.h (struct target_ops) <thread_address_space>: Delete.
1345 (target_thread_address_space): Delete.
1346 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
1348 (delete_thread_1, delete_thread, delete_thread_silent): Take a
1349 thread pointer instead of a ptid_t. Adjust all callers.
1350 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
1351 (first_thread_of_process): Delete, replaced by ...
1352 (first_thread_of_inferior): ... this new function. All callers
1354 (any_thread_of_process): Rename to ...
1355 (any_thread_of_inferior): ... this, and take an inferior pointer.
1356 (any_live_thread_of_process): Rename to ...
1357 (any_live_thread_of_inferior): ... this, and take an inferior
1359 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1360 (value_in_thread_stack_temporaries)
1361 (get_last_thread_stack_temporary): Take a thread pointer instead
1362 of a ptid_t. Adjust all callers.
1363 (thread_info::set_running): New.
1364 (validate_registers_access): Use inferior_thread.
1365 (can_access_registers_ptid): Rename to ...
1366 (can_access_registers_thread): ... this, and take a thread
1368 (print_thread_info_1): Adjust to compare thread pointers instead
1370 (switch_to_no_thread, switch_to_thread): Make extern.
1371 (scoped_restore_current_thread::~scoped_restore_current_thread):
1372 Use m_thread pointer directly.
1373 (scoped_restore_current_thread::scoped_restore_current_thread):
1374 Use inferior_thread.
1375 (thread_command): Use thread pointer directly.
1376 (thread_num_make_value_helper): Use inferior_thread.
1377 * top.c (execute_command): Use inferior_thread.
1378 * tui/tui-interp.c: Include "inferior.h".
1379 * varobj.c (varobj_create): Use inferior_thread.
1380 (value_of_root_1): Use find_thread_global_id instead of
1381 global_thread_id_to_ptid.
1383 2018-06-21 Alan Hayward <alan.hayward@arm.com>
1385 * regcache.c (readable_regcache::read_part): Avoid memcpy when
1387 (regcache::write_part): Likewise.
1388 (readable_regcache::cooked_read_part): Update comment.
1389 (readable_regcache::cooked_write_part): Likewise.
1390 * regcache.h: (readable_regcache::read_part): Likewise.
1391 (regcache::write_part): Likewise.
1393 2018-06-21 Richard Bunt <richard.bunt@arm.com>
1394 Dirk Schubert <dirk.schubert@arm.com>
1396 * aarch64-linux-nat.c (post_attach): New.
1397 (aarch64_linux_nat_target::post_attach): Override post_attach to
1398 record the number of hardware debug registers.
1400 2018-06-20 Tom Tromey <tom@tromey.com>
1402 * python/py-param.c (add_setshow_generic): Make parameters const.
1403 (parmpy_init): Update.
1405 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1407 * regcache.h (regcache_cooked_read_ftype): Rename to...
1408 (register_read_ftype): ...this, change type to function_view.
1409 (class reg_buffer) <save>: Remove src parameter.
1410 (readonly_detached_regcache) <readonly_detached_regcache>: Make
1411 parameter non-const in first overload. Remove src parameter in
1413 * regcache.c (do_cooked_read): Remove.
1414 (readonly_detached_regcache::readonly_detached_regcache): Make
1415 parameter non-const, adjust call to other constructor.
1416 (reg_buffer::save): Remove src parameter.
1417 * frame.c (do_frame_register_read): Remove.
1418 (frame_save_as_regcache): Use lambda function.
1419 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
1420 parameter to ppu2spu_data *.
1421 (ppu2spu_sniffer): Use lambda function.
1423 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1425 * record-full.c (record_full_target::insert_breakpoint): Remove
1426 "struct" keyword, add const.
1428 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1430 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
1431 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
1432 * configure.ac: Remove AC_PREREQ, add missing quoting.
1433 * gnulib/configure.ac: Modernize usage of
1434 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
1435 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
1436 (AUTOMAKE_VERSION): Bump to 1.15.1.
1437 * configure: Re-generate.
1438 * config.in: Re-generate.
1439 * aclocal.m4: Re-generate.
1440 * gnulib/aclocal.m4: Re-generate.
1441 * gnulib/config.in: Re-generate.
1442 * gnulib/configure: Re-generate.
1443 * gnulib/import/Makefile.in: Re-generate.
1445 2018-06-19 Pedro Alves <palves@redhat.com>
1447 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
1448 (lookup_minimal_symbol_by_pc_section): ... here with
1449 gdb_assert_not_reached added.
1451 2018-06-19 Pedro Alves <palves@redhat.com>
1453 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
1454 parameter with a block parameter. Compare location's block symbol
1455 with the frame's block instead of addresses.
1456 (skip_inline_frames): Pass the current block instead of the
1457 frame's address. Break out as soon as we determine the frame
1458 should not be skipped.
1460 2018-06-18 Tom Tromey <tom@tromey.com>
1462 * solib-aix.c (solib_aix_get_section_offsets): Return
1464 (solib_aix_solib_create_inferior_hook): Update.
1466 2018-06-18 Tom Tromey <tom@tromey.com>
1468 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
1470 2018-06-18 Tom Tromey <tom@tromey.com>
1472 * solib-frv.c (frv_relocate_main_executable): Use
1474 * solib-dsbt.c (dsbt_relocate_main_executable): Use
1477 2018-06-18 Tom Tromey <tom@tromey.com>
1479 * objfiles.h (inhibit_section_map_updates): Update.
1480 (resume_section_map_updates, resume_section_map_updates_cleanup):
1482 * solib-svr4.c (svr4_handle_solib_event): Update.
1483 * objfiles.c (inhibit_section_map_updates): Return
1484 scoped_restore_tmpl<int>.
1485 (resume_section_map_updates, resume_section_map_updates_cleanup):
1488 2018-06-18 Tom Tromey <tom@tromey.com>
1490 * valprint.h (read_string): Update.
1491 * valprint.c (read_string): Change type of "buffer".
1492 (val_print_string): Update.
1493 * python/py-value.c (valpy_string): Update.
1494 * language.h (struct language_defn) <la_get_string>: Change
1496 (default_get_string, c_get_string): Update.
1497 * language.c (default_get_string): Change type of "buffer".
1498 * guile/scm-value.c (gdbscm_value_to_string): Update.
1499 * c-lang.c (c_get_string): Change type of "buffer".
1501 2018-06-18 Tom Tromey <tom@tromey.com>
1503 * ser-mingw.c (struct pipe_state_destroyer): New.
1504 (pipe_state_up): New typedef.
1505 (cleanup_pipe_state): Remove.
1506 (pipe_windows_open): Use pipe_state_up. Don't release argv.
1508 2018-06-18 Tom Tromey <tom@tromey.com>
1510 * rust-lang.h (rust_yyerror): Don't declare.
1511 * rust-lang.c (rust_language_defn): Update.
1512 * rust-exp.y (yyerror): Now static.
1513 * parse.c (parse_exp_in_context_1): Update.
1514 * p-lang.h (p_yyerror): Don't declare.
1515 * p-lang.c (p_language_defn): Update.
1516 * p-exp.y (yyerror): Now static.
1517 * opencl-lang.c (opencl_language_defn): Update.
1518 * objc-lang.c (objc_language_defn): Update.
1519 * m2-lang.h (m2_yyerror): Don't declare.
1520 * m2-lang.c (m2_language_defn): Update.
1521 * m2-exp.y (yyerror): Now static.
1522 * language.h (struct language_defn) <la_error>: Remove.
1523 * language.c (unk_lang_error): Remove.
1524 (unknown_language_defn, auto_language_defn): Remove.
1525 * go-lang.h (go_yyerror): Don't declare.
1526 * go-lang.c (go_language_defn): Update.
1527 * go-exp.y (yyerror): Now static.
1528 * f-lang.h (f_yyerror): Don't declare.
1529 * f-lang.c (f_language_defn): Update.
1530 * f-exp.y (yyerror): Now static.
1531 * d-lang.h (d_yyerror): Don't declare.
1532 * d-lang.c (d_language_defn): Update.
1533 * d-exp.y (yyerror): Now static.
1534 * c-lang.h (c_yyerror): Don't declare.
1535 * c-lang.c (c_language_defn, cplus_language_defn)
1536 (asm_language_defn, minimal_language_defn): Update.
1537 * c-exp.y (yyerror): Now static.
1538 * ada-lang.h (ada_yyerror): Don't declare.
1539 * ada-lang.c (ada_language_defn): Update.
1540 * ada-exp.y (yyerror): Now static.
1542 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1544 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
1545 (store_sveregs_to_thread): Likewise.
1546 (aarch64_linux_fetch_inferior_registers): Check for SVE.
1547 (aarch64_linux_store_inferior_registers): Likewise.
1548 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
1550 (aarch64_sve_regs_copy_to_regcache): Likewise.
1551 (aarch64_sve_regs_copy_from_regcache): Likewise.
1552 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
1554 (aarch64_sve_regs_copy_to_regcache): Likewise.
1555 (aarch64_sve_regs_copy_from_regcache): Likewise.
1556 (sve_context): Structure from Linux headers.
1557 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
1558 (SVE_SIG_ZREG_SIZE): Likewise.
1559 (SVE_SIG_PREG_SIZE): Likewise.
1560 (SVE_SIG_FFR_SIZE): Likewise.
1561 (SVE_SIG_REGS_OFFSET): Likewise.
1562 (SVE_SIG_ZREGS_OFFSET): Likewise.
1563 (SVE_SIG_ZREG_OFFSET): Likewise.
1564 (SVE_SIG_ZREGS_SIZE): Likewise.
1565 (SVE_SIG_PREGS_OFFSET): Likewise.
1566 (SVE_SIG_PREG_OFFSET): Likewise.
1567 (SVE_SIG_PREGS_SIZE): Likewise.
1568 (SVE_SIG_FFR_OFFSET): Likewise.
1569 (SVE_SIG_REGS_SIZE): Likewise.
1570 (SVE_SIG_CONTEXT_SIZE): Likewise.
1571 (SVE_PT_REGS_MASK): Likewise.
1572 (SVE_PT_REGS_FPSIMD): Likewise.
1573 (SVE_PT_REGS_SVE): Likewise.
1574 (SVE_PT_VL_INHERIT): Likewise.
1575 (SVE_PT_VL_ONEXEC): Likewise.
1576 (SVE_PT_REGS_OFFSET): Likewise.
1577 (SVE_PT_FPSIMD_OFFSET): Likewise.
1578 (SVE_PT_FPSIMD_SIZE): Likewise.
1579 (SVE_PT_SVE_ZREG_SIZE): Likewise.
1580 (SVE_PT_SVE_PREG_SIZE): Likewise.
1581 (SVE_PT_SVE_FFR_SIZE): Likewise.
1582 (SVE_PT_SVE_FPSR_SIZE): Likewise.
1583 (SVE_PT_SVE_FPCR_SIZE): Likewise.
1584 (__SVE_SIG_TO_PT): Likewise.
1585 (SVE_PT_SVE_OFFSET): Likewise.
1586 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
1587 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
1588 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
1589 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
1590 (SVE_PT_SVE_PREG_OFFSET): Likewise.
1591 (SVE_PT_SVE_PREGS_SIZE): Likewise.
1592 (SVE_PT_SVE_FFR_OFFSET): Likewise.
1593 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
1594 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
1595 (SVE_PT_SVE_SIZE): Likewise.
1596 (SVE_PT_SIZE): Likewise.
1597 (HAS_SVE_STATE): New define.
1599 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1601 * nat/aarch64-sve-linux-sigcontext.h: New file.
1602 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
1604 (SVE_VQ_MIN): Likewise.
1605 (SVE_VQ_MAX): Likewise.
1606 (SVE_VL_MIN): Likewise.
1607 (SVE_VL_MAX): Likewise.
1608 (SVE_NUM_ZREGS): Likewise.
1609 (SVE_NUM_PREGS): Likewise.
1610 (sve_vl_valid): Likewise.
1611 (struct user_sve_header): Likewise.
1613 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
1614 Richard Bunt <Richard.Bunt@arm.com>
1616 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
1617 was requested by GDB.
1619 2018-06-15 Tom de Vries <tdevries@suse.de>
1621 * MAINTAINERS (Write After Approval): Add Tom de Vries.
1623 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
1625 * gnulib/update-gnulib.sh: Print expected versions of
1628 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
1630 * arch-utils.c (default_type_align): Use type_length_units.
1631 * gdbtypes.c (type_align): Use type_length_units.
1633 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1635 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
1636 of 'define' command.
1638 2018-06-14 Tom de Vries <tdevries@suse.de>
1641 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
1642 get_no_prettyformat_print_options.
1644 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
1646 * sparc-nat.h: Include target.h.
1647 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
1648 <fetch_registers>: Remove this argument in function call.
1649 <store_registers>: Remove this argument in function call, remove
1651 <low_forget_process>: Call sparc64_forget_process instead of
1652 sparc_forget_process.
1654 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1656 * procfs.c (_initialize_procfs): Use add_inf_child_target.
1657 (procfs_target::make_corefile_notes): Adjust to new
1658 target_read_alloc return type.
1660 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1661 Stephen Roberts <stephen.roberts@arm.com>
1664 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
1665 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
1666 Move should_notify_stop local into more inner scope.
1668 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1669 Stephen Roberts <stephen.roberts@arm.com>
1672 * infrun.c (resume_1): Add call to mark_async_event_handler.
1674 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1676 * infrun.c (do_target_wait): Change old version of $pc printed.
1678 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
1680 * dwarf2read.c (read_index_from_section): Rename to...
1681 (read_gdb_index_from_section): ... this, update all callers.
1682 (dwarf2_read_index): Rename to...
1683 (dwarf2_read_gdb_index): ... this, update all callers.
1685 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
1687 * gdb/hppa-linux-nat.c
1688 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
1689 hppa_linux_nat_target::fetch_registers.
1691 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1693 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
1694 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
1695 (AARCH64_DWARF_SVE_FFR): Likewise.
1696 (AARCH64_DWARF_SVE_P0): Likewise.
1697 (AARCH64_DWARF_SVE_Z0): Likewise.
1699 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1701 * common/common-regcache.h (raw_compare): New function.
1702 * regcache.c (regcache::raw_compare): Likewise.
1703 * regcache.h (regcache::raw_compare): New declaration.
1705 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1707 * common/common-regcache.h (reg_buffer_common): New structure.
1708 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
1709 (reg_buffer::raw_supply): Likewise.
1710 (reg_buffer::raw_supply_integer): Likewise.
1711 (reg_buffer::raw_supply_zeroed): Likewise.
1712 (reg_buffer::raw_collect): Likewise.
1713 (reg_buffer::raw_collect_integer): Likewise.
1714 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
1715 (reg_buffer::raw_supply): Likewise.
1716 (reg_buffer::raw_supply_integer): Likewise.
1717 (reg_buffer::raw_supply_zeroed): Likewise.
1718 (reg_buffer::raw_collect): Likewise.
1719 (reg_buffer::raw_collect_integer): Likewise.
1721 2018-06-10 Tom Tromey <tom@tromey.com>
1723 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
1724 (class remote_state) <stop_reply_queue>: Now std::vector.
1725 (remote_state::~remote_state)
1726 (remote_target::stop_reply_queue_length): Update.
1727 (struct queue_iter_param, remove_child_of_pending_fork)
1728 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
1729 (check_pending_event_prevents_wildcard_vcont_callback)
1730 (remove_stop_reply_for_inferior)
1731 (remove_stop_reply_of_remote_state)
1732 (remote_notif_remove_once_on_match)
1733 (stop_reply_match_ptid_and_ws)
1734 (remote_kill_child_of_pending_fork): Remove.
1735 (remote_target::remove_new_fork_children)
1736 (remote_target::check_pending_events_prevent_wildcard_vcont)
1737 (remote_target::discard_pending_stop_replies)
1738 (remote_target::discard_pending_stop_replies_in_queue)
1739 (remote_target::remote_notif_remove_queued_reply)
1740 (remote_target::queued_stop_reply)
1741 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
1742 (remote_target::wait, remote_target::kill_new_fork_children)
1743 (remote_target::async): Update.
1745 2018-06-10 Tom Tromey <tom@tromey.com>
1747 * record-full.c (record_full_arch_list_cleanups): Remove.
1748 (record_full_message): Use try/catch.
1749 (record_full_wait_cleanups): Remove.
1750 (record_full_wait_1): Use try/catch.
1751 (record_full_restore): Likewise.
1753 2018-06-10 Tom Tromey <tom@tromey.com>
1755 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
1756 declare VEC. Add constructor.
1757 <in_target_beneath>: Now bool.
1758 (record_full_breakpoints): Now a std::vector, static.
1759 (record_full_sync_record_breakpoints)
1760 (record_full_init_record_breakpoints)
1761 (record_full_target::insert_breakpoint)
1762 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
1764 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
1766 * dwarf2read.c (process_cu_includes): Remove struct keyword.
1767 * serial.c (serial_interface_lookup): Remove struct keyword.
1769 2018-06-10 Tom Tromey <tom@tromey.com>
1771 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
1773 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
1775 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
1777 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
1778 "beneath" as a method.
1779 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
1780 Use "beneath" as a method.
1782 2018-06-10 Tom Tromey <tom@tromey.com>
1784 * tracefile.c (struct trace_file_writer_deleter): New.
1785 <operator()>: Rename from trace_file_writer_xfree.
1786 (trace_file_writer_up): New typedef.
1787 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
1789 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1791 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
1792 <m_registers, m_register_status>: Change type to
1794 * regcache.c (reg_buffer::reg_buffer): Use new instead of
1797 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1799 * common/common-regcache.h (enum register_status): Add
1800 underlying type "signed char".
1801 * regcache.h (reg_buffer) <m_register_status>: Change type to
1803 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
1804 register_status instead of signed char.
1805 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
1806 (reg_buffer::get_register_status): Remove cast.
1807 (readable_regcache::raw_read): Remove cast.
1808 (readable_regcache::cooked_read): Remove cast.
1810 2018-06-09 Tom Tromey <tom@tromey.com>
1812 * source.c (reverse_search_command, forward_search_command): Use
1815 2018-06-09 Tom Tromey <tom@tromey.com>
1817 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
1818 (serial_ops_list): Now static, std::vector.
1819 (serial_interface_lookup, serial_add_interface): Update.
1821 2018-06-09 Tom Tromey <tom@tromey.com>
1823 * dwarf2read.c (process_cu_includes): Update.
1824 (process_full_comp_unit): Update.
1825 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
1828 2018-06-08 Paul Koning <paul_koning@dell.com>
1832 * python/python.c (do_start_initialization):
1833 Avoid call to internal Python API.
1834 (init__gdb_module): New function.
1836 2018-06-08 Gary Benson <gbenson@redhat.com>
1838 * linux-thread-db.c (valprint.h): New include.
1839 (struct check_thread_db_info): New structure.
1840 (check_thread_db_on_load, tdb_testinfo): New static globals.
1841 (check_thread_db, check_thread_db_callback): New functions.
1842 (try_thread_db_load_1): Run integrity checks if requested.
1843 (maintenance_check_libthread_db): New function.
1844 (_initialize_thread_db): Register "maint check libthread-db"
1845 and "maint set/show check-libthread-db".
1846 * NEWS: Mention the above new commands.
1848 2018-06-08 Tom Tromey <tom@tromey.com>
1850 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
1853 2018-06-08 Tom Tromey <tom@tromey.com>
1855 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
1857 2018-06-08 Tom Tromey <tom@tromey.com>
1859 * common/btrace-common.h (struct btrace_data): Add constructor,
1860 destructor, move assignment operator.
1861 <empty, clear, fini>: New methods.
1862 <format>: Initialize.
1863 (btrace_data_init, btrace_data_fini, btrace_data_clear)
1864 (btrace_data_empty): Don't declare.
1865 * common/btrace-common.c (btrace_data_init): Remove.
1866 (btrace_data::fini): Rename from btrace_data_fini.
1867 (btrace_data::empty): Rename from btrace_data_empty.
1868 (btrace_data::clear): Rename from btrace_data_clear. Return
1870 * btrace.h (make_cleanup_btrace_data): Don't declare.
1871 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
1872 (parse_xml_btrace): Update.
1873 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
1874 (maint_btrace_clear_packet_history_cmd): Update.
1876 2018-06-07 Pedro Alves <palves@redhat.com>
1878 * target.h (target_ops) <beneath>: Now a method. All references
1880 (class target_stack): New.
1881 * target.c (g_target_stack): New.
1882 (g_current_top_target): Delete.
1883 (current_top_target): Get the top target out of g_target_stack.
1884 (target_stack::push, target_stack::unpush): New.
1885 (push_target, unpush_target): Reimplement.
1886 (target_is_pushed): Reimplement in terms of g_target_stack.
1887 (target_ops::beneath, target_stack::find_beneath): New.
1889 2018-06-07 Pedro Alves <palves@redhat.com>
1891 * target.h (find_target_beneath): Delete declaration.
1892 * target.c (find_target_beneath): Delete definition.
1893 * aix-thread.c: All callers of find_target_beneath adjusted to
1894 call target_ops::beneath instead.
1895 * bsd-uthread.c: Likewise.
1896 * linux-thread-db.c: Likewise.
1897 * ravenscar-thread.c: Likewise.
1898 * sol-thread.c: Likewise.
1899 * spu-multiarch.c: Likewise.
1901 2018-06-07 Pedro Alves <palves@redhat.com>
1903 * target.h (target_ops) <beneath>: Now a method. All references
1905 (target_ops) <m_beneath>: New.
1906 * target.c (target_ops::beneath): New.
1907 * corelow.c: Adjust all references to target_ops::beneath.
1908 * linux-thread-db.c: Likewise.
1909 * make-target-delegates: Likewise.
1910 * record-btrace.c: Likewise.
1911 * record-full.c: Likewise.
1912 * remote.c: Likewise.
1913 * target.c: Likewise.
1914 * target-delegates.c: Regenerate.
1916 2018-06-07 Pedro Alves <palves@redhat.com>
1918 * target.h (target_stack): Delete.
1919 (current_top_target): Declare function.
1920 * target.c (target_stack): Delete.
1921 (g_current_top_target): New.
1922 (current_top_target): New function.
1923 * auxv.c: Use current_top_target instead of target_stack
1925 * avr-tdep.c: Likewise.
1926 * breakpoint.c: Likewise.
1927 * corefile.c: Likewise.
1928 * elfread.c: Likewise.
1930 * exceptions.c: Likewise.
1931 * frame.c: Likewise.
1932 * gdbarch-selftests.c: Likewise.
1933 * gnu-v3-abi.c: Likewise.
1934 * ia64-tdep.c: Likewise.
1935 * ia64-vms-tdep.c: Likewise.
1936 * infcall.c: Likewise.
1937 * infcmd.c: Likewise.
1938 * infrun.c: Likewise.
1939 * linespec.c: Likewise.
1940 * linux-tdep.c: Likewise.
1941 * minsyms.c: Likewise.
1942 * ppc-linux-nat.c: Likewise.
1943 * ppc-linux-tdep.c: Likewise.
1944 * procfs.c: Likewise.
1945 * regcache.c: Likewise.
1946 * remote.c: Likewise.
1947 * rs6000-tdep.c: Likewise.
1948 * s390-linux-nat.c: Likewise.
1949 * s390-tdep.c: Likewise.
1950 * solib-aix.c: Likewise.
1951 * solib-darwin.c: Likewise.
1952 * solib-dsbt.c: Likewise.
1953 * solib-spu.c: Likewise.
1954 * solib-svr4.c: Likewise.
1955 * solib-target.c: Likewise.
1956 * sparc-tdep.c: Likewise.
1957 * sparc64-tdep.c: Likewise.
1958 * spu-tdep.c: Likewise.
1959 * symfile.c: Likewise.
1960 * symtab.c: Likewise.
1961 * target-descriptions.c: Likewise.
1962 * target-memory.c: Likewise.
1963 * target.c: Likewise.
1964 * target.h: Likewise.
1965 * tracefile-tfile.c: Likewise.
1966 * tracepoint.c: Likewise.
1967 * valops.c: Likewise.
1968 * valprint.c: Likewise.
1969 * value.c: Likewise.
1970 * windows-tdep.c: Likewise.
1971 * mi/mi-main.c: Likewise.
1973 2018-06-07 Tom Tromey <tom@tromey.com>
1975 * valprint.h (build_address_symbolic): Declare.
1976 * printcmd.c (print_address_symbolic): Update.
1977 (build_address_symbolic): Change "name" and "filename" to
1979 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
1981 * defs.h (build_address_symbolic): Remove declaration.
1983 2018-06-07 Alan Hayward <alan.hayward@arm.com>
1985 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
1986 (aarch64_vnv_type): Add function.
1987 (aarch64_pseudo_register_name): Add V regs for SVE.
1988 (aarch64_pseudo_register_type): Likewise.
1989 (aarch64_pseudo_register_reggroup_p): Likewise.
1990 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
1991 (aarch64_pseudo_read_value): Add V regs for SVE.
1992 (aarch64_pseudo_write_2): Use V0 offset for SVE
1993 (aarch64_pseudo_write): Add V regs for SVE.
1994 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
1996 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
1998 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
1999 (sve_vl_from_vq): Likewise.
2001 2018-06-05 Tom Tromey <tom@tromey.com>
2003 * cli/cli-cmds.c (show_version): Update.
2004 * top.c (print_gdb_version): Add "interactive" parameter.
2006 * main.c (captured_main_1): Update.
2007 * top.h (print_gdb_version): Add "interactive" parameter and a
2010 2018-06-05 David Malcolm <dmalcolm@redhat.com>
2012 * common/enum-flags.h: Add trailing semicolon to example in
2015 2018-06-05 Tom Tromey <tom@tromey.com>
2018 * NEWS: Add entry about pager.
2019 * utils.c (pagination_disabled_for_command): New global.
2020 (prompt_for_continue): Allow "c" response to prompt.
2021 (reinitialize_more_filter): Clear
2022 pagination_disabled_for_command.
2023 (fputs_maybe_filtered): Check pagination_disabled_for_command.
2025 2018-06-04 Tom Tromey <tom@tromey.com>
2027 * ada-lang.h (ada_lookup_symbol_list): Update.
2028 * ada-lang.c (resolve_subexp): Update.
2029 (symbols_are_identical_enums): Change type of syms. Remove nsyms
2031 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
2032 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
2033 results parameter to std::vector.
2034 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
2036 * ada-exp.y (block_lookup): Update.
2037 (select_possible_type_sym): Change type of syms. Remove nsyms
2039 (write_var_or_type, write_name_assoc): Update.
2041 2018-06-04 Joel Brobecker <brobecker@adacore.com>
2043 * windows-nat.c (windows_nat_target::xfer_partial): Return
2044 TARGET_XFER_E_IO if we need to delegate to the target beneath
2045 but BENEATH is NULL.
2047 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
2049 * Makefile.in (config.status): Add configure.nat as a
2052 2018-06-04 Tom Tromey <tom@tromey.com>
2054 * cp-name-parser.y (cpname_state): Add method declarations.
2055 (HANDLE_QUAL): Update.
2056 (cpname_state::d_grab, cpname_state::fill_comp)
2057 (cpname_state::make_operator, cpname_state::make_dtor)
2058 (cpname_state::make_builtin_type, cpname_state::make_name)
2059 (cpname_state::d_qualify, cpname_state::d_int_type)
2060 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
2061 (%union): Move earlier.
2063 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2065 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
2067 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2069 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
2070 (aarch64_pseudo_write_1): Likewise.
2071 (aarch64_pseudo_read_value): Use helper.
2072 (aarch64_pseudo_write): Likewise.
2074 2018-06-04 Pedro Alves <palves@redhat.com>
2076 * darwin-nat.c (darwin_ops): Delete.
2077 (darwin_attach_pid): Use get_native_target.
2079 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2081 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
2082 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
2084 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2086 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
2087 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
2088 (aarch64_gdbarch_init): Check for SVE.
2089 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
2091 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2093 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
2094 * aarch64-tdep.h (aarch64_read_description): Likewise.
2095 * arch/aarch64.c (aarch64_create_target_description): Likewise.
2096 * arch/aarch64.h (aarch64_create_target_description): Likewise.
2097 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
2098 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
2099 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
2101 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
2103 * value.c (value_fetch_lazy_bitfield): New.
2104 (value_fetch_lazy_memory): New.
2105 (value_fetch_lazy_register): New.
2106 (value_fetch_lazy): Factor out to smaller functions.
2108 2018-06-01 Tom Tromey <tom@tromey.com>
2110 * cp-name-parser.y (backslashable, represented): Now const.
2112 2018-06-01 Tom Tromey <tom@tromey.com>
2114 * cp-name-parser.y: Include parser-defs.h.
2115 (parser_fprintf): Remove declaration.
2117 2018-06-01 Tom Tromey <tom@tromey.com>
2119 * cp-name-parser.y: Use %pure-parser, %lex-param, and
2121 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
2122 (global_result): Remove globals.
2123 (struct cpname_state): New.
2124 (yyparse): Don't declare.
2125 (yylex, yyerror): Move declarations after %union.
2126 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
2127 (make_name): Add state parameter.
2129 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
2131 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
2133 (yylex): Add lvalp, state parameters.
2134 (yyerror): Add state parameter.
2135 (cp_demangled_name_to_comp): Update.
2137 2018-06-01 Tom Tromey <tom@tromey.com>
2139 * cp-name-parser.y (parser_fprintf): Declare.
2140 (GDB_YY_REMAP_PREFIX): Define.
2141 Include yy-remap.h. Don't redefine yy* identifiers.
2143 2018-06-01 Tom Tromey <tom@tromey.com>
2145 * python/py-type.c (typy_legacy_template_argument): Update.
2146 * cp-support.h (cp_demangled_name_to_comp): Update.
2147 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
2148 parameter to be a "std::string *".
2151 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
2153 * ada-lex.l: Include "diagnostics.h" instead of
2154 "common/diagnostics.h".
2155 * unittests/environ-selftests.c: Likewise.
2156 * common/diagnostics.h: Moved to ../include.
2158 2018-06-01 Joel Brobecker <brobecker@adacore.com>
2160 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
2161 to language_mode_manual while calling breakpoint_re_set_one.
2163 2018-06-01 Tom Tromey <tom@tromey.com>
2165 * valops.c (value_cast_structs, destructor_name_p): Update.
2166 * symtab.c (gdb_mangle_name): Update.
2167 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
2169 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
2170 (pascal_object_print_value_fields, pascal_object_print_value):
2172 * p-typeprint.c (pascal_type_print_derivation_info): Update.
2173 * linespec.c (find_methods): Update.
2174 * gdbtypes.h (type_name_no_tag): Remove.
2175 (type_name_or_error): Rename from type_name_no_tag_or_error.
2176 * gdbtypes.c (type_name_no_tag): Remove.
2177 (type_name_or_error): Rename from type_name_no_tag_or_error.
2178 (lookup_struct_elt_type, check_typedef): Update.
2179 * expprint.c (print_subexp_standard): Update.
2180 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
2181 * d-namespace.c (d_lookup_nested_symbol): Update.
2182 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
2183 (cp_print_class_member): Update.
2184 * cp-namespace.c (cp_lookup_nested_symbol): Update.
2185 * completer.c (add_struct_fields): Update.
2186 * c-typeprint.c (cp_type_print_derivation_info)
2187 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
2189 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
2190 (ada_prefer_type, ada_is_exception_sym): Update.
2192 2018-06-01 Tom Tromey <tom@tromey.com>
2194 * valops.c (enum_constant_from_type, value_namespace_elt)
2195 (value_maybe_namespace_elt): Update.
2196 * valarith.c (find_size_for_pointer_math): Update.
2197 * target-descriptions.c (make_gdb_type): Update.
2198 * symmisc.c (print_symbol): Update.
2199 * stabsread.c (define_symbol, read_type)
2200 (complain_about_struct_wipeout, add_undefined_type)
2201 (cleanup_undefined_types_1): Update.
2202 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
2203 (rust_range_type_p, val_print_struct, rust_print_struct_def)
2204 (rust_internal_print_type, rust_composite_type)
2205 (rust_evaluate_funcall, rust_evaluate_subexp)
2206 (rust_inclusive_range_type_p): Update.
2207 * python/py-type.c (typy_get_tag): Update.
2208 * p-typeprint.c (pascal_type_print_base): Update.
2209 * mdebugread.c (parse_symbol, parse_type): Update.
2210 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
2212 * guile/scm-type.c (gdbscm_type_tag): Update.
2213 * go-lang.c (sixg_string_p): Update.
2214 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
2216 * gdbtypes.h (struct main_type) <tag_name>: Remove.
2217 (TYPE_TAG_NAME): Remove.
2218 * gdbtypes.c (type_name_no_tag): Simplify.
2219 (check_typedef, check_types_equal, recursive_dump_type)
2220 (copy_type_recursive, arch_composite_type): Update.
2221 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
2222 in summary mode when needed.
2223 * eval.c (evaluate_funcall): Update.
2224 * dwarf2read.c (fixup_go_packaging, read_structure_type)
2225 (process_structure_scope, read_enumeration_type)
2226 (read_namespace_type, read_module_type, determine_prefix): Update.
2227 * cp-support.c (inspect_type): Update.
2228 * coffread.c (process_coff_symbol, decode_base_type): Update.
2229 * c-varobj.c (c_is_path_expr_parent): Update.
2230 * c-typeprint.c (c_type_print_base_struct_union): Update.
2231 (c_type_print_base_1): Update. Print struct/class/union/enum in
2232 summary when using C language.
2233 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
2234 (gen_maybe_namespace_elt): Update.
2235 * ada-lang.c (ada_type_name): Simplify.
2236 (empty_record, ada_template_to_fixed_record_type_1)
2237 (template_to_static_fixed_type)
2238 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
2240 2018-06-01 Tom Tromey <tom@tromey.com>
2242 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
2244 * c-typeprint.c (c_print_type_1): Add "language" parameter.
2245 (c_print_type): Update.
2246 (c_print_type): New overload.
2247 (c_type_print_varspec_prefix, c_type_print_args)
2248 (c_type_print_varspec_suffix, c_print_type_no_offsets)
2249 (c_type_print_base_struct_union, c_type_print_base_1)
2250 (cp_type_print_method_args): Add "language" parameter.
2251 (c_type_print_base): Update.
2252 * c-lang.h (c_print_type): Add new overload.
2254 2018-06-01 Tom Tromey <tom@tromey.com>
2256 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
2257 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
2259 2018-06-01 Alan Hayward <alan.hayward@arm.com>
2261 * aarch64-tdep.c (aarch64_sve_register_names): New const
2263 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
2264 (AARCH64_SVE_Z_REGS_NUM): New define.
2265 (AARCH64_SVE_P_REGS_NUM): Likewise.
2266 (AARCH64_SVE_NUM_REGS): Likewise.
2268 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
2270 * nat/linux-ptrace.h [__alpha__]
2271 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
2274 2018-05-31 Maciej W. Rozycki <macro@mips.com>
2276 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
2277 the endianness selected.
2278 * NEWS: Document `set endian auto' mode operation update.
2280 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2282 * Makefile.in: Add new header.
2283 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
2284 (sve_vl_from_vg): Likewise.
2285 (sve_vq_from_vl): Likewise.
2286 (sve_vl_from_vq): Likewise.
2287 (sve_vq_from_vg): Likewise.
2288 (sve_vg_from_vq): Likewise.
2289 * configure.nat: Add new c file.
2290 * nat/aarch64-sve-linux-ptrace.c: New file.
2291 * nat/aarch64-sve-linux-ptrace.h: New file.
2293 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2295 * aarch64-linux-nat.c (aarch64_linux_read_description):
2297 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
2299 * aarch64-tdep.c (tdesc_aarch64_list): Add.
2300 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
2301 (aarch64_gdbarch_init): Add parmeter zero.
2302 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
2303 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
2304 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
2306 * doc/gdb.texinfo: Describe SVE feature
2307 * features/aarch64-sve.c: New file.
2309 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
2312 * gdbarch.sh (significant_addr_bit): Default to zero when
2313 not set by target architecture.
2314 * gdbarch.c: Re-generated.
2315 * utils.c (address_significant): Update.
2317 2018-05-30 Joel Brobecker <brobecker@adacore.com>
2319 * stack.c (func_command): Remove trailing newline in call to error.
2321 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2323 * regcache.h (regcache_raw_collect): Remove, update callers to
2324 use regcache::raw_collect.
2325 * regcache.c (regcache_raw_collect): Remove.
2327 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2329 * regcache.h (regcache_raw_supply): Remove, update callers to
2330 use detached_regcache::raw_supply.
2331 * regcache.c (regcache_raw_supply): Remove.
2333 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2335 * regcache.h (regcache_cooked_write_part): Remove, update
2336 callers to use regcache::cooked_write_part.
2337 * regcache.c (regcache_cooked_write_part): Remove.
2339 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2341 * regcache.h (regcache_cooked_read_part): Remove, update callers
2342 to use readable_regcache::cooked_read_part.
2343 * regcache.c (regcache_cooked_read_part): Remove.
2345 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2347 * regcache.h (regcache_cooked_read_value): Remove, update
2348 callers to use readable_regcache::cooked_read_value.
2349 * regcache.c (regcache_cooked_read_value): Remove.
2351 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2353 * regcache.h (regcache_cooked_write): Remove, update callers to
2354 use regcache::cooked_write.
2355 * regcache.c (regcache_cooked_write): Remove.
2357 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2359 * regcache.h (regcache_invalidate): Remove, update callers to
2360 use detached_regcache::invalidate instead.
2361 * regcache.c (regcache_invalidate): Remove.
2363 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2365 * regcache.h (regcache_raw_write_part): Remove, update callers
2366 to use regcache::raw_write_part instead.
2367 * regcache.c (regcache_raw_write_part): Remove.
2369 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2371 * regcache.h (regcache_raw_read_part): Remove, update callers to
2372 use readable_regcache::raw_read_part instead.
2373 * regcache.c (regcache_raw_read_part): Remove.
2375 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2377 * regcache.h (regcache_cooked_read): Remove, update callers to
2378 use readable_regcache::cooked_read instead.
2379 * regcache.c (regcache_cooked_read): Remove.
2381 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2383 * regcache.h (regcache_raw_write): Remove, update callers to use
2384 regcache::raw_write instead.
2385 * regcache.c (regcache_raw_write): Remove.
2387 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2389 * regcache.h (regcache_raw_read): Remove, update callers to use
2390 readable_regcache::raw_read instead.
2391 * regcache.c (regcache_raw_read): Remove.
2393 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2395 * regcache.h (regcache_raw_update): Remove, update callers to
2396 use readable_regcache::raw_update instead.
2397 * regcache.c (regcache_raw_update): Remove.
2399 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2401 * regcache.h (regcache_register_status): Remove, update callers
2402 to use reg_buffer::get_register_status directly instead.
2403 * regcache.c (regcache_register_status): Remove.
2405 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2407 * regcache.h (regcache_get_ptid): Remove, update all callers to
2408 call regcache::ptid instead.
2409 * regcache.c (regcache_get_ptid): Remove.
2411 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2413 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
2415 2018-05-30 Pedro Alves <palves@redhat.com>
2417 * common/common-exceptions.h (exception_rethrow): Use
2420 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
2422 * breakpoint.c (print_solib_event, check_status_catch_solib):
2423 Remove struct keyword in range-based for loops.
2424 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
2425 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
2427 * linespec.c (find_superclass_methods, search_minsyms_for_name):
2429 * symfile.c (addr_info_make_relative): Likewise.
2430 * thread.c (value_in_thread_stack_temporaries): Likewise.
2432 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
2435 * valops.c (value_struct_elt_for_reference): Call check_typedef on
2436 aggregate type to get its real type before accessing it.
2438 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
2440 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
2441 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
2442 * coff-pe-read.c (add_pe_forwarded_sym): Replace
2443 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
2444 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
2445 * jit.c (jit_breakpoint_re_set_internal): Likewise.
2446 * printcmd.c (info_address_command): Likewise.
2448 2018-05-29 Tom Tromey <tom@tromey.com>
2450 * windows-nat.c (handle_exception): Update fall-through comment.
2452 2018-05-29 Tom Tromey <tom@tromey.com>
2454 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
2455 (struct program_space) <added_solibs>: Now a std::vector.
2456 * breakpoint.c (print_solib_event): Update.
2457 (check_status_catch_solib): Update.
2458 * progspace.c (clear_program_space_solib_cache): Update.
2459 * solib.c (update_solib_list): Update.
2461 2018-05-29 Tom Tromey <tom@tromey.com>
2463 * python/py-type.c (typy_richcompare): Update.
2464 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
2465 * gdbtypes.h (types_deeply_equal): Return bool.
2466 (types_equal): Likewise.
2467 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
2469 (check_types_equal): Change worklist to std::vector. Return
2471 (struct type_equality_entry): Add constructor.
2472 (compare_maybe_null_strings): Return bool.
2473 (check_types_worklist): Return bool. Change worklist to
2475 (types_deeply_equal): Use std::vector.
2476 (types_equal): Return bool.
2477 (compare_maybe_null_strings): Simplify.
2479 2018-05-29 Tom Tromey <tom@tromey.com>
2481 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
2483 2018-05-29 Tom Tromey <tom@tromey.com>
2485 * objc-lang.h: Don't include cp-support.h.
2486 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
2489 2018-05-27 Tom Tromey <tom@tromey.com>
2491 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
2493 2018-05-25 Tom Tromey <tom@tromey.com>
2495 * value.c (value::location): Initialize.
2497 2018-05-25 Tom Tromey <tom@tromey.com>
2499 * dbxread.c (init_bincl_list): Remove.
2500 (bincl_list): Now a std::vector.
2501 (bincls_allocated, next_bincl): Remove.
2502 (free_bincl_list, do_free_bincl_list_cleanup)
2503 (make_cleanup_free_bincl_list): Remove.
2504 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
2506 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
2507 (struct header_file_location): Add constructor.
2508 (add_bincl_to_list): Remove.
2510 2018-05-25 Tom Tromey <tom@tromey.com>
2512 * tui/tui.c (tui_enable): Update.
2513 * mi/mi-interp.c (mi_interp::init): Update.
2514 * interps.h (class interp) <name>: New method.
2515 <m_name>: Rename from name.
2516 (~scoped_restore_interp): Update.
2517 * interps.c (interp::interp): Update.
2518 (interp_add, interp_set, interp_lookup_existing)
2519 (current_interp_named_p): Update.
2521 2018-05-25 Tom Tromey <tom@tromey.com>
2523 * interps.c (interp_name): Remove.
2524 * mi/mi-interp.c (mi_interp::init): Update.
2525 * interps.h (interp_name): Remove.
2526 (~scoped_restore_interp): Update.
2527 * tui/tui.c (tui_enable): Update.
2529 2018-05-25 Tom Tromey <tom@tromey.com>
2531 * utils.c (fputs_maybe_filtered): Update.
2532 * linespec.c (decode_line_full): Update.
2533 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
2534 (mi_print_breakpoint_for_event, mi_solib_loaded)
2535 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
2536 (mi_user_selected_context_changed): Update.
2537 * mi/mi-main.c (mi_execute_command): Update.
2538 * cli/cli-script.c (execute_control_command): Update.
2539 * python/python.c (execute_gdb_command): Update.
2540 * solib.c (info_sharedlibrary_command): Update.
2541 * interps.c (interp_ui_out): Remove.
2542 * interps.h (interp_ui_out): Remove.
2544 2018-05-25 Tom Tromey <tom@tromey.com>
2546 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
2547 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
2548 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
2550 2018-05-25 Tom Tromey <tom@tromey.com>
2552 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
2553 * interps.c (interp_exec): Use scoped_restore.
2555 2018-05-25 Tom Tromey <tom@tromey.com>
2557 * remote.c (remote_target::remote_file_get): Use
2559 (remote_target::remote_file_put): Likewise.
2561 2018-05-25 Tom Tromey <tom@tromey.com>
2563 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
2565 (get_pe_section_index, add_pe_exported_sym): Update.
2566 (read_pe_exported_syms): Use gdb::def_vector.
2568 2018-05-25 Tom Tromey <tom@tromey.com>
2570 * frame.c (remove_prev_frame): Remove.
2571 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
2573 2018-05-25 Maciej W. Rozycki <macro@mips.com>
2575 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
2577 * mips-linux-nat.c (supply_fpregset): Always call
2578 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
2579 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
2580 `mips_fill_fpregset'.
2581 * mips-linux-tdep.c (mips_supply_fpregset)
2582 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
2583 (mips_fill_fpregset_wrapper): Remove functions.
2584 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
2585 (mips_linux_fpregset): Remove variable.
2586 (mips_linux_iterate_over_regset_sections): Use
2587 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
2588 (mips_linux_o32_sigframe_init): Remove comment.
2590 2018-05-25 Pedro Alves <palves@redhat.com>
2592 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
2593 (struct readahead_cache, struct packet_reg, struct
2594 remote_arch_state, class remote_state): Move higher up in the
2596 (remote_target::m_remote_state): Now an object instead of a pointer.
2597 (remote_target::get_remote_state): Adjust.
2599 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2601 * stack.c (select_and_print_frame): Delete.
2602 (struct function_bounds): Move struct within function.
2603 (func_command): Most content moved into new function
2604 find_frame_for_function, use new function, print result, add
2606 (find_frame_for_function): New function, now returns a result.
2608 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2610 * stack.c (iterate_over_block_arg_vars): Fix comment.
2611 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
2613 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2617 (scoped_restore_selected_frame::scoped_restore_selected_frame):
2619 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
2621 * frame.h (class scoped_restore_selected_frame): New class.
2622 * stack.c (print_frame_local_vars): Remove catching and rethrowing
2623 of any exception, use scoped_restore_selected_frame to restore the
2626 2018-05-24 Pedro Alves <palves@redhat.com>
2628 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
2631 2018-05-23 Tom Tromey <tom@tromey.com>
2633 * complaints.c (struct complaints): Remove.
2634 (symfile_complaint_book): Remove.
2635 (series): New global.
2636 (complaint_internal): Update.
2637 (clear_complaints): Update.
2639 2018-05-23 Tom Tromey <tom@tromey.com>
2641 * complaints.c (counters): New global.
2642 (struct complain): Remove.
2643 (struct complaints) <root>: Remove.
2644 (complaint_sentinel): Remove.
2645 (symfile_complaint_book): Update.
2646 (find_complaint) Remove.
2647 (complaint_internal, clear_complaints): Update.
2649 2018-05-23 Tom Tromey <tom@tromey.com>
2651 * complaints.c (struct complain) <file, line>: Remove.
2652 (find_complaint): Remove file, line parameters.
2653 (complaint_internal): Update.
2655 2018-05-23 Tom Tromey <tom@tromey.com>
2657 * complaints.c (vcomplaint): Remove.
2658 (complaint_internal) Merge in contents of vcomplaint.
2660 2018-05-23 Tom Tromey <tom@tromey.com>
2662 * complaints.c (struct complaints) <explanation>: Remove.
2663 (symfile_explanations): Remove.
2664 (symfile_complaint_book): Update.
2665 (vcomplaint): Update.
2666 (struct explanation): Remove.
2668 2018-05-23 Tom Tromey <tom@tromey.com>
2670 * complaints.c (symfile_complaints): Remove.
2671 (complaint_internal): Remove "complaints" parameter.
2672 (clear_complaints, vcomplaint): Remove "c" parameter.
2673 (get_complaints): Remove.
2674 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
2675 (dwarf2_debug_line_missing_file_complaint)
2676 (dwarf2_debug_line_missing_end_sequence_complaint)
2677 (dwarf2_complex_location_expr_complaint)
2678 (dwarf2_const_value_length_mismatch_complaint)
2679 (dwarf2_section_buffer_overflow_complaint)
2680 (dwarf2_macro_malformed_definition_complaint)
2681 (dwarf2_invalid_attrib_class_complaint)
2682 (create_addrmap_from_index, dw2_symtab_iter_next)
2683 (dw2_expand_marked_cus)
2684 (dw2_debug_names_iterator::find_vec_in_debug_names)
2685 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
2686 (create_debug_type_hash_table, init_cutu_and_read_dies)
2687 (partial_die_parent_scope, add_partial_enumeration)
2688 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
2689 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
2690 (read_import_statement, read_file_scope, create_dwo_cu_reader)
2691 (create_cus_hash_table, create_dwp_hash_table)
2692 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
2693 (dwarf2_rnglists_process, dwarf2_ranges_process)
2694 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
2695 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
2696 (handle_struct_member_die, process_structure_scope)
2697 (read_array_type, read_common_block, read_module_type)
2698 (read_tag_pointer_type, read_typedef, read_base_type)
2699 (read_subrange_type, load_partial_dies, partial_die_info::read)
2700 (partial_die_info::read, partial_die_info::read)
2701 (partial_die_info::read, read_checked_initial_length_and_offset)
2702 (dwarf2_string_attr, read_formatted_entries)
2703 (dwarf_decode_line_header)
2704 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2705 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
2706 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
2707 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
2708 (get_signatured_type, get_DW_AT_signature_type)
2709 (decode_locdesc, file_file_name, consume_improper_spaces)
2710 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
2711 (dwarf_decode_macro_bytes, dwarf_decode_macros)
2712 (dwarf2_symbol_mark_computed, set_die_type)
2713 (read_attribute_value): Update.
2714 * stap-probe.c (handle_stap_probe, get_stap_base_address):
2716 * dbxread.c (unknown_symtype_complaint)
2717 (lbrac_mismatch_complaint, repeated_header_complaint)
2718 (set_namestring, function_outside_compilation_unit_complaint)
2719 (read_dbx_symtab, process_one_symbol): Update.
2720 * gdbtypes.c (stub_noname_complaint): Update.
2721 * windows-nat.c (handle_unload_dll): Update.
2722 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
2723 (decode_base_type): Update.
2724 * xcoffread.c (bf_notfound_complaint, ef_complaint)
2725 (eb_complaint, record_include_begin, record_include_end)
2726 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
2727 (process_xcoff_symbol, read_symbol)
2728 (function_outside_compilation_unit_complaint)
2729 (scan_xcoff_symtab): Update.
2730 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
2731 * buildsym.c (finish_block_internal, make_blockvector)
2732 (end_symtab_get_static_block, augment_type_symtab): Update.
2733 * dtrace-probe.c (dtrace_process_dof)
2734 (dtrace_static_probe_ops::get_probes): Update.
2735 * complaints.h (struct complaint): Don't declare.
2736 (symfile_complaints): Remove.
2737 (complaint_internal): Remove "complaints" parameter.
2738 (complaint): Likewise.
2739 (clear_complaints): Likewise.
2740 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2741 (reread_symbols): Update.
2742 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2743 (dwarf2_frame_cache, decode_frame_entry): Update.
2744 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
2745 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2746 (info_selectors_command): Update.
2747 * macrotab.c (macro_include, check_for_redefinition)
2748 (macro_undef): Update.
2749 * objfiles.c (filter_overlapping_sections): Update.
2750 * stabsread.c (invalid_cpp_abbrev_complaint)
2751 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
2752 (define_symbol, error_type, read_type, rs6000_builtin_type)
2753 (stabs_method_name_from_physname, read_member_functions)
2754 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
2755 (attach_fields_to_type, complain_about_struct_wipeout)
2756 (read_range_type, read_args, common_block_start)
2757 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
2759 * mdebugread.c (index_complaint, unknown_ext_complaint)
2760 (basic_type_complaint, bad_tag_guess_complaint)
2761 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
2762 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
2763 (parse_procedure, parse_lines)
2764 (function_outside_compilation_unit_complaint)
2765 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
2766 (bad_tag_guess_complaint, reg_value_complaint): Update.
2767 * cp-support.c (demangled_name_complaint): Update.
2768 * macroscope.c (sal_macro_scope): Update.
2769 * dwarf-index-write.c (class debug_names): Update.
2771 2018-05-23 Tom Tromey <tom@tromey.com>
2773 * complaints.c (clear_complaints): Remove "noisy" parameter.
2774 * complaints.h (clear_complaints): Update.
2775 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2776 (reread_symbols): Update.
2778 2018-05-23 Tom Tromey <tom@tromey.com>
2780 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
2782 (vcomplaint, clear_complaints): Update.
2783 (symfile_explanations): Remove some messages.
2785 2018-05-23 Tom Tromey <tom@tromey.com>
2787 * complaints.c (internal_complaint): Remove.
2788 * complaints.h (internal_complaint): Remove.
2790 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2792 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
2794 2018-05-22 Pedro Alves <palves@redhat.com>
2796 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
2797 (remote_fileio_badfd, remote_fileio_return_errno)
2798 (remote_fileio_return_success, remote_fileio_func_open)
2799 (remote_fileio_func_open, remote_fileio_func_close)
2800 (remote_fileio_func_read, remote_fileio_func_write)
2801 (remote_fileio_func_lseek, remote_fileio_func_rename)
2802 (remote_fileio_func_unlink, remote_fileio_func_stat)
2803 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
2804 (remote_fileio_func_isatty, remote_fileio_func_system): Add
2805 remote_target parameter.
2806 (remote_fio_func_map) <func>: Add remote_target parameter.
2807 (do_remote_fileio_request, remote_fileio_request):
2808 * remote-fileio.h (remote_fileio_request):
2809 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
2810 remote_target parameter.
2811 (remote_notif_process, handle_notification): Adjust to pass down
2813 (remote_notif_state_allocate): Add remote_target parameter. Save
2815 * remote-notif.h (struct remote_target): Forward declare.
2816 (struct notif_client) <parse, ack, can_get_pending_events>: Add
2817 remote_target parameter.
2818 (struct remote_notif_state) <remote>: New field.
2819 (remote_notif_ack, remote_notif_parse): Add remote_target
2821 (remote_notif_state_allocate, remote_notif_state_allocate): Add
2822 remote_target parameter.
2823 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
2824 (threads_listing_context, rmt_thread_action, protocol_feature)
2825 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
2826 (packet_result, struct threads_listing_context, remote_state):
2827 Move definitions and declarations higher up.
2828 (remote_target) <~remote_target>: Declare.
2829 (remote_download_command_source, remote_file_put, remote_file_get)
2830 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
2831 (remote_hostio_pread_vFile, remote_hostio_send_command)
2832 (remote_hostio_set_filesystem, remote_hostio_open)
2833 (remote_hostio_close, remote_hostio_unlink, remote_state)
2834 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
2835 (get_memory_write_packet_size, get_memory_read_packet_size)
2836 (append_pending_thread_resumptions, remote_detach_1)
2837 (append_resumption, remote_resume_with_vcont)
2838 (add_current_inferior_and_thread, wait_ns, wait_as)
2839 (process_stop_reply, remote_notice_new_inferior)
2840 (process_initial_stop_replies, remote_add_thread)
2841 (btrace_sync_conf, remote_btrace_maybe_reopen)
2842 (remove_new_fork_children, kill_new_fork_children)
2843 (discard_pending_stop_replies, stop_reply_queue_length)
2844 (check_pending_events_prevent_wildcard_vcont)
2845 (discard_pending_stop_replies_in_queue, stop_reply)
2846 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
2847 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
2848 (remote_interrupt_as, remote_interrupt_ns)
2849 (remote_get_noisy_reply, remote_query_attached)
2850 (remote_add_inferior, remote_current_thread, get_current_thread)
2851 (set_thread, set_general_thread, set_continue_thread)
2852 (set_general_process, write_ptid)
2853 (remote_unpack_thread_info_response, remote_get_threadinfo)
2854 (parse_threadlist_response, remote_get_threadlist)
2855 (remote_threadlist_iterator, remote_get_threads_with_ql)
2856 (remote_get_threads_with_qxfer)
2857 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
2858 (get_offsets, remote_check_symbols, remote_supported_packet)
2859 (remote_query_supported, remote_packet_size)
2860 (remote_serial_quit_handler, remote_detach_pid)
2861 (remote_vcont_probe, remote_resume_with_hc)
2862 (send_interrupt_sequence, interrupt_query)
2863 (remote_notif_get_pending_events, fetch_register_using_p)
2864 (send_g_packet, process_g_packet, fetch_registers_using_g)
2865 (store_register_using_P, store_registers_using_G)
2866 (set_remote_traceframe, check_binary_download)
2867 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
2868 (remote_xfer_live_readonly_partial, remote_read_bytes)
2869 (remote_send_printf, remote_flash_write, readchar)
2870 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
2871 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
2872 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
2873 (extended_remote_disable_randomization, extended_remote_run)
2874 (send_environment_packet, extended_remote_environment_support)
2875 (extended_remote_set_inferior_cwd, remote_write_qxfer)
2876 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
2877 (packet_command): Now methods of ...
2878 (remote_target): ... this class.
2879 (m_remote_state) <remote_target>: New field.
2880 (struct remote_state) <stop_reply_queue,
2881 remote_async_inferior_event_token, wait_forever_enabled_p>: New
2883 (remote_state::remote_state): Allocate stop_reply_queue.
2884 (remote_state): Delete global.
2885 (get_remote_state_raw): Delete.
2886 (remote_target::get_remote_state): Allocate m_remote_state on
2888 (get_current_remote_target): New.
2889 (remote_ops, extended_remote_ops): Delete.
2890 (wait_forever_enabled_p, remote_async_inferior_event_token):
2891 Delete, moved to struct remote_state.
2892 (remote_target::close): Delete self. Destruction bits split to
2894 (remote_target::~remote_target): ... this.
2895 (show_memory_packet_size): Adjust to use
2896 get_current_remote_target.
2897 (struct protocol_feature) <func>: Add remote_target parameter.
2898 All callers adjusted.
2899 (curr_quit_handler_target): New.
2900 (remote_serial_quit_handler): Reimplement.
2901 (remote_target::open_1): Adjust to use get_current_remote_target.
2902 Heap-allocate remote_target/extended_remote_target instances.
2903 (vcont_builder::vcont_builder): Add remote_target parameter, and
2904 save it in m_remote. All callers adjusted.
2905 (vcont_builder::m_remote): New field.
2906 (vcont_builder::restart, vcont_builder::flush)
2907 (vcont_builder::push_action): Use it.
2908 (remote_target::commit_resume): Use it.
2909 (struct queue_iter_param) <remote>: New field.
2910 (remote_target::remove_new_fork_children): Fill in 'remote' field.
2911 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
2912 (check_pending_event_prevents_wildcard_vcont_callback)
2913 (remote_target::check_pending_events_prevent_wildcard_vcont)
2914 (remote_target::discard_pending_stop_replies)
2915 (remote_target::discard_pending_stop_replies_in_queue)
2916 (remote_target::remote_notif_remove_queued_reply): Fill in
2918 (remote_notif_get_pending_events): New.
2919 (remote_target::readchar, remote_target::remote_serial_write):
2920 Save/restore curr_quit_handler_target.
2922 (kill_new_fork_children): Fill in 'remote' field.
2923 (packet_command): Use get_current_remote_target, defer to
2924 remote_target method of same name.
2925 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
2926 parameter, and save it in m_remote. All callers adjusted.
2927 (scoped_remote_fd::release): Use m_remote.
2928 (scoped_remote_fd::m_remote): New field.
2929 (remote_file_put, remote_file_get, remote_file_delete): Use
2930 get_current_remote_target, defer to remote_target method of same
2932 (remote_btrace_reset): Add remote_state paremeter. Update all
2934 (remote_async_inferior_event_handler). Pass down 'data'.
2935 (remote_new_objfile): Use get_current_remote_target.
2936 (remote_target::vcont_r_supported): New.
2937 (set_range_stepping): Use get_current_remote_target and
2938 remote_target::vcont_r_supported.
2939 (_initialize_remote): Don't allocate 'remote_state' and
2940 'stop_reply_queue' globals.
2941 * remote.h (struct remote_target): Forward declare.
2942 (getpkt, putpkt, remote_notif_get_pending_events): Add
2943 'remote_target' parameter.
2945 2018-05-22 Pedro Alves <palves@redhat.com>
2947 * remote.c (vcont_builder): Now a class. Make all data members
2949 (vcont_builder) <vcont_builder, restart, flush, push_action>:
2951 (vcont_builder_restart): Rename to ...
2952 (vcont_builder::restart): ... this.
2953 (vcont_builder_flush): Rename to ...
2954 (vcont_builder::flush): ... this.
2955 (vcont_builder_push_action): Rename to ...
2956 (vcont_builder::push_action): ... this.
2957 (remote_target::commit_resume): Adjust.
2959 2018-05-22 Pedro Alves <palves@redhat.com>
2961 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
2962 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
2963 (get_fixed_memory_packet_size): New.
2964 (get_memory_packet_size): Use it.
2965 (set_memory_packet_size): Don't override the config size with
2966 DEFAULT_MAX_MEMORY_PACKET_SIZE.
2967 (show_memory_packet_size): Use get_fixed_memory_packet_size.
2968 Don't refer to get_memory_packet_size if not connected to a remote
2969 target. Show "(default)" if configured size is 0.
2971 2018-05-22 Pedro Alves <palves@redhat.com>
2973 * remote.c (remote_target::mourn_inferior): Move
2974 discard_pending_stop_replies call here from ...
2975 (_initialize_remote): ... here.
2977 2018-05-22 Pedro Alves <palves@redhat.com>
2979 * remote.c (compare_section_command): Remove set_general_process
2982 2018-05-22 Pedro Alves <palves@redhat.com>
2984 * remote.c (struct packet_reg, struct remote_arch_state):
2985 Move higher up in the file.
2986 (remote_state) <m_arch_states>: Store remote_arch_state values
2987 instead of remote_arch_state pointers.
2988 (remote_state::get_remote_arch_state): Adjust.
2990 2018-05-22 Pedro Alves <palves@redhat.com>
2992 * remote.c: Include <unordered_map>.
2993 (remote_state): Now a class.
2994 (remote_state) <get_remote_arch_state>: Declare method.
2995 <get_remote_arch_state>: New field.
2996 (remote_arch_state) <remote_arch_state>: Declare ctor.
2997 <regs>: Now a unique_ptr.
2998 (remote_gdbarch_data_handle): Delete.
2999 (get_remote_arch_state): Delete.
3000 (remote_state::get_remote_arch_state): New.
3001 (get_remote_state): Adjust to call remote_state's
3002 get_remote_arch_state method.
3003 (init_remote_state): Delete, bits factored out to ...
3004 (remote_arch_state::remote_arch_state): ... this new method.
3005 (get_remote_packet_size, get_memory_packet_size)
3006 (process_g_packet, remote_target::fetch_registers)
3007 (remote_target::prepare_to_store, store_registers_using_G)
3008 (remote_target::store_registers, remote_target::get_trace_status):
3009 Adjust to call remote_state's method.
3010 (_initialize_remote): Remove reference to
3011 remote_gdbarch_data_handle.
3013 2018-05-22 Pedro Alves <palves@redhat.com>
3015 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
3016 pread>: New method declarations.
3017 (remote_target::open_1): Adjust.
3018 (readahead_cache_invalidate): Rename to ...
3019 (readahead_cache::invalidate): ... this, and adjust to be a class
3021 (readahead_cache_invalidate_fd): Rename to ...
3022 (readahead_cache::invalidate_fd): ... this, and adjust to be a
3024 (remote_hostio_pwrite): Adjust.
3025 (remote_hostio_pread_from_cache): Rename to ...
3026 (readahead_cache::pread): ... this, and adjust to be a class
3028 (remote_hostio_close): Adjust.
3030 2018-05-22 Pedro Alves <palves@redhat.com>
3032 * remote.c (remote_hostio_close_cleanup): Delete.
3033 (class scoped_remote_fd): New.
3034 (remote_file_put, remote_file_get): Use it.
3036 2018-05-22 Pedro Alves <palves@redhat.com>
3038 (struct vCont_action_support): Use bool and initialize all fields.
3039 (struct readahead_cache): Initialize all fields.
3040 (remote_state): Use bool and initialize all fields.
3041 (remote_state::remote_state, remote_state::~remote_state): New.
3042 (new_remote_state): Delete.
3043 (_initialize_remote): Use new to allocate remote_state.
3045 2018-05-22 Pedro Alves <palves@redhat.com>
3049 * c-exp.y: Include "c-support.h".
3050 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
3051 of tolower. Use c_ident_is_alpha to scan names.
3052 * c-lang.c: Include "c-support.h".
3053 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
3054 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
3055 * c-support.h: New file, with bits factored out from ...
3056 * cp-name-parser.y: ... this file.
3057 Include "c-support.h".
3058 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
3059 c-support.h and renamed.
3060 (symbol_end, yylex): Adjust.
3062 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3064 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
3065 parameter type to CORE_ADDR.
3066 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
3067 parameter type in declaration to CORE_ADDR.
3068 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
3069 target_auxv_search to get AT_HWCAP and use the result to get the
3071 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
3072 to CORE_ADDR. Remove the cast of the return value to unsigned
3073 long. Fix error predicate of target_auxv_search.
3074 (ppc_linux_nat_target::read_description): Change the type of the
3075 hwcap variable to CORE_ADDR.
3077 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3079 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
3080 if the size of fpscr is larger than 32 bits.
3082 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3084 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
3085 (ppc32_linux_vsxregmap): New global.
3086 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
3087 regcache_supply_regset, and regcache_collect_regset.
3088 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
3089 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
3090 (fetch_vsx_register, store_vsx_register): Remove.
3091 (fetch_vsx_registers): Add regno parameter. Get regset using
3092 ppc_linux_vsxregset. Use regset to supply registers.
3093 (store_vsx_registers): Add regno parameter. Get regset using
3094 ppc_linux_vsxregset. Use regset to collect registers.
3095 (fetch_register): Call fetch_vsx_registers instead of
3097 (store_register): Call store_vsx_registers instead of
3099 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
3100 new regno parameter.
3101 (store_ppc_registers): Call store_vsx_registers with -1 for the
3102 new regno parameter.
3103 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
3104 (ppc_collect_vsxregset): Remove.
3106 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3108 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
3110 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
3111 for vector register offset fields.
3112 (ppc64_fbsd_reg_offsets): Likewise.
3113 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3114 to vector register offset fields.
3115 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3116 to vector register offset fields.
3117 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
3118 vector register offset fields.
3119 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
3120 initializers for vector register offset fields.
3121 (rs6000_aix64_reg_offsets): Likewise.
3122 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
3123 (ppc_supply_vrregset): Remove.
3124 (ppc_collect_vrregset): Remove.
3125 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
3126 (ppc_linux_vrregset) : New function.
3127 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
3128 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
3129 (ppc32_linux_vrregset): Remove.
3130 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
3131 and use result instead of ppc32_linux_vrregset.
3132 (ppc32_linux_reg_offsets): Remove initializers for vector register
3134 (ppc64_linux_reg_offsets): Likewise.
3135 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
3136 * ppc-linux-nat.c: Include regset.h.
3137 (gdb_vrregset_t): Adjust comment to account for little-endian
3139 (supply_vrregset, fill_vrregset): Remove.
3140 (fetch_altivec_register, store_altivec_register): Remove.
3141 (fetch_altivec_registers): Add regno parameter. Get regset using
3142 ppc_linux_vrregset. Use regset to supply registers.
3143 (store_altivec_registers): Add regno parameter. Get regset using
3144 ppc_linux_vrregset. Use regset to collect registers.
3145 (fetch_register): Call fetch_altivec_registers instead of
3146 fetch_altivec_register.
3147 (store_register): Call store_altivec_registers instead of
3148 store_altivec_register.
3149 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
3150 the new regno parameter.
3151 (store_ppc_registers): Call store_altivec_registers with -1 for
3152 the new regno parameter.
3154 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3156 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
3157 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
3158 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3159 (gdb_vrregset_t): Change array type size to
3160 PPC_LINUX_SIZEOF_VRREGSET.
3161 (gdb_vsxregset_t): Change array type size to
3162 PPC_LINUX_SIZEOF_VSXREGSET.
3163 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
3164 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
3165 PPC_LINUX_SIZEOF_VSXREGSET.
3167 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3169 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
3170 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
3172 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
3173 ppc_linux_target_wordsize with tid.
3174 (ppc_linux_nat_target::read_description): Call ppc_linux_target
3176 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
3177 (ppc64_64bit_inferior_p): Add static and inline specifiers.
3178 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
3179 tid parameter. Remove static specifier.
3180 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
3181 (ppc_linux_target_wordsize): New declaration.
3183 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3185 * arch/ppc-linux-common.c: New file.
3186 * arch/ppc-linux-common.h: New file.
3187 * arch/ppc-linux-tdesc.h: New file.
3188 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
3189 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
3190 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
3191 arch/ppc-linux-tdesc.h.
3192 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
3193 arch/ppc-linux-tdesc.h.
3194 (ppc_linux_nat_target::read_description): Remove target
3195 description matching code. Fill a ppc_linux_features struct and
3196 call ppc_linux_match_description with it. Move comment about ISA
3197 2.05 to ppc-linux-common.c.
3198 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
3199 arch/ppc-linux-tdesc.h.
3200 (ppc_linux_core_read_description): Remove target description
3201 matching code. Fill a ppc_linux_features struct and call
3202 ppc_linux_match_description with it.
3203 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3204 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3205 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3206 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3207 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3208 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3209 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3210 (tdesc_powerpc_e500l): Remove.
3212 2018-05-22 Joel Brobecker <brobecker@adacore.com>
3214 * ada-lang.c (catch_assert_command): Pass empty string instead
3215 of NULL for excep_string argument.
3217 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3219 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
3220 the width of the requested register exceeds the width of the
3223 2018-05-21 Tom Tromey <tom@tromey.com>
3225 * printcmd.c (output_command): Remove.
3226 (output_command_const): Rename to output_command.
3227 * valprint.h (output_command): Rename from output_command_const.
3228 * tracepoint.c (trace_dump_actions): Call output_command.
3230 2018-05-21 Tom Tromey <tom@tromey.com>
3232 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3233 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
3234 * ada-lang.h (create_ada_exception_catchpoint): Update.
3235 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
3237 (create_excep_cond_exprs, ~ada_catchpoint)
3238 (should_stop_exception, print_one_exception)
3239 (print_mention_exception, print_recreate_exception): Update.
3240 (ada_get_next_arg): Remove.
3241 (catch_ada_exception_command_split): Use std::string. Change type
3242 of "excep_string", "cond_string".
3243 (catch_ada_exception_command): Update.
3244 (create_ada_exception_catchpoint): Change type of excep_string.
3245 (ada_exception_sal): Remove excep_string parameter.
3246 (~ada_catchpoint): Remove.
3248 2018-05-21 Tom Tromey <tom@tromey.com>
3250 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
3253 2018-05-21 Tom Tromey <tom@tromey.com>
3255 * ada-lang.c (ada_exception_message_1, ada_exception_message):
3256 Return unique_xmalloc_ptr.
3257 (print_it_exception): Update.
3259 2018-05-21 Tom Tromey <tom@tromey.com>
3261 * tracepoint.c (trace_dump_actions): Use std::string.
3263 2018-05-21 Tom Tromey <tom@tromey.com>
3265 * symfile.c (reread_symbols): Use std::string for original_name.
3267 2018-05-21 Tom Tromey <tom@tromey.com>
3269 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
3270 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
3273 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
3275 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
3277 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
3278 * objfiles.c (get_objfile_bfd_data): Allocate
3279 objfile_per_bfd_storage with obstack_new when allocating on
3282 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3284 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
3286 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
3287 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
3288 * mdebugread.c (mdebug_build_psymtabs): Likewise.
3289 (add_pending): Likewise.
3290 (parse_symbol): Likewise.
3291 (parse_partial_symbols): Likewise.
3292 (psymtab_to_symtab_1): Likewise.
3293 (new_psymtab): Likewise.
3294 (elfmdebug_build_psymtabs): Likewise.
3295 * minsyms.c (terminate_minimal_symbol_table): Likewise.
3296 * objfiles.c (get_objfile_bfd_data): Likewise.
3297 (objfile_register_static_link): Likewise.
3298 * psymtab.c (allocate_psymtab): Likewise.
3299 * stabsread.c (read_member_functions): Likewise.
3300 * xcoffread.c (xcoff_end_psymtab): Likewise.
3302 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3304 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
3305 compiler supports std::is_trivially_constructible.
3306 * common/poison.h: Include obstack.h.
3307 (IsMallocable): Define to is_trivially_constructible if the
3308 compiler supports it, define to true_type otherwise.
3312 (XOBNEWVEC): Redefine.
3313 * gdb_obstack.h (obstack_zalloc): New.
3314 (OBSTACK_ZALLOC): Redefine.
3315 (obstack_calloc): New.
3316 (OBSTACK_CALLOC): Redefine.
3318 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
3319 (gdbarch_obstack): New declaration in gdbarch.h, definition in
3321 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
3322 obstack_calloc/obstack_zalloc.
3323 (gdbarch_obstack_zalloc): Remove.
3324 * target-descriptions.c (tdesc_data_init): Use obstack_new.
3326 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3328 * stack.c (backtrace_command_1): Remove useless variable int i.
3330 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3332 * stack.c (print_frame_info): Fix comment.
3334 2018-05-18 Tom Tromey <tom@tromey.com>
3336 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
3337 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
3338 (~dwarf2_per_objfile): Update
3339 (dwarf2_get_dwz_file): Use new.
3340 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
3343 2018-05-18 Tom Tromey <tom@tromey.com>
3345 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
3347 * dwarf2read.c (struct dwp_file): Add constructor and
3349 (open_and_init_dwp_file): Return a unique_ptr.
3350 (dwarf2_per_objfile, create_dwp_hash_table)
3351 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
3352 (lookup_dwo_unit_in_dwp): Update.
3353 (open_and_init_dwp_file, get_dwp_file): Update.
3355 2018-05-18 Tom Tromey <tom@tromey.com>
3357 * dwarf2read.c (dwarf2_per_objfile): Update.
3358 (struct mapped_index): Add initializers.
3359 (dwarf2_read_index): Use new.
3360 (dw2_symtab_iter_init): Update.
3361 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
3364 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3366 * dwarf2read.c (mapped_index) <total_size>: Remove.
3368 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3370 * unittests/format_pieces-selftests.c (test_format_specifier):
3373 2018-05-18 Tom Tromey <tom@tromey.com>
3375 * c-typeprint.c (maybe_print_hole): New function.
3376 (c_print_type_struct_field_offset): Update.
3377 (c_type_print_base_struct_union): Call maybe_print_hole.
3379 2018-05-17 Keith Seitz <keiths@redhat.com>
3381 * breakpoint.c (build_bpstat_chain): New function, moved from
3383 (bpstat_stop_status): Add optional parameter, `stop_chain'.
3384 If no stop chain is passed, call build_bpstat_chain to build it.
3385 * breakpoint.h (build_bpstat_chain): Declare.
3386 (bpstat_stop_status): Move documentation here from breakpoint.c.
3387 * infrun.c (handle_signal_stop): Before eliding inlined frames,
3388 build the stop chain and pass it to skip_inline_frames.
3389 Pass this stop chain to bpstat_stop_status.
3390 * inline-frame.c: Include breakpoint.h.
3391 (stopped_by_user_bp_inline_frame): New function.
3392 (skip_inline_frames): Add parameter `stop_chain'.
3393 Move documention to inline-frame.h.
3394 If non-NULL, use stopped_by_user_bp_inline_frame to determine
3395 whether the frame should be elided.
3396 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
3397 Add moved documentation and update for new parameter.
3399 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3402 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3403 unittests/format_pieces-selftests.c.
3404 * common/format.h (format_piece) <operator==>: New.
3405 (format_pieces) <operator[]>: Remove.
3406 * common/format.c (format_pieces::format_pieces): Handle \e.
3407 * unittests/format_pieces-selftests.c: New.
3409 2018-05-17 Tom Tromey <tom@tromey.com>
3412 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
3413 (dw2_instantiate_symtab): Add skip_partial parameter.
3414 (dw2_find_last_source_symtab, dw2_map_expand_apply)
3415 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
3416 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
3417 (dw2_expand_symtabs_matching_one)
3418 (dw2_find_pc_sect_compunit_symtab)
3419 (dw2_debug_names_lookup_symbol)
3420 (dw2_debug_names_expand_symtabs_for_function): Update.
3421 (init_cutu_and_read_dies): Add skip_partial parameter.
3422 (process_psymtab_comp_unit, build_type_psymtabs_1)
3423 (process_skeletonless_type_unit, load_partial_comp_unit)
3424 (psymtab_to_symtab_1): Update.
3425 (load_full_comp_unit): Add skip_partial parameter.
3426 (process_imported_unit_die, dwarf2_read_addr_index)
3427 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
3428 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
3429 (read_signatured_type): Update.
3431 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3433 * value.c (release_value): Remove unused variable.
3434 (record_latest_value): Likewise.
3435 (access_value_history): Likewise.
3436 (preserve_values): Likewise.
3438 2018-05-17 Tom Tromey <tom@tromey.com>
3440 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
3443 2018-05-16 Maciej W. Rozycki <macro@mips.com>
3446 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
3447 Also handle registers whose width is not a multiple of
3449 (linux_nat_trad_target::store_register): Likewise.
3451 2018-05-16 Tom Tromey <tom@tromey.com>
3453 * gdbcore.h (core_bfd): Redefine.
3454 * corelow.c (core_target::close): Update.
3455 (core_target_open): Update.
3456 * progspace.h (struct program_space) <cbfd>: Now a
3459 2018-05-16 Tom Tromey <tom@tromey.com>
3462 * symfile-add-flags.h (enum symfile_add_flags)
3463 <SYMFILE_NOT_FILENAME>: New constant.
3464 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
3465 objfile name from BFD.
3466 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
3467 * minidebug.c (find_separate_debug_file_in_section): Put
3468 ".gnu_debugdata" into BFD's file name.
3470 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
3472 * regcache.c (regcache_read_ftype, regcache_write_ftype):
3475 2018-05-15 Tamar Christina <tamar.christina@arm.com>
3478 * aarch64-tdep.c (aarch64_analyze_prologue,
3479 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
3480 Indicate not interested in errors.
3482 2018-05-15 Maciej W. Rozycki <macro@mips.com>
3484 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
3485 Supply the MIPS_ZERO_REGNUM register.
3487 2018-05-15 Maciej W. Rozycki <macro@mips.com>
3489 * mips-tdep.c (mask_address_var): Make variable static.
3491 2018-05-14 Tom Tromey <tom@tromey.com>
3493 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
3495 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
3497 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
3498 FXSAVE_ADDR for the mxcsr register.
3500 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
3502 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
3504 2018-05-11 Pedro Alves <palves@redhat.com>
3506 * corelow.c (core_target) <core_target>: No longer inline.
3507 Initialize m_core_gdbarch, m_core_vec and build the section table
3509 <~core_target>: New.
3510 <core_gdbarch, get_core_register_section>: New methods.
3511 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
3512 factored out from ...
3513 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
3515 (sniff_core_bfd): Add gdbarch parameter.
3516 (core_close): Delete, merged into ...
3517 (core_target::close): ... here. Delete self.
3518 (core_close_cleanup): Delete.
3519 (core_target_open): Allocate a core_target on the heap. Use a
3520 unique_ptr instead of a cleanup. Bits moved into the core_target
3521 ctor. Adjust to use core_target methods instead of globals.
3522 (get_core_register_section): Rename to ...
3523 (core_target::get_core_register_section): ... this and adjust.
3524 (struct get_core_registers_cb_data): New.
3525 (get_core_registers_cb): Use it. Use bool.
3526 (core_target::fetch_registers, core_target::files_info)
3527 (core_target::xfer_partial, core_target::read_description)
3528 (core_target::pid_to, core_target::thread_name): Adjust to
3529 reference class fields instead of globals.
3530 * target.h (struct target_ops_deleter, target_ops_up): New.
3532 2018-05-11 Pedro Alves <palves@redhat.com>
3534 * corefile.c (core_file_command): Move to corelow.c.
3535 * corelow.c (the_core_target): Delete.
3536 (core_file_command): Moved from corefile.c. Check exec_bfd
3537 instead of the_core_target. Use target_detach instead of calling
3538 into the_core_target directly.
3539 (maybe_say_no_core_file_now): New.
3540 (core_target::detach): Use it.
3541 (_initialize_corelow): Remove references to the_core_target.
3542 * gdbcore.h (the_core_target): Delete.
3544 2018-05-11 Tom Tromey <tromey@redhat.com>
3545 Pedro Alves <palves@redhat.com>
3547 * corefile.c (core_bfd): Remove.
3548 * gdbcore.h (core_bfd): Now a macro.
3549 * progspace.h (struct program_space) <cbfd>: New field.
3551 2018-05-11 Tom Tromey <tom@tromey.com>
3553 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
3556 2018-05-10 Tom Tromey <tom@tromey.com>
3558 * configure: Rebuild.
3559 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
3561 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3564 * regformats/regdat.sh: Adjust script, following the addition
3565 of the new expedite_regs parameter to init_target_desc.
3567 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
3570 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
3571 set_gdbarch_significant_addr_bit.
3572 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
3573 set_gdbarch_significant_addr_bit.
3574 * utils.c (address_significant): Update to sign extend addr.
3576 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
3578 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
3579 (xtensa_linux_init_abi): Limit tdep->num_regs by
3580 tdep->num_nopriv_regs.
3581 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
3582 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
3585 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
3587 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
3589 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3591 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
3592 (I387_MXCSR_INIT_VAL): New constant.
3593 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
3594 buffer if it was supplied by the inferior.
3595 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
3596 (i387_xsave_get_clear_bv): New function.
3597 (i387_supply_xsave): Only read x87 control registers from the
3598 xsave buffer if the feature is enabled, and the state will have
3599 been written, otherwise, provide a suitable default.
3600 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
3601 including x87 control registers. Update control registers if they
3602 have changed from the default value, and mark features as enabled
3604 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
3606 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
3608 * spu-tdep.c (info_spu_event_command): Fix output formatting.
3610 2018-05-07 Tom Tromey <tom@tromey.com>
3612 * configure: Rebuild.
3613 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
3615 2018-05-07 Tom Tromey <tom@tromey.com>
3618 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
3619 bit. Use correct value for VDIV.
3621 2018-05-04 Tom Tromey <tom@tromey.com>
3623 * configure: Rebuild.
3624 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
3626 2018-05-04 Tom Tromey <tom@tromey.com>
3628 * linux-record.c (record_linux_system_call) <case
3629 RECORD_SYS_RECVFROM>: Add "break".
3631 2018-05-04 Tom Tromey <tom@tromey.com>
3633 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
3634 Add missing "break".
3635 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
3636 Add missing "break".
3638 2018-05-04 Tom Tromey <tom@tromey.com>
3640 * rs6000-tdep.c (ppc_process_record_op4)
3641 (ppc_process_record_op63): Add fall-through comment.
3643 2018-05-04 Tom Tromey <tom@tromey.com>
3645 * i386-tdep.c (i386_process_record): Add fall-through comment.
3647 2018-05-04 Tom Tromey <tom@tromey.com>
3649 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
3652 2018-05-04 Tom Tromey <tom@tromey.com>
3654 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
3655 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
3656 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
3658 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
3660 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
3663 2018-05-04 Tom Tromey <tom@tromey.com>
3665 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
3667 2018-05-04 Tom Tromey <tom@tromey.com>
3669 * s390-tdep.c (s390_process_record): Fix fall-through comments.
3670 * xcoffread.c (scan_xcoff_symtab): Move comment later.
3671 * symfile.c (section_is_mapped): Fix fall-through comment.
3672 * stabsread.c (define_symbol, read_member_functions): Fix
3673 fall-through comment.
3674 * s390-linux-tdep.c (s390_process_record): Fix fall-through
3676 * remote.c (remote_wait_as): Fix fall-through comment.
3677 * p-exp.y (yylex): Fix fall-through comment.
3678 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
3680 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
3681 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
3682 * jv-exp.y (yylex): Fix fall-through comment.
3683 * go-exp.y (lex_one_token): Fix fall-through comment.
3684 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
3685 fall-through comment.
3686 * f-exp.y (yylex): Fix fall-through comment.
3687 * dwarf2read.c (process_die): Fix fall-through comments.
3688 * dbxread.c (process_one_symbol): Fix fall-through comment.
3689 * d-exp.y (lex_one_token): Fix fall-through comment.
3690 * cp-name-parser.y (yylex): Fix fall-through comment.
3691 * coffread.c (coff_symtab_read): Fix fall-through comment.
3692 * c-exp.y (lex_one_token): Fix fall-through comment.
3693 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
3695 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
3698 2018-05-04 Tom Tromey <tom@tromey.com>
3701 * NEWS: Mention gdb.execute change.
3702 * gdbcmd.h (execute_control_command): Don't declare.
3703 * python/python.c (execute_gdb_command): Use read_command_lines_1,
3704 execute_control_commands, execute_control_commands_to_string.
3705 * cli/cli-script.h (execute_control_commands)
3706 (execute_control_commands_to_string): Declare.
3707 (execute_control_command): Add from_tty parameter.
3708 * cli/cli-script.c (execute_control_commands)
3709 (execute_control_commands_to_string): New functions.
3710 (execute_user_command): Use execute_control_commands.
3711 (execute_control_command_1): Add "from_tty" parameter. Update.
3712 (execute_control_command): Likewise.
3714 2018-05-04 Tom Tromey <tom@tromey.com>
3717 * NEWS: Mention that breakpoint commands are writable.
3718 * python/py-breakpoint.c (bppy_set_commands): New function.
3719 (breakpoint_object_getset) <"commands">: Use it.
3721 2018-05-04 Tom Tromey <tom@tromey.com>
3723 * tracepoint.c (actions_command): Update.
3724 * mi/mi-cmd-break.c (mi_command_line_array)
3725 (mi_command_line_array_cnt, mi_command_line_array_ptr)
3726 (mi_read_next_line): Remove.
3727 (mi_cmd_break_commands): Update.
3728 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
3730 * cli/cli-script.c (get_command_line): Update.
3731 (process_next_line): Use function_view. Constify.
3732 (recurse_read_control_structure, read_command_lines)
3733 (read_command_lines_1): Change argument types to function_view.
3734 (do_define_command, document_command): Update.
3735 * breakpoint.h (check_tracepoint_command): Don't declare.
3736 * breakpoint.c (check_tracepoint_command): Remove.
3737 (commands_command_1, create_tracepoint_from_upload): Update.
3739 2018-05-04 Tom Tromey <tom@tromey.com>
3742 * cli/cli-script.h (enum command_control_type) <define_control>:
3744 * cli/cli-script.c (multi_line_command_p): Handle define_control.
3745 (build_command_line, execute_control_command_1)
3746 (process_next_line): Likewise.
3747 (do_define_command): New function, extracted from define_command.
3748 (define_command): Use it.
3750 2018-05-04 Tom Tromey <tom@tromey.com>
3752 * tracepoint.c (actions_command): Update.
3753 * cli/cli-script.h (read_command_lines): Update.
3754 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
3755 (MAX_TMPBUF): Remove define.
3756 (define_command): Use string_printf.
3757 (document_command): Likewise.
3758 * breakpoint.c (commands_command_1): Update.
3760 2018-05-04 Tom Tromey <tom@tromey.com>
3762 * top.c (execute_command): Update.
3763 * cli/cli-script.h (print_command_lines): Now varargs.
3764 * cli/cli-script.c (print_command_lines): Now varargs.
3765 (execute_control_command_1) <case while_control, case if_control>:
3768 2018-05-04 Tom Tromey <tom@tromey.com>
3770 * tracepoint.c (all_tracepoint_actions): Rename from
3771 all_tracepoint_actions_and_cleanup. Change return type.
3772 (actions_command, encode_actions_1, encode_actions)
3773 (trace_dump_actions, tdump_command): Update.
3774 * remote.c (remote_download_command_source): Update.
3775 * python/python.c (gdbpy_eval_from_control_command)
3776 (python_command, python_interactive_command): Update.
3777 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
3778 * guile/guile.c (guile_command)
3779 (gdbscm_eval_from_control_command, guile_command): Update.
3780 * compile/compile.c (compile_code_command)
3781 (compile_print_command, compile_to_object): Update.
3782 * cli/cli-script.h (struct command_lines_deleter): New.
3783 (counted_command_line): New typedef.
3784 (struct command_line): Add constructor, destructor.
3785 <body_list>: Remove.
3786 <body_list_0, body_list_1>: New members.
3787 (command_line_up): Remove typedef.
3788 (read_command_lines, read_command_lines_1, get_command_line):
3790 (copy_command_lines): Don't declare.
3791 * cli/cli-script.c (build_command_line): Use "new".
3792 (get_command_line): Return counted_command_line.
3793 (print_command_lines, execute_user_command)
3794 (execute_control_command_1, while_command, if_command): Update.
3795 (realloc_body_list): Remove.
3796 (process_next_line, recurse_read_control_structure): Update.
3797 (read_command_lines, read_command_lines_1): Return counted_command_line.
3798 (free_command_lines): Use "delete".
3799 (copy_command_lines): Remove.
3800 (define_command, document_command, show_user_1): Update.
3801 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
3802 a counted_command_line.
3803 * breakpoint.h (counted_command_line): Remove typedef.
3804 (breakpoint_set_commands): Update.
3805 * breakpoint.c (check_no_tracepoint_commands)
3806 (validate_commands_for_breakpoint): Update.
3807 (breakpoint_set_commands): Change commands to be a
3808 counted_command_line.
3809 (commands_command_1, update_dprintf_command_list)
3810 (create_tracepoint_from_upload): Update.
3812 2018-05-04 Tom Tromey <tom@tromey.com>
3814 * cli/cli-decode.h (cmd_list_element): New constructor.
3815 (~cmd_list_element): New destructor.
3816 (struct cmd_list_element): Add initializers.
3817 * cli/cli-decode.c (do_add_cmd): Use "new".
3818 (delete_cmd): Use "delete".
3820 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3821 Pedro Alves <palves@redhat.com>
3823 PR breakpoints/19806 and support for PR external/20207.
3824 * NEWS: Mention Aarch64 watchpoint improvements.
3825 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
3826 watchpoints and PR external/20207 watchpoints.
3827 * nat/aarch64-linux-hw-point.c
3828 (kernel_supports_any_contiguous_range): New.
3829 (aarch64_watchpoint_offset): New.
3830 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
3831 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
3832 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
3833 (aarch64_align_watchpoint): New parameters aligned_offset_p and
3834 next_addr_orig_p. Support PR external/20207 watchpoints.
3835 (aarch64_downgrade_regs): New.
3836 (aarch64_dr_state_insert_one_point): New parameters offset and
3838 (aarch64_dr_state_remove_one_point): Likewise.
3839 (aarch64_handle_breakpoint): Update caller.
3840 (aarch64_handle_aligned_watchpoint): Likewise.
3841 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
3843 (aarch64_linux_set_debug_regs): Remove const from state. Call
3844 aarch64_downgrade_regs.
3845 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
3846 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
3847 (DR_CONTROL_MASK): ... this.
3848 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
3849 (unsigned int aarch64_watchpoint_offset): New prototype.
3850 (aarch64_linux_set_debug_regs): Remove const from state.
3851 * utils.c (align_up, align_down): Move to ...
3852 * common/common-utils.c (align_up, align_down): ... here.
3853 * utils.h (align_up, align_down): Move to ...
3854 * common/common-utils.h (align_up, align_down): ... here.
3856 2018-05-04 Joel Brobecker <brobecker@adacore.com>
3858 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
3859 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
3860 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
3861 Re-implement to match the ABI as summarized in GCC's
3862 gcc/config/sparc/sparc.c. All callers updated.
3863 (sparc32_store_arguments): Remove assertion.
3865 2018-05-04 Tom Tromey <tom@tromey.com>
3867 * printcmd.c: Don't include tui.h.
3868 (decode_format): Use skip_spaces.
3870 2018-05-04 Tom Tromey <tom@tromey.com>
3873 * printcmd.c (last_count): New global.
3874 (x_command): Use saved count when repeating.
3876 2018-05-04 Tom Tromey <tom@tromey.com>
3878 * nto-procfs.c (do_closedir_cleanup): Remove.
3879 (procfs_pidlist): Use gdb_dir_up.
3880 * procfs.c (do_closedir_cleanup): Remove.
3881 (proc_update_threads): Use gdb_dir_up.
3882 * common/filestuff.h (struct gdb_dir_deleter): New.
3883 (gdb_dir_up): New typedef.
3885 2018-05-04 Tom Tromey <tom@tromey.com>
3887 * ada-lang.c (print_mention_exception): Use std::string.
3889 2018-05-04 Tom Tromey <tom@tromey.com>
3891 * ada-lang.c (create_excep_cond_exprs): Update.
3892 (ada_exception_catchpoint_cond_string): Use std::string.
3894 2018-05-04 Tom Tromey <tom@tromey.com>
3896 * ada-lang.c (xget_renaming_scope): Return std::string.
3897 (old_renaming_is_invisible): Update.
3899 2018-05-04 Tom Tromey <tom@tromey.com>
3901 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
3902 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
3904 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
3906 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
3908 2018-05-04 Tom Tromey <tom@tromey.com>
3910 * remote.c (remote_query_supported_append): Change type.
3911 (remote_check_symbols): Update.
3913 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
3916 * configure.ac: Prepend libpython.
3917 * python/python-config.py: Likewise.
3918 * configure: Regenerate.
3920 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
3922 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
3924 2018-05-03 Pedro Alves <palves@redhat.com>
3927 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
3928 override. Write 'true' instead of '1'.
3929 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
3932 2018-05-02 Pedro Alves <palves@redhat.com>
3934 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
3935 add_inf_child_target.
3936 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
3937 add_inf_child_target.
3938 * aix-thread.c (aix_thread_target_info): New.
3939 (aix_thread_target) <shortname, longname, doc>: Delete.
3941 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
3942 add_inf_child_target.
3943 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
3944 add_inf_child_target.
3945 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
3946 add_inf_child_target.
3947 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
3948 add_inf_child_target.
3949 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
3950 add_inf_child_target.
3951 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
3952 add_inf_child_target.
3953 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
3954 add_inf_child_target.
3955 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
3956 add_inf_child_target.
3957 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
3958 add_inf_child_target.
3959 * bfd-target.c (target_bfd_target_info): New.
3960 (target_bfd) <shortname, longname, doc>: Delete.
3962 * bsd-kvm.c (bsd_kvm_target_info): New.
3963 (bsd_kvm_target) <shortname, longname, doc>: Delete.
3965 (bsd_kvm_target::open): Rename to ...
3966 (bsd_kvm_target_open): ... this. Adjust.
3967 * bsd-uthread.c (bsd_uthread_target_info): New.
3968 (bsd_uthread_target) <shortname, longname, doc>: Delete.
3970 * corefile.c (core_file_command): Adjust.
3971 * corelow.c (core_target_info): New.
3972 (core_target) <shortname, longname, doc>: Delete.
3974 (core_target::open): Rename to ...
3975 (core_target_open): ... this. Adjust.
3976 * ctf.c (ctf_target_info): New.
3977 (ctf_target) <shortname, longname, doc>: Delete.
3979 (ctf_target::open): Rename to ...
3980 (ctf_target_open): ... this.
3981 (_initialize_ctf): Adjust.
3982 * exec.c (exec_target_info): New.
3983 (exec_target) <shortname, longname, doc>: Delete.
3985 (exec_target::open): Rename to ...
3986 (exec_target_open): ... this.
3987 * gdbcore.h (core_target_open): Declare.
3988 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
3989 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
3990 add_inf_child_target.
3991 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
3992 add_inf_child_target.
3993 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
3994 add_inf_child_target.
3995 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
3996 add_inf_child_target.
3997 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
3998 add_inf_child_target.
3999 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
4000 add_inf_child_target.
4001 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
4002 add_inf_child_target.
4003 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
4004 add_inf_child_target.
4005 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
4006 add_inf_child_target.
4007 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
4008 add_inf_child_target.
4009 * inf-child.c (inf_child_target_info): New.
4010 (inf_child_target::info): New.
4011 (inf_child_open_target): Remove 'target' parameter. Use
4012 get_native_target instead.
4013 (inf_child_target::open): Delete.
4014 (add_inf_child_target): New.
4015 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
4018 (add_inf_child_target): Declare.
4019 (inf_child_open_target): Declare.
4020 * linux-thread-db.c (thread_db_target_info): New.
4021 (thread_db_target) <shortname, longname, doc>: Delete.
4023 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
4024 add_inf_child_target.
4025 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
4026 add_inf_child_target.
4027 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
4028 add_inf_child_target.
4029 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
4030 add_inf_child_target.
4031 * make-target-delegates (print_class): Adjust.
4032 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
4033 add_inf_child_target.
4034 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
4035 add_inf_child_target.
4036 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
4037 add_inf_child_target.
4038 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
4039 add_inf_child_target.
4040 * nto-procfs.c (nto_native_target_info): New.
4041 (nto_procfs_target_native) <shortname, longname, doc>:
4044 (nto_procfs_target_info): New.
4045 (nto_procfs_target_procfs) <shortname, longname, doc>:
4048 (init_procfs_targets): Adjust.
4049 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
4050 add_inf_child_target.
4051 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
4052 add_inf_child_target.
4053 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
4054 add_inf_child_target.
4055 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
4056 add_inf_child_target.
4057 * ravenscar-thread.c (ravenscar_target_info): New.
4058 (ravenscar_thread_target) <shortname, longname, doc>:
4061 * record-btrace.c (record_btrace_target_info):
4062 (record_btrace_target) <shortname, longname, doc>: Delete.
4064 (record_btrace_target::open): Rename to ...
4065 (record_btrace_target_open): ... this. Adjust.
4066 * record-full.c (record_longname, record_doc): New.
4067 (record_full_base_target) <shortname, longname, doc>: Delete.
4069 (record_full_target_info): New.
4070 (record_full_target): <shortname>: Delete.
4072 (record_full_core_open_1, record_full_open_1): Update comments.
4073 (record_full_base_target::open): Rename to ...
4074 (record_full_open): ... this.
4075 (cmd_record_full_restore): Update.
4076 (_initialize_record_full): Update.
4077 * remote-sim.c (remote_sim_target_info): New.
4078 (gdbsim_target) <shortname, longname, doc>: Delete.
4080 (gdbsim_target::open): Rename to ...
4081 (gdbsim_target_open): ... this.
4082 (_initialize_remote_sim): Adjust.
4083 * remote.c (remote_doc): New.
4084 (remote_target_info): New.
4085 (remote_target) <shortname, longname, doc>: Delete.
4087 (extended_remote_target_info): New.
4088 (extended_remote_target) <shortname, longname, doc>: Delete.
4090 (remote_target::open_1): Make static. Adjust.
4091 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
4092 * s390-linux-nat.c (_initialize_s390_nat): Use
4093 add_inf_child_target.
4094 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
4095 add_inf_child_target.
4096 * sol-thread.c (thread_db_target_info): New.
4097 (sol_thread_target) <shortname, longname, doc>: Delete.
4099 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
4100 add_inf_child_target.
4101 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
4102 add_inf_child_target.
4103 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
4104 add_inf_child_target.
4105 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
4106 add_inf_child_target.
4107 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
4108 add_inf_child_target.
4109 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
4110 add_inf_child_target.
4111 * spu-linux-nat.c (_initialize_spu_nat): Use
4112 add_inf_child_target.
4113 * spu-multiarch.c (spu_multiarch_target_info): New.
4114 (spu_multiarch_target) <shortname, longname, doc>: Delete.
4116 * target-delegates.c: Regenerate.
4117 * target.c: Include <unordered_map>.
4118 (target_ops_p): Delete.
4119 (DEF_VEC_P(target_ops_p)): Delete.
4120 (target_factories): New.
4121 (test_target_info): New.
4122 (test_target_ops::info): New.
4123 (open_target): Adjust to use target_factories.
4124 (add_target_with_completer): Rename to ...
4125 (add_target): ... this. Change prototype. Register target_info
4126 and open callback in target_factories. Register target_info in
4127 command context instead of target_ops.
4128 (add_target): Delete old implementation.
4129 (add_deprecated_target_alias): Change prototype. Adjust.
4130 (the_native_target): New.
4131 (set_native_target, get_native_target): New.
4132 (find_default_run_target): Use the_native_target.
4133 (find_attach_target, find_run_target): Simplify.
4134 (target_ops::open): Delete.
4135 (dummy_target_info): New.
4136 (dummy_target::shortname, dummy_target::longname)
4137 (dummy_target::doc): Delete.
4138 (dummy_target::info): New.
4139 (debug_target::shortname, debug_target::longname)
4140 (debug_target::doc): Delete.
4141 (debug_target::info): New.
4142 * target.h (struct target_info): New.
4143 (target_ops::~target_ops): Add comment.
4144 (target_ops::info): New.
4145 (target_ops::shortname, target_ops::longname, target_ops::doc): No
4146 longer virtual. Implement in terms of target_info.
4147 (set_native_target, get_native_target): Declare.
4148 (target_open_ftype): New.
4149 (add_target, add_target_with_completer)
4150 (add_deprecated_target_alias): Change prototype.
4151 (test_target) <shortname, longname, doc>: Delete.
4153 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
4154 add_inf_child_target.
4155 * tracefile-tfile.c (tfile_target_info): New.
4156 (tfile_target) <shortname, longname, doc>: Delete.
4158 (tfile_target::open): Rename to ...
4159 (tfile_target_open): ... this.
4160 (_initialize_tracefile_tfile): Adjust.
4161 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
4162 add_inf_child_target.
4163 * windows-nat.c (_initialize_windows_nat): Use
4164 add_inf_child_target.
4165 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
4166 add_inf_child_target.
4168 2018-05-02 Pedro Alves <palves@redhat.com>
4170 * linux-nat.h (linux_nat_target) <low_new_thread,
4171 low_delete_thread, low_new_fork, low_forget_process,
4172 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
4173 New virtual methods.
4174 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4175 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
4176 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
4177 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4178 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
4180 * linux-fork.c (delete_fork): Adjust to call low method.
4181 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
4182 (linux_nat_new_fork, linux_nat_forget_process_hook)
4183 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
4184 (linux_nat_status_is_event):
4185 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
4186 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
4188 (sigtrap_is_event): Rename to ...
4189 (linux_nat_target::low_status_is_event): ... this.
4190 (linux_nat_set_status_is_event): Delete.
4191 (save_stop_reason, linux_nat_wait_1)
4192 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
4194 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4195 (linux_nat_set_new_fork, linux_nat_set_forget_process)
4196 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4197 (linux_nat_set_prepare_to_resume): Delete.
4198 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
4199 low virtual methods.
4200 * amd64-linux-nat.c: Likewise.
4201 * arm-linux-nat.c: Likewise.
4202 * i386-linux-nat.c: Likewise.
4203 * ia64-linux-nat.c: Likewise.
4204 * mips-linux-nat.c: Likewise.
4205 * ppc-linux-nat.c: Likewise.
4206 * s390-linux-nat.c: Likewise.
4207 * sparc64-linux-nat.c: Likewise.
4208 * x86-linux-nat.c: Likewise.
4209 * x86-linux-nat.h: Include "nat/x86-linux.h".
4210 (x86_linux_nat_target) <low_new_fork, low_forget_process,
4211 low_prepare_to_resume, low_new_thread, low_delete_thread>:
4214 2018-05-02 Pedro Alves <palves@redhat.com>
4216 * target.h (target_ops)
4217 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
4218 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
4219 stopped_by_watchpoint, have_continuable_watchpoint,
4220 stopped_data_address, watchpoint_addr_within_range,
4221 can_accel_watchpoint_condition, can_run, thread_alive,
4222 has_all_memory, has_memory, has_stack, has_registers,
4223 has_execution, can_async_p, is_async_p, supports_non_stop,
4224 always_non_stop_p, can_execute_reverse, supports_multi_process,
4225 supports_enable_disable_tracepoint,
4226 supports_disable_randomization, supports_string_tracing,
4227 supports_evaluation_of_breakpoint_conditions,
4228 can_run_breakpoint_commands, filesystem_is_local,
4229 can_download_tracepoint, get_trace_state_variable_value,
4230 set_trace_notes, get_tib_address, use_agent, can_use_agent,
4231 record_is_replaying, record_will_replay,
4232 augmented_libraries_svr4_read>: Adjust to return bool.
4233 * aarch64-linux-nat.c: All implementations adjusted.
4234 * aix-thread.c: All implementations adjusted.
4235 * arm-linux-nat.c: All implementations adjusted.
4236 * breakpoint.c: All implementations adjusted.
4237 * bsd-kvm.c: All implementations adjusted.
4238 * bsd-uthread.c: All implementations adjusted.
4239 * corelow.c: All implementations adjusted.
4240 * ctf.c: All implementations adjusted.
4241 * darwin-nat.c: All implementations adjusted.
4242 * darwin-nat.h: All implementations adjusted.
4243 * exec.c: All implementations adjusted.
4244 * fbsd-nat.c: All implementations adjusted.
4245 * fbsd-nat.h: All implementations adjusted.
4246 * gnu-nat.c: All implementations adjusted.
4247 * gnu-nat.h: All implementations adjusted.
4248 * go32-nat.c: All implementations adjusted.
4249 * ia64-linux-nat.c: All implementations adjusted.
4250 * inf-child.c: All implementations adjusted.
4251 * inf-child.h: All implementations adjusted.
4252 * inf-ptrace.c: All implementations adjusted.
4253 * inf-ptrace.h: All implementations adjusted.
4254 * linux-nat.c: All implementations adjusted.
4255 * linux-nat.h: All implementations adjusted.
4256 * mips-linux-nat.c: All implementations adjusted.
4257 * nto-procfs.c: All implementations adjusted.
4258 * ppc-linux-nat.c: All implementations adjusted.
4259 * procfs.c: All implementations adjusted.
4260 * ravenscar-thread.c: All implementations adjusted.
4261 * record-btrace.c: All implementations adjusted.
4262 * record-full.c: All implementations adjusted.
4263 * remote-sim.c: All implementations adjusted.
4264 * remote.c: All implementations adjusted.
4265 * s390-linux-nat.c: All implementations adjusted.
4266 * sol-thread.c: All implementations adjusted.
4267 * spu-multiarch.c: All implementations adjusted.
4268 * target-delegates.c: All implementations adjusted.
4269 * target.c: All implementations adjusted.
4270 * target.h: All implementations adjusted.
4271 * tracefile-tfile.c: All implementations adjusted.
4272 * tracefile.c: All implementations adjusted.
4273 * tracefile.h: All implementations adjusted.
4274 * windows-nat.c: All implementations adjusted.
4275 * x86-linux-nat.h: All implementations adjusted.
4276 * x86-nat.h: All implementations adjusted.
4278 2018-05-02 Pedro Alves <palves@redhat.com>
4280 * make-target-delegates (scan_target_h): Don't trim lines here.
4281 Replace sequences of tabs and/or whitespace with a single
4283 (top level, parsing methods): Trim each line before processing it
4286 2018-05-02 Pedro Alves <palves@redhat.com>
4287 John Baldwin <jhb@freebsd.org>
4289 * target.h (enum strata) <debug_stratum>: New.
4290 (struct target_ops) <all delegation methods>: Replace by C++
4291 virtual methods, and drop "to_" prefix. All references updated
4293 <to_shortname, to_longname, to_doc, to_data,
4294 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
4295 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
4296 virtual methods. All references updated throughout.
4297 <can_attach, supports_terminal_ours, can_create_inferior,
4298 get_thread_control_capabilities, attach_no_wait>: New
4300 <insert_breakpoint, remove_breakpoint>: Now
4301 TARGET_DEFAULT_NORETURN methods.
4302 <info_proc>: Now returns bool.
4304 (OPS_MAGIC): Delete.
4305 (current_target): Delete. All references replaced by references
4307 (target_stack): ... this. New.
4308 (target_shortname, target_longname): Adjust.
4309 (target_can_run): Now a function declaration.
4310 (default_child_has_all_memory, default_child_has_memory)
4311 (default_child_has_stack, default_child_has_registers)
4312 (default_child_has_execution): Remove target_ops parameter.
4313 (complete_target_initialization): Delete.
4314 (memory_breakpoint_target): New template class.
4315 (test_target_ops): Refactor as a C++ class with virtual methods.
4316 * make-target-delegates (NAME_PART): Tighten.
4317 (POINTER_PART, CP_SYMBOL): New.
4318 (SIMPLE_RETURN_PART): Reimplement.
4319 (VEC_RETURN_PART): Expect less.
4320 (RETURN_PART, VIRTUAL_PART): New.
4321 (METHOD): Adjust to C++ virtual methods.
4322 (scan_target_h): Remove reference to C99.
4323 (dname): Output "target_ops::" prefix.
4324 (write_function_header): Adjust to output a C++ class method.
4325 (write_declaration): New.
4326 (write_delegator): Adjust to output a C++ class method.
4327 (tdname): Output "dummy_target::" prefix.
4328 (write_tdefault, write_debugmethod): Adjust to output a C++ class
4330 (tdefault_names, debug_names): Delete.
4331 (return_types, tdefaults, styles, argtypes_array): New.
4332 (top level): All methods are delegators.
4334 (top level): Print dummy_target and debug_target classes.
4335 * target-delegates.c: Regenerate.
4336 * target-debug.h (target_debug_print_enum_info_proc_what)
4337 (target_debug_print_thread_control_capabilities)
4338 (target_debug_print_thread_info_p): New.
4339 * target.c (dummy_target): Delete.
4340 (the_dummy_target, the_debug_target): New.
4341 (target_stack): Now extern.
4342 (set_targetdebug): Push/unpush debug target.
4343 (default_child_has_all_memory, default_child_has_memory)
4344 (default_child_has_stack, default_child_has_registers)
4345 (default_child_has_execution): Remove target_ops parameter.
4346 (complete_target_initialization): Delete.
4347 (add_target_with_completer): No longer call
4348 complete_target_initialization.
4349 (target_supports_terminal_ours): Use regular delegation.
4350 (update_current_target): Delete.
4351 (push_target): No longer check magic number. Don't call
4352 update_current_target.
4353 (unpush_target): Don't call update_current_target.
4354 (target_is_pushed): No longer check magic number.
4355 (target_require_runnable): Skip for all stratums over
4357 (target_ops::info_proc): New.
4358 (target_info_proc): Use find_target_at and
4359 find_default_run_target.
4360 (target_supports_disable_randomization): Use regular delegation.
4361 (target_get_osdata): Use find_target_at.
4362 (target_ops::open, target_ops::close, target_ops::can_attach)
4363 (target_ops::attach, target_ops::can_create_inferior)
4364 (target_ops::create_inferior, target_ops::can_run)
4365 (target_can_run): New.
4366 (default_fileio_target): Use regular delegation.
4367 (target_ops::fileio_open, target_ops::fileio_pwrite)
4368 (target_ops::fileio_pread, target_ops::fileio_fstat)
4369 (target_ops::fileio_close, target_ops::fileio_unlink)
4370 (target_ops::fileio_readlink): New.
4371 (target_fileio_open_1, target_fileio_unlink)
4372 (target_fileio_readlink): Always call the target method. Handle
4374 (return_zero, return_zero_has_execution): Delete.
4375 (init_dummy_target): Delete.
4376 (dummy_target::dummy_target, dummy_target::shortname)
4377 (dummy_target::longname, dummy_target::doc)
4378 (debug_target::debug_target, debug_target::shortname)
4379 (debug_target::longname, debug_target::doc): New.
4380 (target_supports_delete_record): Use regular delegation.
4381 (setup_target_debug): Delete.
4382 (maintenance_print_target_stack): Skip debug_stratum.
4383 (initialize_targets): Instantiate the_dummy_target and
4385 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
4387 (target_auxv_search, fprint_target_auxv): Adjust.
4388 (info_auxv_command): Adjust to use target_stack.
4389 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
4390 * exceptions.c (print_flush): Handle a NULL target_stack.
4391 * regcache.c (target_ops_no_register): Refactor as class with
4394 * exec.c (exec_target): New class.
4395 (exec_ops): Now an exec_target.
4396 (exec_open, exec_close_1, exec_get_section_table)
4397 (exec_xfer_partial, exec_files_info, exec_has_memory)
4398 (exec_make_note_section): Refactor as exec_target methods.
4399 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
4401 (exec_target::find_memory_regions): New.
4402 (_initialize_exec): Don't call init_exec_ops.
4403 * gdbcore.h (exec_file_clear): Delete.
4405 * corefile.c (core_target): Delete.
4406 (core_file_command): Adjust.
4407 * corelow.c (core_target): New class.
4408 (the_core_target): New.
4409 (core_close): Remove target_ops parameter.
4410 (core_close_cleanup): Adjust.
4411 (core_target::close): New.
4412 (core_open, core_detach, get_core_registers, core_files_info)
4413 (core_xfer_partial, core_thread_alive, core_read_description)
4414 (core_pid_to_str, core_thread_name, core_has_memory)
4415 (core_has_stack, core_has_registers, core_info_proc): Rework as
4416 core_target methods.
4417 (ignore, core_remove_breakpoint, init_core_ops): Delete.
4418 (_initialize_corelow): Initialize the_core_target.
4419 * gdbcore.h (core_target): Delete.
4420 (the_core_target): New.
4422 * ctf.c: (ctf_target): New class.
4423 (ctf_ops): Now a ctf_target.
4424 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
4425 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
4426 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
4428 (init_ctf_ops): Delete.
4429 (_initialize_ctf): Don't call it.
4430 * tracefile-tfile.c (tfile_target): New class.
4431 (tfile_ops): Now a tfile_target.
4432 (tfile_open, tfile_close, tfile_files_info)
4433 (tfile_get_tracepoint_status, tfile_trace_find)
4434 (tfile_fetch_registers, tfile_xfer_partial)
4435 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
4436 Refactor as tfile_target methods.
4437 (tfile_xfer_partial_features): Remove target_ops parameter.
4438 (init_tfile_ops): Delete.
4439 (_initialize_tracefile_tfile): Don't call it.
4440 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
4441 (tracefile_has_stack, tracefile_has_registers)
4442 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
4443 tracefile_target methods.
4444 (init_tracefile_ops): Delete.
4445 (tracefile_target::tracefile_target): New.
4446 * tracefile.h: Include "target.h".
4447 (tracefile_target): New class.
4448 (init_tracefile_ops): Delete.
4450 * spu-multiarch.c (spu_multiarch_target): New class.
4451 (spu_ops): Now a spu_multiarch_target.
4452 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
4453 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
4454 (spu_search_memory, spu_mourn_inferior): Refactor as
4455 spu_multiarch_target methods.
4456 (init_spu_ops): Delete.
4457 (_initialize_spu_multiarch): Remove references to init_spu_ops,
4458 complete_target_initialization.
4460 * ravenscar-thread.c (ravenscar_thread_target): New class.
4461 (ravenscar_ops): Now a ravenscar_thread_target.
4462 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
4463 (ravenscar_thread_alive, ravenscar_pid_to_str)
4464 (ravenscar_fetch_registers, ravenscar_store_registers)
4465 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
4466 (ravenscar_stopped_by_hw_breakpoint)
4467 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
4468 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
4469 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
4471 (init_ravenscar_thread_ops): Delete.
4472 (_initialize_ravenscar): Remove references to
4473 init_ravenscar_thread_ops and complete_target_initialization.
4475 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
4476 (bsd_uthread_target): New class.
4477 (bsd_uthread_ops): Now a bsd_uthread_target.
4478 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
4479 (bsd_uthread_close, bsd_uthread_mourn_inferior)
4480 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
4481 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
4482 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
4483 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
4484 (bsd_uthread_target): Delete function.
4485 (_initialize_bsd_uthread): Remove reference to
4486 complete_target_initialization.
4488 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
4489 (target_bfd): ... this new class.
4490 (target_bfd_xfer_partial, target_bfd_get_section_table)
4491 (target_bfd_close): Refactor as target_bfd methods.
4492 (target_bfd::~target_bfd): New.
4493 (target_bfd_reopen): Adjust.
4494 (target_bfd::close): New.
4496 * record-btrace.c (record_btrace_target): New class.
4497 (record_btrace_ops): Now a record_btrace_target.
4498 (record_btrace_open, record_btrace_stop_recording)
4499 (record_btrace_disconnect, record_btrace_close)
4500 (record_btrace_async, record_btrace_info)
4501 (record_btrace_insn_history, record_btrace_insn_history_range)
4502 (record_btrace_insn_history_from, record_btrace_call_history)
4503 (record_btrace_call_history_range)
4504 (record_btrace_call_history_from, record_btrace_record_method)
4505 (record_btrace_is_replaying, record_btrace_will_replay)
4506 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
4507 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
4508 (record_btrace_store_registers, record_btrace_prepare_to_store)
4509 (record_btrace_to_get_unwinder)
4510 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
4511 (record_btrace_commit_resume, record_btrace_wait)
4512 (record_btrace_stop, record_btrace_can_execute_reverse)
4513 (record_btrace_stopped_by_sw_breakpoint)
4514 (record_btrace_supports_stopped_by_sw_breakpoint)
4515 (record_btrace_stopped_by_hw_breakpoint)
4516 (record_btrace_supports_stopped_by_hw_breakpoint)
4517 (record_btrace_update_thread_list, record_btrace_thread_alive)
4518 (record_btrace_goto_begin, record_btrace_goto_end)
4519 (record_btrace_goto, record_btrace_stop_replaying_all)
4520 (record_btrace_execution_direction)
4521 (record_btrace_prepare_to_generate_core)
4522 (record_btrace_done_generating_core): Refactor as
4523 record_btrace_target methods.
4524 (init_record_btrace_ops): Delete.
4525 (_initialize_record_btrace): Remove reference to
4526 init_record_btrace_ops.
4527 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
4528 the execution_direction global.
4529 (record_full_base_target, record_full_target)
4530 (record_full_core_target): New classes.
4531 (record_full_ops): Now a record_full_target.
4532 (record_full_core_ops): Now a record_full_core_target.
4533 (record_full_target::detach, record_full_target::disconnect)
4534 (record_full_core_target::disconnect)
4535 (record_full_target::mourn_inferior, record_full_target::kill):
4537 (record_full_open, record_full_close, record_full_async): Refactor
4538 as methods of the record_full_base_target class.
4539 (record_full_resume, record_full_commit_resume): Refactor
4540 as methods of the record_full_target class.
4541 (record_full_wait, record_full_stopped_by_watchpoint)
4542 (record_full_stopped_data_address)
4543 (record_full_stopped_by_sw_breakpoint)
4544 (record_full_supports_stopped_by_sw_breakpoint)
4545 (record_full_stopped_by_hw_breakpoint)
4546 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
4547 methods of the record_full_base_target class.
4548 (record_full_store_registers, record_full_xfer_partial)
4549 (record_full_insert_breakpoint, record_full_remove_breakpoint):
4550 Refactor as methods of the record_full_target class.
4551 (record_full_can_execute_reverse, record_full_get_bookmark)
4552 (record_full_goto_bookmark, record_full_execution_direction)
4553 (record_full_record_method, record_full_info, record_full_delete)
4554 (record_full_is_replaying, record_full_will_replay)
4555 (record_full_goto_begin, record_full_goto_end, record_full_goto)
4556 (record_full_stop_replaying): Refactor as methods of the
4557 record_full_base_target class.
4558 (record_full_core_resume, record_full_core_kill)
4559 (record_full_core_fetch_registers)
4560 (record_full_core_prepare_to_store)
4561 (record_full_core_store_registers, record_full_core_xfer_partial)
4562 (record_full_core_insert_breakpoint)
4563 (record_full_core_remove_breakpoint)
4564 (record_full_core_has_execution): Refactor
4565 as methods of the record_full_core_target class.
4566 (record_full_base_target::supports_delete_record): New.
4567 (init_record_full_ops): Delete.
4568 (init_record_full_core_ops): Delete.
4569 (record_full_save): Refactor as method of the
4570 record_full_base_target class.
4571 (_initialize_record_full): Remove references to
4572 init_record_full_ops and init_record_full_core_ops.
4574 * remote.c (remote_target, extended_remote_target): New classes.
4575 (remote_ops): Now a remote_target.
4576 (extended_remote_ops): Now an extended_remote_target.
4577 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
4578 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
4579 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
4580 (remote_pass_signals, remote_set_syscall_catchpoint)
4581 (remote_program_signals, )
4582 (remote_thread_always_alive): Remove target_ops parameter.
4583 (remote_thread_alive, remote_thread_name)
4584 (remote_update_thread_list, remote_threads_extra_info)
4585 (remote_static_tracepoint_marker_at)
4586 (remote_static_tracepoint_markers_by_strid)
4587 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
4588 (remote_open): Refactor as methods of remote_target.
4589 (extended_remote_open, extended_remote_detach)
4590 (extended_remote_attach, extended_remote_post_attach):
4591 (extended_remote_supports_disable_randomization)
4592 (extended_remote_create_inferior): : Refactor as method of
4593 extended_remote_target.
4594 (remote_set_permissions, remote_open_1, remote_detach)
4595 (remote_follow_fork, remote_follow_exec, remote_disconnect)
4596 (remote_resume, remote_commit_resume, remote_stop)
4597 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
4598 (remote_terminal_ours, remote_wait, remote_fetch_registers)
4599 (remote_prepare_to_store, remote_store_registers)
4600 (remote_flash_erase, remote_flash_done, remote_files_info)
4601 (remote_kill, remote_mourn, remote_insert_breakpoint)
4602 (remote_remove_breakpoint, remote_insert_watchpoint)
4603 (remote_watchpoint_addr_within_range)
4604 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
4605 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
4606 (remote_supports_stopped_by_sw_breakpoint)
4607 (remote_stopped_by_hw_breakpoint)
4608 (remote_supports_stopped_by_hw_breakpoint)
4609 (remote_stopped_by_watchpoint, remote_stopped_data_address)
4610 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
4611 (remote_verify_memory): Refactor as methods of remote_target.
4612 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
4614 (remote_xfer_partial, remote_get_memory_xfer_limit)
4615 (remote_search_memory, remote_rcmd, remote_memory_map)
4616 (remote_pid_to_str, remote_get_thread_local_address)
4617 (remote_get_tib_address, remote_read_description): Refactor as
4618 methods of remote_target.
4619 (remote_target::fileio_open, remote_target::fileio_pwrite)
4620 (remote_target::fileio_pread, remote_target::fileio_close): New.
4621 (remote_hostio_readlink, remote_hostio_fstat)
4622 (remote_filesystem_is_local, remote_can_execute_reverse)
4623 (remote_supports_non_stop, remote_supports_disable_randomization)
4624 (remote_supports_multi_process, remote_supports_cond_breakpoints)
4625 (remote_supports_enable_disable_tracepoint)
4626 (remote_supports_string_tracing)
4627 (remote_can_run_breakpoint_commands, remote_trace_init)
4628 (remote_download_tracepoint, remote_can_download_tracepoint)
4629 (remote_download_trace_state_variable, remote_enable_tracepoint)
4630 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
4631 (remote_trace_start, remote_get_trace_status)
4632 (remote_get_tracepoint_status, remote_trace_stop)
4633 (remote_trace_find, remote_get_trace_state_variable_value)
4634 (remote_save_trace_data, remote_get_raw_trace_data)
4635 (remote_set_disconnected_tracing, remote_core_of_thread)
4636 (remote_set_circular_trace_buffer, remote_traceframe_info)
4637 (remote_get_min_fast_tracepoint_insn_len)
4638 (remote_set_trace_buffer_size, remote_set_trace_notes)
4639 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
4640 (remote_disable_btrace, remote_teardown_btrace)
4641 (remote_read_btrace, remote_btrace_conf)
4642 (remote_augmented_libraries_svr4_read, remote_load)
4643 (remote_pid_to_exec_file, remote_can_do_single_step)
4644 (remote_execution_direction, remote_thread_handle_to_thread_info):
4645 Refactor as methods of remote_target.
4646 (init_remote_ops, init_extended_remote_ops): Delete.
4647 (remote_can_async_p, remote_is_async_p, remote_async)
4648 (remote_thread_events, remote_upload_tracepoints)
4649 (remote_upload_trace_state_variables): Refactor as methods of
4651 (_initialize_remote): Remove references to init_remote_ops and
4652 init_extended_remote_ops.
4654 * remote-sim.c (gdbsim_target): New class.
4655 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
4656 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
4657 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
4658 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
4659 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
4660 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
4661 Refactor as methods of gdbsim_target.
4662 (gdbsim_ops): Now a gdbsim_target.
4663 (init_gdbsim_ops): Delete.
4664 (gdbsim_cntrl_c): Adjust.
4665 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
4667 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
4668 (the_amd64_linux_nat_target): New.
4669 (amd64_linux_fetch_inferior_registers)
4670 (amd64_linux_store_inferior_registers): Refactor as methods of
4671 amd64_linux_nat_target.
4672 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
4673 * i386-linux-nat.c: Don't include "linux-nat.h".
4674 (i386_linux_nat_target): New class.
4675 (the_i386_linux_nat_target): New.
4676 (i386_linux_fetch_inferior_registers)
4677 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
4678 as methods of i386_linux_nat_target.
4679 (_initialize_i386_linux_nat): Adjust. Set linux_target.
4680 * inf-child.c (inf_child_ops): Delete.
4681 (inf_child_fetch_inferior_registers)
4682 (inf_child_store_inferior_registers): Delete.
4683 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
4684 methods of inf_child_target.
4685 (inf_child_target::supports_terminal_ours)
4686 (inf_child_target::terminal_init)
4687 (inf_child_target::terminal_inferior)
4688 (inf_child_target::terminal_ours_for_output)
4689 (inf_child_target::terminal_ours, inf_child_target::interrupt)
4690 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
4692 (inf_child_open, inf_child_disconnect, inf_child_close)
4693 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
4694 (inf_child_post_startup_inferior, inf_child_can_run)
4695 (inf_child_pid_to_exec_file): Refactor as methods of
4697 (inf_child_follow_fork): Delete.
4698 (inf_child_target::can_create_inferior)
4699 (inf_child_target::can_attach): New.
4700 (inf_child_target::has_all_memory, inf_child_target::has_memory)
4701 (inf_child_target::has_stack, inf_child_target::has_registers)
4702 (inf_child_target::has_execution): New.
4703 (inf_child_fileio_open, inf_child_fileio_pwrite)
4704 (inf_child_fileio_pread, inf_child_fileio_fstat)
4705 (inf_child_fileio_close, inf_child_fileio_unlink)
4706 (inf_child_fileio_readlink, inf_child_use_agent)
4707 (inf_child_can_use_agent): Refactor as methods of
4709 (return_zero, inf_child_target): Delete.
4710 (inf_child_target::inf_child_target): New.
4711 * inf-child.h: Include "target.h".
4712 (inf_child_target): Delete function prototype.
4713 (inf_child_target): New class.
4714 (inf_child_open_target, inf_child_mourn_inferior)
4715 (inf_child_maybe_unpush_target): Delete.
4716 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
4717 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
4718 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
4719 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
4720 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
4721 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
4722 (inf_ptrace_wait, inf_ptrace_xfer_partial)
4723 (inf_ptrace_thread_alive, inf_ptrace_files_info)
4724 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
4725 methods of inf_ptrace_target.
4726 (inf_ptrace_target): Delete function.
4727 * inf-ptrace.h: Include "inf-child.h".
4728 (inf_ptrace_target): Delete function declaration.
4729 (inf_ptrace_target): New class.
4730 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
4731 * linux-nat.c (linux_target): New.
4732 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
4733 (linux_nat_target::~linux_nat_target): New.
4734 (linux_child_post_attach, linux_child_post_startup_inferior)
4735 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
4736 (linux_child_remove_fork_catchpoint)
4737 (linux_child_insert_vfork_catchpoint)
4738 (linux_child_remove_vfork_catchpoint)
4739 (linux_child_insert_exec_catchpoint)
4740 (linux_child_remove_exec_catchpoint)
4741 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
4742 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
4743 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
4744 (linux_nat_stopped_data_address)
4745 (linux_nat_stopped_by_sw_breakpoint)
4746 (linux_nat_supports_stopped_by_sw_breakpoint)
4747 (linux_nat_stopped_by_hw_breakpoint)
4748 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
4749 (linux_nat_kill, linux_nat_mourn_inferior)
4750 (linux_nat_xfer_partial, linux_nat_thread_alive)
4751 (linux_nat_update_thread_list, linux_nat_pid_to_str)
4752 (linux_nat_thread_name, linux_child_pid_to_exec_file)
4753 (linux_child_static_tracepoint_markers_by_strid)
4754 (linux_nat_is_async_p, linux_nat_can_async_p)
4755 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
4756 (linux_nat_supports_multi_process)
4757 (linux_nat_supports_disable_randomization, linux_nat_async)
4758 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
4759 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
4760 (linux_nat_fileio_open, linux_nat_fileio_readlink)
4761 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
4762 methods of linux_nat_target.
4763 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
4764 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
4766 (check_stopped_by_watchpoint): Adjust.
4767 (linux_xfer_partial): Delete.
4768 (linux_target_install_ops, linux_target, linux_nat_add_target):
4770 (linux_nat_target::linux_nat_target): New.
4771 * linux-nat.h: Include "inf-ptrace.h".
4772 (linux_nat_target): New.
4773 (linux_target, linux_target_install_ops, linux_nat_add_target):
4774 Delete function declarations.
4775 (linux_target): Declare global.
4776 * linux-thread-db.c (thread_db_target): New.
4777 (thread_db_target::thread_db_target): New.
4778 (thread_db_ops): Delete.
4779 (the_thread_db_target): New.
4780 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
4781 (thread_db_update_thread_list, thread_db_pid_to_str)
4782 (thread_db_extra_thread_info)
4783 (thread_db_thread_handle_to_thread_info)
4784 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
4785 (thread_db_resume): Refactor as methods of thread_db_target.
4786 (init_thread_db_ops): Delete.
4787 (_initialize_thread_db): Remove reference to init_thread_db_ops.
4788 * x86-linux-nat.c: Don't include "linux-nat.h".
4789 (super_post_startup_inferior): Delete.
4790 (x86_linux_nat_target::~x86_linux_nat_target): New.
4791 (x86_linux_child_post_startup_inferior)
4792 (x86_linux_read_description, x86_linux_enable_btrace)
4793 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
4794 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
4795 methods of x86_linux_nat_target.
4796 (x86_linux_create_target): Delete. Bits folded ...
4797 (x86_linux_add_target): ... here. Now takes a linux_nat_target
4799 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
4800 (x86_linux_nat_target): New class.
4801 (x86_linux_create_target): Delete.
4802 (x86_linux_add_target): Now takes a linux_nat_target pointer.
4803 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
4804 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
4805 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
4806 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
4807 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
4809 (x86_use_watchpoints): Delete.
4810 * x86-nat.h: Include "breakpoint.h" and "target.h".
4811 (x86_use_watchpoints): Delete.
4812 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
4813 (x86_stopped_by_watchpoint, x86_stopped_data_address)
4814 (x86_insert_watchpoint, x86_remove_watchpoint)
4815 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
4816 (x86_stopped_by_hw_breakpoint): New declarations.
4817 (x86_nat_target): New template class.
4819 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
4820 (the_ppc_linux_nat_target): New.
4821 (ppc_linux_fetch_inferior_registers)
4822 (ppc_linux_can_use_hw_breakpoint)
4823 (ppc_linux_region_ok_for_hw_watchpoint)
4824 (ppc_linux_ranged_break_num_registers)
4825 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
4826 (ppc_linux_insert_mask_watchpoint)
4827 (ppc_linux_remove_mask_watchpoint)
4828 (ppc_linux_can_accel_watchpoint_condition)
4829 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
4830 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
4831 (ppc_linux_watchpoint_addr_within_range)
4832 (ppc_linux_masked_watch_num_registers)
4833 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
4834 (ppc_linux_read_description): Refactor as methods of
4835 ppc_linux_nat_target.
4836 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
4838 * procfs.c (procfs_xfer_partial): Delete forward declaration.
4839 (procfs_target): New class.
4840 (the_procfs_target): New.
4841 (procfs_target): Delete function.
4842 (procfs_auxv_parse, procfs_attach, procfs_detach)
4843 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
4844 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
4845 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
4846 (procfs_create_inferior, procfs_update_thread_list)
4847 (procfs_thread_alive, procfs_pid_to_str)
4848 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
4849 (procfs_stopped_data_address, procfs_insert_watchpoint)
4850 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
4851 (proc_find_memory_regions, procfs_info_proc)
4852 (procfs_make_note_section): Refactor as methods of procfs_target.
4853 (_initialize_procfs): Adjust.
4854 * sol-thread.c (sol_thread_target): New class.
4855 (sol_thread_ops): Now a sol_thread_target.
4856 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
4857 (sol_thread_fetch_registers, sol_thread_store_registers)
4858 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
4859 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
4860 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
4861 (init_sol_thread_ops): Delete.
4862 (_initialize_sol_thread): Adjust. Remove references to
4863 init_sol_thread_ops and complete_target_initialization.
4865 * windows-nat.c (windows_nat_target): New class.
4866 (windows_fetch_inferior_registers)
4867 (windows_store_inferior_registers, windows_resume, windows_wait)
4868 (windows_attach, windows_detach, windows_pid_to_exec_file)
4869 (windows_files_info, windows_create_inferior)
4870 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
4871 (windows_close, windows_pid_to_str, windows_xfer_partial)
4872 (windows_get_tib_address, windows_get_ada_task_ptid)
4873 (windows_thread_name, windows_thread_alive): Refactor as
4874 windows_nat_target methods.
4875 (do_initial_windows_stuff): Adjust.
4876 (windows_target): Delete function.
4877 (_initialize_windows_nat): Adjust.
4879 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
4880 (darwin_mourn_inferior, darwin_kill_inferior)
4881 (darwin_create_inferior, darwin_attach, darwin_detach)
4882 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
4883 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
4884 (darwin_supports_multi_process): Refactor as darwin_nat_target
4886 (darwin_resume_to, darwin_files_info): Delete.
4887 (_initialize_darwin_inferior): Rename to ...
4888 (_initialize_darwin_nat): ... this. Adjust to C++ification.
4889 * darwin-nat.h: Include "inf-child.h".
4890 (darwin_nat_target): New class.
4891 (darwin_complete_target): Delete.
4892 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
4893 (darwin_target): New.
4894 (i386_darwin_fetch_inferior_registers)
4895 (i386_darwin_store_inferior_registers): Refactor as methods of
4897 (darwin_complete_target): Delete, with ...
4898 (_initialize_i386_darwin_nat): ... bits factored out here.
4900 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
4901 (the_alpha_linux_nat_target): New.
4902 (alpha_linux_register_u_offset): Refactor as
4903 alpha_linux_nat_target method.
4904 (_initialize_alpha_linux_nat): Adjust.
4905 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
4906 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
4907 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
4908 methods of linux_nat_trad_target.
4909 (linux_trad_target): Delete.
4910 * linux-nat-trad.h (linux_trad_target): Delete function.
4911 (linux_nat_trad_target): New class.
4912 * mips-linux-nat.c (mips_linux_nat_target): New class.
4913 (super_fetch_registers, super_store_registers, super_close):
4915 (the_mips_linux_nat_target): New.
4916 (mips64_linux_regsets_fetch_registers)
4917 (mips64_linux_regsets_store_registers)
4918 (mips64_linux_fetch_registers, mips64_linux_store_registers)
4919 (mips_linux_register_u_offset, mips_linux_read_description)
4920 (mips_linux_can_use_hw_breakpoint)
4921 (mips_linux_stopped_by_watchpoint)
4922 (mips_linux_stopped_data_address)
4923 (mips_linux_region_ok_for_hw_watchpoint)
4924 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
4925 (mips_linux_close): Refactor as methods of mips_linux_nat.
4926 (_initialize_mips_linux_nat): Adjust to C++ification.
4928 * aix-thread.c (aix_thread_target): New class.
4929 (aix_thread_ops): Now an aix_thread_target.
4930 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
4931 (aix_thread_fetch_registers, aix_thread_store_registers)
4932 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
4933 (aix_thread_thread_alive, aix_thread_pid_to_str)
4934 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
4935 Refactor as methods of aix_thread_target.
4936 (init_aix_thread_ops): Delete.
4937 (_initialize_aix_thread): Remove references to init_aix_thread_ops
4938 and complete_target_initialization.
4939 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
4940 (rs6000_nat_target): New class.
4941 (the_rs6000_nat_target): New.
4942 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
4943 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
4944 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
4945 (super_create_inferior): Delete.
4946 (_initialize_rs6000_nat): Adjust to C++ification.
4948 * arm-linux-nat.c (arm_linux_nat_target): New class.
4949 (the_arm_linux_nat_target): New.
4950 (arm_linux_fetch_inferior_registers)
4951 (arm_linux_store_inferior_registers, arm_linux_read_description)
4952 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
4953 (arm_linux_remove_hw_breakpoint)
4954 (arm_linux_region_ok_for_hw_watchpoint)
4955 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
4956 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
4957 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
4958 arm_linux_nat_target.
4959 (_initialize_arm_linux_nat): Adjust to C++ification.
4961 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
4962 (the_aarch64_linux_nat_target): New.
4963 (aarch64_linux_fetch_inferior_registers)
4964 (aarch64_linux_store_inferior_registers)
4965 (aarch64_linux_child_post_startup_inferior)
4966 (aarch64_linux_read_description)
4967 (aarch64_linux_can_use_hw_breakpoint)
4968 (aarch64_linux_insert_hw_breakpoint)
4969 (aarch64_linux_remove_hw_breakpoint)
4970 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
4971 (aarch64_linux_region_ok_for_hw_watchpoint)
4972 (aarch64_linux_stopped_data_address)
4973 (aarch64_linux_stopped_by_watchpoint)
4974 (aarch64_linux_watchpoint_addr_within_range)
4975 (aarch64_linux_can_do_single_step): Refactor as methods of
4976 aarch64_linux_nat_target.
4977 (super_post_startup_inferior): Delete.
4978 (_initialize_aarch64_linux_nat): Adjust to C++ification.
4980 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
4981 (the_hppa_linux_nat_target): New.
4982 (hppa_linux_fetch_inferior_registers)
4983 (hppa_linux_store_inferior_registers): Refactor as methods of
4984 hppa_linux_nat_target.
4985 (_initialize_hppa_linux_nat): Adjust to C++ification.
4987 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
4988 (the_ia64_linux_nat_target): New.
4989 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
4990 (ia64_linux_stopped_data_address)
4991 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
4992 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
4993 ia64_linux_nat_target methods.
4994 (super_xfer_partial): Delete.
4995 (_initialize_ia64_linux_nat): Adjust to C++ification.
4997 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
4998 (the_m32r_linux_nat_target): New.
4999 (m32r_linux_fetch_inferior_registers)
5000 (m32r_linux_store_inferior_registers): Refactor as
5001 m32r_linux_nat_target methods.
5002 (_initialize_m32r_linux_nat): Adjust to C++ification.
5004 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
5005 (the_m68k_linux_nat_target): New.
5006 (m68k_linux_fetch_inferior_registers)
5007 (m68k_linux_store_inferior_registers): Refactor as
5008 m68k_linux_nat_target methods.
5009 (_initialize_m68k_linux_nat): Adjust to C++ification.
5011 * s390-linux-nat.c (s390_linux_nat_target): New class.
5012 (the_s390_linux_nat_target): New.
5013 (s390_linux_fetch_inferior_registers)
5014 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
5015 (s390_insert_watchpoint, s390_remove_watchpoint)
5016 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
5017 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
5018 (s390_auxv_parse, s390_read_description): Refactor as methods of
5019 s390_linux_nat_target.
5020 (_initialize_s390_nat): Adjust to C++ification.
5022 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
5023 (the_sparc_linux_nat_target): New.
5024 (_initialize_sparc_linux_nat): Adjust to C++ification.
5025 * sparc-nat.c (sparc_fetch_inferior_registers)
5026 (sparc_store_inferior_registers): Remove target_ops parameter.
5027 * sparc-nat.h (sparc_fetch_inferior_registers)
5028 (sparc_store_inferior_registers): Remove target_ops parameter.
5029 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
5030 (the_sparc64_linux_nat_target): New.
5031 (_initialize_sparc64_linux_nat): Adjust to C++ification.
5033 * spu-linux-nat.c (spu_linux_nat_target): New class.
5034 (the_spu_linux_nat_target): New.
5035 (spu_child_post_startup_inferior, spu_child_post_attach)
5036 (spu_child_wait, spu_fetch_inferior_registers)
5037 (spu_store_inferior_registers, spu_xfer_partial)
5038 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
5040 (_initialize_spu_nat): Adjust to C++ification.
5042 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
5043 (the_tilegx_linux_nat_target): New.
5044 (fetch_inferior_registers, store_inferior_registers):
5045 Refactor as methods.
5046 (_initialize_tile_linux_nat): Adjust to C++ification.
5048 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
5049 (the_xtensa_linux_nat_target): New.
5050 (xtensa_linux_fetch_inferior_registers)
5051 (xtensa_linux_store_inferior_registers): Refactor as
5052 xtensa_linux_nat_target methods.
5053 (_initialize_xtensa_linux_nat): Adjust to C++ification.
5055 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
5056 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
5057 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
5058 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
5059 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
5060 (fbsd_stopped_by_sw_breakpoint)
5061 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
5062 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
5063 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
5064 (fbsd_post_startup_inferior, fbsd_post_attach)
5065 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
5066 (fbsd_set_syscall_catchpoint)
5067 (super_xfer_partial, super_resume, super_wait)
5068 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
5069 (fbsd_handle_debug_trap): Remove target_ops parameter.
5070 (fbsd_nat_add_target): Delete.
5071 * fbsd-nat.h: Include "inf-ptrace.h".
5072 (fbsd_nat_add_target): Delete.
5073 (USE_SIGTRAP_SIGINFO): Define.
5074 (fbsd_nat_target): New class.
5076 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
5077 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
5078 (amd64bsd_target): Delete.
5079 * amd64-bsd-nat.h: New file.
5080 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
5082 (amd64_fbsd_nat_target): New class.
5083 (the_amd64_fbsd_nat_target): New.
5084 (amd64fbsd_read_description): Refactor as method of
5085 amd64_fbsd_nat_target.
5086 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5087 (_initialize_amd64fbsd_nat): Adjust to C++ification.
5088 * amd64-nat.h (amd64bsd_target): Delete function declaration.
5089 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
5090 (i386bsd_store_inferior_registers): Remove target_ops parameter.
5091 (i386bsd_target): Delete.
5092 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
5093 (i386bsd_fetch_inferior_registers)
5094 (i386bsd_store_inferior_registers): Declare.
5095 (i386_bsd_nat_target): New class.
5096 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
5097 (the_i386_fbsd_nat_target): New.
5098 (i386fbsd_resume, i386fbsd_read_description): Refactor as
5099 i386_fbsd_nat_target methods.
5100 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5101 (_initialize_i386fbsd_nat): Adjust to C++ification.
5102 * x86-bsd-nat.c (super_mourn_inferior): Delete.
5103 (x86bsd_mourn_inferior, x86bsd_target): Delete.
5104 (_initialize_x86_bsd_nat): Adjust to C++ification.
5105 * x86-bsd-nat.h: Include "x86-nat.h".
5106 (x86bsd_target): Delete declaration.
5107 (x86bsd_nat_target): New class.
5109 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
5110 (the_aarch64_fbsd_nat_target): New.
5111 (aarch64_fbsd_fetch_inferior_registers)
5112 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
5113 aarch64_fbsd_nat_target.
5114 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
5115 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
5116 (the_alpha_bsd_nat_target): New.
5117 (alphabsd_fetch_inferior_registers)
5118 (alphabsd_store_inferior_registers): Refactor as
5119 alpha_bsd_nat_target methods.
5120 (_initialize_alphabsd_nat): Refactor as methods of
5121 alpha_bsd_nat_target.
5122 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
5123 (the_amd64_nbsd_nat_target): New.
5124 (_initialize_amd64nbsd_nat): Adjust to C++ification.
5125 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
5126 (the_amd64_obsd_nat_target): New.
5127 (_initialize_amd64obsd_nat): Adjust to C++ification.
5128 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
5129 (the_arm_fbsd_nat_target): New.
5130 (arm_fbsd_fetch_inferior_registers)
5131 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
5132 (_initialize_arm_fbsd_nat): Refactor as methods of
5133 arm_fbsd_nat_target.
5134 (_initialize_arm_fbsd_nat): Adjust to C++ification.
5135 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
5136 (the_arm_netbsd_nat_target): New.
5137 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
5138 arm_netbsd_nat_target.
5139 (_initialize_arm_netbsd_nat): Adjust to C++ification.
5140 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
5141 (the_hppa_nbsd_nat_target): New.
5142 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
5143 hppa_nbsd_nat_target methods.
5144 (_initialize_hppanbsd_nat): Adjust to C++ification.
5145 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
5146 (the_hppa_obsd_nat_target): New.
5147 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
5148 methods of hppa_obsd_nat_target.
5149 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
5151 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
5152 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
5154 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
5155 (_initialize_i386obsd_nat): Use add_target.
5156 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
5157 (the_m68k_bsd_nat_target): New.
5158 (m68kbsd_fetch_inferior_registers)
5159 (m68kbsd_store_inferior_registers): Refactor as methods of
5160 m68k_bsd_nat_target.
5161 (_initialize_m68kbsd_nat): Adjust to C++ification.
5162 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
5163 (the_mips_fbsd_nat_target): New.
5164 (mips_fbsd_fetch_inferior_registers)
5165 (mips_fbsd_store_inferior_registers): Refactor as methods of
5166 mips_fbsd_nat_target.
5167 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
5169 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
5170 (the_mips_nbsd_nat_target): New.
5171 (mipsnbsd_fetch_inferior_registers)
5172 (mipsnbsd_store_inferior_registers): Refactor as methods of
5173 mips_nbsd_nat_target.
5174 (_initialize_mipsnbsd_nat): Adjust to C++ification.
5175 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
5176 (the_mips64_obsd_nat_target): New.
5177 (mips64obsd_fetch_inferior_registers)
5178 (mips64obsd_store_inferior_registers): Refactor as methods of
5179 mips64_obsd_nat_target.
5180 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
5182 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
5184 * nbsd-nat.h: Include "inf-ptrace.h".
5185 (nbsd_nat_target): New class.
5186 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
5187 (obsd_wait): Refactor as methods of obsd_nat_target.
5188 (obsd_add_target): Delete.
5189 * obsd-nat.h: Include "inf-ptrace.h".
5190 (obsd_nat_target): New class.
5191 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
5192 (the_ppc_fbsd_nat_target): New.
5193 (ppcfbsd_fetch_inferior_registers)
5194 (ppcfbsd_store_inferior_registers): Refactor as methods of
5195 ppc_fbsd_nat_target.
5196 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
5198 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
5199 (the_ppc_nbsd_nat_target): New.
5200 (ppcnbsd_fetch_inferior_registers)
5201 (ppcnbsd_store_inferior_registers): Refactor as methods of
5202 ppc_nbsd_nat_target.
5203 (_initialize_ppcnbsd_nat): Adjust to C++ification.
5204 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
5205 (the_ppc_obsd_nat_target): New.
5206 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
5207 methods of ppc_obsd_nat_target.
5208 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
5210 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
5211 (the_sh_nbsd_nat_target): New.
5212 (shnbsd_fetch_inferior_registers)
5213 (shnbsd_store_inferior_registers): Refactor as methods of
5215 (_initialize_shnbsd_nat): Adjust to C++ification.
5216 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
5217 (inf_ptrace_xfer_partial): Delete.
5218 (sparc_xfer_partial, sparc_target): Delete.
5219 * sparc-nat.h (sparc_fetch_inferior_registers)
5220 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
5221 (sparc_target): Delete function declaration.
5222 (sparc_target): New template class.
5223 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
5224 (_initialize_sparcnbsd_nat): Adjust to C++ification.
5225 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
5226 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
5228 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
5229 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
5230 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
5231 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
5233 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
5234 (the_vax_bsd_nat_target): New.
5235 (vaxbsd_fetch_inferior_registers)
5236 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
5238 (_initialize_vaxbsd_nat): Adjust to C++ification.
5240 * bsd-kvm.c (bsd_kvm_target): New class.
5241 (bsd_kvm_ops): Now a bsd_kvm_target.
5242 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
5243 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
5244 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
5246 (bsd_kvm_return_one): Delete.
5247 (bsd_kvm_add_target): Adjust to C++ification.
5249 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
5250 (nto_procfs_target_procfs): New classes.
5251 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
5252 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
5253 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
5254 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
5255 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
5256 (procfs_remove_hw_breakpoint, procfs_resume)
5257 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
5258 (procfs_kill_inferior, procfs_store_registers)
5259 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
5260 as methods of nto_procfs_target.
5261 (nto_procfs_ops): Now an nto_procfs_target_procfs.
5262 (nto_native_ops): Delete.
5263 (procfs_open, procfs_native_open): Delete.
5264 (nto_native_ops): Now an nto_procfs_target_native.
5265 (init_procfs_targets): Adjust to C++ification.
5266 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
5267 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
5268 Refactor as methods of nto_procfs_target.
5270 * go32-nat.c (go32_nat_target): New class.
5271 (the_go32_nat_target): New.
5272 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
5273 (go32_store_registers, go32_xfer_partial, go32_files_info)
5274 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
5275 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
5276 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
5277 (go32_pid_to_str): Refactor as methods of go32_nat_target.
5278 (go32_target): Delete.
5279 (_initialize_go32_nat): Adjust to C++ification.
5281 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
5282 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
5283 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
5284 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
5286 (gnu_target): Delete.
5287 * gnu-nat.h (gnu_target): Delete.
5288 (gnu_nat_target): New class.
5289 * i386-gnu-nat.c (gnu_base_target): New.
5290 (i386_gnu_nat_target): New class.
5291 (the_i386_gnu_nat_target): New.
5292 (_initialize_i386gnu_nat): Adjust to C++ification.
5294 2018-05-02 Pedro Alves <palves@redhat.com>
5296 * bfd-target.c (target_bfd_xclose): Rename to ...
5297 (target_bfd_close): ... this.
5298 (target_bfd_reopen): Adjust.
5299 * target.c (target_close): Remove references to to_xclose.
5300 * target.h (target_ops::to_xclose): Delete.
5301 (target_ops::to_close): Update comments.
5303 2018-05-02 Pedro Alves <palves@redhat.com>
5305 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
5307 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
5308 * inf-ptrace.c (inf_ptrace_register_u_offset)
5309 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
5310 (inf_ptrace_store_register, inf_ptrace_store_registers)
5311 (inf_ptrace_trad_target): Move to ...
5312 * linux-nat-trad.c: ... this new file.
5313 * linux-nat-trad.h: New file.
5314 * linux-nat.c (linux_target_install_ops): Make extern.
5315 (linux_trad_target): Delete.
5316 * linux-nat.h (linux_trad_target): Delete declaration.
5317 (linux_target_install_ops): Declare.
5318 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
5321 2018-05-02 Pedro Alves <palves@redhat.com>
5323 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5324 procfs_target/add_target here.
5325 * procfs.c (procfs_target): Make static.
5326 (_initialize_procfs): Call add_target here.
5327 * procfs.h (struct target_ops): Remove forward declaration.
5328 (procfs_target): Remove declaration.
5329 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
5331 2018-05-02 Pedro Alves <palves@redhat.com>
5333 * procfs.c (procfs_stopped_by_watchpoint)
5334 (procfs_insert_watchpoint, procfs_remove_watchpoint)
5335 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
5337 (procfs_use_watchpoints): Delete, move contents...
5338 (procfs_target): ... here.
5339 * procfs.h (procfs_use_watchpoints): Delete declaration.
5340 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5341 procfs_use_watchpoints.
5342 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
5343 procfs_use_watchpoints.
5345 2018-05-02 Tom Tromey <tom@tromey.com>
5348 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
5349 and var_zuinteger_unlimited.
5350 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
5351 and PARAM_ZUINTEGER_UNLIMITED.
5352 (set_parameter_value): Handle var_zuinteger and
5353 var_zuinteger_unlimited.
5354 (add_setshow_generic): Likewise.
5355 (parmpy_init): Likewise.
5357 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
5360 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
5361 pointer is not null before dereferencing it.
5363 2018-04-30 Tom Tromey <tom@tromey.com>
5365 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
5368 2018-04-30 Tom Tromey <tom@tromey.com>
5370 * breakpoint.c (mention): Remove use of is_mi_like_p.
5371 (print_mention_ranged_breakpoint): Likewise.
5372 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
5375 2018-04-30 Tom Tromey <tom@tromey.com>
5377 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
5379 2018-04-30 Tom Tromey <tom@tromey.com>
5381 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
5382 (info_spu_event_command): Remove some uses of is_mi_like_p.
5384 2018-04-30 Tom Tromey <tom@tromey.com>
5386 * python/py-framefilter.c (py_print_single_arg)
5387 (enumerate_locals, py_print_args, py_print_frame): Remove some
5388 uses of is_mi_like_p.
5390 2018-04-30 Tom Tromey <tom@tromey.com>
5393 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
5394 * ui-out.h (ui_out::is_mi_like_p): Now const.
5395 (ui_out::do_is_mi_like_p): Now const.
5396 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
5398 2018-04-30 Tom Tromey <tom@tromey.com>
5400 * varobj.c (varobj_set_visualizer): Use new_reference.
5401 * python/python.c (gdbpy_decode_line): Use new_reference.
5402 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
5405 2018-04-30 Tom Tromey <tom@tromey.com>
5407 * varobj.c (install_new_value): Use new_reference.
5408 * value.h (value_incref): Return void. Swap intro comment with
5410 * value.c (set_value_parent): Use new_reference.
5411 (value_incref): Return void. Update intro comment.
5412 (release_value): Use new_reference.
5413 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
5415 2018-04-30 Tom Tromey <tom@tromey.com>
5417 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
5418 * gdb_bfd.h (new_bfd_ref): Remove.
5419 (gdb_bfd_open): Update comment.
5420 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
5421 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
5422 (gdb_bfd_fdopenr): Use new_reference.
5423 * exec.c (exec_file_attach): Use new_reference.
5425 2018-04-30 Tom Tromey <tom@tromey.com>
5427 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
5430 2018-04-30 Tom Tromey <tom@tromey.com>
5432 * jit.c (jit_read_code_entry): Use type_align.
5433 * i386-tdep.c (i386_gdbarch_init): Don't call
5434 set_gdbarch_long_long_align_bit.
5435 * gdbarch.sh: Remove long_long_align_bit.
5436 * gdbarch.c, gdbarch.h: Rebuild.
5437 * arc-tdep.c (arc_type_align): New function.
5438 (arc_gdbarch_init): Use arc_type_align. Don't call
5439 set_gdbarch_long_long_align_bit.
5441 2018-04-30 Tom Tromey <tom@tromey.com>
5443 * rust-lang.c (rust_type_alignment): Remove.
5444 (rust_composite_type): Use type_align.
5446 2018-04-30 Tom Tromey <tom@tromey.com>
5448 * NEWS: Mention Type.align.
5449 * python/py-type.c (typy_get_alignof): New function.
5450 (type_object_getset): Add "alignof".
5452 2018-04-30 Tom Tromey <tom@tromey.com>
5456 * std-operator.def (UNOP_ALIGNOF): New operator.
5457 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
5459 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
5460 * c-lang.c (c_op_print_tab): Add alignof.
5461 * c-exp.y (ALIGNOF): New token.
5462 (exp): Add "ALIGNOF" production.
5463 (ident_tokens): Add _Alignof and alignof.
5465 2018-04-30 Tom Tromey <tom@tromey.com>
5467 * i386-tdep.c (i386_type_align): New function.
5468 (i386_gdbarch_init): Update.
5469 * gdbarch.sh (type_align): New method.
5470 * gdbarch.c, gdbarch.h: Rebuild.
5471 * arch-utils.h (default_type_align): Declare.
5472 * arch-utils.c (default_type_align): New function.
5473 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
5474 (struct type) <align_log2>: New field.
5475 <instance_flags>: Now a bitfield.
5476 (TYPE_RAW_ALIGN): New macro.
5477 (type_align, type_raw_align, set_type_align): Declare.
5478 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
5480 * dwarf2read.c (quirk_rust_enum): Set type alignment.
5481 (get_alignment, maybe_set_alignment): New functions.
5482 (read_structure_type, read_enumeration_type, read_array_type)
5483 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
5484 (read_subrange_type, read_base_type): Set type alignment.
5486 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
5488 * dwarf2read.c (read_index_from_section): Use bool.
5490 2018-04-29 Fabian Groffen <grobian@gentoo.org>
5493 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
5496 2018-04-29 John Reiser <jreiser@BitWagon.com>
5499 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
5500 last step, and do it atomically.
5502 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
5504 * compile/compile-c-types.c (convert_int, convert_float):
5507 2018-04-27 Tom Tromey <tom@tromey.com>
5510 * rust-lang.c (rust_inclusive_range_type_p): New function.
5511 (rust_range): Handle inclusive ranges.
5512 (rust_compute_range): Likewise.
5513 * rust-exp.y (struct rust_op) <inclusive>: New field.
5514 (DOTDOTEQ): New constant.
5515 (range_expr): Add "..=" productions.
5516 (operator_tokens): Add "..=" token.
5517 (ast_range): Add "inclusive" parameter.
5518 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
5520 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
5522 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
5523 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
5525 * expprint.c (print_subexp_standard): Handle new bounds values.
5526 (dump_subexp_body_standard): Likewise.
5528 2018-04-27 Tom Tromey <tom@tromey.com>
5530 * configure: Rebuild.
5531 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
5532 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
5534 (class symbol_needs_eval_context): Likewise.
5535 * dwarf2read.c (mock_mapped_index::symbol_name_count)
5536 (mock_mapped_index::symbol_name_at): Use "override". Remove
5538 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
5540 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
5541 * aarch64-tdep.c (instruction_reader::read): Use "override".
5542 (instruction_reader_test::read): Likewise.
5543 * arm-tdep.c (instruction_reader::read): Use "override".
5544 (instruction_reader_thumb::read): Likewise.
5546 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
5549 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
5550 instead of remote_send.
5551 (remote_send): Remove.
5553 2018-04-26 Pedro Alves <palves@redhat.com>
5555 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
5556 find_function_start_sal instead of find_pc_line.
5558 2018-04-26 Pedro Alves <palves@redhat.com>
5560 * breakpoint.c (set_breakpoint_location_function): Handle
5562 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
5563 * elfread.c (elf_symtab_read): Give data symbols with
5564 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
5565 (elf_rel_plt_read): Update comment.
5566 * linespec.c (convert_linespec_to_sals): Handle
5568 (minsym_found): Handle mst_data_gnu_ifunc.
5569 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
5570 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
5571 * parse.c (find_minsym_type_and_address): Handle
5573 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
5574 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
5575 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
5577 <mst_data_gnu_ifunc>: New enumerator.
5579 2018-04-26 Pedro Alves <palves@redhat.com>
5581 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
5582 (lookup_minimal_symbol_by_pc_section): ... this. Replace
5583 'want_trampoline' parameter by a lookup_msym_prefer parameter.
5585 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
5586 (lookup_minimal_symbol_by_pc): Adjust.
5587 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
5588 (lookup_solib_trampoline_symbol_by_pc): Adjust.
5589 * minsyms.h (lookup_msym_prefer): New enum.
5590 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5591 parameter by a lookup_msym_prefer parameter.
5593 2018-04-26 Pedro Alves <palves@redhat.com>
5595 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
5596 ends in "@plt" instead of looking at the symbol's section.
5598 2018-04-26 Pedro Alves <palves@redhat.com>
5600 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
5602 (find_pc_partial_function_gnu_ifunc): Rename to ...
5603 (find_pc_partial_function): ... this, and remove references to
5605 (find_pc_partial_function): Delete old implementation.
5606 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
5608 2018-04-26 Pedro Alves <palves@redhat.com>
5610 * linespec.c (struct bound_minimal_symbol_search_key): New.
5611 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
5612 skip first line if we found a GNU ifunc minimal symbol by name.
5613 (compare_msymbols): Change parameters to work with a destructured
5615 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
5618 2018-04-26 Pedro Alves <palves@redhat.com>
5620 * breakpoint.c (set_breakpoint_location_function): Don't resolve
5621 ifunc targets here. Instead, if we have an ifunc minsym, use its
5623 (add_location_to_breakpoint): Store the minsym and the objfile in
5624 the breakpoint location.
5625 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
5626 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
5627 Record the minsym in the sal.
5628 * symtab.h (symtab_and_line) <msymbol>: New field.
5630 2018-04-26 Pedro Alves <palves@redhat.com>
5632 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
5633 unless we actually resolved the ifunc.
5635 2018-04-26 Pedro Alves <palves@redhat.com>
5637 * c-exp.y (variable production): Prefer ifunc minsyms over
5638 regular function symbols.
5639 * symtab.c (find_gnu_ifunc): New function.
5640 * minsyms.h (lookup_msym_prefer): New enum.
5641 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5642 parameter by a lookup_msym_prefer parameter.
5643 * symtab.h (find_gnu_ifunc): New declaration.
5645 2018-04-26 Pedro Alves <palves@redhat.com>
5647 * blockframe.c (find_gnu_ifunc_target_type): New function.
5648 (find_function_type): New.
5649 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
5650 return a value with a memory address.
5651 (eval_call): For calls to GNU ifunc functions, try to find the
5652 type of the target function from the type that the resolver
5654 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
5656 * infcall.c (find_function_return_type): Delete.
5657 (find_function_addr): Add 'function_type' parameter. For calls to
5658 GNU ifunc functions, try to find the type of the target function
5659 from the type that the resolver returns, and return it via
5661 (call_function_by_hand_dummy): Adjust to use the function type
5662 returned by find_function_addr.
5663 (find_function_addr): Add 'function_type' parameter and move
5665 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
5668 2018-04-26 Pedro Alves <palves@redhat.com>
5670 * c-exp.y (variable production): Skip finding an alias for ifunc
5673 2018-04-26 Pedro Alves <palves@redhat.com>
5675 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
5677 2018-04-25 Pedro Alves <palves@redhat.com>
5679 * infcmd.c (kill_command): Print the pid as string, not the whole
5680 thread's ptid. Add comment. s/has been killed/killed/ in output
5682 * remote.c (remote_detach_1): Print the pid as string, not the
5683 whole thread's ptid.
5685 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5686 Sergio Durigan Junior <sergiodj@redhat.com>
5687 Pedro Alves <palves@redhat.com>
5689 * infcmd.c (kill_command): Print message when inferior has
5691 * inferior.c (print_inferior_events): Remove 'static'. Set as
5693 (add_inferior): Improve message printed when
5694 'print_inferior_events' is on.
5695 (exit_inferior): Remove message printed when
5696 'print_inferior_events' is on.
5697 (detach_inferior): Improve message printed when
5698 'print_inferior_events' is on.
5699 (initialize_inferiors): Use 'add_inferior_silent' to set
5700 'current_inferior_'.
5701 * inferior.h (print_inferior_events): Declare here as
5703 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
5704 '[Detaching...]' messages when 'print_inferior_events' is on.
5705 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
5706 as prefix/suffix for messages. Remove periods. Fix erroneous
5707 'Detaching after fork from child...', replace it by '... from
5709 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
5710 prefix/suffix when printing 'Detaching...' messages. Print
5711 them when 'print_inferior_events' is on.
5712 * remote.c (remote_detach_1): Print message when detaching
5713 from inferior and '!is_fork_parent'.
5715 2018-04-24 Tom Tromey <tom@tromey.com>
5717 * cli-out.h: Reindent.
5719 2018-04-24 Tom Tromey <tom@tromey.com>
5721 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
5722 (cli_ui_out::do_field_string): Use fputs_filtered.
5723 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
5725 2018-04-23 Tom Tromey <tom@tromey.com>
5727 * guile/scm-frame.c (gdbscm_frame_read_var): Use
5728 gdb::unique_xmalloc_ptr.
5730 2018-04-23 Tom Tromey <tom@tromey.com>
5732 * configure: Rebuild.
5734 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
5737 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
5738 prepare_for_testing. Set normal_bp to r_debug_state if target
5741 2018-04-21 Pedro Alves <palves@redhat.com>
5742 Rajendra SY <rajendra.sy@gmail.com>
5744 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
5745 * remote.c (extended_remote_attach): In all-stop mode, mark the
5746 thread as executing.
5748 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5750 * thread.c (thread_apply_all_command): Fix comment.
5751 (thread_command): Fix comment.
5753 2018-04-10 Alan Hayward <alan.hayward@arm.com>
5755 * common/tdesc.h (tdesc_create_feature): Remove xml filename
5757 * features/aarch64-core.c (create_feature_aarch64_core):
5759 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
5761 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
5763 * features/i386/32bit-avx512.c
5764 (create_feature_i386_32bit_avx512): Likewise.
5765 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
5767 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
5769 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
5771 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
5773 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
5775 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
5777 * features/i386/64bit-avx512.c
5778 (create_feature_i386_64bit_avx512): Likewise.
5779 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
5781 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
5783 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
5785 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
5787 * features/i386/64bit-segments.c
5788 (create_feature_i386_64bit_segments): Likewise.
5789 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
5791 * features/i386/x32-core.c
5792 (create_feature_i386_x32_core): Likewise.
5793 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
5794 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
5795 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
5796 * target-descriptions.c: In generated code, don't pass xml
5799 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5801 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
5802 (print_xml_feature::visit_post): Likewise.
5803 (print_xml_feature::visit): Likewise.
5804 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
5805 (print_xml_feature): Add new class.
5806 * regformats/regdat.sh: Null xmltarget on feature targets.
5807 * target-descriptions.c (struct target_desc): Add xmltarget.
5808 (maintenance_check_tdesc_xml_convert): Add unittest function.
5809 (tdesc_get_features_xml): Add function to get xml.
5810 (maintenance_check_xml_descriptions): Test xml generation.
5811 * xml-tdesc.c (string_read_description_xml): Add function.
5812 * xml-tdesc.h (string_read_description_xml): Add declaration.
5814 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5816 * features/Makefile: Add feature marker to targets with new style
5817 target descriptions.
5818 * regformats/aarch64.dat: Regenerate.
5819 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
5820 * regformats/i386/amd64-avx-linux.dat: Likewise.
5821 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
5822 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
5823 * regformats/i386/amd64-linux.dat: Likewise.
5824 * regformats/i386/amd64-mpx-linux.dat: Likewise.
5825 * regformats/i386/amd64.dat: Likewise.
5826 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
5827 * regformats/i386/i386-avx-linux.dat: Likewise.
5828 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
5829 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
5830 * regformats/i386/i386-linux.dat: Likewise.
5831 * regformats/i386/i386-mmx-linux.dat: Likewise.
5832 * regformats/i386/i386-mpx-linux.dat: Likewise.
5833 * regformats/i386/i386.dat: Likewise.
5834 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
5835 * regformats/i386/x32-avx-linux.dat: Likewise.
5836 * regformats/i386/x32-linux.dat: Likewise.
5837 * regformats/tic6x-c62x-linux.dat: Likewise.
5838 * regformats/tic6x-c64x-linux.dat: Likewise.
5839 * regformats/tic6x-c64xp-linux.dat: Likewise.
5840 * regformats/regdat.sh: Parse feature marker.
5842 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5844 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
5845 (tdesc_osabi_name): Likewise.
5846 * target-descriptions.c (tdesc_architecture_name): Add new
5848 (tdesc_osabi_name): Likewise.
5850 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5852 * common/tdesc.c (tdesc_predefined_type): Move to here.
5853 (tdesc_named_type): Likewise.
5854 (tdesc_create_vector): Likewise.
5855 (tdesc_create_struct): Likewise.
5856 (tdesc_set_struct_size): Likewise.
5857 (tdesc_create_union): Likewise.
5858 (tdesc_create_flags): Likewise.
5859 (tdesc_create_enum): Likewise.
5860 (tdesc_add_field): Likewise.
5861 (tdesc_add_typed_bitfield): Likewise.
5862 (tdesc_add_bitfield): Likewise.
5863 (tdesc_add_flag): Likewise.
5864 (tdesc_add_enum_value): Likewise.
5865 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
5866 (struct tdesc_type_vector): Likewise.
5867 (struct tdesc_type_field): Likewise.
5868 (struct tdesc_type_with_fields): Likewise.
5869 (tdesc_create_enum): Add declaration.
5870 (tdesc_add_typed_bitfield): Likewise.
5871 (tdesc_add_enum_value): Likewise.
5872 * target-descriptions.c (tdesc_type_field): Move from here.
5873 (tdesc_type_builtin): Likewise.
5874 (tdesc_type_vector): Likewise.
5875 (tdesc_type_with_fields): Likewise.
5876 (tdesc_predefined_types): Likewise.
5877 (tdesc_named_type): Likewise.
5878 (tdesc_create_vector): Likewise.
5879 (tdesc_create_struct): Likewise.
5880 (tdesc_set_struct_size): Likewise.
5881 (tdesc_create_union): Likewise.
5882 (tdesc_create_flags): Likewise.
5883 (tdesc_create_enum): Likewise.
5884 (tdesc_add_field): Likewise.
5885 (tdesc_add_typed_bitfield): Likewise.
5886 (tdesc_add_bitfield): Likewise.
5887 (tdesc_add_flag): Likewise.
5888 (tdesc_add_enum_value): Likewise.
5889 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
5890 (tdesc_add_typed_bitfield): Likewise.
5891 (tdesc_add_enum_value): Likewise.
5893 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5895 * common/tdesc.c (tdesc_feature::accept): Move to here.
5896 (tdesc_feature::operator==): Likewise.
5897 (tdesc_create_reg): Likewise.
5898 * common/tdesc.h (tdesc_type_kind): Likewise.
5899 (struct tdesc_type): Likewise.
5900 (struct tdesc_feature): Likewise.
5901 * regformats/regdat.sh: Create a feature.
5902 * target-descriptions.c (tdesc_type_kind): Move from here.
5903 (tdesc_type): Likewise.
5904 (tdesc_type_up): Likewise.
5905 (tdesc_feature): Likewise.
5906 (tdesc_create_reg): Likewise.
5908 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5910 * Makefile.in: Add arch/tdesc.c
5911 * common/tdesc.c: New file.
5912 * common/tdesc.h (tdesc_element_visitor): Move to here.
5913 (tdesc_element): Likewise.
5914 (tdesc_reg): Likewise.
5915 (tdesc_reg_up): Likewise.
5916 * regformats/regdef.h (reg): Add offset to constructors.
5917 * target-descriptions.c (tdesc_element_visitor): Move from here.
5918 (tdesc_element): Likewise.
5919 (tdesc_reg): Likewise.
5920 (tdesc_reg_up): Likewise.
5922 2018-04-17 Tom Tromey <tom@tromey.com>
5924 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
5927 2018-04-17 Tom Tromey <tom@tromey.com>
5929 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
5931 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
5933 * symtab.c (print_symbol_info): Skip printing filename and line
5934 number when `last' is NULL.
5935 (symtab_symbol_info): Use empty string instead of NULL for first
5936 invocation of print_symbol_info.
5937 (rbreak_command): Pass NULL to `last' parameter of
5940 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
5942 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
5945 2018-04-16 Pedro Alves <palves@redhat.com>
5947 * MAINTAINERS (sh): Remove.
5948 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
5949 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
5950 (ALLDEPFILES): Remove sh64-tdep.c.
5951 * NEWS: Mentions that support for SH-5/SH64 is removed.
5952 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
5953 (sh*-*-openbsd*): Ditto.
5954 (sh64-*-elf*): Remove.
5956 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
5957 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
5958 * sh-tdep.c: No longer include "sh64-tdep.h".
5959 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
5960 * sh64-tdep.c, sh64-tdep.h: Remove files.
5962 2018-04-16 Pedro Alves <palves@redhat.com>
5964 * MAINTAINERS: Remove m88k.
5965 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
5966 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
5967 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
5968 * NEWS: Mention that support for m88k was removed.
5969 * configure.host (m88*-*-*): Remove support.
5970 * configure.nat (m88k-*-*): Remove support.
5971 * configure.tgt (m88*-*-openbsd*): Remove.
5972 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
5974 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
5976 * configure.tgt (x86_tobjs): New variable.
5977 (amd64_tobjs, i386_tobjs): Use it.
5979 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5981 * symtab.c (print_symbol_info): Precede the symbol definition by
5982 the line number when available.
5983 * NEWS: Advertise this enhancement.
5985 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
5987 * NEWS (New options): announce set/show record btrace cpu.
5988 * btrace.c: Include record-btrace.h.
5989 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
5990 the vendor is unknown.
5991 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
5992 Maybe overwrite the btrace configuration's cpu.
5993 (btrace_compute_ftrace): Add cpu parameter. Update callers.
5994 (btrace_fetch): Add cpu parameter. Update callers.
5995 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
5996 Maybe overwrite the btrace configuration's cpu. Skip enabling
5997 errata workarounds if the vendor is unknown.
5998 * python/py-record-btrace.c: Include record-btrace.h.
5999 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
6000 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
6001 * record-btrace.c (record_btrace_cpu_state_kind): New.
6002 (record_btrace_cpu): New.
6003 (set_record_btrace_cpu_cmdlist): New.
6004 (record_btrace_get_cpu): New.
6005 (require_btrace_thread, record_btrace_info)
6006 (record_btrace_resume_thread): Call record_btrace_get_cpu.
6007 (cmd_set_record_btrace_cpu_none): New.
6008 (cmd_set_record_btrace_cpu_auto): New.
6009 (cmd_set_record_btrace_cpu): New.
6010 (cmd_show_record_btrace_cpu): New.
6011 (_initialize_record_btrace): Initialize set/show record btrace cpu
6013 * record-btrace.h (record_btrace_get_cpu): New.
6015 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6017 * record.c (set_record_command): Fix typo in message.
6019 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6021 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
6023 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6025 * infrun.c (process_event_stop_test): Call
6026 gdbarch_in_indirect_branch_thunk.
6027 * gdbarch.sh (in_indirect_branch_thunk): New.
6028 * gdbarch.c: Regenerated.
6029 * gdbarch.h: Regenerated.
6032 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
6033 (HFILES_NO_SRCDIR): Add x86-tdep.h.
6034 (ALLDEPFILES): Add x86-tdep.c.
6035 * arch-utils.h (default_in_indirect_branch_thunk): New.
6036 * arch-utils.c (default_in_indirect_branch_thunk): New.
6037 * i386-tdep: Include x86-tdep.h.
6038 (i386_in_indirect_branch_thunk): New.
6039 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
6041 * amd64-tdep: Include x86-tdep.h.
6042 (amd64_in_indirect_branch_thunk): New.
6043 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
6045 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
6048 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
6049 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
6050 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
6053 2018-04-12 Tom Tromey <tom@tromey.com>
6055 * rust-lang.c (rust_print_struct_def): Remove univariant code.
6056 (rust_evaluate_subexp): Likewise.
6058 2018-04-12 Pedro Alves <palves@redhat.com>
6060 * procfs.c (procfs_detach): Make forward declaration's prototype
6061 match definition's protototype.
6062 (proc_get_LDT_entry): Remove stale do_cleanups call.
6064 2018-04-12 Pedro Alves <palves@redhat.com>
6066 * target.h (target_ops::to_has_exited): Delete.
6067 (target_has_exited): Delete.
6068 * target-delegates.c: Regenerate.
6070 2018-04-11 Pedro Alves <palves@redhat.com>
6072 * target.c (fileio_fh_t::t): Add comment.
6073 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6074 (target_fileio_close): Handle a NULL target.
6075 (invalidate_fileio_fh): New.
6076 (target_close): Call it.
6077 * remote.c (remote_hostio_send_command): No longer check whether
6078 remote_desc is open.
6080 2018-04-11 Pedro Alves <palves@redhat.com>
6082 * target.c (fileio_fh_t): Make it a named struct instead of a
6084 (fileio_fh_t::is_closed): New method.
6085 (DEF_VEC_O (fileio_fh_t)): Remove.
6086 (fileio_fhandles): Now a std::vector.
6087 (is_closed_fileio_fh): Delete.
6088 (acquire_fileio_fd): Adjust. Rename parameters.
6089 (release_fileio_fd): Adjust.
6090 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
6091 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6092 (target_fileio_close): Adjust.
6094 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
6096 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
6099 2018-04-10 Pedro Alves <palves@redhat.com>
6101 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
6102 (scoped_finish_thread_state): New class.
6103 * infcmd.c (run_command_1): Use it instead of finish_thread_state
6105 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
6106 (fetch_inferior_event, normal_stop): Likewise.
6107 * thread.c (finish_thread_state_cleanup): Delete.
6109 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6110 Pedro Alves <palves@redhat.com>
6112 * value.c: Include "selftest.h" and "common/array-view.h".
6113 (struct range) <operator ==>: New.
6114 (test_ranges_contain): New.
6115 (check_ranges_vector): New.
6116 (test_insert_into_bit_range_vector): New.
6117 (_initialize_values): Register selftests.
6118 * common/array-view.h (operator==, operator!=): New.
6120 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6122 * common/gdb_vecs.h (unordered_remove): Add overload that takes
6124 * inline-frame.c: Include <algorithm>.
6125 (struct inline_state): Add constructor.
6126 (inline_state_s): Remove.
6127 (DEF_VEC_O(inline_state_s)): Remove.
6128 (inline_states): Change type to std::vector.
6129 (find_inline_frame_state): Adjust to std::vector.
6130 (allocate_inline_frame_state): Remove.
6131 (clear_inline_frame_state): Adjust to std::vector.
6132 (skip_inline_frames): Adjust to std::vector.
6134 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6136 * tracepoint.h (struct trace_state_variable): Add constructor.
6137 <name>: Change type to std::string.
6138 * tracepoint.c (tsv_s): Remove.
6139 (DEF_VEC_O(tsv_s)): Remove.
6140 (tvariables): Change to std::vector.
6141 (create_trace_state_variable): Adjust to std::vector.
6142 (find_trace_state_variable): Likewise.
6143 (find_trace_state_variable_by_number): Likewise.
6144 (delete_trace_state_variable): Likewise.
6145 (trace_variable_command): Adjust to std::string.
6146 (delete_trace_variable_command): Likewise.
6147 (tvariables_info_1): Adjust to std::vector.
6148 (save_trace_state_variables): Likewise.
6149 (start_tracing): Likewise.
6150 (merge_uploaded_trace_state_variables): Adjust to std::vector
6152 * target.h (struct target_ops)
6153 <to_download_trace_state_variable>: Pass reference to
6154 trace_state_variable.
6155 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
6156 * target-delegates.c: Re-generate.
6157 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
6158 (mi_tsv_deleted): Likewise.
6159 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
6160 * remote.c (remote_download_trace_state_variable): Change
6161 pointer to reference and adjust.
6162 * make-target-delegates (parse_argtypes): Handle references.
6163 (write_function_header): Likewise.
6164 (munge_type): Likewise.
6166 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6168 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6169 string_view-selftests.c.
6170 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
6172 * unittests/basic_string_view/cons/char/1.cc: Likewise.
6173 * unittests/basic_string_view/cons/char/2.cc: Likewise.
6174 * unittests/basic_string_view/cons/char/3.cc: Likewise.
6175 * unittests/basic_string_view/element_access/char/1.cc:
6177 * unittests/basic_string_view/element_access/char/empty.cc:
6179 * unittests/basic_string_view/element_access/char/front_back.cc:
6181 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
6182 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
6184 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
6186 * unittests/basic_string_view/modifiers/swap/char/1.cc:
6188 * unittests/basic_string_view/operations/compare/char/1.cc:
6190 * unittests/basic_string_view/operations/compare/char/13650.cc:
6192 * unittests/basic_string_view/operations/copy/char/1.cc:
6194 * unittests/basic_string_view/operations/data/char/1.cc:
6196 * unittests/basic_string_view/operations/find/char/1.cc:
6198 * unittests/basic_string_view/operations/find/char/2.cc:
6200 * unittests/basic_string_view/operations/find/char/3.cc:
6202 * unittests/basic_string_view/operations/find/char/4.cc:
6204 * unittests/basic_string_view/operations/rfind/char/1.cc:
6206 * unittests/basic_string_view/operations/rfind/char/2.cc:
6208 * unittests/basic_string_view/operations/rfind/char/3.cc:
6210 * unittests/basic_string_view/operations/substr/char/1.cc:
6212 * unittests/basic_string_view/operators/char/2.cc: Likewise.
6213 * unittests/string_view-selftests.c: New file.
6215 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6217 * unittests/basic_string_view/capacity/1.cc: New file.
6218 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
6219 * unittests/basic_string_view/cons/char/1.cc: New file.
6220 * unittests/basic_string_view/cons/char/2.cc: New file.
6221 * unittests/basic_string_view/cons/char/3.cc: New file.
6222 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
6223 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
6224 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
6225 * unittests/basic_string_view/element_access/char/1.cc: New file.
6226 * unittests/basic_string_view/element_access/char/2.cc: New file.
6227 * unittests/basic_string_view/element_access/char/empty.cc: New file.
6228 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
6229 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
6230 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
6231 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
6232 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
6233 * unittests/basic_string_view/include.cc: New file.
6234 * unittests/basic_string_view/inserters/char/1.cc: New file.
6235 * unittests/basic_string_view/inserters/char/2.cc: New file.
6236 * unittests/basic_string_view/inserters/char/3.cc: New file.
6237 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
6238 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
6239 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
6240 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
6241 * unittests/basic_string_view/literals/types.cc: New file.
6242 * unittests/basic_string_view/literals/values.cc: New file.
6243 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
6244 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
6245 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
6246 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
6247 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
6248 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
6249 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
6250 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
6251 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
6252 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
6253 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
6254 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
6255 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
6256 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
6257 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
6258 * unittests/basic_string_view/operations/data/char/1.cc: New file.
6259 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
6260 * unittests/basic_string_view/operations/find/char/1.cc: New file.
6261 * unittests/basic_string_view/operations/find/char/2.cc: New file.
6262 * unittests/basic_string_view/operations/find/char/3.cc: New file.
6263 * unittests/basic_string_view/operations/find/char/4.cc: New file.
6264 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
6265 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
6266 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
6267 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
6268 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
6269 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
6270 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
6271 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
6272 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
6273 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
6274 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
6275 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
6276 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
6277 * unittests/basic_string_view/operators/char/2.cc: New file.
6278 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
6279 * unittests/basic_string_view/range_access/char/1.cc: New file.
6280 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
6281 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
6282 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
6283 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
6284 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
6285 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
6286 * unittests/basic_string_view/requirements/typedefs.cc: New file.
6287 * unittests/basic_string_view/typedefs.cc: New file.
6288 * unittests/basic_string_view/types/1.cc: New file.
6290 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6292 * common/gdb_string_view.h: Remove libstdc++ implementation
6293 details, adjust to gdb reality.
6294 * common/gdb_string_view.tcc: Likewise.
6295 * cli/cli-script.c (struct string_view): Remove.
6296 (user_args) <m_args>: Change element type to gdb::string_view.
6297 (user_args::insert_args): Adjust.
6299 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6301 * common/gdb_string_view.h: New file.
6302 * common/gdb_string_view.tcc: New file.
6304 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6306 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
6307 * configure: Re-generate.
6309 2018-04-09 Pedro Alves <palves@redhat.com>
6311 * gdbarch.sh: Include "observable.h" instead of "observer.h".
6312 (set_target_gdbarch): Call
6313 gdb::observers::architecture_changed.notify instead of
6314 observer_notify_architecture_changed.
6316 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6318 * tracepoint.c (struct current_traceframe_cleanup): Remove.
6319 (do_restore_current_traceframe_cleanup): Remove.
6320 (restore_current_traceframe_cleanup_dtor): Remove.
6321 (make_cleanup_restore_current_traceframe): Remove.
6322 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
6324 * tracepoint.h (struct scoped_restore_current_traceframe): New.
6325 * infrun.c (fetch_inferior_event): Use
6326 scoped_restore_current_traceframe.
6328 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6330 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
6332 <n_allocated_type_units>: Remove.
6333 <all_type_units>: Change to std::vector.
6334 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6335 to std::vector change.
6336 (dwarf2_per_objfile::get_cutu): Likewise.
6337 (dwarf2_per_objfile::get_tu): Likewise.
6338 (create_signatured_type_table_from_index): Likewise.
6339 (create_signatured_type_table_from_debug_names): Likewise.
6340 (dw2_symtab_iter_next): Likewise.
6341 (dw2_print_stats): Likewise.
6342 (dw2_expand_all_symtabs): Likewise.
6343 (dw2_expand_marked_cus): Likewise.
6344 (dw2_debug_names_iterator::next): Likewise.
6345 (dwarf2_initialize_objfile): Likewise.
6346 (add_signatured_type_cu_to_table): Likewise.
6347 (create_all_type_units): Likewise.
6348 (add_type_unit): Likewise.
6349 (struct tu_abbrev_offset): Add constructor.
6350 (build_type_psymtabs_1): Adjust to std::vector change.
6351 (print_tu_stats): Likewise.
6352 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6353 (write_debug_names): Likewise.
6355 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6357 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
6358 Make an std::vector.
6359 <n_comp_units>: Remove.
6360 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6361 to std::vector change.
6362 (dwarf2_per_objfile::get_cutu): Likewise.
6363 (dwarf2_per_objfile::get_cu): Likewise.
6364 (create_cus_from_index): Likewise.
6365 (create_addrmap_from_index): Likewise.
6366 (create_addrmap_from_aranges): Likewise.
6367 (dwarf2_read_index): Likewise.
6368 (dw2_find_last_source_symtab): Likewise.
6369 (dw2_map_symtabs_matching_filename): Likewise.
6370 (dw2_symtab_iter_next): Likewise.
6371 (dw2_print_stats): Likewise.
6372 (dw2_expand_all_symtabs): Likewise.
6373 (dw2_expand_symtabs_with_fullname): Likewise.
6374 (dw2_expand_marked_cus): Likewise.
6375 (dw2_map_symbol_filenames): Likewise.
6376 (create_cus_from_debug_names): Likewise.
6377 (dwarf2_read_debug_names): Likewise.
6378 (dw2_debug_names_iterator::next): Likewise.
6379 (dwarf2_initialize_objfile): Likewise.
6380 (set_partial_user): Likewise.
6381 (dwarf2_build_psymtabs_hard): Likewise.
6382 (read_comp_units_from_section): Remove arguments, adjust to
6384 (create_all_comp_units): Adjust to std::vector and
6385 read_comp_units_from_section changes.
6386 (dwarf2_find_containing_comp_unit): Adjust to std::vector
6388 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6389 (psyms_seen_size): Likewise.
6390 (write_gdbindex): Likewise.
6391 (write_debug_names): Likewise.
6393 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6395 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
6396 with dwarf2_per_objfile.
6397 (create_cus_from_index): Likewise.
6398 (create_signatured_type_table_from_index): Likewise.
6399 (dwarf2_read_index): Likewise.
6400 (dwarf2_initialize_objfile): Likewise.
6401 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
6402 per_cu rather than get_dwarf2_per_objfile.
6404 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6406 * dwarf2read.h (struct signatured_type): Forward declare.
6407 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
6409 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
6410 (dw2_get_cutu): ...this.
6411 (dwarf2_per_objfile::get_cu): Rename from...
6412 (dw2_get_cu): ...this.
6413 (dwarf2_per_objfile::get_tu): New.
6414 (create_addrmap_from_index): Adjust.
6415 (create_addrmap_from_aranges): Adjust.
6416 (dw2_find_last_source_symtab): Adjust.
6417 (dw2_map_symtabs_matching_filename): Adjust.
6418 (dw2_symtab_iter_next): Adjust.
6419 (dw2_print_stats): Adjust.
6420 (dw2_expand_all_symtabs): Adjust.
6421 (dw2_expand_symtabs_with_fullname): Adjust.
6422 (dw2_expand_marked_cus): Adjust.
6423 (dw_expand_symtabs_matching_file_matcher): Adjust.
6424 (dw2_map_symbol_filenames): Adjust.
6425 (dw2_debug_names_iterator::next): Adjust.
6426 (dwarf2_initialize_objfile): Adjust.
6427 (set_partial_user): Adjust.
6428 (dwarf2_build_psymtabs_hard): Adjust.
6430 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6432 * dwarf2read.c (create_signatured_type_table_from_debug_names):
6433 Remove unused variables.
6434 (dw2_map_symtabs_matching_filename): Likewise.
6435 (dwarf2_record_block_ranges): Likewise.
6436 (dwarf2_read_addr_index): Likewise.
6437 (follow_die_offset): Likewise.
6439 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6441 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
6442 to symbol_file_add_main.
6444 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6447 * mi/mi-console.c (do_fputc_async_safe): New.
6448 (mi_console_file::write_async_safe): New.
6449 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
6450 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
6452 * ui-file.c (ui_file::putstrn): Adjust call to
6453 fputstrn_unfiltered.
6454 * utils.c (printchar): Replace do_fputs and do_fprintf
6455 parameters by do_fputc.
6456 (fputstr_filtered): Adjust call to printchar.
6457 (fputstr_unfiltered): Likewise.
6458 (fputstrn_filtered): Likewise.
6459 (fputstrn_unfiltered): Add do_fputc parameter, pass to
6461 * utils.h (do_fputc_ftype): New typedef.
6462 (fputstrn_unfiltered): Add do_fputc parameter.
6464 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6466 * regformats/i386/i386-avx.dat: Remove.
6468 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6471 * amd64-tdep.c (amd64_none_init_abi): New function.
6472 (amd64_x32_none_init_abi): New function.
6473 (_initialize_amd64_tdep): Register handlers for x86-64 and
6474 x64_32 with GDB_OSABI_NONE.
6475 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
6476 GDB_OSABI_NONE osabi.
6478 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6481 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
6483 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
6484 * osabi.c (gdb_osabi_names): Add "unknown" entry.
6486 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6488 * common/byte-vector.h (char_vector): New type.
6489 * target.h (target_read_alloc): Return
6490 gdb::optional<byte_vector>.
6491 (target_read_stralloc): Return gdb::optional<char_vector>.
6492 (target_get_osdata): Return gdb::optional<char_vector>.
6493 * target.c (target_read_alloc_1): Templatize. Replacement
6494 manual memory management with vector.
6495 (target_read_alloc): Change return type, adjust.
6496 (target_read_stralloc): Change return type, adjust.
6497 (target_get_osdata): Change return type, adjust.
6498 * auxv.c (struct auxv_info) <length>: Remove.
6499 <data>: Change type to gdb::optional<byte_vector>.
6500 (auxv_inferior_data_cleanup): Free auxv_info with delete.
6501 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
6502 (target_auxv_search): Adjust.
6503 (fprint_target_auxv): Adjust.
6504 * avr-tdep.c (avr_io_reg_read_command): Adjust.
6505 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
6506 (linux_make_corefile_notes): Adjust.
6507 * osdata.c (get_osdata): Adjust.
6508 * remote.c (remote_get_threads_with_qxfer): Adjust.
6509 (remote_memory_map): Adjust.
6510 (remote_traceframe_info): Adjust.
6511 (btrace_read_config): Adjust.
6512 (remote_read_btrace): Adjust.
6513 (remote_pid_to_exec_file): Adjust.
6514 * solib-aix.c (solib_aix_get_library_list): Adjust.
6515 * solib-dsbt.c (decode_loadmap): Don't free buf.
6516 (dsbt_get_initial_loadmaps): Adjust.
6517 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
6518 * solib-target.c (solib_target_current_sos): Adjust.
6519 * tracepoint.c (sdata_make_value): Adjust.
6520 * xml-support.c (xinclude_start_include): Adjust.
6521 (xml_fetch_content_from_file): Adjust.
6522 * xml-support.h (xml_fetch_another): Change return type.
6523 (xml_fetch_content_from_file): Change return type.
6524 * xml-syscall.c (xml_init_syscalls_info): Adjust.
6525 * xml-tdesc.c (file_read_description_xml): Adjust.
6526 (fetch_available_features_from_target): Change return type.
6527 (target_fetch_description_xml): Adjust.
6528 (target_read_description_xml): Adjust.
6530 2018-04-06 Tom Tromey <tom@tromey.com>
6532 * value.c (~value): Update.
6533 (struct value) <contents>: Now unique_xmalloc_ptr.
6534 (value_contents_bits_eq, allocate_value_contents)
6535 (value_contents_raw, value_contents_all_raw)
6536 (value_contents_for_printing, value_contents_for_printing_const)
6537 (set_value_enclosing_type): Update.
6539 2018-04-06 Tom Tromey <tom@tromey.com>
6541 * value.c (range_s): Remove typedef, VEC.
6542 (struct range): Add operator<.
6543 (range_lessthan): Remove.
6544 (ranges_contain): Change type.
6546 (struct value) <unavailable, optimized_out>: Now std::vector.
6547 (value_entirely_available)
6548 (value_entirely_covered_by_range_vector)
6549 (value_entirely_unavailable, value_entirely_optimized_out):
6551 (insert_into_bit_range_vector): Change argument type.
6552 (find_first_range_overlap): Likewise.
6553 (struct ranges_and_idx, value_contents_bits_eq)
6554 (require_not_optimized_out, require_available): Update.
6555 (ranges_copy_adjusted): Change argument types.
6556 (value_optimized_out, value_copy, value_fetch_lazy): Update.
6558 2018-04-06 Tom Tromey <tom@tromey.com>
6560 * value.c (~value): Update.
6561 (struct value) <parent>: Now a value_ref_ptr.
6562 (value_parent, set_value_parent, value_address, value_copy):
6565 2018-04-06 Tom Tromey <tom@tromey.com>
6567 * value.c (struct value): Add constructor, destructor, and member
6569 (allocate_value_lazy, value_decref): Update.
6571 2018-04-06 Tom Tromey <tom@tromey.com>
6573 * value.c (struct value) <released, next>: Remove.
6574 (all_values): Now a std::vector.
6575 (allocate_value_lazy): Update.
6576 (value_next): Remove.
6577 (value_mark, value_free_to_mark, release_value)
6578 (value_release_to_mark): Update.
6580 2018-04-06 Tom Tromey <tom@tromey.com>
6582 * value.h (fetch_subexp_value, value_release_to_mark): Update.
6583 (free_value_chain): Remove.
6584 * value.c (free_value_chain): Remove.
6585 (value_release_to_mark): Return a std::vector.
6586 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
6588 (check_condition): Update.
6589 * eval.c (fetch_subexp_value): Change "val_chain" to a
6591 * breakpoint.c (update_watchpoint): Update.
6592 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
6594 2018-04-06 Tom Tromey <tom@tromey.com>
6596 * value.h (free_all_values): Remove.
6597 * value.c (free_all_values): Remove.
6599 2018-04-06 Tom Tromey <tom@tromey.com>
6601 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
6602 (value_history_chain, value_history_count): Remove.
6603 (value_history): New global.
6604 (record_latest_value, access_value_history, show_values)
6605 (preserve_values): Update.
6607 2018-04-06 Tom Tromey <tom@tromey.com>
6609 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
6610 * varobj.c (varobj_set_display_format, varobj_set_value)
6611 (install_default_visualizer, construct_visualizer)
6612 (install_new_value, ~varobj, varobj_get_value_type)
6613 (my_value_of_variable, varobj_editable_p): Update.
6614 * c-varobj.c (c_describe_child, c_value_of_variable)
6615 (cplus_number_of_children, cplus_describe_child): Update.
6616 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
6617 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
6618 (ada_value_of_variable, ada_value_is_changeable_p): Update.
6620 2018-04-06 Tom Tromey <tom@tromey.com>
6622 * printcmd.c (last_examine_address): Change type to
6624 (do_examine, x_command): Update.
6626 2018-04-06 Tom Tromey <tom@tromey.com>
6628 * value.c (release_value): Update.
6629 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
6630 (struct bpstats) <val>: Now a value_ref_ptr.
6631 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6632 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6633 (~watchpoint, print_it_watchpoint, watch_command_1)
6634 (invalidate_bp_value_on_memory_change): Update.
6636 2018-04-06 Tom Tromey <tom@tromey.com>
6638 * varobj.c (varobj_clear_saved_item)
6639 (update_dynamic_varobj_children, install_new_value, ~varobj):
6641 * value.h (value_incref): Move declaration earlier.
6642 (value_decref): Rename from value_free.
6643 (struct value_ref_policy): New.
6644 (value_ref_ptr): New typedef.
6645 (struct value_deleter): Remove.
6646 (gdb_value_up): Remove typedef.
6647 (release_value): Change return type.
6648 (release_value_or_incref): Remove.
6649 * value.c (set_value_parent): Update.
6650 (value_incref): Change return type.
6651 (value_decref): Rename from value_free.
6652 (value_free_to_mark, free_all_values, free_value_chain): Update.
6653 (release_value): Return value_ref_ptr.
6654 (release_value_or_incref): Remove.
6655 (record_latest_value, set_internalvar, clear_internalvar):
6657 * stack.c (info_frame_command): Don't call value_free.
6658 * python/py-value.c (valpy_dealloc, valpy_new)
6659 (value_to_value_object): Update.
6660 * printcmd.c (do_examine): Update.
6661 * opencl-lang.c (lval_func_free_closure): Update.
6662 * mi/mi-main.c (register_changed_p): Don't call value_free.
6663 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
6664 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
6665 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
6667 * guile/scm-value.c (vlscm_free_value_smob)
6668 (vlscm_scm_from_value): Update.
6669 * frame.c (frame_register_unwind, frame_unwind_register_signed)
6670 (frame_unwind_register_unsigned, get_frame_register_bytes)
6671 (put_frame_register_bytes): Don't call value_free.
6672 * findvar.c (address_from_register): Don't call value_free.
6673 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
6674 * dwarf2loc.c (entry_data_value_free_closure)
6675 (value_of_dwarf_reg_entry, free_pieced_value_closure)
6676 (dwarf2_evaluate_loc_desc_full): Update.
6677 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6678 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6679 (~watchpoint, watch_command_1)
6680 (invalidate_bp_value_on_memory_change): Update.
6681 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
6683 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
6686 * warning.m4: Add -Wno-error=deprecated-register.
6687 * configure: Re-generate.
6689 2018-04-05 Tom Tromey <tom@tromey.com>
6691 * linespec.h: Remove include of "vec.h".
6693 2018-04-05 Tom Tromey <tom@tromey.com>
6695 * linespec.c (typep): Remove typedef.
6696 (find_methods, find_superclass_methods): Take a std::vector.
6697 (find_method): Use std::vector.
6699 2018-04-05 Tom Tromey <tom@tromey.com>
6701 * utils.c (compare_strings): Remove.
6702 * utils.h (compare_strings): Remove.
6703 * objc-lang.h (find_imps): Update.
6704 * objc-lang.c (find_methods): Take a std::vector.
6705 (uniquify_strings, find_imps): Likewise.
6706 * linespec.c (find_methods): Take a std::vector.
6707 (decode_objc): Use std::vector.
6708 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
6710 (find_method, find_function_symbols): Use std::vector.
6712 2018-04-05 Tom Tromey <tom@tromey.com>
6714 * completer.c (completion_tracker::completion_tracker): Remove
6716 (completion_tracker::discard_completions): Likewise.
6717 * breakpoint.c (ambiguous_names_p): Remove cast.
6718 * ada-lang.c (_initialize_ada_language): Remove cast.
6719 * utils.h (streq): Update.
6720 (streq_hash): Add new declaration.
6721 * utils.c (streq): Return bool.
6722 (streq_hash): New function.
6724 2018-04-05 Tom Tromey <tom@tromey.com>
6726 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
6727 Remove a string copy.
6729 2018-04-05 Tom Tromey <tom@tromey.com>
6731 * linespec.c (filter_results): Use std::vector.
6732 (decode_line_2, decode_line_full): Update.
6734 2018-04-05 Tom Tromey <tom@tromey.com>
6736 * linespec.c (canonical_to_fullform): Return std::string.
6737 (filter_results): Update.
6738 (struct decode_line_2_item): Add constructor.
6739 <fullform, displayform>: Now std::string.
6740 (decode_line_2_compare_items): Now a std::sort comparator.
6741 (decode_line_2): Update.
6743 2018-04-05 Tom Tromey <tom@tromey.com>
6745 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
6746 (unexpected_linespec_error): Update.
6747 (linespec_parse_basic, parse_linespec): Update.
6749 2018-04-05 Tom Tromey <tom@tromey.com>
6751 * linespec.c (linespec_parse_basic): Reindent.
6753 2018-04-05 Tom Tromey <tom@tromey.com>
6755 * minsyms.h (iterate_over_minimal_symbols): Update.
6756 * minsyms.c (iterate_over_minimal_symbols): Take a
6758 * linespec.c (struct collect_minsyms): Remove.
6759 (compare_msyms): Now a std::sort comparator.
6760 (add_minsym): Add parameters.
6761 (search_minsyms_for_name): Update. Use std::vector.
6763 2018-04-03 Tom Tromey <tom@tromey.com>
6765 * mipsread.c (read_alphacoff_dynamic_symtab): Use
6768 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
6770 * MAINTAINERS (Write After Approval): Add Weimin Pan.
6772 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
6775 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
6776 printing static type.
6778 2018-04-01 Tom Tromey <tom@tromey.com>
6780 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
6781 (rs6000_xfer_shared_libraries): Update.
6783 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
6785 * common/gdb_vecs.h (char_ptr): Remove.
6786 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
6788 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6790 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
6792 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
6794 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6796 * tracepoint.h (struct uploaded_tp): Initialize fields.
6797 <actions, step_actions, cmd_strings>: Change type to
6798 std::vector<char *>.
6799 * tracepoint.c (get_uploaded_tp): Allocate with new.
6800 (free_uploaded_tps): Free with delete.
6801 (parse_tracepoint_definition): Adjust to std::vector change.
6802 * breakpoint.c (read_uploaded_action): Likewise.
6803 (create_tracepoint_from_upload): Likewise.
6804 * ctf.c (ctf_write_uploaded_tp): Likewise.
6805 (SET_ARRAY_FIELD): Likewise.
6806 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
6808 2018-03-30 Tom Tromey <tom@tromey.com>
6810 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
6812 (svr4_keep_data_in_core): Update.
6813 (svr4_read_so_list): Update.
6815 2018-03-30 Tom Tromey <tom@tromey.com>
6817 * windows-nat.c (handle_output_debug_string, handle_exception):
6819 * target.h (target_read_string): Update.
6820 * target.c (target_read_string): Change "string" to
6822 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
6824 * solib-frv.c (frv_current_sos): Update.
6825 * solib-dsbt.c (dsbt_current_sos): Update.
6826 * solib-darwin.c (darwin_current_sos): Update.
6827 * linux-thread-db.c (inferior_has_bug): Update.
6828 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
6829 Update. Remove alloca.
6830 * ada-lang.c (ada_main_name): Update.
6832 2018-03-30 Tom Tromey <tom@tromey.com>
6834 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
6835 (struct dwo_file_deleter): New.
6836 (dwo_file_up): New typedef.
6837 (open_and_init_dwo_file): Use dwo_file_up.
6838 (free_dwo_file_cleanup): Remove.
6840 2018-03-30 Tom Tromey <tom@tromey.com>
6842 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
6843 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
6845 2018-03-30 Tom Tromey <tom@tromey.com>
6847 * dwarf2read.c (class free_cached_comp_units): New class.
6848 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
6849 (free_cached_comp_units): Remove function.
6851 2018-03-30 Tom Tromey <tom@tromey.com>
6853 * utils.h (make_cleanup_unpush_target): Remove.
6854 * inf-ptrace.c (struct target_unpusher): New.
6855 (target_unpush_up) New typedef.
6856 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
6858 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
6860 2018-03-27 Tom Tromey <tom@tromey.com>
6862 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
6864 2018-03-27 Pedro Alves <palves@redhat.com>
6865 Tom Tromey <tom@tromey.com>
6867 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
6868 destructor. Now a class.
6869 (gdb_readline_wrapper_cleanup): Remove function.
6870 (gdb_readline_wrapper): Remove cleanups.
6872 2018-03-27 Tom Tromey <tom@tromey.com>
6874 * typeprint.h (struct type_print_options) <local_typedefs,
6875 global_typedefs>: Remove "struct" keyword.
6876 (class typedef_hash_table): New class.
6877 (recursively_update_typedef_hash, add_template_parameters)
6878 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
6879 (find_typedef_in_hash): Don't declare.
6880 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
6881 (typedef_hash_table::recursively_update): Rename from
6882 recursively_update_typedef_hash. Now a member.
6883 (typedef_hash_table::add_template_parameters): Rename from
6884 add_template_parameters. Now a member.
6885 (typedef_hash_table::typedef_hash_table): Now a constructor;
6886 rename from create_typedef_hash.
6887 (typedef_hash_table::~typedef_hash_table): Now a destructor;
6888 rename from free_typedef_hash.
6889 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
6890 (do_free_global_table): Remove.
6891 (typedef_hash_table::typedef_hash_table): New constructor; renamed
6892 from copy_type_recursive.
6893 (create_global_typedef_table): Remove.
6894 (typedef_hash_table::find_global_typedef): Now a member of
6896 (typedef_hash_table::find_typedef): Rename from
6897 find_typedef_in_hash; now a member.
6898 (whatis_exp): Update.
6899 * extension.h (struct ext_lang_type_printers): Add constructor and
6901 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
6903 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
6904 Now a constructor; rename from start_ext_lang_type_printers.
6905 (ext_lang_type_printers): Now a destructor; rename from
6906 free_ext_lang_type_printers.
6907 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
6909 (c_type_print_base_struct_union): Update. Remove cleanups.
6911 2018-03-27 Tom Tromey <tom@tromey.com>
6913 * dwarf-index-write.c: Include <cmath>.
6915 2018-03-27 Joel Brobecker <brobecker@adacore.com>
6917 * NEWS: Add entry describing new "set|show varsize-limit" command.
6918 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
6920 * printcmd.c (_initialize_printcmd): Add "set var" alias of
6923 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
6925 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
6927 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
6928 * dwarf-index-common.c: New file.
6929 * dwarf-index-common.h: New file.
6930 * dwarf-index-write.c: New file.
6931 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
6932 (struct dwarf2_section_info): Move from here.
6933 (dwarf2_section_info_def): Likewise.
6934 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
6935 (offset_type): Likewise.
6936 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
6937 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
6938 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
6939 (byte_swap): Likewise.
6940 (MAYBE_SWAP): Likewise.
6941 (dwarf2_per_cu_ptr): Likewise.
6942 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
6943 (struct tu_stats): Likewise.
6944 (struct dwarf2_per_objfile): Likewise.
6945 (struct dwarf2_per_cu_data): Likewise.
6946 (struct signatured_type): Likewise.
6947 (sig_type_ptr): Likewise.
6948 (DEF_VEC_P (sig_type_ptr)): Likewise.
6949 (INDEX4_SUFFIX): Likewise.
6950 (INDEX5_SUFFIX): Likewise.
6951 (DEBUG_STR_SUFFIX): Likewise.
6952 (dwarf2_read_section): Make non-static.
6953 (mapped_index_string_hash): Move from here.
6954 (dwarf5_djb_hash): Likewise.
6955 (file_write): Likewise.
6956 (class data_buf): Likewise.
6957 (struct symtab_index_entry): Likewise.
6958 (struct mapped_symtab): Likewise.
6959 (find_slot): Likewise.
6960 (hash_expand): Likewise.
6961 (add_index_entry): Likewise.
6962 (uniquify_cu_indices): Likewise.
6963 (class c_str_view): Likewise.
6964 (class c_str_view_hasher): Likewise.
6965 (class vector_hasher): Likewise.
6966 (write_hash_table): Likewise.
6967 (psym_index_map): Likewise.
6968 (struct addrmap_index_data): Likewise.
6969 (add_address_entry): Likewise.
6970 (add_address_entry_worker): Likewise.
6971 (write_address_map): Likewise.
6972 (symbol_kind): Likewise.
6973 (write_psymbols): Likewise.
6974 (struct signatured_type_index_data): Likewise.
6975 (write_one_signatured_type): Likewise.
6976 (recursively_count_psymbols): Likewise.
6977 (recursively_write_psymbols): Likewise.
6978 (class debug_names): Likewise.
6979 (check_dwarf64_offsets): Likewise.
6980 (psyms_seen_size): Likewise.
6981 (write_gdbindex): Likewise.
6982 (write_debug_names): Likewise.
6983 (assert_file_size): Likewise.
6984 (write_psymtabs_to_index): Likewise.
6985 (save_gdb_index_command): Likewise.
6986 (_initialize_dwarf2_read): Don't register the "save gdb-index"
6988 * dwarf2read.h: New file.
6990 2018-03-27 Joel Brobecker <brobecker@adacore.com>
6993 * dwarf2read.c (dwarf2_physname): Do not return the demangled
6994 symbol name if the CU's language stores symbol names in linkage
6996 * language.h (struct language_defn)
6997 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
6998 all instances of this struct.
7000 2018-03-26 Tom Tromey <tom@tromey.com>
7002 * stack.c (backtrace_command_1): Remove verbose code.
7004 2018-03-26 Tom Tromey <tom@tromey.com>
7006 * python/py-framefilter.c (py_print_type): Don't catch
7007 exceptions. Return void.
7008 (py_print_value): Likewise.
7009 (py_print_single_arg): Likewise.
7010 (enumerate_args): Don't catch exceptions.
7011 (py_print_args): Likewise.
7012 (py_print_frame): Likewise.
7013 (gdbpy_apply_frame_filter): Catch exceptions here.
7015 2018-03-26 Tom Tromey <tom@tromey.com>
7017 * stack.c (_initialize_stack): Remove trailing newlines from help
7018 text. Add "Usage" line to "backtrace" help.
7020 2018-03-26 Tom Tromey <tom@tromey.com>
7023 * python/py-framefilter.c (py_print_args): Call wrap_hint.
7025 2018-03-26 Tom Tromey <tom@tromey.com>
7027 * python/py-framefilter.c (py_print_single_arg): Return
7028 EXT_LANG_BT_ERROR from catch.
7030 2018-03-26 Tom Tromey <tom@tromey.com>
7033 * stack.c (backtrace_command_1): Move some code into no-filters
7036 2018-03-26 Tom Tromey <tom@tromey.com>
7038 * python/py-framefilter.c (throw_quit_or_print_exception): New
7040 (gdbpy_apply_frame_filter): Use it.
7042 2018-03-26 Tom Tromey <tom@tromey.com>
7045 * python/py-framefilter.c (py_print_type, py_print_value)
7046 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
7049 2018-03-26 Tom Tromey <tom@tromey.com>
7051 * python/py-framefilter.c (enumerate_args): Use
7052 gdb::unique_xmalloc_ptr.
7054 2018-03-26 Tom Tromey <tom@tromey.com>
7056 * python/py-framefilter.c (py_print_frame): Return
7058 (gdbpy_apply_frame_filter): Update comment.
7059 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
7061 <EXT_LANG_BT_NO_FILTERS>: Change value.
7063 2018-03-26 Tom Tromey <tom@tromey.com>
7066 * stack.c (backtrace_command): Parse "hide" argument.
7067 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
7068 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
7071 2018-03-26 Tom Tromey <tom@tromey.com>
7073 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
7075 (backtrace_command): Remove "fulltrace", add "flags".
7077 2018-03-26 Tom Tromey <tom@tromey.com>
7079 * stack.c (backtrace_command): Rewrite command line parsing.
7081 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7083 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
7085 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7087 * filename-seen-cache.h: Add include guard.
7089 2018-03-26 Keith Seitz <keiths@redhat.com>
7091 * symfile.c (place_section): Remove "struct" from section_addr_info
7093 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
7094 "struct" keyword from section_addr_info.
7096 2018-03-26 Alan Hayward <alan.hayward@arm.com>
7098 * regformats/regdef.h (reg): Add constructors.
7100 2018-03-25 Pedro Alves <palves@redhat.com>
7102 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
7103 if then/else bodies in var_func_name extraction.
7105 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
7107 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
7108 lookup_minimal_symbol() to find symbol entry.
7109 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
7111 2018-03-23 Keith Seitz <keiths@redhat.com>
7114 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
7115 nested type definitions for C++, too.
7117 2018-03-23 Tom Tromey <tom@tromey.com>
7119 * machoread.c (struct oso_el): Add a constructor. Don't define as
7121 (macho_register_oso): Remove.
7122 (macho_symtab_read): Take a std::vector.
7123 (oso_el_compare_name): Now a std::sort comparator.
7124 (macho_symfile_read_all_oso): Take a std::vector.
7125 (macho_symfile_read): Use std::vector. Remove cleanups.
7127 2018-03-22 Tom Tromey <tom@tromey.com>
7129 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
7130 (record_full_goto_bookmark): Use std::string.
7132 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7135 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
7138 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7140 * rs6000-tdep.c (store_insn_p): New function.
7141 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
7142 and cr_reg to their unshifted values. Use store_insn_p to
7143 match LR saves using either R1 or fdata->alloca_reg. Use
7144 store_insn_p to match CR saves. Set alloca_reg_offset
7145 when alloca_reg and framep are set. Remove lr_reg shift
7146 when assigning to fdata->lr_register.
7148 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
7150 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
7151 command line args instead of emitting a warning.
7153 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7155 * tracepoint.h (struct static_tracepoint_marker): Initialize
7156 fields, define default constructor, move constructor and move
7157 assignment, disable the rest.
7158 <str_id, extra>: Make std::string.
7159 (release_static_tracepoint_marker): Remove.
7160 (free_current_marker): Remove.
7161 * tracepoint.c (free_current_marker): Remove.
7162 (parse_static_tracepoint_marker_definition): Adjust to
7163 std::string, use new hex2str overload.
7164 (release_static_tracepoint_marker): Remove.
7165 (print_one_static_tracepoint_marker): Get marker by reference
7166 and adjust to std::string.
7167 (info_static_tracepoint_markers_command): Adjust to std::vector
7169 * target.h (static_tracepoint_marker_p): Remove typedef.
7170 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
7171 (struct target_ops) <to_static_tracepoint_marker_at>: Return
7173 <to_static_tracepoint_markers_by_strid>: Return std::vector.
7175 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
7176 (target_debug_print_std_vector_static_tracepoint_marker): New.
7177 (target_debug_print_struct_static_tracepoint_marker_p): Rename
7179 (target_debug_print_static_tracepoint_marker_p): ... this.
7180 * target-delegates.c: Re-generate.
7181 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
7183 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
7184 (decode_static_tracepoint_spec): Adjust to std::vector.
7185 (tracepoint_print_one_detail): Adjust to std::string.
7186 (strace_marker_decode_location): Adjust to std::string.
7187 (update_static_tracepoint): Adjust to std::string, remove call
7188 to release_static_tracepoint_marker.
7189 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
7190 Adjust to std::vector.
7191 * remote.c (remote_static_tracepoint_marker_at): Return bool.
7192 (remote_static_tracepoint_markers_by_strid): Adjust to
7194 * common/rsp-low.h (hex2str): New overload with explicit count
7196 * common/rsp-low.c (hex2str): New overload with explicit count
7198 * unittests/rsp-low-selftests.c (test_hex2str): New function.
7199 (_initialize_rsp_low_selftests): Add test_hex2str test.
7200 * unittests/tracepoint-selftests.c
7201 (test_parse_static_tracepoint_marker_definition): Adjust to
7204 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7206 * tracepoint.c (parse_static_tracepoint_marker_definition):
7207 Consider case where the definition is followed by more
7209 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7210 tracepoint-selftests.c.
7211 * unittests/tracepoint-selftests.c: New.
7213 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7215 * MAINTAINERS (Write After Approval): Add Pedro Franco de
7218 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7220 * symtab.c (find_pc_sect_line): fixed indentation.
7222 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7224 * symtab.c (find_pc_sect_line): now uses binary search.
7226 2018-03-19 Tom Tromey <tom@tromey.com>
7228 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
7231 2018-03-19 Pedro Alves <palves@redhat.com>
7232 Tom Tromey <tom@tromey.com>
7234 * unittests/observable-selftests.c: New file.
7235 * common/observable.h: New file.
7236 * observable.h: New file.
7237 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
7238 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
7239 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
7240 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
7241 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
7242 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
7243 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
7244 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
7245 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
7246 python/py-breakpoint.c, python/py-finishbreakpoint.c,
7247 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
7248 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
7249 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
7250 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
7251 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
7252 tui/tui-interp.c, valops.c: Update all users.
7253 * tui/tui-hooks.c (tui_bp_created_observer)
7254 (tui_bp_deleted_observer, tui_bp_modified_observer)
7255 (tui_inferior_exit_observer, tui_before_prompt_observer)
7256 (tui_normal_stop_observer, tui_register_changed_observer):
7258 (tui_observers_token): New global.
7259 (attach_or_detach, tui_attach_detach_observers): New functions.
7260 (tui_install_hooks, tui_remove_hooks): Use
7261 tui_attach_detach_observers.
7262 * record-btrace.c (record_btrace_thread_observer): Remove.
7263 (record_btrace_thread_observer_token): New global.
7264 * observer.sh: Remove.
7265 * observer.c: Rename to observable.c.
7266 * observable.c (namespace gdb_observers): Define new objects.
7267 (observer_debug): Move into gdb_observers namespace.
7268 (struct observer, struct observer_list, xalloc_observer_list_node)
7269 (xfree_observer_list_node, generic_observer_attach)
7270 (generic_observer_detach, generic_observer_notify): Remove.
7271 (_initialize_observer): Update.
7272 Don't include observer.inc.
7273 * Makefile.in (generated_files): Remove observer.h, observer.inc.
7274 (clean mostlyclean): Likewise.
7275 (observer.h, observer.inc): Remove targets.
7276 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
7277 (COMMON_SFILES): Use observable.c, not observer.c.
7278 * .gitignore: Remove observer.h.
7280 2018-03-18 Tom Tromey <tom@tromey.com>
7282 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
7284 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
7286 2018-03-17 Tom Tromey <tom@tromey.com>
7288 * auto-load.c (auto_load_objfile_script_1): Use std::string.
7290 2018-03-17 Tom Tromey <tom@tromey.com>
7292 * target.c (class scoped_target_fd): New.
7293 (target_fileio_close_cleanup): Remove.
7294 (target_fileio_read_alloc_1): Use scoped_target_fd.
7296 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
7298 * silent-rules.mk: New.
7299 * Makefile.in: Include silent-rules.mk
7300 (srcdir, VPATH, top_srcdir): Move up.
7301 (COMPILE): Add ECHO_CXX.
7302 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
7303 (init.c): Add ECHO_INIT_C.
7304 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
7305 (version.c): Add ECHO_GEN.
7306 (printcmd.o): Add ECHO_CXX.
7307 (target-float.o): Add ECHO_CXX.
7308 (ada-exp.o): Add ECHO_CXX.
7309 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
7310 (insight$(EXEEXT)): Add ECHO_CXXLD.
7311 * gnulib/configure.ac: Add AM_SILENT_RULES.
7312 * gnulib/aclocal.m4: Re-generate.
7313 * gnulib/configure: Re-generate.
7314 * gnulib/import/Makefile.in: Re-generate.
7316 2018-03-16 Tom Tromey <tom@tromey.com>
7318 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
7319 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
7320 * utils.c (do_free_section_addr_info)
7321 (make_cleanup_free_section_addr_info): Remove.
7322 * symfile.h (struct other_sections): Add constructor.
7323 (struct section_addr_info): Remove.
7324 (section_addr_info): New typedef.
7325 (struct sym_fns) <sym_offsets>: Change type of parameter.
7326 (build_section_addr_info_from_objfile)
7327 (relative_addr_info_to_section_offsets, addr_info_make_relative)
7328 (default_symfile_offsets, symbol_file_add)
7329 (symbol_file_add_from_bfd)
7330 (build_section_addr_info_from_section_table): Update.
7331 (alloc_section_addr_info, free_section_addr_info): Don't declare.
7332 * symfile.c (alloc_section_addr_info): Remove.
7333 (build_section_addr_info_from_section_table): Change return type.
7335 (build_section_addr_info_from_bfd)
7336 (build_section_addr_info_from_objfile): Likewise.
7337 (free_section_addr_info): Remove.
7338 (relative_addr_info_to_section_offsets): Change type of "addrs".
7339 (addrs_section_compar): Now a std::sort comparator.
7340 (addrs_section_sort): Change return type.
7341 (addr_info_make_relative): Change type of "addrs". Update.
7342 (default_symfile_offsets, syms_from_objfile_1)
7343 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
7344 (symbol_file_add_separate): Update.
7345 (symbol_file_add): Change type of "addrs". Update.
7346 (add_symbol_file_command): Update. Remove cleanups.
7347 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
7349 * symfile-debug.c (debug_sym_offsets): Change type of "info".
7350 * solib.c (solib_read_symbols): Update.
7351 * objfiles.c (objfile_relocate): Update. Remove cleanups.
7352 * machoread.c (macho_symfile_offsets): Update.
7353 * jit.c (jit_bfd_try_read_symtab): Update.
7355 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
7357 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7358 unittests/utils-selftests.c.
7359 * unittests/utils-selftests.c: New file.
7361 2018-03-14 Tom Tromey <tom@tromey.com>
7364 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
7367 2018-03-14 Tom Tromey <tom@tromey.com>
7370 * printcmd.c (printf_pointer): Allow "-" in format.
7372 2018-03-14 Tom Tromey <tom@tromey.com>
7374 * printcmd.c (_initialize_printcmd): Add usage to printf.
7376 2018-03-14 Yao Qi <qiyao@sourceware.org>
7378 * MAINTAINERS: Update my email address.
7380 2018-03-13 Tom Tromey <tom@tromey.com>
7382 * machoread.c (macho_check_dsym): Change filenamep to a
7384 (macho_symfile_read): Update.
7385 * symfile.c (load_command): Use std::string.
7387 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
7389 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
7390 to error message string.
7391 (riscv_register_name): Use xsnprintf instead of sprintf.
7392 (riscv_insn::fetch_instruction): Use gdb_assert instead of
7394 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
7396 (riscv_push_dummy_call): Likewise.
7398 2018-03-12 Tom Tromey <tom@tromey.com>
7400 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
7401 Use gdb::byte_vector.
7402 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
7404 2018-03-12 Yao Qi <yao.qi@linaro.org>
7406 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
7407 parameter type to readable_regcache.
7408 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
7411 2018-03-11 Tom Tromey <tom@tromey.com>
7413 * dwarf2read.c (struct nextfield): Add initializers.
7414 (struct nextfnfield): Remove.
7415 (struct fnfieldlist): Add initializers. Remove "length" and
7416 "head", use std::vector.
7417 (struct decl_field_list): Remove.
7418 (struct field_info): Add initializers.
7419 <fields, baseclasses>: Now std::vector.
7420 <nbaseclasses, nfnfields, typedef_field_list_count,
7421 nested_types_list_count>: Remove.
7422 (dwarf2_add_field, dwarf2_add_type_defn)
7423 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
7424 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
7425 (process_structure_scope): Update.
7427 2018-03-11 Tom Tromey <tom@tromey.com>
7429 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
7430 for use by std::sort.
7431 (build_type_psymtabs_1): Use std::vector.
7433 2018-03-09 Eli Zaretskii <eliz@gnu.org>
7435 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
7436 and LIBMPFR in the printed configuration.
7438 2018-03-08 Tom Tromey <tom@tromey.com>
7440 * source.c (get_filename_and_charpos): Use scoped_fd.
7441 * nto-procfs.c (procfs_open_1): Use scoped_fd.
7442 (procfs_pidlist): Likewise.
7443 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
7444 (iterate_over_mappings): Likewise.
7446 2018-03-08 Tom Tromey <tom@tromey.com>
7448 * infcall.c (struct call_return_meta_info)
7449 <stack_temporaries_enabled>: Remove.
7450 (get_call_return_value, call_function_by_hand_dummy): Update.
7451 * thread.c (disable_thread_stack_temporaries): Remove.
7452 (enable_thread_stack_temporaries): Remove.
7453 (thread_stack_temporaries_enabled_p): Return bool.
7454 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
7455 (get_last_thread_stack_temporary): Update.
7456 * eval.c (evaluate_subexp): Update.
7457 * gdbthread.h (class enable_thread_stack_temporaries): Now a
7458 class, not a function.
7459 (value_ptr, value_vec): Remove typedefs.
7460 (class thread_info) <stack_temporaries_enabled>: Now bool.
7461 <stack_temporaries>: Now a std::vector.
7462 (thread_stack_temporaries_enabled_p)
7463 (value_in_thread_stack_temporaries): Return bool.
7465 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
7467 * remote.c (putpkt_binary): Fix omitted bytes reporting.
7468 (getpkt_or_notif_sane_1): Likewise.
7470 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7472 * build-id.c (build_id_to_debug_bfd): Use std::string.
7474 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7476 * build-id.c (find_separate_debug_file_by_buildid): Return
7478 * build-id.h (find_separate_debug_file_by_buildid): Return
7480 * coffread.c (coff_symfile_read): Adjust to std::string.
7481 * elfread.c (elf_symfile_read): Adjust to std::string.
7482 * symfile.c (separate_debug_file_exists): Change parameter to
7484 (find_separate_debug_file): Return std::string.
7485 (find_separate_debug_file_by_debuglink): Return std::string.
7486 * symfile.h (find_separate_debug_file_by_debuglink): Return
7489 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7491 * common/xml-utils.c (xml_escape_text): Move code to...
7492 (xml_escape_text_append): ... this new function.
7493 * common/xml-utils.h (xml_escape_text_append): New declaration.
7494 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
7496 (_initialize_xml_utils): register test_xml_escape_text_append as
7499 2018-03-07 Alan Hayward <alan.hayward@arm.com>
7501 * defs.h: Remove MAX_REGISTER_SIZE.
7502 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
7504 * python/py-unwind.c (pyuw_sniffer): Likewise.
7506 2018-03-07 Tom Tromey <tom@tromey.com>
7508 * linux-tdep.c (linux_info_proc): Update.
7509 * target.h (struct target_ops) <to_fileio_readlink>: Return
7511 (target_fileio_readlink): Return optional<string>.
7512 * remote.c (remote_hostio_readlink): Return optional<string>.
7513 * inf-child.c (inf_child_fileio_readlink): Return
7515 * target.c (target_fileio_readlink): Return optional<string>.
7517 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
7519 * regcache.c (cooked_read_test): Add riscv to the list of
7520 architectures that have a save_reggroup.
7522 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
7524 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
7525 value is not a dynamic class object.
7527 2018-03-06 Tom Tromey <tom@tromey.com>
7529 * rust-exp.y: Formatting fixes.
7531 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7533 * riscv-tdep.c (riscv_register_name): Remove target description
7535 (riscv_gdbarch_init): Remove target description check.
7537 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7539 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
7541 * riscv-tdep.h: Likewise.
7543 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7545 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
7546 (riscv_pseudo_register_write): Delete.
7547 (riscv_gdbarch_init): Remove all use of pseudo registers.
7549 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7551 * record-btrace.c (btrace_print_lines): Replace cleanup
7552 parameter with RAII equivalents.
7553 (btrace_insn_history): Replace cleanup with RAII equivalents.
7554 * ui-out.h (make_cleanup_ui_out_list_begin_end,
7555 make_cleanup_ui_out_tuple_begin_end): Remove.
7556 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
7557 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
7558 make_cleanup_ui_out_list_begin_end): Remove.
7560 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7562 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
7563 parameter types to std::vector. Use bool.
7564 (record_btrace_wait): Replace VEC(tp_t) with
7565 std::vector<thread_info *>.
7566 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
7568 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7570 * record-btrace.c (record_btrace_disable_callback): Remove.
7571 (struct scoped_btrace_disable): New.
7572 (record_btrace_open): Use scoped_btrace_disable.
7574 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7576 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
7577 reading values from registers.
7579 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7581 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
7584 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7586 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
7587 change parameter type. Use GDB's print functions, and use
7588 core_addr_to_string where appropriate.
7589 (riscv_push_dummy_call): Use core_addr_to_string where
7590 appropriate, update call to riscv_print_arg_location, and reindent
7592 (riscv_return_value): Update call to riscv_print_arg_location.
7594 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7595 Tim Newsome <tim@sifive.com>
7596 Albert Ou <a0u@eecs.berkeley.edu>
7597 Darius Rad <darius@bluespec.com>
7599 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
7600 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
7601 (ALLDEPFILES): Add riscv-tdep.c
7602 * configure.tgt: Add riscv support.
7603 * riscv-tdep.c: New file.
7604 * riscv-tdep.h: New file.
7605 * NEWS: Mention new target.
7606 * MAINTAINERS: Add entry for riscv.
7608 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7610 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
7611 fields within aggregates.
7613 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
7615 * record-btrace.c (btrace_print_lines): Change type of flags to
7616 gdb_disassembly_flags.
7618 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7620 * fbsd-nat.c: Include "inf-ptrace.h".
7621 (USE_SIGTRAP_SIGINFO): Conditionally define.
7622 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
7623 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
7624 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
7626 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
7628 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
7630 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
7631 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
7632 "supports_stopped_by_hw_breakpoint" target methods.
7634 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7636 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
7637 * fbsd-nat.c (debug_fbsd_nat): New variable.
7638 (show_fbsd_nat_debug): New function.
7639 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
7640 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
7642 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7644 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
7645 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
7647 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
7648 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
7651 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7653 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
7654 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
7656 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7658 * charset.c (struct charset_vector): New.
7659 (charsets): Change type to charset_vector.
7660 (find_charset_names): Adjust.
7662 (_initialize_charset): Adjust.
7664 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7666 * progspace.h (struct program_space) <deleted_solibs>: Change
7667 type to std::vector<std::string>.
7668 * progspace.c (clear_program_space_solib_cache): Adjust.
7669 * breakpoint.c (print_solib_event): Adjust.
7670 (check_status_catch_solib): Adjust.
7671 * solib.c (update_solib_list): Adjust.
7672 * ui-out.h (class ui_out) <field_string>: New overload.
7673 * ui-out.c (ui_out::field_string): New overload.
7675 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7677 * progspace.h (struct program_space): Add constructor and
7678 destructor, initialize fields.
7679 (add_program_space): Remove.
7680 * progspace.c (add_program_space): Rename to...
7681 (program_space::program_space): ... this.
7682 (release_program_space): Rename to...
7683 (program_space::~program_space): ... this.
7684 (delete_program_space): Use delete to delete program_space.
7685 (initialize_progspace): Use new to allocate program_space.
7686 * inferior.c (add_inferior_with_spaces): Likewise.
7687 (clone_inferior_command): Likewise.
7688 * infrun.c (follow_fork_inferior): Likewise.
7689 (handle_vfork_child_exec_or_exit): Likewise.
7691 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7693 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
7694 (delim_string_to_char_ptr_vec): Return std::vector of
7695 gdb::unique_xmalloc_ptr.
7696 (dirnames_to_char_ptr_vec_append): Take std::vector of
7697 gdb::unique_xmalloc_ptr.
7698 (dirnames_to_char_ptr_vec): Return std::vector of
7699 gdb::unique_xmalloc_ptr.
7700 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
7701 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
7702 (delim_string_to_char_ptr_vec): Return an std::vector of
7703 gdb::unique_xmalloc_ptr, adjust the code.
7704 (dirnames_to_char_ptr_vec_append): Take an std::vector of
7705 gdb::unique_xmalloc_ptr, adjust the code.
7706 (dirnames_to_char_ptr_vec): Return an std::vector of
7707 gdb::unique_xmalloc_ptr, adjust the code.
7708 * auto-load.c (auto_load_safe_path_vec): Change type to
7709 std::vector of gdb::unique_xmalloc_ptr.
7710 (auto_load_expand_dir_vars): Return an std::vector of
7711 gdb::unique_xmalloc_ptr, adjust the code.
7712 (auto_load_safe_path_vec_update): Adjust.
7713 (filename_is_in_auto_load_safe_path_vec): Adjust.
7714 (auto_load_objfile_script_1): Adjust.
7715 * build-id.c (build_id_to_debug_bfd): Adjust.
7716 * linux-thread-db.c (thread_db_load_search): Adjust.
7717 * source.c (add_path): Adjust.
7719 * symfile.c (find_separate_debug_file): Adjust.
7720 * utils.c (do_free_char_ptr_vec): Remove.
7721 (make_cleanup_free_char_ptr_vec): Remove.
7723 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
7726 * common/pathstuff.c: Conditionally include "<windows.h>".
7728 2018-03-01 Georg Sauthoff <mail@georg.so>
7731 * gcore.in: Quote variables and switch interpreter to bash.
7733 2018-03-01 Tom Tromey <tom@tromey.com>
7735 * dwarf2read.c (alloc_discriminant_info): Fix default_index
7736 assertion. Add assertion for discriminant_index.
7737 (quirk_rust_enum): Use correct base type name in univariant case.
7739 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
7741 * record.c (get_call_history_modifiers): Return a
7743 (cmd_record_call_history): Adjust.
7744 * record-btrace.c (record_btrace_call_history): Adjust.
7745 (record_btrace_call_history_range): Adjust.
7746 (record_btrace_call_history_from): Adjust.
7747 * target-debug.h (target_debug_print_record_print_flags): New.
7748 * target-delegates.c: Re-generate.
7749 * target.c (target_call_history): Change flags type.
7750 (target_call_history_from): Likewise.
7751 (target_call_history_range): Likewise.
7752 * target.h (struct target_ops) <target_call_history>: Likewise.
7753 (target_call_history_from): Likewise.
7754 (target_call_history_range): Likewise.
7756 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7757 Simon Marchi <simon.marchi@polymtl.ca>
7759 * common/common-utils.c: Include "sys/stat.h".
7760 (is_regular_file): Move here from "source.c"; change return
7762 * common/common-utils.h (is_regular_file): New prototype.
7763 * common/pathstuff.c (contains_dir_separator): New function.
7764 * common/pathstuff.h (contains_dir_separator): New prototype.
7765 * source.c: Don't include "sys/stat.h".
7766 (is_regular_file): Move to "common/common-utils.c".
7768 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7770 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
7771 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
7772 * auto-load.c: Include "common/pathstuff.h".
7773 * common/common-def.h (current_directory): Move here.
7774 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
7776 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
7778 * common/pathstuff.c: New file.
7779 * common/pathstuff.h: New file.
7780 * compile/compile.c: Include "common/pathstuff.h".
7781 * defs.h (current_directory): Move to "common/common-defs.h".
7782 * dwarf2read.c: Include "common/pathstuff.h".
7784 * guile/scm-safe-call.c: Likewise.
7785 * linux-thread-db.c: Likewise.
7787 * nto-tdep.c: Likewise.
7788 * objfiles.c: Likewise.
7789 * source.c: Likewise.
7790 * symtab.c: Likewise.
7791 * utils.c: Include "common/pathstuff.h".
7792 (gdb_realpath): Move to "common/pathstuff.c".
7793 (gdb_realpath_keepfile): Likewise.
7794 (gdb_abspath): Likewise.
7795 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
7796 (gdb_realpath_keepfile): Likewise.
7797 (gdb_abspath): Likewise.
7799 2018-02-28 John Baldwin <jhb@FreeBSD.org>
7801 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
7802 wildcard process pid for super_resume for kernels with a
7805 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
7807 * compile/compile.c (get_args): Add additional comments
7808 explaining function.
7810 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
7811 Tom Tromey <tom@tromey.com>
7813 * target.h (memory_write_request_s): Remove typedef. Don't define
7815 (target_write_memory_blocks): Change argument to std::vector.
7816 (struct memory_write_request): Add constructor.
7817 * target-memory.c (compare_block_starting_address): Return bool.
7818 Change argument types.
7819 (claim_memory): Change arguments to use std::vector.
7820 (split_regular_and_flash_blocks, blocks_to_erase)
7821 (compute_garbled_blocks): Likewise.
7822 (cleanup_request_data, cleanup_write_requests_vector): Remove.
7823 (target_write_memory_blocks): Change argument to std::vector.
7824 * symfile.c (struct load_section_data): Add constructor and
7825 destructor. Use std::vector for "requests".
7826 (struct load_progress_data): Add initializers.
7827 (load_section_callback): Update. Use "new".
7828 (clear_memory_write_data): Remove.
7829 (generic_load): Update.
7831 2018-02-27 Alan Hayward <alan.hayward@arm.com>
7833 * arch/aarch64.h: Use common/tdesc.h.
7835 2018-02-26 Maciej W. Rozycki <macro@mips.com>
7837 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
7838 architecture with a 64-bit ABI.
7840 2018-02-26 Maciej W. Rozycki <macro@mips.com>
7842 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
7843 ahead of target description loading.
7845 2018-02-26 Tom Tromey <tom@tromey.com>
7847 * stack.c (backtrace_command_1): Update.
7848 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
7850 * python/py-framefilter.c (py_print_frame)
7851 (gdbpy_apply_frame_filter): Change type of "flags".
7852 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
7854 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
7855 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
7856 * extension.h (enum frame_filter_flag): Rename from
7858 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
7859 (apply_ext_lang_frame_filter): Change type of "flags".
7860 * extension.c (apply_ext_lang_frame_filter): Change type of
7862 * extension-priv.h (struct extension_language_ops)
7863 <apply_frame_filter>: Change type of "flags".
7865 2018-02-26 Tom Tromey <tom@tromey.com>
7868 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
7869 off-by-one in py_end computation.
7870 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
7872 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
7875 2018-02-26 Tom Tromey <tom@tromey.com>
7877 * dwarf2read.c (struct variant_field): New.
7878 (struct nextfield) <variant>: New field.
7879 (dwarf2_add_field): Handle DW_TAG_variant_part.
7880 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
7881 discriminated union.
7882 (read_structure_type): Handle DW_TAG_variant_part.
7883 (handle_struct_member_die): New function, extracted from
7884 process_structure_scope. Handle DW_TAG_variant.
7885 (process_structure_scope): Handle discriminated unions. Call
7886 handle_struct_member_die.
7888 2018-02-26 Tom Tromey <tom@tromey.com>
7890 * rust-lang.h (rust_last_path_segment): Declare.
7891 * rust-lang.c (rust_last_path_segment): Now public. Change
7893 (struct disr_info): Remove.
7894 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
7895 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
7896 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
7897 (rust_enum_p, rust_enum_variant): New function.
7898 (rust_underscore_fields): Remove "offset" parameter.
7899 (rust_print_enum): New function.
7900 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
7901 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
7902 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
7904 (rust_internal_print_type): New function, from rust_print_type.
7906 (rust_print_type): Call rust_internal_print_type.
7907 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
7908 Update enum handling.
7909 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
7910 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
7911 (rust_union_quirks): New functions.
7912 (process_full_comp_unit, process_full_type_unit): Call
7914 (process_structure_scope): Update rust_unions if necessary.
7916 2018-02-26 Tom Tromey <tom@tromey.com>
7918 * value.h (value_union_variant): Declare.
7919 * valops.c (value_union_variant): New function.
7920 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
7921 (struct discriminant_info): New.
7922 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
7924 (struct main_type) <flag_discriminated_union>: New field.
7926 2018-02-26 Tom Tromey <tom@tromey.com>
7928 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7929 unittests/unpack-selftests.c.
7930 * unittests/unpack-selftests.c: New file.
7931 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
7933 2018-02-26 Yao Qi <yao.qi@linaro.org>
7935 * dwarf2read.c (struct partial_die_info) <read>: New method.
7936 (read_partial_die): Remove the declaration.
7937 (load_partial_dies): Update.
7938 (partial_die_info::partial_die_info):
7939 (read_partial_die): Change it to partial_die_info::read.
7941 2018-02-26 Yao Qi <yao.qi@linaro.org>
7943 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
7944 (fixup_partial_die): Remove declaration.
7945 (scan_partial_symbols): Update.
7946 (partial_die_parent_scope): Likewise.
7947 (partial_die_full_name): Likewise.
7948 (fixup_partial_die): Change it to partial_die_info::fixup.
7950 2018-02-26 Yao Qi <yao.qi@linaro.org>
7952 * dwarf2read.c (read_partial_die): Update the declaration.
7953 (load_partial_dies): Caller update.
7954 (read_partial_die): Remove one argument abbrev_len.
7956 2018-02-26 Yao Qi <yao.qi@linaro.org>
7958 * dwarf2read.c (struct partial_die_info): Add ctor, delete
7959 assignment operator.
7960 (load_partial_dies): Use ctor and copy ctor.
7961 (read_partial_die): Update.
7962 (dwarf2_cu::find_partial_die): Use ctor.
7964 2018-02-26 Yao Qi <yao.qi@linaro.org>
7966 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
7967 (find_partial_die_in_comp_unit): Change it to
7968 dwarf2_cu::find_partial_die.
7969 (find_partial_die): Update.
7971 2018-02-26 Yao Qi <yao.qi@linaro.org>
7973 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
7976 2018-02-26 Yao Qi <yao.qi@linaro.org>
7978 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
7980 2018-02-26 Alan Hayward <alan.hayward@arm.com>
7982 * arch/amd64.h: Use common/tdesc.h.
7983 * arch/i386.c: Likewise.
7984 * arch/i386.h: Likewise.
7985 * arch/tic6x.c: Likewise.
7986 * arch/tdesc.h: Move file from here...
7987 * common/tdesc.h: ...to here.
7988 * features/aarch64-core.c: Regenerate.
7989 * features/aarch64-fpu.c: Regenerate.
7990 * features/i386/32bit-avx.c: Regenerate.
7991 * features/i386/32bit-avx512.c: Regenerate.
7992 * features/i386/32bit-core.c: Regenerate.
7993 * features/i386/32bit-linux.c: Regenerate.
7994 * features/i386/32bit-mpx.c: Regenerate.
7995 * features/i386/32bit-pkeys.c: Regenerate.
7996 * features/i386/32bit-sse.c: Regenerate.
7997 * features/i386/64bit-avx.c: Regenerate.
7998 * features/i386/64bit-avx512.c: Regenerate.
7999 * features/i386/64bit-core.c: Regenerate.
8000 * features/i386/64bit-linux.c: Regenerate.
8001 * features/i386/64bit-mpx.c: Regenerate.
8002 * features/i386/64bit-pkeys.c: Regenerate.
8003 * features/i386/64bit-segments.c: Regenerate.
8004 * features/i386/64bit-sse.c: Regenerate.
8005 * features/i386/x32-core.c: Regenerate.
8006 * features/tic6x-c6xp.c: Regenerate.
8007 * features/tic6x-core.c: Regenerate.
8008 * features/tic6x-gp.c: Regenerate.
8009 * target-descriptions.c: Use common/tdesc.h.
8010 * target-descriptions.h: Likewise.
8012 2018-02-24 Tom Tromey <tom@tromey.com>
8014 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
8015 (try_thread_db_load_from_dir, thread_db_load_search): Use
8017 (info_auto_load_libthread_db_compare): Return bool. Change
8019 (info_auto_load_libthread_db): Use std::vector, std::string.
8022 2018-02-24 Tom Tromey <tom@tromey.com>
8024 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
8026 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
8028 * gdbarch.c: Rebuild.
8029 * gdbarch.h: Rebuild.
8030 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
8031 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
8032 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
8035 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
8037 * gdbtypes.h (sect_offset): Change type to uint64_t.
8038 (sect_offset_str): New function.
8039 * dwarf2read.c (create_addrmap_from_aranges): Use
8041 (error_check_comp_unit_head): Likewise.
8042 (create_debug_type_hash_table): Likewise.
8043 (read_cutu_die_from_dwo): Likewise.
8044 (init_cutu_and_read_dies): Likewise.
8045 (init_cutu_and_read_dies_no_follow): Likewise.
8046 (process_psymtab_comp_unit_reader): Likewise.
8047 (partial_die_parent_scope): Likewise.
8048 (peek_die_abbrev): Likewise.
8049 (process_queue): Likewise.
8050 (dwarf2_physname): Likewise.
8051 (read_namespace_alias): Likewise.
8052 (read_import_statement): Likewise.
8053 (create_dwo_cu_reader): Likewise.
8054 (create_cus_hash_table): Likewise.
8055 (lookup_dwo_cutu): Likewise.
8056 (inherit_abstract_dies): Likewise.
8057 (read_func_scope): Likewise.
8058 (read_call_site_scope): Likewise.
8059 (dwarf2_add_member_fn): Likewise.
8060 (read_common_block): Likewise.
8061 (read_module_type): Likewise.
8062 (read_typedef): Likewise.
8063 (read_subrange_type): Likewise.
8064 (load_partial_dies): Likewise.
8065 (read_partial_die): Likewise.
8066 (find_partial_die): Likewise.
8067 (read_str_index): Likewise.
8068 (dwarf2_string_attr): Likewise.
8069 (build_error_marker_type): Likewise.
8070 (lookup_die_type): Likewise.
8071 (dump_die_shallow): Likewise.
8072 (follow_die_ref): Likewise.
8073 (dwarf2_fetch_die_loc_sect_off): Likewise.
8074 (dwarf2_fetch_constant_bytes): Likewise.
8075 (follow_die_sig): Likewise.
8076 (get_signatured_type): Likewise.
8077 (get_DW_AT_signature_type): Likewise.
8078 (dwarf2_find_containing_comp_unit): Likewise.
8079 (set_die_type): Likewise.
8081 2018-02-21 John Baldwin <jhb@FreeBSD.org>
8083 * arch/aarch64.c: Include "common-defs.h".
8084 * arch/amd64.c: Likewise.
8085 * arch/i386.c: Likewise.
8087 2018-02-21 Tom Tromey <tom@tromey.com>
8089 * value.h: (extract_field_op): Update.
8090 * eval.c (extract_field_op): Return a const char *.
8091 * expression.h (parse_expression_for_completion): Update.
8092 * completer.c (complete_expression): Update.
8093 (add_struct_fields): Make fieldname const.
8094 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
8095 (mark_completion_tag, parse_exp_in_context_1): Update.
8096 (parse_expression_for_completion): Change "name" to
8097 unique_xmalloc_ptr*.
8099 2018-02-21 Tom Tromey <tom@tromey.com>
8101 * infcall.c (call_function_by_hand_dummy): Use std::vector.
8103 2018-02-21 Yao Qi <yao.qi@linaro.org>
8105 * avr-tdep.c (avr_read_pc): Change parameter type to
8107 * gdbarch.sh (read_pc): Likewise.
8108 * gdbarch.c: Re-generated.
8109 * gdbarch.h: Re-generated.
8110 * hppa-tdep.c (hppa_read_pc): Change parameter type to
8112 * ia64-tdep.c (ia64_read_pc): Likewise.
8113 * mips-tdep.c (mips_read_pc): Likewise.
8114 * spu-tdep.c (spu_read_pc): Likewise.
8116 2018-02-21 Yao Qi <yao.qi@linaro.org>
8118 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
8119 * regcache-dump.c: New file.
8120 * regcache.c: Move register_dump to regcache-dump.c.
8121 (maintenance_print_registers): Likewise.
8122 (maintenance_print_raw_registers): Likewise.
8123 (maintenance_print_cooked_registers): Likewise.
8124 (maintenance_print_register_groups): Likewise.
8125 (maintenance_print_remote_registers): Likewise.
8126 (_initialize_regcache): Likewise.
8127 * regcache.h (register_dump): Moved from regcache.c.
8129 2018-02-21 Yao Qi <yao.qi@linaro.org>
8131 * regcache.c (regcache::regcache): Update.
8132 (regcache::invalidate): Move it to detached_regcache::invalidate.
8133 (get_thread_arch_aspace_regcache): Update.
8134 (regcache::raw_update): Update.
8135 (regcache::cooked_read): Remove some code.
8136 (regcache::cooked_read_value): Likewise.
8137 (regcache::raw_write): Remove assert on m_readonly_p.
8138 (regcache::raw_supply_integer): Move it to
8139 detached_regcache::raw_supply_integer.
8140 (regcache::raw_supply_zeroed): Likewise.
8141 * regcache.h (detached_regcache) <raw_supply_integer>: New
8143 <raw_supply_zeroed, invalidate>: Likewise.
8144 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
8145 <invalidate>: Likewise.
8146 <m_readonly_p>: Removed.
8148 2018-02-21 Yao Qi <yao.qi@linaro.org>
8150 * infcmd.c (get_return_value): Let stop_regs point to
8151 get_current_regcache.
8152 * regcache.c (regcache::regcache): Remove.
8153 (register_dump_reg_buffer): New class.
8154 (regcache_print): Adjust.
8155 * regcache.h (regcache): Remove constructors.
8157 2018-02-21 Yao Qi <yao.qi@linaro.org>
8159 * regcache.c (class register_dump): New class.
8160 (register_dump_regcache, register_dump_none): New class.
8161 (register_dump_remote, register_dump_groups): New class.
8162 (regcache_print): Update.
8163 * regcache.h (regcache_dump_what): Move it to regcache.c.
8164 (regcache) <dump>: Remove.
8166 2018-02-21 Yao Qi <yao.qi@linaro.org>
8168 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
8170 (jit_unwind_reg_set_impl): Call raw_supply.
8171 (jit_frame_sniffer): Use reg_buffer_rw.
8172 * record-full.c (record_full_core_regbuf): Change its type.
8173 (record_full_core_open_1): Use reg_buffer_rw.
8174 (record_full_close): Likewise.
8175 (record_full_core_fetch_registers): Use regcache->raw_supply.
8176 (record_full_core_store_registers): Likewise.
8177 * regcache.c (regcache::get_register_status): Move it to
8179 (regcache_raw_set_cached_value): Remove.
8180 (regcache::raw_set_cached_value): Remove.
8181 (regcache::raw_write): Call raw_supply.
8182 (regcache::raw_supply): Move it to reg_buffer_rw.
8183 * regcache.h (regcache_raw_set_cached_value): Remove.
8184 (reg_buffer_rw): New class.
8186 2018-02-21 Yao Qi <yao.qi@linaro.org>
8188 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
8189 readonly_detached_regcache.
8190 (dummy_frame_prev_register): Use regcache->cooked_read.
8191 * frame.c (frame_save_as_regcache): Change return type.
8192 (frame_pop): Update.
8193 * frame.h (frame_save_as_regcache): Update declaration.
8194 * inferior.h (get_infcall_suspend_state_regcache): Update
8196 * infrun.c (infcall_suspend_state) <registers>: use
8197 readonly_detached_regcache.
8198 (save_infcall_suspend_state): Don't use regcache_dup.
8199 (get_infcall_suspend_state_regcache): Change return type.
8200 * linux-fork.c (struct fork_info) <savedregs>: Change to
8201 readonly_detached_regcache.
8203 (fork_save_infrun_state): Don't use regcache_dup.
8204 (info_checkpoints_command): Adjust.
8205 * mi/mi-main.c (register_changed_p): Update declaration.
8206 (mi_cmd_data_list_changed_registers): Use
8207 readonly_detached_regcache.
8208 (register_changed_p): Change parameter type to
8209 readonly_detached_regcache.
8210 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
8211 readonly_detached_regcache.
8212 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
8213 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
8215 (regcache::save): Move it to reg_buffer.
8216 (regcache::restore): Change parameter type.
8217 (regcache_dup): Remove.
8218 * regcache.h (reg_buffer) <save>: New method.
8219 (readonly_detached_regcache): New class.
8220 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
8221 readonly_detached_regcache.
8222 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
8224 2018-02-21 Yao Qi <yao.qi@linaro.org>
8226 * frame.c (frame_save_as_regcache): Use regcache method save.
8227 (frame_pop): Use regcache method restore.
8228 * infrun.c (restore_infcall_suspend_state): Likewise.
8229 * linux-fork.c (fork_load_infrun_state): Likewise.
8230 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
8232 * regcache.c (regcache_save): Remove.
8233 (regcache::restore): More asserts.
8234 (regcache_cpy): Remove.
8235 * regcache.h (regcache_save): Remove the declaration.
8236 (regcache::restore): Move from private to public.
8237 Remove the friend declaration of regcache_cpy.
8238 (regcache_cpy): Remove declaration.
8240 2018-02-21 Yao Qi <yao.qi@linaro.org>
8242 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
8243 parameter type to 'readable_regcache *'.
8244 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
8245 * arm-tdep.c (arm_neon_quad_read): Likewise.
8246 (arm_pseudo_read): Likewise.
8247 * avr-tdep.c (avr_pseudo_register_read): Likewise.
8248 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
8249 * frv-tdep.c (frv_pseudo_register_read): Likewise.
8250 * gdbarch.c: Re-generated.
8251 * gdbarch.h: Re-generated.
8252 * gdbarch.sh (pseudo_register_read): Change parameter type to
8253 'readable_regcache *'.
8254 (pseudo_register_read_value): Likewise.
8255 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
8256 (h8300_pseudo_register_read): Likewise.
8257 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
8258 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
8259 (i386_pseudo_register_read_into_value): Likewise.
8260 (i386_pseudo_register_read_value): Likewise.
8261 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
8263 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
8264 * m32c-tdep.c (m32c_raw_read): Likewise.
8265 (m32c_read_flg): Likewise.
8266 (m32c_banked_register): Likewise.
8267 (m32c_banked_read): Likewise.
8268 (m32c_sb_read): Likewise.
8269 (m32c_part_read): Likewise.
8270 (m32c_cat_read): Likewise.
8271 (m32c_r3r2r1r0_read): Likewise.
8272 (m32c_pseudo_register_read): Likewise.
8273 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
8274 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
8275 (mep_pseudo_cr64_read): Likewise.
8276 (mep_pseudo_register_read): Likewise.
8277 * mips-tdep.c (mips_pseudo_register_read): Likewise.
8278 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
8279 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
8280 * regcache.c (regcache::raw_read): Move it to readable_regcache.
8281 (regcache::cooked_read): Likewise.
8282 (regcache::cooked_read_value): Likewise.
8283 (regcache_cooked_read_signed):
8284 (regcache::cooked_read): Likewise.
8285 * regcache.h (readable_regcache): New class.
8286 (regcache): Inherit readable_regcache. Move some methods to
8288 * rl78-tdep.c (rl78_pseudo_register_read): Change
8289 parameter type to 'readable_regcache *'.
8290 * rs6000-tdep.c (do_regcache_raw_read): Remove.
8291 (e500_pseudo_register_read): Change parameter type to
8292 'readable_regcache *'.
8293 (dfp_pseudo_register_read): Likewise.
8294 (vsx_pseudo_register_read): Likewise.
8295 (efpr_pseudo_register_read): Likewise.
8296 * s390-tdep.c (s390_pseudo_register_read): Likewise.
8297 * sh-tdep.c (sh_pseudo_register_read): Likewise.
8298 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
8299 (sh64_pseudo_register_read): Likewise.
8300 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
8301 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
8302 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
8303 (spu_pseudo_register_read): Likewise.
8304 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
8305 (xtensa_pseudo_register_read): Likewise.
8307 2018-02-21 Yao Qi <yao.qi@linaro.org>
8309 * regcache.c (regcache::regcache): Call reg_buffer ctor.
8310 (regcache::arch): Move it to reg_buffer::arch.
8311 (regcache::register_buffer): Likewise.
8312 (regcache::assert_regnum): Likewise.
8313 (regcache::num_raw_registers): Likewise.
8314 * regcache.h (reg_buffer): New class.
8315 (regcache): Inherit reg_buffer.
8317 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
8319 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
8320 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
8322 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
8324 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
8326 2018-02-19 Alan Hayward <alan.hayward@arm.com>
8328 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
8329 (SFILES): Remove common/*.c files.
8330 (COMMON_OBS): Remove some *.o files built from common/*.c files.
8331 * common/common.host: Add common reference.
8332 * configure.ac: Likewise.
8333 * configure: Regenerate.
8335 2018-02-16 Yao Qi <yao.qi@linaro.org>
8337 * block.c (block_namespace_info): Inherit allocate_on_obstack.
8338 (block_initialize_namespace): Use new.
8339 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
8340 (dwarf2_free_objfile): Use delete.
8341 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
8342 (copy_type_recursive): Use new.
8343 * gdb_obstack.h (allocate_on_obstack): New.
8345 2018-02-15 Yao Qi <yao.qi@linaro.org>
8348 * inferior.c (exit_inferior_1): Reset inf->control.
8350 2018-02-15 Joel Brobecker <brobecker@adacore.com>
8352 * ada-lang.c (ada_to_fixed_value_create): Delete advance
8355 2018-02-14 Pedro Alves <palves@redhat.com>
8357 * frame-unwind.c (frame_unwind_try_unwinder): Always call
8358 frame_cleanup_after_sniffer on exception.
8360 2018-02-14 Tom Tromey <tom@tromey.com>
8362 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
8364 (solib_bfd_open): Make pathname const.
8365 * solib.c (solib_bfd_open): Make pathname const.
8366 * solib-spu.c (spu_bfd_fopen): Make name const.
8367 (spu_bfd_open): Make pathname const.
8368 * solib-darwin.c (darwin_bfd_open): Make pathname const.
8369 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
8371 2018-02-14 Tom Tromey <tom@tromey.com>
8373 * symfile.c (symfile_bfd_open): Update.
8374 * source.h (openp, source_full_path_of, find_and_open_source):
8375 Change argument type to unique_xmalloc_ptr.
8376 * source.c (openp): Take a unique_xmalloc_ptr.
8377 (source_full_path_of, find_and_open_source): Likewise.
8378 (open_source_file, symtab_to_fullname): Update.
8379 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
8381 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
8382 (exec_file_find): Update.
8383 * psymtab.c (psymtab_to_fullname): Update.
8384 * nto-tdep.h (nto_find_and_open_solib): Update.
8385 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
8387 * exec.c (exec_file_attach): Update.
8388 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
8389 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
8391 2018-02-14 Tom Tromey <tom@tromey.com>
8393 * solib.c: Include source.h.
8394 * nto-tdep.c: Include source.h.
8395 * mi/mi-cmd-env.c: Include source.h.
8396 * infcmd.c: Include source.h.
8397 * exec.c: Include source.h.
8398 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
8399 (add_path, directory_switch, source_path, init_source_path): Move
8401 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
8402 (add_path, directory_switch, source_path, init_source_path):
8405 2018-02-14 Tom Tromey <tom@tromey.com>
8407 * solist.h (exec_file_find, solib_find): Return
8409 (solib_bfd_fopen): Take a const char *.
8410 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
8411 (exec_file_find, solib_find): Likewise.
8412 (solib_bfd_fopen): Do not take ownership of "pathname".
8413 (solib_bfd_open): Use unique_xmalloc_ptr.
8414 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
8415 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
8416 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
8417 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
8419 2018-02-14 Joel Brobecker <brobecker@adacore.com>
8421 * ada-lang.c (name_match_type_from_name): Remove reference to
8422 ada_name_for_lookup in function's documentation.
8423 * ada-lang.h (ada_name_for_lookup): Delete declaration.
8425 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8427 * defs.h (enum openp_flags): New enum.
8428 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
8429 Move to enum openp_flags.
8430 (openp_flags): New enum flags.
8431 (openp): Change parameter type to openp_flags.
8432 * source.c (openp): Change parameter type to openp_flags.
8433 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
8434 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
8436 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8438 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
8441 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
8443 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
8445 (class dwarf2_queue_guard): ...the destructor of this new class.
8446 (dw2_do_instantiate_symtab): Create instance of the new class
8447 dwarf2_queue_guard, remove cleanup.
8449 2018-02-09 Tom Tromey <tom@tromey.com>
8451 * source.c (find_source_lines): Don't reference past the end of
8454 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8456 * remote.c (remote_btrace_maybe_reopen): Change error message.
8457 * btrace.c (btrace_enable): Likewise.
8458 (parse_xml_btrace): Likewise.
8459 (parse_xml_btrace_conf): Likewise.
8461 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8463 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
8464 (linux_enable_pt, linux_enable_bts): Call
8465 diagnose_perf_event_open_fail.
8467 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8469 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
8470 Remove parameter and change return type. Update callers. Move it.
8471 (linux_enable_bts, linux_enable_pt): Improve error message.
8472 (linux_enable_pt): Remove zero buffer size check.
8473 (linux_enable_btrace): Improve error messages. Remove NULL return
8476 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8478 * btrace.c (btrace_enable): Remove target_supports_btrace call.
8479 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
8480 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
8481 (linux_supports_pt, linux_supports_btrace): Remove.
8482 (linux_enable_bts): Call cpu_supports_bts.
8483 * nat/linux-btrace.h (linux_supports_btrace): Remove.
8484 * remote.c (remote_supports_btrace): Remove.
8485 (init_remote_ops): Remove remote_supports_btrace.
8486 * target-delegates.c: Regenerated.
8487 * target.c (target_supports_btrace): Remove.
8488 * target.h (target_ops) <to_supports_btrace>: Remove
8489 (target_supports_btrace): Remove.
8490 * x86-linux-nat.c (x86_linux_create_target): Remove
8491 linux_supports_btrace.
8493 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8495 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
8497 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
8498 exception and use message in own exception.
8500 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8502 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
8503 (perf_event_pt_event_type): Use gdb_file_up.
8504 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
8505 scoped_fd, and scoped_mmap.
8507 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8509 * common/scoped_mmap.h: New.
8510 * unittests/scoped_mmap-selftest.c: New.
8511 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8512 unittests/scoped_mmap-selftest.c.
8514 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8516 * common/scoped_fd.h: New.
8517 * unittests/scoped_fd-selftest.c: New.
8518 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8519 unittests/scoped_fd-selftest.c.
8521 2018-02-09 Tom Tromey <tom@tromey.com>
8523 * auto-load.c (auto_load_section_scripts): Use
8524 gdb::unique_xmalloc_ptr.
8526 2018-02-09 Tom Tromey <tom@tromey.com>
8528 * auto-load.c (execute_script_contents): Use std::string.
8530 2018-02-09 Joel Brobecker <brobecker@adacore.com>
8532 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
8533 Python function, rather than a new command.
8535 2018-02-08 Tom Tromey <tom@tromey.com>
8537 * solib.c (solib_find_1): Use std::string.
8538 (solib_bfd_fopen): Use unique_xmalloc_ptr.
8540 2018-02-08 Tom Tromey <tom@tromey.com>
8542 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
8544 2018-02-08 Tom Tromey <tom@tromey.com>
8546 * source.c (find_source_lines): Use gdb::def_vector.
8548 2018-02-08 Tom Tromey <tom@tromey.com>
8550 * macrocmd.c (struct temporary_macro_definition): New.
8551 (macro_define_command): Use temporary_macro_definition. Remove
8553 (free_macro_definition_ptr): Remove.
8555 2018-02-08 Tom Tromey <tom@tromey.com>
8557 * macroexp.c (maybe_expand): Use std::string.
8559 2018-02-08 Tom Tromey <tom@tromey.com>
8561 * macroexp.c (struct macro_buffer): Add initializers for some
8563 (init_buffer, init_shared_buffer, free_buffer)
8564 (free_buffer_return_text): Remove.
8565 (macro_buffer): New constructors.
8566 (~macro_buffer): New destructor.
8567 (macro_buffer::set_shared): New method.
8568 (macro_buffer::resize_buffer, macro_buffer::appendc)
8569 (macro_buffer::appendmem): Now methods, not free functions.
8570 (set_token, append_tokens_without_splicing, stringify)
8571 (macro_stringify): Update.
8572 (gather_arguments): Change return type. Remove argc_p argument,
8573 add args_ptr argument. Use std::vector.
8574 (substitute_args): Remove argc argument. Accept std::vector.
8575 (expand): Update. Use std::vector.
8576 (scan, macro_expand, macro_expand_next): Update.
8578 2018-02-08 Tom Tromey <tom@tromey.com>
8580 * symtab.c (default_collect_symbol_completion_matches_break_on):
8581 Use unique_xmalloc_ptr.
8582 * macroscope.h: (sal_macro_scope, user_macro_scope)
8583 (default_macro_scope): Return unique_xmalloc_ptr.
8584 * macroscope.c (sal_macro_scope, user_macro_scope)
8585 (default_macro_scope): Return unique_xmalloc_ptr.
8586 * macroexp.h (macro_expand, macro_expand_once): Return
8588 * macroexp.c (macro_expand, macro_expand_once): Return
8590 * macrocmd.c (macro_expand_command, macro_expand_once_command)
8591 (info_macro_command, info_macros_command): Use
8593 * compile/compile-c-support.c (write_macro_definitions): Use
8595 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
8597 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
8599 * value.c (value_static_field): Assign field type instead of
8600 containing type when returning an optimized out value.
8602 2018-02-06 Yao Qi <yao.qi@linaro.org>
8604 * ft32-tdep.c (ft32_read_pc): Remove.
8605 (ft32_write_pc): Remove.
8606 (ft32_gdbarch_init): Update.
8607 * m32r-tdep.c (m32r_read_pc): Remove.
8608 (m32r_gdbarch_init): Update.
8609 * mep-tdep.c (mep_read_pc): Remove.
8610 (mep_gdbarch_init): Update.
8611 * microblaze-tdep.c (microblaze_write_pc): Remove.
8612 (microblaze_gdbarch_init): Update.
8613 * mn10300-tdep.c (mn10300_read_pc): Remove.
8614 (mn10300_write_pc): Remove.
8615 (mn10300_gdbarch_init): Update.
8616 * moxie-tdep.c (moxie_read_pc): Remove.
8617 (moxie_write_pc): Remove.
8618 (moxie_gdbarch_init): Update.
8620 2018-02-06 Yao Qi <yao.qi@linaro.org>
8622 * expprint.c (print_subexp_standard): Handle
8623 OP_F77_UNDETERMINED_ARGLIST.
8624 (dump_subexp_body_standard): Likewise.
8626 2018-02-05 Alan Hayward <alan.hayward@arm.com>
8628 * target-descriptions.c (tdesc_element_visitor) Add empty
8630 (tdesc_type): Move make_gdb_type from here.
8631 (tdesc_type_builtin): Likewise.
8632 (tdesc_type_vector): Likewise.
8633 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
8634 (make_gdb_type_struct): Move from tdesc_type_with_fields.
8635 (make_gdb_type_union): Likewise.
8636 (make_gdb_type_flags): Likewise.
8637 (make_gdb_type_enum): Likewise.
8638 (make_gdb_type): New function.
8639 (tdesc_register_type): Use static make_gdb_type.
8641 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
8643 * infcmd.c (default_print_one_register_info): Align natural-format
8644 column values consistently one under another.
8645 (pad_to_column): New function.
8647 2018-02-05 Joel Brobecker <brobecker@adacore.com>
8649 * dwarf2read.c (dwarf2_physname): Move commment.
8651 2018-02-01 Leszek Swirski <leszeks@google.com>
8653 * varobj.c (varobj_formatted_print_options): Allow recursive
8654 pretty printing if pretty printing is enabled.
8656 2018-02-01 Leszek Swirski <leszeks@google.com>
8658 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
8659 names after a structop as a filename.
8661 2018-02-01 Yao Qi <yao.qi@linaro.org>
8663 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
8664 (arm_record_coproc_data_proc): Likewise.
8666 2018-02-01 Yao Qi <yao.qi@linaro.org>
8668 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
8670 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
8672 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
8673 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
8675 2018-01-31 Pedro Alves <palves@redhat.com>
8677 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
8678 * inflow.c (child_terminal_save_inferior): Wrap reference to
8679 tcgetpgrp in HAVE_TERMIOS_H.
8680 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
8682 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
8683 always iterate over all inferiors.
8684 (gdbsim_cntrl_c): Adjust.
8685 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
8687 2018-01-31 Joel Brobecker <brobecker@adacore.com>
8689 * gdbtypes.c (lookup_array_range_type): Make sure the array's
8690 index type is objfile-owned if the element type is as well.
8692 2018-01-31 Joel Brobecker <brobecker@adacore.com>
8696 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
8698 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
8699 "features/s390x-linux64.c".
8700 (_initialize_s390_linux_tdep): Remove initialization of tdescs
8701 s390_linux32 and s390x_linux64.
8702 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
8704 * s390-tdep.c: Include "features/s390-linux32.c" and
8705 "features/s390x-linux64.c".
8706 (s390_tdesc_valid): Add check for tdesc_has_registers.
8707 (s390_gdbarch_init): Make sure there is always a valid tdesc.
8708 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
8709 tdesc_s390x_linux64.
8710 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
8711 tdesc_s390x_linux64 to...
8712 * s390-tdep.h: ...here.
8714 2018-01-30 Pedro Alves <palves@redhat.com>
8717 * config.in, configure: Regenerate.
8718 * configure.ac: Check for getpgid.
8719 * go32-nat.c (go32_pass_ctrlc): New.
8720 (go32_target): Install it.
8721 * inf-child.c (inf_child_target): Install
8722 child_terminal_save_inferior, child_pass_ctrlc and
8724 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
8725 (inf_ptrace_target): No longer install it.
8726 * infcmd.c (interrupt_target_1): Adjust.
8727 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
8728 (child_interrupt): Declare.
8729 (inferior::terminal_state): New.
8730 * inflow.c (struct terminal_info): Update comments.
8731 (inferior_process_group): Delete.
8732 (terminal_is_ours): Delete.
8733 (gdb_tty_state): New.
8734 (child_terminal_init): Adjust.
8735 (is_gdb_terminal, sharing_input_terminal_1)
8736 (sharing_input_terminal): New functions.
8737 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
8738 Set the process's actual process group in the foreground if
8739 possible. Handle is_ours_for_output/is_ours distinction. Don't
8740 mark terminal as the inferior's if not sharing GDB's terminal.
8741 Don't check attach_flag.
8742 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
8743 pass down a target_terminal_state.
8744 (child_terminal_save_inferior): New, factored out from ...
8745 (child_terminal_ours_1): ... this. Handle
8746 target_terminal_state::is_ours_for_output.
8747 (child_interrupt, child_pass_ctrlc): New.
8748 (inflow_inferior_exit): Clear the inferior's terminal_state.
8749 (copy_terminal_info): Copy the inferior's terminal state.
8750 (_initialize_inflow): Remove reference to terminal_is_ours.
8751 * inflow.h (inferior_process_group): Delete.
8752 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
8753 * procfs.c (procfs_target): Don't install procfs_interrupt.
8754 (procfs_interrupt): Delete.
8755 * remote.c (remote_serial_quit_handler): Adjust.
8756 (remote_interrupt): Remove ptid parameter. Adjust.
8757 * target-delegates.c: Regenerate.
8758 * target.c: Include "terminal.h".
8759 (target_terminal::terminal_state): Rename to ...
8760 (target_terminal::m_terminal_state): ... this.
8761 (target_terminal::init): Adjust.
8762 (target_terminal::inferior): Adjust to per-inferior
8764 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
8765 (target_terminal::ours, target_terminal::ours_for_output): Use
8766 target_terminal_is_ours_kind.
8767 (target_interrupt): Remove ptid parameter. Adjust.
8768 (default_target_pass_ctrlc): Adjust.
8769 * target.h (target_ops::to_terminal_save_inferior): New field.
8770 (target_ops::to_interrupt): Remove ptid_t parameter.
8771 (target_interrupt): Remove ptid_t parameter. Update comment.
8772 (target_pass_ctrlc): Update comment.
8773 * target/target.h (target_terminal_state): New scoped enum,
8775 (target_terminal::terminal_state): ... here.
8776 (target_terminal::inferior): Update comments.
8777 (target_terminal::restore_inferior): New.
8778 (target_terminal::is_inferior, target_terminal::is_ours)
8779 (target_terminal::is_ours_for_output): Adjust.
8780 (target_terminal::scoped_restore_terminal_state): Adjust to
8781 rename, and call restore_inferior() instead of inferior().
8782 (target_terminal::scoped_restore_terminal_state::m_state): Change
8784 (target_terminal::terminal_state): Rename to ...
8785 (target_terminal::m_terminal_state): ... this and change type.
8787 2018-01-30 Pedro Alves <palves@redhat.com>
8789 * linux-nat.c (wait_for_signal): New function.
8790 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
8792 (async_terminal_is_ours)
8793 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
8794 (linux_nat_add_target): Don't override
8795 to_terminal_inferior/to_terminal_ours.
8797 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
8799 * remote.c (remote_follow_fork): Don't call "detach_inferior".
8801 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
8803 * dwarf2read.c (free_dwo_files): Add forward-declaration.
8804 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
8805 dwarf2_per_objfile_free here.
8806 (dwarf2_per_objfile_free): Remove.
8807 (_initialize_dwarf2_read): Don't register
8808 dwarf2_per_objfile_free as a registry cleanup.
8810 2018-01-27 Eli Zaretskii <eliz@gnu.org>
8812 Avoid compilation errors in MinGW native builds
8814 The error is triggered by including python-internal.h, and the
8817 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
8818 from build-gnulib/import/math.h:27,
8819 from d:/usr/Python26/include/pyport.h:235,
8820 from d:/usr/Python26/include/Python.h:58,
8821 from python/python-internal.h:94,
8822 from python/py-arch.c:24:
8823 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
8827 This happens because Python headers define 'hypot' to expand t
8828 '_hypot' in the Windows builds.
8829 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
8830 'hypoth'. This avoids a compilation error.
8832 2018-01-26 Alan Hayward <alan.hayward@arm.com>
8834 * MAINTAINERS (Write After Approval): Fix ordering.
8836 2018-01-26 Alan Hayward <alan.hayward@arm.com>
8838 * MAINTAINERS (Write After Approval): Add Alan Hayward.
8840 2018-01-26 Alan Modra <amodra@gmail.com>
8842 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
8843 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
8844 Remove nop. Make const. Comment.
8845 (powerpc32_plt_stub_so_2): New.
8846 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
8847 Correct count. Update uses.
8848 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
8849 Move common code reading PLT entry word. Correct
8850 powerpc32_plt_stub PLT address calculation.
8851 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
8852 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
8853 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
8854 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
8855 (ppc64_standard_linkage8): Likewise.
8856 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
8857 Correct insns description.
8858 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
8860 2018-01-24 Pedro Alves <palves@redhat.com>
8862 GCC PR libstdc++/83906
8863 * gdbtypes.c (operator==(const dynamic_prop &,
8864 const dynamic_prop &)): New.
8865 (operator==(const range_bounds &, const range_bounds &)): New.
8866 (check_types_equal): Use them instead of memcmp.
8867 * gdbtypes.h (operator==(const dynamic_prop &,
8868 const dynamic_prop &)): Declare.
8869 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
8870 (operator==(const range_bounds &, const range_bounds &)): Declare.
8871 (operator!=(const range_bounds &, const range_bounds &)): Declare.
8873 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8875 * s390-linux-tdep.c (s390_record_address_mask)
8876 (s390_record_calc_disp_common, s390_record_calc_disp)
8877 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8878 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8879 (s390_process_record): Move to s390-tdep.c.
8880 (s390_linux_init_abi_any): Adjust.
8881 * s390-tdep.c (s390_record_address_mask)
8882 (s390_record_calc_disp_common, s390_record_calc_disp)
8883 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8884 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8885 (s390_process_record): Moved from s390-linux-tdep.c
8886 (s390_gdbarch_init): Adjust.
8888 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8890 * s390-linux-nat.c (s390-tdep.h): New include.
8891 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
8892 (HFILES_NO_SRCDIR): Add s390-tdep.h.
8893 (ALLDEPFILES): Add s390-tdep.c.
8894 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
8895 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
8896 * s390-tdep.h: ...this. New file.
8897 * s390-linux-tdep.c (s390-tdep.h): New include.
8898 (_initialize_s390_tdep): Rename to...
8899 (_initialize_s390_linux_tdep): ...this and adjust.
8900 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
8901 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
8903 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
8904 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
8905 (s390_is_partial_instruction, s390_software_single_step)
8906 (is_non_branch_ril, s390_displaced_step_copy_insn)
8907 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
8908 (s390_prologue_data, s390_addr, s390_store, s390_load)
8909 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
8910 (s390_register_call_saved, s390_guess_tracepoint_registers)
8911 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
8912 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
8913 (s390_pseudo_register_name, s390_pseudo_register_type)
8914 (s390_pseudo_register_read, s390_pseudo_register_write)
8915 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
8916 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
8917 (s390_addr_bits_remove, s390_address_class_type_flags)
8918 (s390_address_class_type_flags_to_name)
8919 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
8920 (s390_function_arg_float, s390_function_arg_vector)
8921 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
8922 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
8923 (s390_frame_align, s390_register_return_value, s390_return_value)
8924 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
8925 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
8926 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
8927 (s390_trad_frame_prev_register, s390_unwind_cache)
8928 (s390_prologue_frame_unwind_cache)
8929 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
8930 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
8931 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
8932 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
8933 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
8934 (s390_frame_base_address, s390_local_base_address)
8935 (s390_frame_base, s390_gcc_target_options)
8936 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
8937 (s390_validate_reg_range, s390_tdesc_valid)
8938 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
8939 * s390-tdep.c: ...this. New file.
8941 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8943 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
8944 (s390_process_record, s390_gdbarch_tdep_alloc)
8945 (s390_linux_init_abi_any): Use/set new hook.
8947 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8949 * s390-linux-tdep.c (osabi.h): New include.
8950 (s390_linux_init_abi_31, s390_linux_init_abi_64)
8951 (s390_linux_init_abi_any): New functions.
8952 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
8954 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8956 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
8957 tdesc_has_registers check
8959 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8961 * s390-linux-tdep.c (s390_tdesc_valid): New function.
8962 (s390_validate_reg_range): New macro.
8963 (s390_gdbarch_init): Adjust.
8965 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8967 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
8968 (s390_gdbarch_tdep_alloc): Adjust.
8969 (s390_gdbarch_init): Adjust.
8971 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8973 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
8974 <have_tdb>: Change type to bool.
8975 (s390_gdbarch_tdep_alloc): Adjust.
8976 (s390_gdbarch_init): Adjust.
8978 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8980 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
8981 (gdbarch_tdep) <have_upper, have_vx>: New fields.
8982 (s390_gdbarch_tdep_alloc): New function.
8983 (s390_gdbarch_init): Allocate tdep at start and use its fields
8984 instead of separate variables.
8986 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8988 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
8989 when looking for cached gdbarch and add comment for remaining.
8991 2018-01-22 Pedro Alves <palves@redhat.com>
8992 Sergio Durigan Junior <sergiodj@redhat.com>
8994 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
8997 2018-01-22 Maciej W. Rozycki <macro@mips.com>
8999 * MAINTAINERS: Update my company e-mail address.
9001 2018-01-22 Yao Qi <yao.qi@linaro.org>
9003 * regcache.c (cooked_write_test): New function.
9004 (_initialize_regcache): Register the test.
9006 2018-01-22 Yao Qi <yao.qi@linaro.org>
9008 * ia64-tdep.c (ia64_pseudo_register_read): Call
9009 regcache->cooked_read instead of regcache_cooked_read_unsigned.
9010 * m32c-tdep.c (m32c_cat_read): Likewise.
9011 (m32c_r3r2r1r0_read): Likewise.
9012 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9013 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9015 2018-01-22 Yao Qi <yao.qi@linaro.org>
9017 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
9018 method raw_read instead of regcache_raw_read.
9019 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9020 * arm-tdep.c (arm_neon_quad_read): Likewise.
9021 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9022 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9023 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9024 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
9025 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9026 (i386_pseudo_register_read_into_value): Likewise.
9027 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9028 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9029 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9030 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
9031 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
9032 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9033 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9034 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9035 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
9037 2018-01-22 Yao Qi <yao.qi@linaro.org>
9039 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
9040 * configure.tgt: Remove target mt.
9041 * mt-tdep.c: Remove.
9042 * regcache.c (cooked_read_test): Remove the check for mt.
9044 2018-01-22 Yao Qi <yao.qi@linaro.org>
9046 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
9047 instead of gdbarch_pseudo_register_read_value.
9049 2018-01-22 Joel Brobecker <brobecker@adacore.com>
9051 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
9054 2018-01-22 Joel Brobecker <brobecker@adacore.com>
9056 * linespec.c (create_sals_line_offset): Remove code that preserved
9057 the symtab_and_line's line number.
9059 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9061 * varobj.c (varobj_create): Don't set valid_block when creating a
9064 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9066 * varobj.c (varobj_create): Remove out of date comment.
9068 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9071 * ada-exp.y (write_var_from_sym): Pass extra parameter when
9072 updating innermost block.
9073 * parse.c (innermost_block_tracker::update): Take extra type
9074 parameter, and check types match before updating innermost block.
9075 (write_dollar_variable): Update innermost block for registers.
9076 * parser-defs.h (enum innermost_block_tracker_type): New enum.
9077 (innermost_block_tracker::innermost_block_tracker): Initialise
9079 (innermost_block_tracker::reset): Take type parameter.
9080 (innermost_block_tracker::update): Take type parameter, and pass
9081 type through as needed.
9082 (innermost_block_tracker::m_types): New member.
9083 * varobj.c (varobj_create): Pass type when reseting innermost
9086 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9088 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
9089 * ada-lang.c (resolve_subexp): Likewise.
9090 * breakpoint.c (set_breakpoint_condition) Likewise.
9091 (watch_command_1) Likewise.
9092 * c-exp.y (variable): Likewise.
9093 * d-exp.y (PrimaryExpression): Likewise.
9094 * f-exp.y (variable): Likewise.
9095 * go-exp.y (variable): Likewise.
9096 * m2-exp.y (variable): Likewise.
9097 * objfiles.c (objfile::~objfile): Likewise.
9098 * p-exp.y (variable): Likewise.
9099 * parse.c (innermost_block): Change type.
9100 * parser-defs.h (class innermost_block_tracker): New.
9101 (innermost_block): Change to innermost_block_tracker.
9102 * printcmd.c (display_command): Switch to innermost_block API.
9103 (do_one_display): Likewise.
9104 * rust-exp.y (do_one_display): Likewise.
9105 * symfile.c (clear_symtab_users): Likewise.
9106 * varobj.c (varobj_create): Switch to innermost_block API, replace
9107 use of innermost_block with block stored on varobj object.
9109 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9111 * expression.h (innermost_block): Remove declaration.
9112 * varobj.c: Add 'parser-defs.h' include.
9114 2018-01-19 Tom Tromey <tom@tromey.com>
9116 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
9117 symbols in the static and global blocks.
9119 2018-01-19 James Clarke <jrtc27@jrtc27.com>
9121 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
9122 gdb_ptrace.h, and move including gdb_wait.h ...
9123 * nat/linux-ptrace.h: ... to here.
9125 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9127 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
9128 inf_ptrace_detach_success.
9129 (inf_ptrace_detach_success): Add inferior parameter, use it
9130 instead of inferior_ptid, pass it to detach_inferior.
9131 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
9133 * inferior.c (detach_inferior): Add overload that takes an
9135 * inferior.h (detach_inferior): Likewise.
9136 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
9137 use inferior_ptid, adjust call to inf_ptrace_detach_success.
9138 * linux-thread-db.c (thread_db_detach): Use inf parameter.
9140 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9142 * target.h (struct target_ops) <to_detach>: Add inferior
9144 (target_detach): Likewise.
9145 * target.c (dispose_inferior): Pass inferior down.
9146 (target_detach): Pass inferior down. Assert that it is equal to
9147 the current inferior.
9148 * aix-thread.c (aix_thread_detach): Pass inferior down.
9149 * corefile.c (core_file_command): Pass current_inferior() down.
9150 * corelow.c (core_detach): Add inferior parameter.
9151 * darwin-nat.c (darwin_detach): Likewise.
9152 * gnu-nat.c (gnu_detach): Likewise.
9153 * inf-ptrace.c (inf_ptrace_detach): Likewise.
9154 * infcmd.c (detach_command): Pass current_inferior() down to
9156 * infrun.c (follow_fork_inferior): Pass parent_inf to
9158 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
9160 * linux-nat.c (linux_nat_detach): Add inferior parameter.
9161 * linux-thread-db.c (thread_db_detach): Likewise.
9162 * nto-procfs.c (procfs_detach): Likewise.
9163 * procfs.c (procfs_detach): Likewise.
9164 * record.c (record_detach): Likewise.
9165 * record.h (struct inferior): Forward-declare.
9166 (record_detach): Add inferior parameter.
9167 * remote-sim.c (gdbsim_detach): Likewise.
9168 * remote.c (remote_detach_1): Likewise.
9169 (remote_detach): Likewise.
9170 (extended_remote_detach): Likewise.
9171 * sol-thread.c (sol_thread_detach): Likewise.
9172 * target-debug.h (target_debug_print_inferior_p): New macro.
9173 * target-delegates.c: Re-generate.
9174 * top.c (kill_or_detach): Pass inferior down to target_detach.
9175 * windows-nat.c (windows_detach): Add inferior parameter.
9177 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9179 * target.h (struct target_ops) <to_detach>: Remove args
9181 (target_detach): Likewise.
9182 * target.c (dispose_inferior): Adjust.
9183 (target_detach): Remove args parameter, adjust.
9184 * aix-thread.c (aix_thread_detach): Adjust.
9185 * corefile.c (core_file_command): Adjust.
9186 * corelow.c (core_detach): Adjust.
9187 * darwin-nat.c (darwin_detach): Adjust.
9188 * gnu-nat.c (gnu_detach): Adjust.
9189 * inf-ptrace.c (inf_ptrace_detach): Adjust.
9190 * infcmd.c (detach_command): Adjust
9191 * infrun.c (follow_fork_inferior): Adjust.
9192 (handle_vfork_child_exec_or_exit): Adjust.
9193 * linux-fork.c (linux_fork_detach): Remove args parameter.
9194 * linux-fork.h (linux_fork_detach): Likewise.
9195 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
9196 * linux-thread-db.c (thread_db_detach): Likewise.
9197 * nto-procfs.c (procfs_detach): Likewise.
9198 * procfs.c (procfs_detach): Likewise.
9199 (do_detach): Remove signo parameter.
9200 * record.c (record_detach): Remove args parameter.
9201 * record.h (record_detach): Likewise.
9202 * remote-sim.c (gdbsim_detach): Likewise.
9203 * remote.c (remote_detach_1): Likewise.
9204 (remote_detach): Likewise.
9205 (extended_remote_detach): Likewise.
9206 * sol-thread.c (sol_thread_detach): Likewise.
9207 * target-delegates.c: Re-generate.
9208 * top.c (struct qt_args) <args>: Remove field.
9209 (kill_or_detach): Don't pass args.
9210 (quit_force): Don't set args.
9211 * windows-nat.c (windows_detach): Remove args parameter.
9213 2018-01-19 Yao Qi <yao.qi@linaro.org>
9215 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
9216 (arm_linux_init_abi): Install it.
9218 2018-01-19 Yao Qi <yao.qi@linaro.org>
9220 * osabi.c (gdb_osabi_names): Extend the regexp for
9221 arm-linux-gnueabihf.
9223 2018-01-18 Yao Qi <yao.qi@linaro.org>
9225 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
9227 (abbrev_table::add_abbrev): Update.
9228 (abbrev_table::lookup_abbrev): Update.
9230 2018-01-18 Yao Qi <yao.qi@linaro.org>
9232 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
9234 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
9236 * compile/compile.c (compile_to_object): Convert "triplet_rx"
9239 2018-01-17 Tom Tromey <tom@tromey.com>
9241 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
9243 2018-01-17 Tom Tromey <tom@tromey.com>
9245 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
9246 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
9247 (create_array_type_with_stride): Update.
9248 * dwarf2read.c (set_die_type): Update.
9250 2018-01-17 Tom Tromey <tom@tromey.com>
9252 * dwarf2read.c (delayed_method_info): Remove typedef.
9253 (dwarf2_cu::method_info): Now a std::vector.
9254 (add_to_method_list): Update.
9255 (free_delayed_list): Remove.
9256 (compute_delayed_physnames): Update.
9257 (process_full_comp_unit, process_full_type_unit): Clear the method
9258 list. Remove cleanups.
9259 (psymtab_include_file_name): Add name_holder parameter. Use
9261 (dwarf_decode_lines): Update.
9263 2018-01-17 Tom Tromey <tom@tromey.com>
9264 Simon Marchi <simon.marchi@ericsson.com>
9266 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
9267 (dwarf2_per_objfile::free_cached_comp_units)
9268 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9269 (init_cutu_and_read_dies_no_follow): Update.
9270 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
9271 (dwarf2_cu::~dwarf2_cu): New.
9272 (free_heap_comp_unit, free_stack_comp_unit): Remove.
9273 (age_cached_comp_units, free_one_cached_comp_unit): Update.
9275 2018-01-17 Tom Tromey <tom@tromey.com>
9276 Simon Marchi <simon.marchi@ericsson.com>
9278 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
9279 (struct die_reader_specs) <abbrev_table>: New member.
9280 (struct abbrev_table): Add constructor.
9281 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
9282 <abbrev_obstack>: Now an auto_obstack.
9283 (abbrev_table_up): New typedef.
9284 (init_cu_die_reader): Add abbrev_table parameter.
9285 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
9286 Add result_dwo_abbrev_table.
9287 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9288 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
9290 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
9292 (skip_children): Update.
9293 (abbrev_table::alloc_abbrev): Rename from
9294 abbrev_table_alloc_abbrev.
9295 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
9296 (abbrev_table::lookup_abbrev): Rename from
9297 abbrev_table_lookup_abbrev.
9298 (abbrev_table_read_table): Return abbrev_table_up.
9299 (abbrev_table_free, abbrev_table_free_cleanup)
9300 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
9301 (load_partial_dies): Update.
9303 2018-01-17 Tom Tromey <tom@tromey.com>
9305 * dwarf2read.c (dwarf2_compute_name): Update comment.
9306 (read_func_scope, read_variable): Update.
9307 (new_symbol): Remove.
9308 (new_symbol_full): Rename to new_symbol.
9310 2018-01-17 Mike Gulick <mgulick@mathworks.com>
9313 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
9314 a warning instead of throwing an error, set section size to 0 and return
9316 * gdb_bfd.h (gdb_bfd_map_section): Update description.
9318 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9320 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
9322 (linux_ptrace_attach_fail_reason_string): Likewise.
9323 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
9325 (linux_ptrace_attach_fail_reason_string): Likewise.
9326 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
9328 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9330 * linux-nat.c (linux_nat_attach): Remove xstrdup.
9332 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
9335 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
9336 checking for fs_base/gs_base fields in struct user_regs_struct.
9337 * configure: Regenerate.
9339 2018-01-17 Yao Qi <yao.qi@linaro.org>
9341 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
9343 (aarch64_linux_init_abi): Install it to gdbarch hook
9346 2018-01-15 Pedro Alves <palves@redhat.com>
9348 * common/signals-state-save-restore.c
9349 (save_original_signals_state): Fix typos.
9351 2017-01-12 Tom Tromey <tom@tromey.com>
9352 Sergio Durigan Junior <sergiodj@redhat.com>
9354 * Makefile.in (install-only): Install gdb-add-index.
9356 2018-01-12 John Baldwin <jhb@FreeBSD.org>
9358 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
9360 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9362 * infrun.c (keep_going_pass_signal): Clear step-over info when
9363 insert_breakpoints fails.
9365 2018-01-11 Pedro Alves <palves@redhat.com>
9368 * infrun.c (resume): Rename to ...
9369 (resume_1): ... this.
9370 (resume): Reimplement as wrapper around resume_1.
9372 2018-01-11 Pedro Alves <palves@redhat.com>
9375 * remote.c (remote_parse_stop_reply): Default to the last-set
9376 general thread instead of to 'magic_null_ptid'.
9378 2018-01-10 Pedro Alves <palves@redhat.com>
9380 * language.h (language_get_symbol_name_matcher): Rename ...
9381 (get_symbol_name_matcher): ... this.
9382 * language.c (language_get_symbol_name_matcher): Ditto.
9383 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
9386 2018-01-10 Pedro Alves <palves@redhat.com>
9390 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
9391 Adjust to use language_get_symbol_name_matcher instead of
9392 language_defn::la_get_symbol_name_matcher.
9393 * language.c (language_get_symbol_name_matcher): If in Ada mode
9394 and the lookup name is a verbatim match, return Ada's matcher.
9395 * language.h (language_get_symbol_name_matcher): Adjust comment.
9396 (ada_lookup_name_info::verbatim_p):: New method.
9398 2018-01-10 Pedro Alves <palves@redhat.com>
9401 * ada-lang.c (ada_collect_symbol_completion_matches): If the
9402 minsym's language is language_auto or language_cplus, pass down
9403 language_ada instead.
9404 * symtab.c (compare_symbol_name): Don't frob symbol language here.
9406 2018-01-10 Pedro Alves <palves@redhat.com>
9409 * minsyms.c (linkage_name_str): New function.
9410 (iterate_over_minimal_symbols): Use it.
9412 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9414 * NEWS: Document that 'info proc' now works on FreeBSD.
9416 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9418 * configure.ac: Check for kinfo_getfile in libutil.
9419 * configure: Regenerate.
9420 * config.in: Regenerate.
9421 * fbsd-nat.c: Include "fbsd-tdep.h".
9422 (fbsd_fetch_cmdline): New.
9423 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
9424 rather than calling error.
9425 (fbsd_info_proc): New.
9426 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
9427 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
9428 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
9430 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9432 * fbsd-nat.c (struct free_deleter): Remove.
9433 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
9435 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9437 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
9438 NULL for an empty pathname.
9440 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9442 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
9443 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
9444 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
9445 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
9446 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
9447 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
9448 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
9449 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
9450 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
9451 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
9452 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
9453 (fbsd_core_fetch_timeval, fbsd_print_sigset)
9454 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
9455 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
9456 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
9458 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
9460 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
9461 (gnu_xfer_auxv): New function.
9462 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
9465 2018-01-08 Yao Qi <yao.qi@linaro.org>
9466 Simon Marchi <simon.marchi@ericsson.com>
9468 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
9470 (COMMON_OBS): Remove selftest.o.
9471 * configure.ac: Append selftest-arch.c and common/selftest.c to
9472 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
9473 * configure: Re-generated.
9474 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
9476 (maintenance_info_selftests): Likewise.
9478 2018-01-08 Xavier Roirand <roirand@adacore.com>
9480 * ada-valprint.c (val_print_packed_array_elements): Use
9481 proper number of elements when printing an array indexed
9482 by an enumeration type.
9484 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9486 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
9487 (dw2_get_file_names_reader): Adjust.
9488 (lookup_dwo_signatured_type): Adjust.
9489 (lookup_dwp_signatured_type): Adjust.
9490 (lookup_signatured_type): Adjust.
9491 (create_type_unit_group): Adjust.
9492 (get_type_unit_group): Adjust.
9493 (process_psymtab_comp_unit_reader): Adjust.
9494 (build_type_psymtabs_reader): Adjust.
9495 (scan_partial_symbols): Adjust.
9496 (add_partial_symbol): Adjust.
9497 (add_partial_subprogram): Adjust.
9498 (peek_die_abbrev): Adjust.
9499 (fixup_go_packaging): Adjust.
9500 (process_imported_unit_die): Adjust.
9501 (dwarf2_compute_name): Adjust.
9502 (dwarf2_physname): Adjust.
9503 (read_import_statement): Adjust.
9504 (handle_DW_AT_stmt_list): Adjust.
9505 (read_file_scope): Adjust.
9506 (read_func_scope): Adjust.
9507 (read_lexical_block_scope): Adjust.
9508 (read_call_site_scope): Adjust.
9509 (read_variable): Adjust.
9510 (dwarf2_rnglists_process): Adjust.
9511 (dwarf2_ranges_process): Adjust.
9512 (dwarf2_ranges_read): Adjust.
9513 (dwarf2_get_pc_bounds): Adjust.
9514 (dwarf2_record_block_ranges): Adjust.
9515 (dwarf2_add_field): Adjust.
9516 (dwarf2_add_member_fn): Adjust.
9517 (read_structure_type): Adjust.
9518 (process_structure_scope): Adjust.
9519 (read_enumeration_type): Adjust.
9520 (read_array_type): Adjust.
9521 (mark_common_block_symbol_computed): Adjust.
9522 (read_common_block): Adjust.
9523 (read_namespace_type): Adjust.
9524 (read_namespace): Adjust.
9525 (read_module_type): Adjust.
9526 (read_tag_pointer_type): Adjust.
9527 (read_tag_ptr_to_member_type): Adjust.
9528 (read_tag_string_type): Adjust.
9529 (read_subroutine_type): Adjust.
9530 (read_typedef): Adjust.
9531 (read_base_type): Adjust.
9532 (attr_to_dynamic_prop): Adjust.
9533 (read_subrange_type): Adjust.
9534 (read_unspecified_type): Adjust.
9535 (dwarf2_read_abbrevs): Adjust.
9536 (load_partial_dies): Adjust.
9537 (read_partial_die): Adjust.
9538 (find_partial_die): Adjust.
9539 (guess_partial_die_structure_name): Adjust.
9540 (fixup_partial_die): Adjust.
9541 (read_attribute_value): Adjust.
9542 (read_addr_index): Adjust.
9543 (read_addr_index_from_leb128): Adjust.
9544 (read_str_index): Adjust.
9545 (dwarf2_string_attr): Adjust.
9546 (get_debug_line_section): Adjust.
9547 (dwarf_decode_line_header): Adjust.
9548 (lnp_state_machine::check_line_address): Adjust.
9549 (dwarf_decode_lines_1): Adjust.
9550 (dwarf_decode_lines): Adjust.
9551 (dwarf2_start_symtab): Adjust.
9552 (var_decode_location): Adjust.
9553 (new_symbol_full): Adjust.
9554 (dwarf2_const_value_data): Adjust.
9555 (dwarf2_const_value_attr): Adjust.
9556 (dwarf2_const_value): Adjust.
9558 (die_containing_type): Adjust.
9559 (build_error_marker_type): Adjust.
9560 (lookup_die_type): Adjust.
9561 (guess_full_die_structure_name): Adjust.
9562 (anonymous_struct_prefix): Adjust.
9563 (determine_prefix): Adjust.
9564 (dwarf2_name): Adjust.
9565 (follow_die_ref_or_sig): Adjust.
9566 (follow_die_offset): Adjust.
9567 (follow_die_ref): Adjust.
9568 (follow_die_sig_1): Adjust.
9569 (follow_die_sig): Adjust.
9570 (get_signatured_type): Adjust.
9571 (get_DW_AT_signature_type): Adjust.
9572 (decode_locdesc): Adjust.
9573 (dwarf_decode_macros): Adjust.
9574 (cu_debug_loc_section): Adjust.
9575 (fill_in_loclist_baton): Adjust.
9576 (dwarf2_symbol_mark_computed): Adjust.
9577 (init_one_comp_unit): Don't assign
9578 dwarf2_cu::dwarf2_per_objfile.
9579 (set_die_type): Adjust.
9581 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9583 * dwarf2read.c (struct mapped_debug_names): Add constructor.
9584 <dwarf2_per_objfile>: New field.
9585 (dwarf2_per_objfile): Remove global.
9586 (get_dwarf2_per_objfile): New function.
9587 (set_dwarf2_per_objfile): New function.
9588 (dwarf2_build_psymtabs_hard): Change objfile parameter to
9590 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9591 (read_abbrev_offset): Likewise.
9592 (read_indirect_string): Likewise.
9593 (read_indirect_line_string): Likewise.
9594 (read_indirect_string_at_offset): Likewise.
9595 (read_indirect_string_from_dwz): Likewise.
9596 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9598 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9599 (create_all_comp_units): Change objfile parameter to
9601 (create_all_type_units): Likewise.
9602 (process_queue): Add dwarf2_per_objfile parameter.
9603 (read_and_check_comp_unit_head): Likewise.
9604 (lookup_dwo_unit_in_dwp): Likewise.
9605 (get_dwp_file): Likewise.
9606 (process_cu_includes): Likewise.
9607 (struct free_dwo_file_cleanup_data): New struct.
9608 (dwarf2_has_info): Use get_dwarf2_per_objfile and
9609 set_dwarf2_per_objfile.
9610 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
9611 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
9612 context, adjust calls.
9613 (dw2_instantiate_symtab): Likewise.
9614 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
9615 (dw2_get_cu): Likewise.
9616 (create_cu_from_index_list): Change objfile parameter to
9618 (create_cus_from_index_list): Get dwarf2_per_objfile from
9619 context, adjust calls.
9620 (create_cus_from_index): Likewise.
9621 (create_signatured_type_table_from_index): Change objfile
9622 parameter to dwarf2_per_objfile.
9623 (create_signatured_type_table_from_debug_names): Change objfile
9624 parameter to dwarf2_per_objfile.
9625 (create_addrmap_from_index): Likewise.
9626 (create_addrmap_from_aranges): Likewise.
9627 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
9628 (dw2_setup): Remove.
9629 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
9631 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
9632 get_dwarf2_per_objfile.
9633 (dw2_forget_cached_source_info): Likewise.
9634 (dw2_map_symtabs_matching_filename): Likewise.
9635 (struct dw2_symtab_iterator) <index>: Remove.
9636 <dwarf2_per_objfile>: New field.
9637 (dw2_symtab_iter_init): Replace index parameter with
9639 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
9640 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
9641 (dw2_print_stats): Likewise.
9642 (dw2_dump): Likewise.
9643 (dw2_expand_symtabs_for_function): Likewise.
9644 (dw2_expand_all_symtabs): Likewise.
9645 (dw2_expand_symtabs_with_fullname): Likewise.
9646 (dw2_expand_marked_cus): Replace index and objfile parameters
9647 with dwarf2_per_objfile.
9648 (dw_expand_symtabs_matching_file_matcher): Add
9649 dwarf2_per_objfile parameter and adjust calls.
9650 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
9652 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
9653 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
9655 (create_cus_from_debug_names_list): Replace objfile parameter
9656 with dwarf2_per_objfile and adjust calls.
9657 (create_cus_from_debug_names): Likewise.
9658 (dwarf2_read_debug_names): Likewise.
9659 (mapped_debug_names::namei_to_name): Adjust call.
9660 (dw2_debug_names_iterator::next): Likewise.
9661 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
9662 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
9663 (dw2_debug_names_dump): Likewise.
9664 (dw2_debug_names_expand_symtabs_for_function): Likewise.
9665 (dw2_debug_names_expand_symtabs_matching): Likewise.
9666 (dwarf2_initialize_objfile): Likewise.
9667 (dwarf2_build_psymtabs): Likewise.
9668 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
9670 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
9671 (read_and_check_comp_unit_head): Likewise.
9672 (read_abbrev_offset): Likewise.
9673 (create_debug_type_hash_table): Likewise.
9674 (create_debug_types_hash_table): Likewise.
9675 (create_all_type_units): Replace objfile parameter with
9677 (add_type_unit): Add dwarf2_per_objfile parameter.
9678 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
9679 with dwarf2_per_objfile.
9680 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
9681 (lookup_dwp_signatured_type): Likewise.
9682 (lookup_signatured_type): Likewise.
9683 (read_cutu_die_from_dwo): Likewise.
9684 (init_tu_and_read_dwo_dies): Likewise.
9685 (init_cutu_and_read_dies): Likewise.
9686 (init_cutu_and_read_dies_no_follow): Likewise.
9687 (allocate_type_unit_groups_table): Add objfile parameter.
9688 (create_type_unit_group): Use dwarf2_per_objfile from cu.
9689 (get_type_unit_group): Likewise.
9690 (process_psymtab_comp_unit): Update call.
9691 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
9692 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
9693 (print_tu_stats): Likewise.
9694 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
9696 (build_type_psymtabs): Change objfile parameter to
9698 (process_skeletonless_type_unit): Use dwarf2_per_objfile
9699 passed in void* parameter.
9700 (process_skeletonless_type_units): Change objfile parameter to
9702 (set_partial_user): Likewise.
9703 (dwarf2_build_psymtabs_hard): Likewise.
9704 (read_comp_units_from_section): Likewise.
9705 (create_all_comp_units): Likewise.
9706 (scan_partial_symbols): Update calls.
9707 (add_partial_symbol): Likewise.
9708 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
9709 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
9710 (process_queue): Add dwarf2_per_objfile parameter.
9711 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
9712 (compute_compunit_symtab_includes): Likewise.
9713 (process_cu_includes): Add dwarf2_per_objfile parameter.
9714 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
9715 (process_full_type_unit): Likewise.
9716 (process_imported_unit_die): Update call.
9717 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
9718 (read_file_scope): Likewise.
9719 (allocate_dwo_file_hash_table): Add objfile parameter.
9720 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
9721 (create_cus_hash_table): Likewise.
9722 (create_dwp_hash_table): Likewise.
9723 (create_dwo_unit_in_dwp_v1): Likewise.
9724 (create_dwp_v2_section): Likewise.
9725 (create_dwo_unit_in_dwp_v2): Likewise.
9726 (lookup_dwo_unit_in_dwp): Likewise.
9727 (try_open_dwop_file): Likewise.
9728 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
9729 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
9730 cleanup to include a reference to dwarf2_per_objfile.
9731 (open_dwp_file): Add dwarf2_per_objfile parameter.
9732 (open_and_init_dwp_file): Likewise.
9733 (get_dwp_file): Likewise.
9734 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
9735 (queue_and_load_all_dwo_tus): Update call.
9736 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
9738 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
9739 (dwarf2_ranges_process): Likewise.
9740 (dwarf2_get_pc_bounds): Likewise.
9741 (mark_common_block_symbol_computed): Likewise.
9742 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9743 (dwarf2_read_abbrevs): Update call.
9744 (read_partial_die): Use dwarf2_per_objfile from cu.
9745 (find_partial_die): Likewise.
9746 (fixup_partial_die): Likewise.
9747 (read_attribute_value): Likewise.
9748 (read_indirect_string_at_offset_from): Add objfile parameter.
9749 (read_indirect_string_at_offset): Add dwarf2_per_objfile
9751 (read_indirect_string_from_dwz): Add objfile parameter.
9752 (read_indirect_string): Add objfile parameter.
9753 (read_addr_index_1): Add dwarf2_per_objfile parameter.
9754 (read_addr_index): Use dwarf2_per_objfile from cu.
9755 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
9757 (read_str_index): Use dwarf2_per_objfile from cu.
9758 (get_debug_line_section): Likewise.
9759 (read_formatted_entries): Add dwarf2_per_objfile parameter.
9760 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
9761 (new_symbol_full): Use dwarf2_per_objfile from cu.
9762 (build_error_marker_type): Likewise.
9763 (lookup_die_type): Likewise.
9764 (determine_prefix): Likewise.
9765 (follow_die_offset): Likewise.
9766 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
9767 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
9768 (dwarf2_fetch_die_type_sect_off): Likewise.
9769 (dwarf2_get_die_type): Likewise.
9770 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
9771 (get_signatured_type): Likewise.
9772 (get_DW_AT_signature_type): Likewise.
9773 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
9774 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
9775 (cu_debug_loc_section): Likewise.
9776 (fill_in_loclist_baton): Likewise.
9777 (dwarf2_symbol_mark_computed): Likewise.
9778 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9780 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
9782 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9783 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
9784 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
9785 (set_die_type): Use dwarf2_free_objfile from cu.
9786 (get_die_type_at_offset): Likewise.
9787 (dwarf2_per_objfile_free): Don't assign global variable.
9788 (debug_names) <constructor>: Add dwarf2_per_objfile
9789 parameter, update m_debugstrlookup construction.
9790 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
9792 <m_dwarf2_per_objfile>: New field.
9793 <lookup>: Use m_dwarf2_per_objfile.
9794 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
9795 (psyms_seen_size): Likewise.
9796 (write_gdbindex): Replace objfile parameter with
9798 (write_debug_names): Likewise.
9799 (write_psymtabs_to_index): Likewise.
9800 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
9803 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9805 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
9806 <dwarf2_per_objfile>: New field.
9807 (struct dwarf2_per_cu_data) <objfile>: Remove.
9808 <dwarf2_per_objfile>: New field.
9809 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
9811 (create_signatured_type_table_from_index): Likewise.
9812 (create_debug_type_hash_table): Likewise.
9813 (fill_in_sig_entry_from_dwo_entry): Likewise.
9814 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
9815 (create_type_unit_group): Assign dwarf2_per_objfile instead of
9817 (create_partial_symtab): Access objfile through
9819 (process_psymtab_comp_unit_reader): Likewise.
9820 (read_comp_units_from_section): Likewise.
9821 (scan_partial_symbols): Likewise.
9822 (add_partial_symbol): Likewise.
9823 (add_partial_subprogram): Likewise.
9824 (peek_die_abbrev): Likewise.
9825 (fixup_go_packaging): Likewise.
9826 (process_full_comp_unit): Likewise.
9827 (process_full_type_unit): Likewise.
9828 (process_imported_unit_die): Likewise.
9829 (dwarf2_compute_name): Likewise.
9830 (dwarf2_physname): Likewise.
9831 (read_import_statement): Likewise.
9832 (create_cus_hash_table): Assign dwarf2_physname instead of
9834 (read_func_scope): Access objfile through dwarf2_per_objfile.
9835 (read_lexical_block_scope): Likewise.
9836 (read_call_site_scope): Likewise.
9837 (read_variable): Likewise.
9838 (dwarf2_rnglists_process): Likewise.
9839 (dwarf2_ranges_process): Likewise.
9840 (dwarf2_ranges_read): Likewise.
9841 (dwarf2_record_block_ranges): Likewise.
9842 (dwarf2_add_field): Likewise.
9843 (dwarf2_add_member_fn): Likewise.
9844 (read_structure_type): Likewise.
9845 (process_structure_scope): Likewise.
9846 (read_enumeration_type): Likewise.
9847 (read_array_type): Likewise.
9848 (read_common_block): Likewise.
9849 (read_namespace_type): Likewise.
9850 (read_namespace): Likewise.
9851 (read_module_type): Likewise.
9852 (read_tag_pointer_type): Likewise.
9853 (read_tag_ptr_to_member_type): Likewise.
9854 (read_tag_string_type): Likewise.
9855 (read_subroutine_type): Likewise.
9856 (read_typedef): Likewise.
9857 (read_base_type): Likewise.
9858 (attr_to_dynamic_prop): Likewise.
9859 (read_subrange_type): Likewise.
9860 (read_unspecified_type): Likewise.
9861 (load_partial_dies): Likewise.
9862 (read_partial_die): Likewise.
9863 (find_partial_die): Likewise.
9864 (guess_partial_die_structure_name): Likewise.
9865 (fixup_partial_die): Likewise.
9866 (read_attribute_value): Likewise.
9867 (read_addr_index_from_leb128): Likewise.
9868 (dwarf2_read_addr_index): Likewise.
9869 (dwarf2_string_attr): Likewise.
9870 (lnp_state_machine::check_line_address): Likewise.
9871 (dwarf_decode_lines_1): Likewise.
9872 (dwarf_decode_lines): Likewise.
9873 (dwarf2_start_symtab): Likewise.
9874 (var_decode_location): Likewise.
9875 (new_symbol_full): Likewise.
9876 (dwarf2_const_value_data): Likewise.
9877 (dwarf2_const_value_attr): Likewise.
9878 (dwarf2_const_value): Likewise.
9879 (die_type): Likewise.
9880 (die_containing_type): Likewise.
9881 (lookup_die_type): Likewise.
9882 (guess_full_die_structure_name): Likewise.
9883 (anonymous_struct_prefix): Likewise.
9884 (dwarf2_name): Likewise.
9885 (follow_die_ref_or_sig): Likewise.
9886 (follow_die_offset): Likewise.
9887 (follow_die_ref): Likewise.
9888 (dwarf2_fetch_die_loc_sect_off): Likewise.
9889 (dwarf2_fetch_constant_bytes): Likewise.
9890 (dwarf2_fetch_die_type_sect_off): Likewise.
9891 (dwarf2_get_die_type): Likewise.
9892 (follow_die_sig): Likewise.
9893 (decode_locdesc): Likewise.
9894 (dwarf2_per_cu_objfile): Likewise.
9895 (dwarf2_per_cu_text_offset): Likewise.
9896 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
9898 (set_die_type): Access objfile through
9901 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9903 * valprint.c (converted_character_d): Remove typedef.
9904 (DEF_VEC_O (converted_character_d)): Remove.
9905 (count_next_character): Use std::vector.
9906 (print_converted_chars_to_obstack): Likewise.
9907 (generic_printstr): Likewise.
9909 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9911 * xml-support.h (struct gdb_xml_value): Add constructor.
9912 <value>: Change type to unique_xmalloc_ptr.
9913 (gdb_xml_value_s): Remove typedef.
9914 (DEF_VEC_O (gdb_xml_value_s)): Remove.
9915 (gdb_xml_element_start_handler): Change parameter type to
9917 (xml_find_attribute): Likewise.
9918 * xml-support.c (xml_find_attribute): Change parameter type to
9919 std::vector and adjust.
9920 (gdb_xml_values_cleanup): Remove.
9921 (gdb_xml_parser::start_element): Adjust to std::vector.
9922 (xinclude_start_include): Change paraeter type to std::vector
9924 * btrace.c (check_xml_btrace_version): Likewise.
9925 (parse_xml_btrace_block): Likewise.
9926 (parse_xml_btrace_pt_config_cpu): Likewise.
9927 (parse_xml_btrace_pt): Likewise.
9928 (parse_xml_btrace_conf_bts): Likewise.
9929 (parse_xml_btrace_conf_pt): Likewise.
9930 * memory-map.c (memory_map_start_memory): Likewise.
9931 (memory_map_start_property): Likewise.
9932 * osdata.c (osdata_start_osdata): Likewise.
9933 (osdata_start_item): Likewise.
9934 (osdata_start_column): Likewise.
9935 * remote.c (start_thread): Likewise.
9936 * solib-aix.c (library_list_start_library): Likewise.
9937 (library_list_start_list): Likewise.
9938 * solib-svr4.c (library_list_start_library): Likewise.
9939 (svr4_library_list_start_list): Likewise.
9940 * solib-target.c (library_list_start_segment): Likewise.
9941 (library_list_start_section): Likewise.
9942 (library_list_start_library): Likewise.
9943 (library_list_start_list): Likewise.
9944 * tracepoint.c (traceframe_info_start_memory): Likewise.
9945 (traceframe_info_start_tvar): Likewise.
9946 * xml-syscall.c (syscall_start_syscall): Likewise.
9947 * xml-tdesc.c (tdesc_start_target): Likewise.
9948 (tdesc_start_feature): Likewise.
9949 (tdesc_start_reg): Likewise.
9950 (tdesc_start_union): Likewise.
9951 (tdesc_start_struct): Likewise.
9952 (tdesc_start_flags): Likewise.
9953 (tdesc_start_enum): Likewise.
9954 (tdesc_start_field): Likewise.
9955 (tdesc_start_enum_value): Likewise.
9956 (tdesc_start_vector): Likewise.
9958 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9960 * extension.h (struct xmethod_worker) <clone>: Remove.
9961 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
9963 (python_xmethod_worker::clone): Remove.
9964 * valops.c (find_overload_match): Use std::move instead of
9967 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9969 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
9970 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
9971 <free_xmethod_worker_data>: Remove.
9972 <get_matching_xmethod_workers>: Chance VEC to std::vector.
9973 <get_xmethod_arg_types>: Remove.
9974 <get_xmethod_result_type>: Remove.
9975 <invoke_xmethod>: Remove.
9976 * extension.c (new_xmethod_worker): Remove.
9977 (clone_xmethod_worker): Remove.
9978 (get_matching_xmethod_workers): Return void, pass std::vector by
9980 (get_xmethod_arg_types): Rename to...
9981 (xmethod_worker::get_arg_types): ... this, and adjust.
9982 (get_xmethod_result_type): Rename to...
9983 (xmethod_worker::get_result_type): ... this, and adjust.
9984 (invoke_xmethod): Remove.
9985 (free_xmethod_worker): Remove.
9986 (free_xmethod_worker_vec): Remove.
9987 * extension.h (enum ext_lang_rc): Move here from
9989 (struct xmethod_worker): Add constructor and destructor.
9992 <invoke, clone, do_get_result_type, do_get_arg_types>: New
9993 virtual pure methods.
9994 <get_arg_types, get_result_type>: New methods.
9995 (xmethod_worker_ptr): Remove typedef.
9996 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
9997 (xmethod_worker_vec): Remove typedef.
9998 (xmethod_worker_up): New typedef.
9999 (invoke_xmethod): Remove.
10000 (clone_xmethod_worker): Remove.
10001 (free_xmethod_worker): Remove.
10002 (free_xmethod_worker_vec): Remove.
10003 (get_xmethod_arg_types): Remove.
10004 (get_xmethod_result_type): Remove.
10005 * valops.c (find_method_list): Use std::vector, don't use
10006 intermediate vector.
10007 (value_find_oload_method_list): Use std::vector.
10008 (find_overload_match): Use std::vector.
10009 (find_oload_champ): Use std::vector.
10010 * value.c (value_free): Use operator delete.
10011 (value_of_xmethod): Rename to...
10012 (value_from_xmethod): ... this. Don't assign
10013 xmethod_worker::value, take rvalue-reference.
10014 (result_type_of_xmethod): Adjust.
10015 (call_xmethod): Adjust.
10016 * value.h: Include extension.h.
10017 (struct xmethod_worker): Don't forward-declare.
10018 (value_of_xmethod): Rename to...
10019 (value_from_xmethod): ... this, take rvalue-reference.
10020 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
10021 (struct python_xmethod_worker): ... this, add constructor and
10023 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
10024 (gdbpy_free_xmethod_worker_data): Rename to...
10025 (python_xmethod_worker::~python_xmethod_worker): ... this and
10027 (gdbpy_clone_xmethod_worker_data): Rename to...
10028 (python_xmethod_worker::clone): ... this and adjust.
10029 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
10031 (gdbpy_get_xmethod_arg_types): Rename to...
10032 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
10033 (gdbpy_get_xmethod_result_type): Rename to...
10034 (python_xmethod_worker::do_get_result_type): ... this and
10036 (gdbpy_invoke_xmethod): Rename to...
10037 (python_xmethod_worker::invoke): ... this and adjust.
10038 (new_python_xmethod_worker): Rename to...
10039 (python_xmethod_worker::python_xmethod_worker): ... this and
10041 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
10043 (gdbpy_free_xmethod_worker_data): Remove.
10044 (gdbpy_get_matching_xmethod_workers): Use std::vector.
10045 (gdbpy_get_xmethod_arg_types): Remove.
10046 (gdbpy_get_xmethod_result_type): Remove.
10047 (gdbpy_invoke_xmethod): Remove.
10048 * python/python.c (python_extension_ops): Remove obsolete
10051 2018-01-05 Pedro Alves <palves@redhat.com>
10054 * common/signals-state-save-restore.c
10055 (save_original_signals_state): New parameter 'quiet'. Warn if we
10056 find a custom handler preinstalled, instead of internal erroring.
10057 But only warn if !quiet.
10058 * common/signals-state-save-restore.h
10059 (save_original_signals_state): New parameter 'quiet'.
10060 * main.c (captured_main_1): Move save_original_signals_state call
10061 after option handling, and pass QUIET.
10063 2018-01-05 Pedro Alves <palves@redhat.com>
10065 * spu-tdep.c (spu_catch_start): Pass
10066 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
10068 2018-01-05 Pedro Alves <palves@redhat.com>
10071 * ada-lang.c (literal_symbol_name_matcher): New function.
10072 (ada_get_symbol_name_matcher): Use it for
10073 symbol_name_match_type::SEARCH_NAME.
10074 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
10075 it down instead of assuming symbol_name_match_type::FULL.
10076 * block.h (block_lookup_symbol): New parameter 'match_type'.
10077 * c-valprint.c (print_unpacked_pointer): Use
10078 lookup_symbol_search_name instead of lookup_symbol.
10079 * compile/compile-object-load.c (get_out_value_type): Pass down
10080 symbol_name_match_type::SEARCH_NAME.
10081 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
10082 symbol_name_match_type::FULL.
10083 * cp-support.c (cp_get_symbol_name_matcher): Handle
10084 symbol_name_match_type::SEARCH_NAME.
10085 * infrun.c (insert_exception_resume_breakpoint): Use
10086 lookup_symbol_search_name.
10087 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
10088 * psymtab.c (maintenance_check_psymtabs): Use
10089 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
10090 * stack.c (print_frame_args): Use lookup_symbol_search_name and
10091 SYMBOL_SEARCH_NAME.
10092 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
10093 if symbol_name_match_type::SEARCH_NAME.
10094 (lookup_symbol_in_language): Pass down
10095 symbol_name_match_type::FULL.
10096 (lookup_symbol_search_name): New.
10097 (lookup_language_this): Pass down
10098 symbol_name_match_type::SEARCH_NAME.
10099 (lookup_symbol_aux, lookup_local_symbol): New parameter
10100 'match_type'. Pass it down.
10101 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
10102 (lookup_symbol_search_name): New declaration.
10103 (lookup_symbol_in_block): New 'match_type' parameter.
10105 2018-01-05 Pedro Alves <palves@redhat.com>
10108 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
10110 (ada_lookup_symbol): Reimplement in terms of
10111 ada_lookup_symbol_list, bits factored out from
10112 ada_lookup_encoded_symbol.
10114 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10116 * ada-exp.y (write_object_renaming): When subscripting an array
10117 using a symbol as the index, pass the block in call to
10118 ada_lookup_encoded_symbol when looking that symbol up.
10120 2018-01-05 Jerome Guitton <guitton@adacore.com>
10122 * ada-lang.c (ada_array_length): Use ada_index_type instead of
10125 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10127 * ada-lang.c (ada_to_fixed_value_create): Add handling of
10128 the case where VALUE_LVAL (val0) is not lval_memory.
10130 2018-01-05 Xavier Roirand <roirand@adacore.com>
10132 * ada-valprint.c (print_optional_low_bound): Handle
10133 character-indexed array printing like boolean-indexed array
10136 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10138 * NEWS: Create a new section for the next release branch.
10139 Rename the section of the current branch, now that it has
10142 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10144 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
10145 * version.in: Bump version to 8.1.50.DATE-git.
10147 2018-01-03 Xavier Roirand <roirand@adacore.com>
10149 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
10151 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
10153 (default_exception_support_info) <catch_handlers_sym>: Add field.
10154 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
10155 (ada_exception_name_addr_1): Add "catch handlers" handling.
10156 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
10157 Update all callers.
10158 (create_excep_cond_exprs) <ex>: Add parameter.
10159 (re_set_exception): Update create_excep_cond_exprs call.
10160 (print_it_exception, print_one_exception, print_mention_exception)
10161 (print_recreate_exception): Add "catch handler" handling.
10162 (allocate_location_catch_handlers, re_set_catch_handlers)
10163 (check_status_catch_handlers, print_it_catch_handlers)
10164 (print_one_catch_handlers, print_mention_catch_handlers)
10165 (print_recreate_catch_handlers): New function.
10166 (catch_handlers_breakpoint_ops): New variable.
10167 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
10168 Add parameter. Add "catch handler" handling.
10169 (ada_exception_sym_name, ada_exception_breakpoint_ops):
10170 Add "catch handler" handling.
10171 (ada_exception_catchpoint_cond_string): Add "catch handler"
10173 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
10175 (catch_ada_handlers_command): New function.
10176 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
10177 operations structure.
10178 (_initialize_ada_language): Add "catch handlers" command entry.
10179 * NEWS: Document "catch handlers" feature.
10181 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10183 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
10184 account when creating the array type of the slice.
10185 (ada_value_slice): Likewise.
10187 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10189 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
10191 (create_array_type_with_stride): Add byte_stride_prop parameter.
10192 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
10193 New parameter. Update all callers in this file.
10194 (array_type_has_dynamic_stride): New function.
10195 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
10196 of arrays with dynamic byte strides.
10197 * dwarf2read.c (read_array_type): Add support for dynamic
10198 DW_AT_byte_stride attributes.
10200 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10202 * dwarf2read.c (read_unspecified_type): Treat
10203 DW_TAG_enumeration_type DIEs from Ada units as stubs.
10205 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10207 Update copyright year range in all GDB files.
10209 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10211 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
10212 and gdb/testsuite/gdb.base/step-line.c.
10214 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10216 * copyright.py (main): Dump the contents of
10217 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
10218 even if BY_HAND is empty.
10220 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10222 * top.c (print_gdb_version): Update Copyright year in version
10225 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10227 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
10229 For older changes see ChangeLog-2017.
10235 version-control: never