1 2018-07-16 Tom Tromey <tom@tromey.com>
3 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
4 * dwarf2read.c (using_directives, new_symbol): Use
6 * dbxread.c (process_one_symbol): Use outermost_context_p.
7 * coffread.c (coff_symtab_read): Use outermost_context_p.
9 2018-07-16 Tom Tromey <tom@tromey.com>
11 * dwarf2read.c (using_directives, read_func_scope)
12 (read_lexical_block_scope): Update.
13 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
14 * buildsym.h (local_using_directives, global_using_directives):
16 (get_local_using_directives, set_local_using_directives)
17 (get_global_using_directives): Declare.
18 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
19 m_global_using_directives>: New members.
20 (finish_block_internal, prepare_for_building)
21 (reset_symtab_globals, end_symtab_get_static_block)
22 (push_context): Update.
23 (get_local_using_directives, set_local_using_directives)
24 (get_global_using_directives): New functions.
25 (buildsym_init): Update.
27 2018-07-16 Tom Tromey <tom@tromey.com>
29 * xcoffread.c (xcoff_initial_scan): Don't call
31 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
32 * buildsym.h (class scoped_free_pendings): Add constructor.
33 (free_pending_blocks): Don't declare.
34 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
35 (free_pending_blocks): Now static.
37 2018-07-16 Tom Tromey <tom@tromey.com>
39 * buildsym.h (push_subfile, pop_subfile): Update declarations.
40 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
42 (struct subfile_stack): Remove.
43 (subfile_stack): Remove.
44 (push_subfile, pop_subfile, buildsym_init): Update.
46 2018-07-16 Tom Tromey <tom@tromey.com>
48 * buildsym.c (push_subfile): Use gdb_assert.
49 (pop_subfile): Use gdb_assert.
51 2018-07-16 Tom Tromey <tom@tromey.com>
53 * buildsym.h (merge_symbol_lists): Remove.
54 * buildsym.c (merge_symbol_lists): Remove.
56 2018-07-16 Tom Tromey <tom@tromey.com>
58 * stabsread.c (scan_file_globals): Update comment.
59 * stabsread.h (scan_file_globals): Move from buildsym.h.
60 * buildsym.h (scan_file_globals): Move to stabsread.h.
62 2018-07-16 Tom Tromey <tom@tromey.com>
64 * xcoffread.c (xcoff_new_init): Update.
65 * mipsread.c (mipscoff_new_init): Update.
66 * mdebugread.c (mdebug_build_psymtabs): Update.
67 * elfread.c (elf_new_init): Update.
68 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
69 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
70 * buildsym.h (buildsym_new_init): Don't declare.
71 * buildsym.c (buildsym_new_init): Remove.
73 2018-07-16 Tom Tromey <tom@tromey.com>
75 * stabsread.h (within_function): Move from buildsym.h.
76 * stabsread.c (start_stabs): Clear within_function.
77 * coffread.c (coff_start_symtab): Clear within_function.
78 * buildsym.h (within_function): Move to stabsread.h.
79 * buildsym.c (prepare_for_building): Update.
81 2018-07-16 Tom Tromey <tom@tromey.com>
83 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
84 * dwarf2read.c (dwarf2_start_symtab): Don't set
85 processing_gcc_compilation.
86 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
88 2018-07-16 Tom Tromey <tom@tromey.com>
90 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
91 (next_symbol_text_func): Move from buildsym.h.
92 * stabsread.c (hashname): Move from buildsym.c.
93 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
94 (next_symbol_text_func, hashname): Move to stabsread.h.
95 * buildsym.c: Don't include bcache.h
96 (hashname): Move to stasbread.c.
98 2018-07-16 Tom Tromey <tom@tromey.com>
100 * buildsym.h (context_stack_size): Don't declare.
101 * buildsym.c (context_stack_size): New global.
103 2018-07-16 Tom Tromey <tom@tromey.com>
105 * dbxread.c (processing_acc_compilation): New global.
106 * buildsym.h (processing_acc_compilation): Don't declare.
108 2018-07-16 Tom Tromey <tom@tromey.com>
110 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
111 * dbxread.c (read_ofile_symtab): Update.
112 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
113 * buildsym.h (last_source_start_addr): Remove.
114 (set_last_source_start_addr, get_last_source_start_addr):
116 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
118 (struct buildsym_compunit) <m_last_source_start_addr>: New
120 (prepare_for_building): Remove start_addr parameter.
121 (start_symtab, restart_symtab, end_symtab_get_static_block)
122 (end_symtab_with_blockvector): Update.
123 (set_last_source_start_addr, get_last_source_start_addr): New
126 2018-07-16 Tom Tromey <tom@tromey.com>
128 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
130 (have_line_numbers): Remove.
131 (record_line, prepare_for_building, end_symtab_get_static_block)
132 (augment_type_symtab): Update.
134 2018-07-16 Tom Tromey <tom@tromey.com>
136 * buildsym.c (~buildsym_compunit): Free the macro table.
137 (struct buildsym_compunit) <get_macro_table, release_macros>: New
139 <m_pending_macros>: New member.
140 (pending_macros): Remove.
141 (~scoped_free_pendings, get_macro_table, prepare_for_building)
142 (reset_symtab_globals, end_symtab_get_static_block)
143 (end_symtab_with_blockvector, augment_type_symtab)
144 (buildsym_init): Update.
146 2018-07-16 Tom Tromey <tom@tromey.com>
148 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
150 (buildsym_compunit::set_last_source_file): New method.
151 <m_last_source_file>: New member.
152 (prepare_for_building): Remove "name" parameter.
153 (start_symtab, restart_symtab, reset_symtab_globals): Update.
154 (last_source_file): Remove.
155 (set_last_source_file, get_last_source_file): Update.
157 2018-07-16 Tom Tromey <tom@tromey.com>
159 * buildsym.c (prepare_for_building): Add assert.
161 2018-07-16 Tom Tromey <tom@tromey.com>
163 * buildsym.c (~buildsym_compunit): Update.
164 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
165 (start_subfile, patch_subfile_names)
166 (end_symtab_with_blockvector): Update.
168 2018-07-16 Tom Tromey <tom@tromey.com>
170 * buildsym.c (struct buildsym_compunit): Add constructor,
171 destructor, initializers.
172 (start_buildsym_compunit): Remove.
173 (free_buildsym_compunit): Use "delete".
174 (start_symtab, restart_symtab): Use "new".
176 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
178 * symfile.c (set_objfile_default_section_offset): Remove struct
181 2018-07-14 Stafford Horne <shorne@gmail.com>
183 * (Responsible Maintainers): Add myself as or1k maintainer.
185 2018-07-13 Tom Tromey <tom@tromey.com>
187 * symfile.c (set_objfile_default_section_offset): Use extra braces
190 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
192 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
195 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
197 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
198 unittests/cli-utils-selftests.c
199 * unittests/cli-utils-selftests.c: New file.
201 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
203 * NEWS: Mention new commands. Mention change to 'thread apply'.
205 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
207 * thread.c (thr_try_catch_cmd): New function.
208 (thread_apply_all_command): Handle qcs flags.
209 (thread_apply_command): Handle qcs flags.
210 (taas_command): New function.
211 (tfaas_command): New function.
212 (_initialize_thread): Update to setup the new commands 'taas
213 and 'tfaas'. Change doc string for 'thread apply'.
215 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
217 * stack.c: (trailing_outermost_frame): New function, mostly
218 extracted from backtrace_command_1.
219 (leading_innermost_frame): New function.
220 (backtrace_command_1): Update to call trailing_outermost_frame.
221 (frame_apply_command_count): New function.
222 (frame_apply_level_command): New function.
223 (frame_apply_all_command): New function.
224 (frame_apply_command): New function.
225 (faas_command): New function.
226 (frame_cmd_list): New variable.
227 (_initialize_stack): Update to setup the new commands 'frame apply'
230 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
232 * cli-utils.c (number_or_range_parser::get_number): Only handle
233 numbers or convenience var as numbers.
234 (parse_flags): New function.
235 (parse_flags_qcs): New function.
236 (number_or_range_parser::finished): Ensure parsing end is detected
237 before end of string.
238 * cli-utils.h (parse_flags): New function.
239 (parse_flags_qcs): New function.
240 (number_or_range_parser): Remove m_finished bool.
241 (number_or_range_parser::skip_range): Set m_in_range to false.
243 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
245 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
248 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
249 Jan Kratochvil <jan.kratochvil@redhat.com>
250 Paul Fertser <fercerpav@gmail.com>
251 Tsutomu Seki <sekiriki@gmail.com>
252 Pedro Alves <palves@redhat.com>
254 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
255 'unittests/parse-connection-spec-selftests.c'.
256 (COMMON_SFILES): Add 'common/netstuff.c'.
257 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
258 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
259 * common/netstuff.c: New file.
260 * common/netstuff.h: New file.
261 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
262 (wait_for_connect): Update comment. New parameter
263 'gdb::optional<int> sock' instead of 'struct serial *scb'.
264 Use 'sock' directly instead of 'scb->fd'.
265 (try_connect): New function, with code from 'net_open'.
266 (net_open): Rewrite main loop to deal with multiple
267 sockets/addresses. Handle IPv6-style hostnames; implement
268 support for IPv6 connections.
269 * unittests/parse-connection-spec-selftests.c: New file.
271 2018-07-11 Pedro Alves <palves@redhat.com>
274 * remote.c (remote_target::remote_detach_pid): Call
277 2018-07-11 Pedro Alves <palves@redhat.com>
279 * h8300-tdep.c (h8300_gdbarch_init): Remove
280 set_gdbarch_ecoff_reg_to_regnum calls.
282 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
285 * c-typeprint.c (c_type_print_base_struct_union): Don't print
286 offsets/sizes for static members of a class/struct.
288 2018-07-11 Alan Hayward <alan.hayward@arm.com>
290 * target-descriptions.c (tdesc_register_bitsize): Rename.
291 * target-descriptions.h (tdesc_register_bitsize): Likewise.
292 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
293 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
295 2018-07-10 Tom Tromey <tom@tromey.com>
297 * breakpoint.c (moribund_locations): Now static and a
299 (breakpoint_init_inferior, moribund_breakpoint_here_p)
300 (build_bpstat_chain, update_global_location_list)
301 (breakpoint_retire_moribund): Update.
302 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
305 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
307 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
308 (riscv_register_reggroup_p): Use new function, remove unneeded
310 (riscv_push_dummy_call): Extend assert to compare against xlen or
311 flen based on register type.
313 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
315 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
317 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
319 * remote.c (show_hardware_watchpoint_limit): New function.
320 (show_hardware_watchpoint_length_limit): New function.
321 (show_hardware_breakpoint_limit): New function.
322 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
323 where appropriate, update help text.
325 2018-07-09 Tom Tromey <tom@tromey.com>
327 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
328 (CLIBS): Don't mention NAT_CLIBS.
330 2018-07-09 Tom Tromey <tom@tromey.com>
332 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
333 (LIBGDB_OBS, clean mostlyclean): Update.
334 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
336 2018-07-09 Tom Tromey <tom@tromey.com>
338 * Makefile.in (%.c: %.y): Use ECHO_YACC.
339 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
340 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
342 2018-07-09 Tom Tromey <tom@tromey.com>
344 * Makefile.in (ALLDEPFILES): Remove exec.c.
345 (COMMON_OBS): Remove exec.o.
346 (COMMON_SFILES): Add exec.c.
348 2018-07-09 Tom Tromey <tom@tromey.com>
350 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
352 2018-07-09 Tom Tromey <tom@tromey.com>
354 * Makefile.in (clean mostlyclean): Remove stamp-version.
355 (version.c): Depend on stamp-version.
356 (stamp-version): New rule, from version.c rule.
358 2018-07-09 Tom Tromey <tom@tromey.com>
360 * Makefile.in (init.c): Depend on stamp-init.
361 (stamp-init): New rule, from init.c rule.
362 (clean mostlyclean): Remove stamp-init.
364 2018-07-09 Tom Tromey <tom@tromey.com>
366 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
367 SUBDIR_GCC_COMPILE_SRCS.
369 2018-07-09 Tom Tromey <tom@tromey.com>
371 * Makefile.in (init.c): Remove some unused sed rules.
373 2018-07-09 Tom Tromey <tom@tromey.com>
375 * Makefile.in (TSOBS): Remove.
376 (INIT_FILES): Update.
377 (LIBGDB_OBS): Update.
378 (COMMON_SFILES): Add inflow.c.
379 (SFILES): Remove inflow.c.
381 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
383 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
385 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
387 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
388 get_saveloc_name, is_signal_frame_name, step_name,
389 init_remote_name, create_addr_space_name,
390 destroy_addr_space_name, search_unwind_table_name,
391 find_dyn_list_name): Constify.
393 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
395 * darwin-nat.c (darwin_pthread_kill): New function.
396 (darwin_resume_thread): Use darwin_pthread_kill.
398 2018-07-05 Tom de Vries <tdevries@suse.de>
400 * macroexp.c (macro_buffer) <operator=>: New member function.
402 2018-07-04 Tom Tromey <tom@tromey.com>
404 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
406 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
408 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
409 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
413 2018-07-04 Joel Brobecker <brobecker@adacore.com>
415 * NEWS: Create a new section for the next release branch.
416 Rename the section of the current branch, now that it has
419 2018-07-04 Joel Brobecker <brobecker@adacore.com>
421 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
422 * version.in: Bump version to 8.2.50.DATE-git.
424 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
425 Pedro Alves <palves@redhat.com>
427 * linux-nat.c (linux_init_ptrace): Rename to ...
428 (linux_init_ptrace_procfs): ... this. Call
429 linux_proc_init_warnings.
430 (linux_nat_target::post_attach)
431 (linux_nat_target::post_startup_inferior): Adjust.
432 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
433 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
435 2018-07-04 Tom de Vries <tdevries@suse.de>
437 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
439 (read_comp_unit_head): ... here.
441 2018-07-03 Tom Tromey <tom@tromey.com>
443 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
444 (stop_tracing, tstatus_command)
445 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
446 (print_one_static_tracepoint_marker): Update.
447 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
449 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
451 (all_tracepoints, static_tracepoints_here): Return std::vector.
453 2018-07-03 Tom Tromey <tom@tromey.com>
455 * common/ptid.c (ptid_equal): Remove.
456 * common/ptid.h (ptid_equal): Don't declare.
457 * ada-tasks.c: Update.
458 * breakpoint.c: Update.
459 * common/agent.c: Update.
461 * darwin-nat-info.c: Update.
462 * darwin-nat.c: Update.
464 * dtrace-probe.c: Update.
465 * dummy-frame.c: Update.
466 * fbsd-nat.c: Update.
468 * gdbthread.h: Update.
470 * go32-nat.c: Update.
471 * inf-loop.c: Update.
472 * inf-ptrace.c: Update.
477 * linux-fork.c: Update.
478 * linux-nat.c: Update.
479 * linux-thread-db.c: Update.
480 * mi/mi-cmd-var.c: Update.
481 * mi/mi-interp.c: Update.
482 * mi/mi-main.c: Update.
483 * nto-procfs.c: Update.
484 * ppc-linux-tdep.c: Update.
486 * python/py-inferior.c: Update.
487 * python/py-record-btrace.c: Update.
488 * python/py-record.c: Update.
489 * ravenscar-thread.c: Update.
490 * regcache.c: Update.
491 * remote-sim.c: Update.
493 * sol-thread.c: Update.
496 * tui/tui-stack.c: Update.
498 * windows-nat.c: Update.
499 * windows-tdep.c: Update.
501 2018-07-03 Tom Tromey <tom@tromey.com>
503 * common/ptid.c (ptid_match): Remove.
504 * common/ptid.h (ptid_match): Don't declare.
505 * fbsd-nat.c: Update.
508 * linux-nat.c: Update.
509 * record-btrace.c: Update.
510 * regcache.c: Update.
513 2018-07-03 Tom Tromey <tom@tromey.com>
515 * common/ptid.c (ptid_tid_p): Remove.
516 * common/ptid.h (ptid_tid_p): Don't declare.
517 * sol-thread.c: Update.
519 2018-07-03 Tom Tromey <tom@tromey.com>
521 * common/ptid.c (ptid_lwp_p): Remove.
522 * common/ptid.h (ptid_lwp_p): Don't declare.
523 * fbsd-nat.c: Update.
524 * linux-nat.c: Update.
525 * nat/linux-procfs.c: Update.
526 * nat/x86-linux-dregs.c: Update.
527 * sol-thread.c: Update.
529 2018-07-03 Tom Tromey <tom@tromey.com>
531 * common/ptid.c (ptid_is_pid): Remove.
532 * common/ptid.h (ptid_is_pid): Don't declare.
534 * linux-nat.c: Update.
535 * mi/mi-interp.c: Update.
539 2018-07-03 Tom Tromey <tom@tromey.com>
541 * common/ptid.c (ptid_get_tid): Remove.
542 * common/ptid.h (ptid_get_tid): Don't declare.
543 * ada-tasks.c: Update.
544 * aix-thread.c: Update.
545 * bsd-uthread.c: Update.
546 * darwin-nat.c: Update.
547 * fbsd-nat.c: Update.
548 * i386-darwin-nat.c: Update.
550 * linux-tdep.c: Update.
551 * nto-procfs.c: Update.
552 * ppc-ravenscar-thread.c: Update.
553 * python/py-infthread.c: Update.
554 * ravenscar-thread.c: Update.
555 * sol-thread.c: Update.
556 * sparc-ravenscar-thread.c: Update.
557 * windows-nat.c: Update.
559 2018-07-03 Tom Tromey <tom@tromey.com>
561 * common/ptid.c (ptid_get_lwp): Remove.
562 * common/ptid.h (ptid_get_lwp): Don't declare.
563 * aarch64-linux-nat.c: Update.
564 * ada-tasks.c: Update.
565 * aix-thread.c: Update.
566 * amd64-linux-nat.c: Update.
567 * arm-linux-nat.c: Update.
569 * fbsd-nat.c: Update.
570 * fbsd-tdep.c: Update.
572 * i386-cygwin-tdep.c: Update.
573 * i386-gnu-nat.c: Update.
574 * i386-linux-nat.c: Update.
575 * ia64-linux-nat.c: Update.
576 * inf-ptrace.c: Update.
578 * linux-fork.c: Update.
579 * linux-nat.c: Update.
580 * linux-tdep.c: Update.
581 * linux-thread-db.c: Update.
582 * mips-linux-nat.c: Update.
583 * nat/aarch64-linux-hw-point.c: Update.
584 * nat/aarch64-linux.c: Update.
585 * nat/linux-btrace.c: Update.
586 * nat/linux-osdata.c: Update.
587 * nat/linux-procfs.c: Update.
588 * nat/x86-linux-dregs.c: Update.
589 * obsd-nat.c: Update.
590 * ppc-fbsd-nat.c: Update.
591 * ppc-linux-nat.c: Update.
593 * python/py-infthread.c: Update.
594 * ravenscar-thread.c: Update.
596 * s390-linux-nat.c: Update.
597 * sol-thread.c: Update.
598 * sol2-tdep.c: Update.
599 * spu-linux-nat.c: Update.
600 * x86-linux-nat.c: Update.
601 * xtensa-linux-nat.c: Update.
603 2018-07-03 Tom Tromey <tom@tromey.com>
605 * common/ptid.c (ptid_get_pid): Remove.
606 * common/ptid.h (ptid_get_pid): Don't declare.
607 * aarch64-linux-nat.c: Update.
608 * ada-lang.c: Update.
609 * aix-thread.c: Update.
610 * alpha-bsd-nat.c: Update.
611 * amd64-fbsd-nat.c: Update.
612 * amd64-linux-nat.c: Update.
613 * arm-linux-nat.c: Update.
614 * arm-nbsd-nat.c: Update.
616 * break-catch-syscall.c: Update.
617 * breakpoint.c: Update.
618 * bsd-uthread.c: Update.
621 * darwin-nat.c: Update.
622 * fbsd-nat.c: Update.
623 * fbsd-tdep.c: Update.
626 * hppa-nbsd-nat.c: Update.
627 * hppa-obsd-nat.c: Update.
628 * i386-fbsd-nat.c: Update.
629 * ia64-linux-nat.c: Update.
630 * inf-ptrace.c: Update.
632 * inferior.c: Update.
633 * inferior.h: Update.
636 * linux-fork.c: Update.
637 * linux-nat.c: Update.
638 * linux-tdep.c: Update.
639 * linux-thread-db.c: Update.
640 * m68k-bsd-nat.c: Update.
641 * mi/mi-interp.c: Update.
642 * mi/mi-main.c: Update.
643 * mips-linux-nat.c: Update.
644 * mips-nbsd-nat.c: Update.
645 * mips64-obsd-nat.c: Update.
646 * nat/aarch64-linux-hw-point.c: Update.
647 * nat/aarch64-linux.c: Update.
648 * nat/linux-btrace.c: Update.
649 * nat/linux-osdata.c: Update.
650 * nat/linux-procfs.c: Update.
651 * nat/x86-linux-dregs.c: Update.
652 * nto-procfs.c: Update.
653 * obsd-nat.c: Update.
654 * ppc-linux-nat.c: Update.
655 * ppc-nbsd-nat.c: Update.
656 * ppc-obsd-nat.c: Update.
657 * proc-service.c: Update.
659 * python/py-inferior.c: Update.
660 * python/py-infthread.c: Update.
661 * ravenscar-thread.c: Update.
663 * remote-sim.c: Update.
665 * rs6000-nat.c: Update.
666 * s390-linux-nat.c: Update.
667 * sh-nbsd-nat.c: Update.
668 * sol-thread.c: Update.
669 * sparc-nat.c: Update.
670 * sparc64-tdep.c: Update.
671 * spu-linux-nat.c: Update.
672 * spu-tdep.c: Update.
673 * target-debug.h: Update.
676 * tid-parse.c: Update.
677 * tracefile-tfile.c: Update.
678 * vax-bsd-nat.c: Update.
679 * windows-nat.c: Update.
680 * x86-linux-nat.c: Update.
683 2018-07-03 Tom Tromey <tom@tromey.com>
685 * common/ptid.c (pid_to_ptid): Remove.
686 * common/ptid.h (pid_to_ptid): Don't declare.
687 * aix-thread.c: Update.
688 * arm-linux-nat.c: Update.
689 * common/ptid.c: Update.
690 * common/ptid.h: Update.
693 * darwin-nat.c: Update.
694 * fbsd-nat.c: Update.
695 * fork-child.c: Update.
697 * go32-nat.c: Update.
698 * inf-ptrace.c: Update.
700 * inferior.c: Update.
702 * linux-fork.c: Update.
703 * linux-nat.c: Update.
704 * nat/aarch64-linux-hw-point.c: Update.
705 * nat/fork-inferior.c: Update.
706 * nat/x86-linux-dregs.c: Update.
707 * nto-procfs.c: Update.
708 * obsd-nat.c: Update.
710 * progspace.c: Update.
712 * rs6000-nat.c: Update.
713 * s390-linux-nat.c: Update.
714 * sol-thread.c: Update.
715 * spu-linux-nat.c: Update.
718 * tracefile-tfile.c: Update.
719 * windows-nat.c: Update.
721 2018-07-03 Tom Tromey <tom@tromey.com>
723 * common/ptid.h (ptid_build): Don't declare.
724 * common/ptid.c (ptid_build): Remove.
725 * aix-thread.c: Update.
727 * bsd-uthread.c: Update.
728 * common/agent.c: Update.
729 * common/ptid.c: Update.
730 * common/ptid.h: Update.
732 * darwin-nat.c: Update.
733 * fbsd-nat.c: Update.
735 * linux-fork.c: Update.
736 * linux-nat.c: Update.
737 * linux-thread-db.c: Update.
738 * nat/linux-osdata.c: Update.
739 * nat/linux-procfs.c: Update.
740 * nto-procfs.c: Update.
741 * obsd-nat.c: Update.
742 * proc-service.c: Update.
744 * ravenscar-thread.c: Update.
745 * remote-sim.c: Update.
747 * sol-thread.c: Update.
749 * windows-nat.c: Update.
751 2018-07-03 Tom Tromey <tom@tromey.com>
753 * infrun.c (follow_exec): Use exit_inferior_silent.
754 * inferior.c (exit_inferior_num_silent): Remove.
755 * inferior.h (exit_inferior_num_silent): Don't declare.
757 2018-07-03 Tom Tromey <tom@tromey.com>
760 * darwin-nat.c (darwin_attach_pid): Reset inferior and
761 inferior_ptid on error.
763 2018-07-02 Maciej W. Rozycki <macro@mips.com>
764 Simon Marchi <simon.marchi@polymtl.ca>
767 * disasm.h (gdb_disassembler): Add
768 `m_disassembler_options_holder'. member
769 * disasm.c (get_all_disassembler_options): New function.
770 (gdb_disassembler::gdb_disassembler): Use it.
771 (gdb_buffered_insn_length_init_dis): Likewise.
772 (gdb_buffered_insn_length): Adjust accordingly.
773 (set_disassembler_options): Handle options with arguments.
774 (show_disassembler_options_sfunc): Likewise. Add a leading new
775 line if showing options with descriptions.
776 (disassembler_options_completer): Adapt to using the
777 `disasm_options_and_args_t' structure.
778 * mips-tdep.c (mips_disassembler_options): New variable.
779 (mips_disassembler_options_o32): Likewise.
780 (mips_disassembler_options_n32): Likewise.
781 (mips_disassembler_options_n64): Likewise.
782 (gdb_print_insn_mips): Don't set `disassembler_options'.
783 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
785 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
786 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
787 `gdbarch_disassembler_options_implicit' and
788 `gdbarch_valid_disassembler_options'.
789 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
790 `disasm_options_and_args_t' structure.
791 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
793 (valid_disassembler_options): Switch from `disasm_options_t' to
794 the `disasm_options_and_args_t' structure.
795 * NEWS: Document `set disassembler-options' support for the MIPS
797 * gdbarch.h: Regenerate.
798 * gdbarch.c: Regenerate.
800 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
802 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
804 2018-06-29 Joel Brobecker <brobecker@adacore.com>
806 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
807 parameter in call to amd64_target_description.
808 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
809 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
810 (amd64fbsd_init_abi): Likewise.
811 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
812 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
813 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
814 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
816 2018-06-29 Pedro Alves <palves@redhat.com>
818 * gdb/amd64-tdep.h (amd64_create_target_description): Add
819 "segments" parameter.
820 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
821 (_initialize_amd64_tdep): Update call to
822 amd64_create_target_description.
823 (amd64_target_description): Add "segments" parameter. Adjust
824 the implementation to use it.
825 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
826 call to amd64_create_target_description.
827 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
828 * gdb/arch/amd64.h (amd64_create_target_description): Add
830 * gdb/arch/amd64.c (amd64_create_target_description): Add
831 "segments" parameter. Call create_feature_i386_64bit_segments
832 only if SEGMENTS is true.
833 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
834 call to amd64_create_target_description.
836 2018-06-29 Pedro Alves <palves@redhat.com>
838 * thread.c (thread_target_id_str): New, factored out from ...
839 (print_thread_info_1): ... here. Use it to compute the max
840 "Target Id" column width.
842 2018-06-29 Pedro Alves <palves@redhat.com>
844 * remote.c (remote_target::extra_thread_info): Delete
845 'display_buf' and 'n' locals. from the cache, regardless of
846 packet mechanims is in use. Use cache for qThreadExtra and qP
849 2018-06-29 Pedro Alves <palves@redhat.com>
851 * blockframe.c (find_pc_sect_containing_function): New function.
852 * breakpoint.c (print_breakpoint_location): Don't call
853 find_pc_sect_function.
854 * linespec.c (create_sals_line_offset): Record the location's
856 * linespec.c (convert_address_location_to_sals): Fill in sal's
857 symbol with find_pc_sect_containing_function.
858 * symtab.c (find_function_start_sal): Rename to ...
859 (find_function_start_sal_1): ... this.
860 (find_function_start_sal): Reimplement as wrapper around
861 find_function_start_sal_1, and use
862 find_pc_sect_containing_function to fill in the sal's symbol.
863 (find_function_start_sal(symbol*, bool)): Adjust.
864 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
866 (find_pc_sect_containing_function): Declare.
868 2018-06-29 Pedro Alves <palves@redhat.com>
870 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
871 true if the the location has no symbol.
873 2018-06-28 Tom Tromey <tom@tromey.com>
875 * NEWS: Mention --enable-codesign.
876 * silent-rules.mk (ECHO_SIGN): New variable.
877 * configure.ac: Add --enable-codesign.
878 * configure: Rebuild.
879 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
880 (gdb$(EXEEXT)): Optionally invoke codesign.
882 2018-06-28 Pedro Alves <palves@redhat.com>
884 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
886 (switch_to_thread_no_regs): Adjust comment.
887 * infcmd.c (stop_pc): Delete.
888 (post_create_inferior, info_program_command): Replace references
889 to stop_pc with references to thread_info->suspend.stop_pc.
890 * inferior.h (stop_pc): Delete declaration.
891 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
892 (handle_inferior_event_1, handle_signal_stop)
893 (process_event_stop_test, keep_going_stepped_thread)
894 (handle_step_into_function, handle_step_into_function_backward)
895 (print_stop_location): Replace references to stop_pc with
896 references to thread_info->suspend.stop_pc.
897 (struct infcall_suspend_state) <stop_pc>: Delete field.
898 (save_infcall_suspend_state, restore_infcall_suspend_state):
899 Remove references to inf_stat->stop_pc.
900 * linux-fork.c (fork_load_infrun_state): Likewise.
901 * record-btrace.c (record_btrace_set_replay): Likewise.
902 * record-full.c (record_full_goto_entry): Likewise.
903 * remote.c (print_one_stopped_thread): Likewise.
904 * target.c (target_resume): Extend comment.
905 * thread.c (set_executing_thread): New.
906 (set_executing): Use it.
907 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
908 Remove references to stop_pc.
910 2018-06-28 Pedro Alves <palves@redhat.com>
912 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
913 Moving fetching stop_pc until after ecs->event_thread is refreshed.
915 2018-06-28 Tom Tromey <tom@tromey.com>
917 * coffread.c (coff_symfile_finish): Update.
918 * xcoffread.c (xcoff_symfile_finish): Update.
919 * elfread.c (elf_symfile_finish): Update.
920 * symfile.h (dwarf2_free_objfile): Don't declare.
921 * dwarf2read.c (_initialize_dwarf2_read): Use
922 register_objfile_data_with_cleanup.
923 (dwarf2_free_objfile): Now static. Change signature.
925 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
927 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
928 option "-o" to add-symbol-file-load to add an offset to each
929 section's load address.
930 * symfile.c (set_objfile_default_section_offset): New function.
932 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
934 * symfile.c (add_symbol_file_command): Make sure that sections
935 with the same name are sorted in the same order.
937 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
939 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
940 require the second argument. If omitted, load sections at the
941 addresses specified in the file.
943 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
945 * symfile.c (symbol_file_command, symbol_file_add_main_1)
946 (_initialize_symfile): Add option "-o" to symbol-file to add an
947 offset to each section of the symbol file.
949 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
951 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
953 2018-06-27 Tom Tromey <tom@tromey.com>
955 * stack.c (_initialize_stack): Update "func" help text.
957 2018-06-27 Tom Tromey <tom@tromey.com>
959 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
961 (unwind_infopy_str, pyuw_create_unwind_info)
962 (unwind_infopy_add_saved_register, pyuw_sniffer)
963 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
965 (struct saved_reg): Add constructor.
966 <value>: Now a gdbpy_ref<>.
968 2018-06-27 Tom Tromey <tom@tromey.com>
970 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
972 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
974 * gdb-gdb.py.in: Format using autopep8.
976 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
978 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
979 (type_lookup_function): Recognize CORE_ADDR values.
981 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
983 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
986 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
988 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
991 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
993 * gdb-gdb.py: Move to...
994 * gdb-gdb.py.in: ... here.
995 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
996 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
998 (distclean): Remove gdb-gdb.py when cleaning.
999 (gdb-gdb.py, gdb-gdb.gdb): New rules.
1000 * configure: Re-generate.
1002 2018-06-27 Pedro Alves <palves@redhat.com>
1004 * proc-service.c (get_ps_regcache): New.
1005 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
1006 (ps_lsetfpregs): Use it.
1008 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
1011 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
1012 (dwarf_decode_lines_1): Adjust.
1014 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1016 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
1018 <info_proc>: Likewise.
1020 2018-06-26 Joel Brobecker <brobecker@adacore.com>
1022 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
1023 to windows_fetch_one_register, and only handle the case of
1024 fetching one register. Move the code that reloads the context
1025 and iterates over all registers if R is negative to...
1026 (windows_nat_target::fetch_registers): ... here.
1027 (do_windows_store_inferior_registers): Rename to
1028 windows_store_one_register, and only handle the case of storing
1029 one register. Move the code that handles the case where r is
1031 (windows_nat_target::store_registers) ... here.
1033 2018-06-26 Tom Tromey <tom@tromey.com>
1036 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
1037 * rust-lang.c (rust_print_struct_def): Add podata parameter.
1039 (rust_internal_print_type): Add podata parameter.
1040 (rust_print_type): Update.
1042 2018-06-26 Tom Tromey <tom@tromey.com>
1044 * typeprint.h (struct print_offset_data) <update, finish,
1045 maybe_print_hole>: New methods.
1046 <indentation>: New constant.
1047 * typeprint.c (print_offset_data::indentation): Define.
1048 (print_offset_data::maybe_print_hole, print_offset_data::update)
1049 (print_offset_data::finish): Move from c-typeprint.c and rename.
1050 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
1051 (print_spaces_filtered_with_print_options): Update.
1052 (c_print_type_union_field_offset, maybe_print_hole)
1053 (c_print_type_struct_field_offset): Move to typeprint.c and
1055 (c_type_print_base_struct_union): Update.
1057 2018-06-25 Pedro Alves <palves@redhat.com>
1059 * gdbthread.h (thread_info_ref, delete_thread)
1060 (delete_thread_silent, first_thread_of_inferior)
1061 (any_thread_of_inferior, switch_to_thread)
1062 (enable_thread_stack_temporaries)
1063 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1064 (get_last_thread_stack_temporary)
1065 (value_in_thread_stack_temporaries, can_access_registers_thread):
1066 Spell out "struct thread_info" instead of just "thread_info".
1067 * inferior.h (notice_new_inferior): Likewise.
1069 2018-06-25 Pedro Alves <palves@redhat.com>
1071 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1072 pass thread_info pointer to delete_thread.
1073 (windows_nat_target::detach): Pass inferior pointer to
1075 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
1077 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
1078 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
1079 and pass a thread_info pointer to delete_thread.
1080 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
1081 pass thread_info pointer to delete_thread.
1082 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
1083 delete_thread_silent call.
1084 * procfs.c (procfs_target::detach): Pass inferior pointer to
1086 (procfs_target::wait): Pass thread_info pointer to delete_thread.
1087 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
1088 delete_thread_silent call.
1089 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1090 pass thread_info pointer to delete_thread.
1091 (windows_nat_target::detach): Pass inferior pointer to
1094 2018-06-22 Alan Hayward <alan.hayward@arm.com>
1096 * regcache.c (readable_regcache::read_part): Fix asserts.
1097 (reg_buffer::raw_collect_part): New function.
1098 (regcache::write_part): Fix asserts.
1099 (reg_buffer::raw_supply_part): New function.
1100 (regcache::transfer_regset_register): New helper function.
1101 (regcache::transfer_regset): Call new functions.
1102 (regcache_supply_regset): Use gdb_byte*.
1103 (regcache::supply_regset): Likewise.
1104 (regcache_collect_regset): Likewise.
1105 (regcache::collect_regset): Likewise.
1106 * regcache.h (reg_buffer::raw_collect_part): New declaration.
1107 (reg_buffer::raw_supply_part): Likewise.
1108 (regcache::transfer_regset_register): Likewise.
1109 (regcache::transfer_regset): Use gdb_byte*.
1111 2018-06-22 Alan Hayward <alan.hayward@arm.com>
1113 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
1115 2018-06-21 Pedro Alves <palves@redhat.com>
1117 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
1118 instead of a ptid_t. All callers adjusted.
1119 * ada-tasks.c (ada_get_task_number): Likewise. All callers
1121 (print_ada_task_info, display_current_task_id, task_command_1):
1123 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
1125 (breakpoint_kind): Adjust.
1126 (remove_breakpoints_pid): Rename to ...
1127 (remove_breakpoints_inf): ... this. Adjust to take an inferior
1128 pointer. All callers adjusted.
1129 (bpstat_clear_actions): Use inferior_thread.
1130 (get_bpstat_thread): New.
1131 (bpstat_do_actions): Use it.
1132 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
1133 to take a thread_info pointer. All callers adjusted.
1134 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
1135 (breakpoint_re_set_thread): Use inferior_thread.
1136 * breakpoint.h (struct inferior): Forward declare.
1137 (bpstat_stop_status): Update.
1138 (remove_breakpoints_pid): Delete.
1139 (remove_breakpoints_inf): New.
1140 * bsd-uthread.c (bsd_uthread_target::wait)
1141 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
1142 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
1143 (maint_btrace_packet_history_cmd)
1144 (maint_btrace_clear_packet_history_cmd): Adjust.
1145 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
1147 * cli/cli-interp.c: Include "inferior.h".
1148 * common/refcounted-object.h (struct
1149 refcounted_object_ref_policy): New.
1150 * compile/compile-object-load.c: Include gdbthread.h.
1151 (store_regs): Use inferior_thread.
1152 * corelow.c (core_target::close): Use current_inferior.
1153 (core_target_open): Adjust to use first_thread_of_inferior and use
1154 the current inferior.
1155 * ctf.c (ctf_target::close): Adjust to use current_inferior.
1156 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
1157 <thread>: ... this new field. All references adjusted.
1158 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
1159 Take a thread_info pointer instead of a ptid_t.
1160 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
1161 (dummy_frame_discard, register_dummy_frame_dtor): Take a
1162 thread_info pointer instead of a ptid_t.
1163 * elfread.c: Include "inferior.h".
1164 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
1165 Use inferior_thread.
1166 * eval.c (evaluate_subexp): Likewise.
1167 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
1169 * gdb_proc_service.h (struct thread_info): Forward declare.
1170 (struct ps_prochandle) <ptid>: Delete, replaced by ...
1171 <thread>: ... this new field. All references adjusted.
1172 * gdbarch.h, gdbarch.c: Regenerate.
1173 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
1174 'thread' parameter. All implementations and callers adjusted.
1175 * gdbthread.h (thread_info) <set_running>: New method.
1176 (delete_thread, delete_thread_silent): Take a thread_info pointer
1178 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
1179 (first_thread_of_process): Delete, replaced by ...
1180 (first_thread_of_inferior): ... this new function. All callers
1182 (any_live_thread_of_process): Delete, replaced by ...
1183 (any_live_thread_of_inferior): ... this new function. All callers
1185 (switch_to_thread, switch_to_no_thread): Declare.
1186 (is_executing): Delete.
1187 (enable_thread_stack_temporaries): Update comment.
1188 <enable_thread_stack_temporaries>: Take a thread_info pointer
1189 instead of a ptid_t. Incref the thread.
1190 <~enable_thread_stack_temporaries>: Decref the thread.
1193 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1194 (get_last_thread_stack_temporary)
1195 (value_in_thread_stack_temporaries, can_access_registers_thread):
1196 Take a thread_info pointer instead of a ptid_t. All callers
1198 * infcall.c (get_call_return_value): Use inferior_thread.
1199 (run_inferior_call): Work with thread pointers instead of ptid_t.
1200 (call_function_by_hand_dummy): Work with thread pointers instead
1201 of ptid_t. Use thread_info_ref.
1202 * infcmd.c (proceed_thread_callback): Access thread's state
1204 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
1205 access thread's state directly.
1206 (continue_command): Use inferior_thread.
1207 (info_program_command): Use find_thread_ptid and access thread
1209 (proceed_after_attach_callback): Use thread state directly.
1210 (notice_new_inferior): Take a thread_info pointer instead of a
1211 ptid_t. All callers adjusted.
1212 (exit_inferior): Take an inferior pointer instead of a pid. All
1214 (exit_inferior_silent): New.
1215 (detach_inferior): Delete.
1216 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
1217 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
1218 (detach_inferior_command, kill_inferior_command): Use
1219 find_inferior_id instead of valid_gdb_inferior_id and
1220 gdb_inferior_id_to_pid.
1221 (inferior_command): Use inferior and thread pointers.
1222 * inferior.h (struct thread_info): Forward declare.
1223 (notice_new_inferior): Take a thread_info pointer instead of a
1224 ptid_t. All callers adjusted.
1225 (detach_inferior): Delete declaration.
1226 (exit_inferior, exit_inferior_silent): Take an inferior pointer
1227 instead of a pid. All callers adjusted.
1228 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
1229 (valid_gdb_inferior_id): Delete.
1230 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
1231 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
1232 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
1234 <inf>: ... this new field.
1235 <step_ptid>: Delete, replaced by ...
1236 <step_thread>: ... this new field.
1237 (get_displaced_stepping_state): Take an inferior pointer instead
1238 of a pid. All callers adjusted.
1239 (displaced_step_in_progress_any_inferior): Adjust.
1240 (displaced_step_in_progress_thread): Take a thread pointer instead
1241 of a ptid_t. All callers adjusted.
1242 (displaced_step_in_progress, add_displaced_stepping_state): Take
1243 an inferior pointer instead of a pid. All callers adjusted.
1244 (get_displaced_step_closure_by_addr): Adjust.
1245 (remove_displaced_stepping_state): Take an inferior pointer
1246 instead of a pid. All callers adjusted.
1247 (displaced_step_prepare_throw, displaced_step_prepare)
1248 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
1249 All callers adjusted.
1250 (start_step_over): Adjust.
1251 (infrun_thread_ptid_changed): Remove bit updating ptids in the
1252 displaced step queue.
1253 (do_target_resume): Adjust.
1254 (fetch_inferior_event): Use inferior_thread.
1255 (context_switch, get_inferior_stop_soon): Take an
1256 execution_control_state pointer instead of a ptid_t. All callers
1258 (switch_to_thread_cleanup): Delete.
1259 (stop_all_threads): Use scoped_restore_current_thread.
1260 * inline-frame.c: Include "gdbthread.h".
1261 (inline_state) <inline_state>: Take a thread pointer instead of a
1262 ptid_t. All callers adjusted.
1263 <ptid>: Delete, replaced by ...
1264 <thread>: ... this new field.
1265 (find_inline_frame_state): Take a thread pointer instead of a
1266 ptid_t. All callers adjusted.
1267 (skip_inline_frames, step_into_inline_frame)
1268 (inline_skipped_frames, inline_skipped_symbol): Take a thread
1269 pointer instead of a ptid_t. All callers adjusted.
1270 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
1271 (inline_skipped_frames, inline_skipped_symbol): Likewise.
1272 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
1274 * linux-nat.c (get_detach_signal): Likewise.
1275 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
1276 (thread_db_notice_clone): Adjust.
1277 (thread_db_find_new_threads_silently)
1278 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
1279 a thread pointer instead of a ptid_t. All callers adjusted.
1280 * mi/mi-cmd-var.c: Include "inferior.h".
1281 (mi_cmd_var_update_iter): Update to use thread pointers.
1282 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
1284 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
1286 (mi_output_running): ... this new function.
1287 (mi_on_resume_1): Adjust to use it.
1288 (mi_user_selected_context_changed): Adjust to use inferior_thread.
1289 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
1291 (interrupt_thread_callback): : Adjust to use thread and inferior
1293 * proc-service.c: Include "gdbthread.h".
1294 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
1295 * progspace-and-thread.c: Include "inferior.h".
1296 * progspace.c: Include "inferior.h".
1297 * python/py-exitedevent.c (create_exited_event_object): Adjust to
1298 hold a reference to an inferior_object.
1299 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
1301 * python/py-inferior.c (struct inferior_object): Give the type a
1302 tag name instead of a typedef.
1303 (python_on_normal_stop): No need to check if the current thread is
1305 (inferior_to_inferior_object): Change return type to
1306 inferior_object. All callers adjusted.
1307 (find_thread_object): Delete, bits factored out to ...
1308 (thread_to_thread_object): ... this new function.
1309 * python/py-infthread.c (create_thread_object): Use
1310 inferior_to_inferior_object.
1311 (thpy_is_stopped): Use thread pointer directly.
1312 (gdbpy_selected_thread): Use inferior_thread.
1313 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
1314 field, replaced with ...
1315 <thread>: ... this new field. All users adjusted.
1316 (btpy_insn_or_gap_new): Drop const.
1317 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
1319 * python/py-record.c: Include "gdbthread.h".
1320 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1321 a ptid_t. All callers adjusted.
1322 (gdbpy_current_recording): Use inferior_thread.
1323 * python/py-record.h (recpy_record_object) <ptid>: Delete
1324 field, replaced with ...
1325 <thread>: ... this new field. All users adjusted.
1326 (recpy_element_object) <ptid>: Delete
1327 field, replaced with ...
1328 <thread>: ... this new field. All users adjusted.
1329 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1330 a ptid_t. All callers adjusted.
1331 * python/py-threadevent.c: Include "gdbthread.h".
1332 (get_event_thread): Use thread_to_thread_object.
1333 * python/python-internal.h (struct inferior_object): Forward
1335 (find_thread_object, find_inferior_object): Delete declarations.
1336 (thread_to_thread_object, inferior_to_inferior_object): New
1338 * record-btrace.c: Include "inferior.h".
1339 (require_btrace_thread): Use inferior_thread.
1340 (record_btrace_frame_sniffer)
1341 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
1342 (get_thread_current_frame): Use scoped_restore_current_thread and
1344 (get_thread_current_frame): Use thread pointer directly.
1345 (record_btrace_replay_at_breakpoint): Use thread's inferior
1347 * record-full.c: Include "inferior.h".
1348 * regcache.c: Include "gdbthread.h".
1349 (get_thread_arch_regcache): Use the inferior's address space
1351 (get_thread_regcache, registers_changed_thread): New.
1352 * regcache.h (get_thread_regcache(thread_info *thread)): New
1354 (registers_changed_thread): New.
1355 (remote_target) <remote_detach_1>: Swap order of parameters.
1356 (remote_add_thread): <remote_add_thread>: Return the new thread.
1357 (get_remote_thread_info(ptid_t)): New overload.
1358 (remote_target::remote_notice_new_inferior): Use thread pointers
1360 (remote_target::process_initial_stop_replies): Use
1361 thread_info::set_running.
1362 (remote_target::remote_detach_1, remote_target::detach)
1363 (extended_remote_target::detach): Adjust.
1364 * stack.c (frame_show_address): Use inferior_thread.
1365 * target-debug.h (target_debug_print_thread_info_pp): New.
1366 * target-delegates.c: Regenerate.
1367 * target.c (default_thread_address_space): Delete.
1368 (memory_xfer_partial_1): Use current_inferior.
1369 (target_detach): Use current_inferior.
1370 (target_thread_address_space): Delete.
1371 (generic_mourn_inferior): Use current_inferior.
1372 * target.h (struct target_ops) <thread_address_space>: Delete.
1373 (target_thread_address_space): Delete.
1374 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
1376 (delete_thread_1, delete_thread, delete_thread_silent): Take a
1377 thread pointer instead of a ptid_t. Adjust all callers.
1378 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
1379 (first_thread_of_process): Delete, replaced by ...
1380 (first_thread_of_inferior): ... this new function. All callers
1382 (any_thread_of_process): Rename to ...
1383 (any_thread_of_inferior): ... this, and take an inferior pointer.
1384 (any_live_thread_of_process): Rename to ...
1385 (any_live_thread_of_inferior): ... this, and take an inferior
1387 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1388 (value_in_thread_stack_temporaries)
1389 (get_last_thread_stack_temporary): Take a thread pointer instead
1390 of a ptid_t. Adjust all callers.
1391 (thread_info::set_running): New.
1392 (validate_registers_access): Use inferior_thread.
1393 (can_access_registers_ptid): Rename to ...
1394 (can_access_registers_thread): ... this, and take a thread
1396 (print_thread_info_1): Adjust to compare thread pointers instead
1398 (switch_to_no_thread, switch_to_thread): Make extern.
1399 (scoped_restore_current_thread::~scoped_restore_current_thread):
1400 Use m_thread pointer directly.
1401 (scoped_restore_current_thread::scoped_restore_current_thread):
1402 Use inferior_thread.
1403 (thread_command): Use thread pointer directly.
1404 (thread_num_make_value_helper): Use inferior_thread.
1405 * top.c (execute_command): Use inferior_thread.
1406 * tui/tui-interp.c: Include "inferior.h".
1407 * varobj.c (varobj_create): Use inferior_thread.
1408 (value_of_root_1): Use find_thread_global_id instead of
1409 global_thread_id_to_ptid.
1411 2018-06-21 Alan Hayward <alan.hayward@arm.com>
1413 * regcache.c (readable_regcache::read_part): Avoid memcpy when
1415 (regcache::write_part): Likewise.
1416 (readable_regcache::cooked_read_part): Update comment.
1417 (readable_regcache::cooked_write_part): Likewise.
1418 * regcache.h: (readable_regcache::read_part): Likewise.
1419 (regcache::write_part): Likewise.
1421 2018-06-21 Richard Bunt <richard.bunt@arm.com>
1422 Dirk Schubert <dirk.schubert@arm.com>
1424 * aarch64-linux-nat.c (post_attach): New.
1425 (aarch64_linux_nat_target::post_attach): Override post_attach to
1426 record the number of hardware debug registers.
1428 2018-06-20 Tom Tromey <tom@tromey.com>
1430 * python/py-param.c (add_setshow_generic): Make parameters const.
1431 (parmpy_init): Update.
1433 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1435 * regcache.h (regcache_cooked_read_ftype): Rename to...
1436 (register_read_ftype): ...this, change type to function_view.
1437 (class reg_buffer) <save>: Remove src parameter.
1438 (readonly_detached_regcache) <readonly_detached_regcache>: Make
1439 parameter non-const in first overload. Remove src parameter in
1441 * regcache.c (do_cooked_read): Remove.
1442 (readonly_detached_regcache::readonly_detached_regcache): Make
1443 parameter non-const, adjust call to other constructor.
1444 (reg_buffer::save): Remove src parameter.
1445 * frame.c (do_frame_register_read): Remove.
1446 (frame_save_as_regcache): Use lambda function.
1447 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
1448 parameter to ppu2spu_data *.
1449 (ppu2spu_sniffer): Use lambda function.
1451 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1453 * record-full.c (record_full_target::insert_breakpoint): Remove
1454 "struct" keyword, add const.
1456 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1458 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
1459 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
1460 * configure.ac: Remove AC_PREREQ, add missing quoting.
1461 * gnulib/configure.ac: Modernize usage of
1462 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
1463 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
1464 (AUTOMAKE_VERSION): Bump to 1.15.1.
1465 * configure: Re-generate.
1466 * config.in: Re-generate.
1467 * aclocal.m4: Re-generate.
1468 * gnulib/aclocal.m4: Re-generate.
1469 * gnulib/config.in: Re-generate.
1470 * gnulib/configure: Re-generate.
1471 * gnulib/import/Makefile.in: Re-generate.
1473 2018-06-19 Pedro Alves <palves@redhat.com>
1475 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
1476 (lookup_minimal_symbol_by_pc_section): ... here with
1477 gdb_assert_not_reached added.
1479 2018-06-19 Pedro Alves <palves@redhat.com>
1481 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
1482 parameter with a block parameter. Compare location's block symbol
1483 with the frame's block instead of addresses.
1484 (skip_inline_frames): Pass the current block instead of the
1485 frame's address. Break out as soon as we determine the frame
1486 should not be skipped.
1488 2018-06-18 Tom Tromey <tom@tromey.com>
1490 * solib-aix.c (solib_aix_get_section_offsets): Return
1492 (solib_aix_solib_create_inferior_hook): Update.
1494 2018-06-18 Tom Tromey <tom@tromey.com>
1496 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
1498 2018-06-18 Tom Tromey <tom@tromey.com>
1500 * solib-frv.c (frv_relocate_main_executable): Use
1502 * solib-dsbt.c (dsbt_relocate_main_executable): Use
1505 2018-06-18 Tom Tromey <tom@tromey.com>
1507 * objfiles.h (inhibit_section_map_updates): Update.
1508 (resume_section_map_updates, resume_section_map_updates_cleanup):
1510 * solib-svr4.c (svr4_handle_solib_event): Update.
1511 * objfiles.c (inhibit_section_map_updates): Return
1512 scoped_restore_tmpl<int>.
1513 (resume_section_map_updates, resume_section_map_updates_cleanup):
1516 2018-06-18 Tom Tromey <tom@tromey.com>
1518 * valprint.h (read_string): Update.
1519 * valprint.c (read_string): Change type of "buffer".
1520 (val_print_string): Update.
1521 * python/py-value.c (valpy_string): Update.
1522 * language.h (struct language_defn) <la_get_string>: Change
1524 (default_get_string, c_get_string): Update.
1525 * language.c (default_get_string): Change type of "buffer".
1526 * guile/scm-value.c (gdbscm_value_to_string): Update.
1527 * c-lang.c (c_get_string): Change type of "buffer".
1529 2018-06-18 Tom Tromey <tom@tromey.com>
1531 * ser-mingw.c (struct pipe_state_destroyer): New.
1532 (pipe_state_up): New typedef.
1533 (cleanup_pipe_state): Remove.
1534 (pipe_windows_open): Use pipe_state_up. Don't release argv.
1536 2018-06-18 Tom Tromey <tom@tromey.com>
1538 * rust-lang.h (rust_yyerror): Don't declare.
1539 * rust-lang.c (rust_language_defn): Update.
1540 * rust-exp.y (yyerror): Now static.
1541 * parse.c (parse_exp_in_context_1): Update.
1542 * p-lang.h (p_yyerror): Don't declare.
1543 * p-lang.c (p_language_defn): Update.
1544 * p-exp.y (yyerror): Now static.
1545 * opencl-lang.c (opencl_language_defn): Update.
1546 * objc-lang.c (objc_language_defn): Update.
1547 * m2-lang.h (m2_yyerror): Don't declare.
1548 * m2-lang.c (m2_language_defn): Update.
1549 * m2-exp.y (yyerror): Now static.
1550 * language.h (struct language_defn) <la_error>: Remove.
1551 * language.c (unk_lang_error): Remove.
1552 (unknown_language_defn, auto_language_defn): Remove.
1553 * go-lang.h (go_yyerror): Don't declare.
1554 * go-lang.c (go_language_defn): Update.
1555 * go-exp.y (yyerror): Now static.
1556 * f-lang.h (f_yyerror): Don't declare.
1557 * f-lang.c (f_language_defn): Update.
1558 * f-exp.y (yyerror): Now static.
1559 * d-lang.h (d_yyerror): Don't declare.
1560 * d-lang.c (d_language_defn): Update.
1561 * d-exp.y (yyerror): Now static.
1562 * c-lang.h (c_yyerror): Don't declare.
1563 * c-lang.c (c_language_defn, cplus_language_defn)
1564 (asm_language_defn, minimal_language_defn): Update.
1565 * c-exp.y (yyerror): Now static.
1566 * ada-lang.h (ada_yyerror): Don't declare.
1567 * ada-lang.c (ada_language_defn): Update.
1568 * ada-exp.y (yyerror): Now static.
1570 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1572 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
1573 (store_sveregs_to_thread): Likewise.
1574 (aarch64_linux_fetch_inferior_registers): Check for SVE.
1575 (aarch64_linux_store_inferior_registers): Likewise.
1576 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
1578 (aarch64_sve_regs_copy_to_regcache): Likewise.
1579 (aarch64_sve_regs_copy_from_regcache): Likewise.
1580 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
1582 (aarch64_sve_regs_copy_to_regcache): Likewise.
1583 (aarch64_sve_regs_copy_from_regcache): Likewise.
1584 (sve_context): Structure from Linux headers.
1585 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
1586 (SVE_SIG_ZREG_SIZE): Likewise.
1587 (SVE_SIG_PREG_SIZE): Likewise.
1588 (SVE_SIG_FFR_SIZE): Likewise.
1589 (SVE_SIG_REGS_OFFSET): Likewise.
1590 (SVE_SIG_ZREGS_OFFSET): Likewise.
1591 (SVE_SIG_ZREG_OFFSET): Likewise.
1592 (SVE_SIG_ZREGS_SIZE): Likewise.
1593 (SVE_SIG_PREGS_OFFSET): Likewise.
1594 (SVE_SIG_PREG_OFFSET): Likewise.
1595 (SVE_SIG_PREGS_SIZE): Likewise.
1596 (SVE_SIG_FFR_OFFSET): Likewise.
1597 (SVE_SIG_REGS_SIZE): Likewise.
1598 (SVE_SIG_CONTEXT_SIZE): Likewise.
1599 (SVE_PT_REGS_MASK): Likewise.
1600 (SVE_PT_REGS_FPSIMD): Likewise.
1601 (SVE_PT_REGS_SVE): Likewise.
1602 (SVE_PT_VL_INHERIT): Likewise.
1603 (SVE_PT_VL_ONEXEC): Likewise.
1604 (SVE_PT_REGS_OFFSET): Likewise.
1605 (SVE_PT_FPSIMD_OFFSET): Likewise.
1606 (SVE_PT_FPSIMD_SIZE): Likewise.
1607 (SVE_PT_SVE_ZREG_SIZE): Likewise.
1608 (SVE_PT_SVE_PREG_SIZE): Likewise.
1609 (SVE_PT_SVE_FFR_SIZE): Likewise.
1610 (SVE_PT_SVE_FPSR_SIZE): Likewise.
1611 (SVE_PT_SVE_FPCR_SIZE): Likewise.
1612 (__SVE_SIG_TO_PT): Likewise.
1613 (SVE_PT_SVE_OFFSET): Likewise.
1614 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
1615 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
1616 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
1617 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
1618 (SVE_PT_SVE_PREG_OFFSET): Likewise.
1619 (SVE_PT_SVE_PREGS_SIZE): Likewise.
1620 (SVE_PT_SVE_FFR_OFFSET): Likewise.
1621 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
1622 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
1623 (SVE_PT_SVE_SIZE): Likewise.
1624 (SVE_PT_SIZE): Likewise.
1625 (HAS_SVE_STATE): New define.
1627 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1629 * nat/aarch64-sve-linux-sigcontext.h: New file.
1630 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
1632 (SVE_VQ_MIN): Likewise.
1633 (SVE_VQ_MAX): Likewise.
1634 (SVE_VL_MIN): Likewise.
1635 (SVE_VL_MAX): Likewise.
1636 (SVE_NUM_ZREGS): Likewise.
1637 (SVE_NUM_PREGS): Likewise.
1638 (sve_vl_valid): Likewise.
1639 (struct user_sve_header): Likewise.
1641 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
1642 Richard Bunt <Richard.Bunt@arm.com>
1644 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
1645 was requested by GDB.
1647 2018-06-15 Tom de Vries <tdevries@suse.de>
1649 * MAINTAINERS (Write After Approval): Add Tom de Vries.
1651 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
1653 * gnulib/update-gnulib.sh: Print expected versions of
1656 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
1658 * arch-utils.c (default_type_align): Use type_length_units.
1659 * gdbtypes.c (type_align): Use type_length_units.
1661 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1663 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
1664 of 'define' command.
1666 2018-06-14 Tom de Vries <tdevries@suse.de>
1669 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
1670 get_no_prettyformat_print_options.
1672 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
1674 * sparc-nat.h: Include target.h.
1675 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
1676 <fetch_registers>: Remove this argument in function call.
1677 <store_registers>: Remove this argument in function call, remove
1679 <low_forget_process>: Call sparc64_forget_process instead of
1680 sparc_forget_process.
1682 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1684 * procfs.c (_initialize_procfs): Use add_inf_child_target.
1685 (procfs_target::make_corefile_notes): Adjust to new
1686 target_read_alloc return type.
1688 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1689 Stephen Roberts <stephen.roberts@arm.com>
1692 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
1693 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
1694 Move should_notify_stop local into more inner scope.
1696 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1697 Stephen Roberts <stephen.roberts@arm.com>
1700 * infrun.c (resume_1): Add call to mark_async_event_handler.
1702 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1704 * infrun.c (do_target_wait): Change old version of $pc printed.
1706 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
1708 * dwarf2read.c (read_index_from_section): Rename to...
1709 (read_gdb_index_from_section): ... this, update all callers.
1710 (dwarf2_read_index): Rename to...
1711 (dwarf2_read_gdb_index): ... this, update all callers.
1713 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
1715 * gdb/hppa-linux-nat.c
1716 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
1717 hppa_linux_nat_target::fetch_registers.
1719 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1721 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
1722 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
1723 (AARCH64_DWARF_SVE_FFR): Likewise.
1724 (AARCH64_DWARF_SVE_P0): Likewise.
1725 (AARCH64_DWARF_SVE_Z0): Likewise.
1727 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1729 * common/common-regcache.h (raw_compare): New function.
1730 * regcache.c (regcache::raw_compare): Likewise.
1731 * regcache.h (regcache::raw_compare): New declaration.
1733 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1735 * common/common-regcache.h (reg_buffer_common): New structure.
1736 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
1737 (reg_buffer::raw_supply): Likewise.
1738 (reg_buffer::raw_supply_integer): Likewise.
1739 (reg_buffer::raw_supply_zeroed): Likewise.
1740 (reg_buffer::raw_collect): Likewise.
1741 (reg_buffer::raw_collect_integer): Likewise.
1742 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
1743 (reg_buffer::raw_supply): Likewise.
1744 (reg_buffer::raw_supply_integer): Likewise.
1745 (reg_buffer::raw_supply_zeroed): Likewise.
1746 (reg_buffer::raw_collect): Likewise.
1747 (reg_buffer::raw_collect_integer): Likewise.
1749 2018-06-10 Tom Tromey <tom@tromey.com>
1751 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
1752 (class remote_state) <stop_reply_queue>: Now std::vector.
1753 (remote_state::~remote_state)
1754 (remote_target::stop_reply_queue_length): Update.
1755 (struct queue_iter_param, remove_child_of_pending_fork)
1756 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
1757 (check_pending_event_prevents_wildcard_vcont_callback)
1758 (remove_stop_reply_for_inferior)
1759 (remove_stop_reply_of_remote_state)
1760 (remote_notif_remove_once_on_match)
1761 (stop_reply_match_ptid_and_ws)
1762 (remote_kill_child_of_pending_fork): Remove.
1763 (remote_target::remove_new_fork_children)
1764 (remote_target::check_pending_events_prevent_wildcard_vcont)
1765 (remote_target::discard_pending_stop_replies)
1766 (remote_target::discard_pending_stop_replies_in_queue)
1767 (remote_target::remote_notif_remove_queued_reply)
1768 (remote_target::queued_stop_reply)
1769 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
1770 (remote_target::wait, remote_target::kill_new_fork_children)
1771 (remote_target::async): Update.
1773 2018-06-10 Tom Tromey <tom@tromey.com>
1775 * record-full.c (record_full_arch_list_cleanups): Remove.
1776 (record_full_message): Use try/catch.
1777 (record_full_wait_cleanups): Remove.
1778 (record_full_wait_1): Use try/catch.
1779 (record_full_restore): Likewise.
1781 2018-06-10 Tom Tromey <tom@tromey.com>
1783 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
1784 declare VEC. Add constructor.
1785 <in_target_beneath>: Now bool.
1786 (record_full_breakpoints): Now a std::vector, static.
1787 (record_full_sync_record_breakpoints)
1788 (record_full_init_record_breakpoints)
1789 (record_full_target::insert_breakpoint)
1790 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
1792 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
1794 * dwarf2read.c (process_cu_includes): Remove struct keyword.
1795 * serial.c (serial_interface_lookup): Remove struct keyword.
1797 2018-06-10 Tom Tromey <tom@tromey.com>
1799 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
1801 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
1803 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
1805 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
1806 "beneath" as a method.
1807 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
1808 Use "beneath" as a method.
1810 2018-06-10 Tom Tromey <tom@tromey.com>
1812 * tracefile.c (struct trace_file_writer_deleter): New.
1813 <operator()>: Rename from trace_file_writer_xfree.
1814 (trace_file_writer_up): New typedef.
1815 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
1817 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1819 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
1820 <m_registers, m_register_status>: Change type to
1822 * regcache.c (reg_buffer::reg_buffer): Use new instead of
1825 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1827 * common/common-regcache.h (enum register_status): Add
1828 underlying type "signed char".
1829 * regcache.h (reg_buffer) <m_register_status>: Change type to
1831 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
1832 register_status instead of signed char.
1833 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
1834 (reg_buffer::get_register_status): Remove cast.
1835 (readable_regcache::raw_read): Remove cast.
1836 (readable_regcache::cooked_read): Remove cast.
1838 2018-06-09 Tom Tromey <tom@tromey.com>
1840 * source.c (reverse_search_command, forward_search_command): Use
1843 2018-06-09 Tom Tromey <tom@tromey.com>
1845 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
1846 (serial_ops_list): Now static, std::vector.
1847 (serial_interface_lookup, serial_add_interface): Update.
1849 2018-06-09 Tom Tromey <tom@tromey.com>
1851 * dwarf2read.c (process_cu_includes): Update.
1852 (process_full_comp_unit): Update.
1853 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
1856 2018-06-08 Paul Koning <paul_koning@dell.com>
1860 * python/python.c (do_start_initialization):
1861 Avoid call to internal Python API.
1862 (init__gdb_module): New function.
1864 2018-06-08 Gary Benson <gbenson@redhat.com>
1866 * linux-thread-db.c (valprint.h): New include.
1867 (struct check_thread_db_info): New structure.
1868 (check_thread_db_on_load, tdb_testinfo): New static globals.
1869 (check_thread_db, check_thread_db_callback): New functions.
1870 (try_thread_db_load_1): Run integrity checks if requested.
1871 (maintenance_check_libthread_db): New function.
1872 (_initialize_thread_db): Register "maint check libthread-db"
1873 and "maint set/show check-libthread-db".
1874 * NEWS: Mention the above new commands.
1876 2018-06-08 Tom Tromey <tom@tromey.com>
1878 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
1881 2018-06-08 Tom Tromey <tom@tromey.com>
1883 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
1885 2018-06-08 Tom Tromey <tom@tromey.com>
1887 * common/btrace-common.h (struct btrace_data): Add constructor,
1888 destructor, move assignment operator.
1889 <empty, clear, fini>: New methods.
1890 <format>: Initialize.
1891 (btrace_data_init, btrace_data_fini, btrace_data_clear)
1892 (btrace_data_empty): Don't declare.
1893 * common/btrace-common.c (btrace_data_init): Remove.
1894 (btrace_data::fini): Rename from btrace_data_fini.
1895 (btrace_data::empty): Rename from btrace_data_empty.
1896 (btrace_data::clear): Rename from btrace_data_clear. Return
1898 * btrace.h (make_cleanup_btrace_data): Don't declare.
1899 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
1900 (parse_xml_btrace): Update.
1901 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
1902 (maint_btrace_clear_packet_history_cmd): Update.
1904 2018-06-07 Pedro Alves <palves@redhat.com>
1906 * target.h (target_ops) <beneath>: Now a method. All references
1908 (class target_stack): New.
1909 * target.c (g_target_stack): New.
1910 (g_current_top_target): Delete.
1911 (current_top_target): Get the top target out of g_target_stack.
1912 (target_stack::push, target_stack::unpush): New.
1913 (push_target, unpush_target): Reimplement.
1914 (target_is_pushed): Reimplement in terms of g_target_stack.
1915 (target_ops::beneath, target_stack::find_beneath): New.
1917 2018-06-07 Pedro Alves <palves@redhat.com>
1919 * target.h (find_target_beneath): Delete declaration.
1920 * target.c (find_target_beneath): Delete definition.
1921 * aix-thread.c: All callers of find_target_beneath adjusted to
1922 call target_ops::beneath instead.
1923 * bsd-uthread.c: Likewise.
1924 * linux-thread-db.c: Likewise.
1925 * ravenscar-thread.c: Likewise.
1926 * sol-thread.c: Likewise.
1927 * spu-multiarch.c: Likewise.
1929 2018-06-07 Pedro Alves <palves@redhat.com>
1931 * target.h (target_ops) <beneath>: Now a method. All references
1933 (target_ops) <m_beneath>: New.
1934 * target.c (target_ops::beneath): New.
1935 * corelow.c: Adjust all references to target_ops::beneath.
1936 * linux-thread-db.c: Likewise.
1937 * make-target-delegates: Likewise.
1938 * record-btrace.c: Likewise.
1939 * record-full.c: Likewise.
1940 * remote.c: Likewise.
1941 * target.c: Likewise.
1942 * target-delegates.c: Regenerate.
1944 2018-06-07 Pedro Alves <palves@redhat.com>
1946 * target.h (target_stack): Delete.
1947 (current_top_target): Declare function.
1948 * target.c (target_stack): Delete.
1949 (g_current_top_target): New.
1950 (current_top_target): New function.
1951 * auxv.c: Use current_top_target instead of target_stack
1953 * avr-tdep.c: Likewise.
1954 * breakpoint.c: Likewise.
1955 * corefile.c: Likewise.
1956 * elfread.c: Likewise.
1958 * exceptions.c: Likewise.
1959 * frame.c: Likewise.
1960 * gdbarch-selftests.c: Likewise.
1961 * gnu-v3-abi.c: Likewise.
1962 * ia64-tdep.c: Likewise.
1963 * ia64-vms-tdep.c: Likewise.
1964 * infcall.c: Likewise.
1965 * infcmd.c: Likewise.
1966 * infrun.c: Likewise.
1967 * linespec.c: Likewise.
1968 * linux-tdep.c: Likewise.
1969 * minsyms.c: Likewise.
1970 * ppc-linux-nat.c: Likewise.
1971 * ppc-linux-tdep.c: Likewise.
1972 * procfs.c: Likewise.
1973 * regcache.c: Likewise.
1974 * remote.c: Likewise.
1975 * rs6000-tdep.c: Likewise.
1976 * s390-linux-nat.c: Likewise.
1977 * s390-tdep.c: Likewise.
1978 * solib-aix.c: Likewise.
1979 * solib-darwin.c: Likewise.
1980 * solib-dsbt.c: Likewise.
1981 * solib-spu.c: Likewise.
1982 * solib-svr4.c: Likewise.
1983 * solib-target.c: Likewise.
1984 * sparc-tdep.c: Likewise.
1985 * sparc64-tdep.c: Likewise.
1986 * spu-tdep.c: Likewise.
1987 * symfile.c: Likewise.
1988 * symtab.c: Likewise.
1989 * target-descriptions.c: Likewise.
1990 * target-memory.c: Likewise.
1991 * target.c: Likewise.
1992 * target.h: Likewise.
1993 * tracefile-tfile.c: Likewise.
1994 * tracepoint.c: Likewise.
1995 * valops.c: Likewise.
1996 * valprint.c: Likewise.
1997 * value.c: Likewise.
1998 * windows-tdep.c: Likewise.
1999 * mi/mi-main.c: Likewise.
2001 2018-06-07 Tom Tromey <tom@tromey.com>
2003 * valprint.h (build_address_symbolic): Declare.
2004 * printcmd.c (print_address_symbolic): Update.
2005 (build_address_symbolic): Change "name" and "filename" to
2007 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
2009 * defs.h (build_address_symbolic): Remove declaration.
2011 2018-06-07 Alan Hayward <alan.hayward@arm.com>
2013 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
2014 (aarch64_vnv_type): Add function.
2015 (aarch64_pseudo_register_name): Add V regs for SVE.
2016 (aarch64_pseudo_register_type): Likewise.
2017 (aarch64_pseudo_register_reggroup_p): Likewise.
2018 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
2019 (aarch64_pseudo_read_value): Add V regs for SVE.
2020 (aarch64_pseudo_write_2): Use V0 offset for SVE
2021 (aarch64_pseudo_write): Add V regs for SVE.
2022 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
2024 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
2026 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
2027 (sve_vl_from_vq): Likewise.
2029 2018-06-05 Tom Tromey <tom@tromey.com>
2031 * cli/cli-cmds.c (show_version): Update.
2032 * top.c (print_gdb_version): Add "interactive" parameter.
2034 * main.c (captured_main_1): Update.
2035 * top.h (print_gdb_version): Add "interactive" parameter and a
2038 2018-06-05 David Malcolm <dmalcolm@redhat.com>
2040 * common/enum-flags.h: Add trailing semicolon to example in
2043 2018-06-05 Tom Tromey <tom@tromey.com>
2046 * NEWS: Add entry about pager.
2047 * utils.c (pagination_disabled_for_command): New global.
2048 (prompt_for_continue): Allow "c" response to prompt.
2049 (reinitialize_more_filter): Clear
2050 pagination_disabled_for_command.
2051 (fputs_maybe_filtered): Check pagination_disabled_for_command.
2053 2018-06-04 Tom Tromey <tom@tromey.com>
2055 * ada-lang.h (ada_lookup_symbol_list): Update.
2056 * ada-lang.c (resolve_subexp): Update.
2057 (symbols_are_identical_enums): Change type of syms. Remove nsyms
2059 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
2060 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
2061 results parameter to std::vector.
2062 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
2064 * ada-exp.y (block_lookup): Update.
2065 (select_possible_type_sym): Change type of syms. Remove nsyms
2067 (write_var_or_type, write_name_assoc): Update.
2069 2018-06-04 Joel Brobecker <brobecker@adacore.com>
2071 * windows-nat.c (windows_nat_target::xfer_partial): Return
2072 TARGET_XFER_E_IO if we need to delegate to the target beneath
2073 but BENEATH is NULL.
2075 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
2077 * Makefile.in (config.status): Add configure.nat as a
2080 2018-06-04 Tom Tromey <tom@tromey.com>
2082 * cp-name-parser.y (cpname_state): Add method declarations.
2083 (HANDLE_QUAL): Update.
2084 (cpname_state::d_grab, cpname_state::fill_comp)
2085 (cpname_state::make_operator, cpname_state::make_dtor)
2086 (cpname_state::make_builtin_type, cpname_state::make_name)
2087 (cpname_state::d_qualify, cpname_state::d_int_type)
2088 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
2089 (%union): Move earlier.
2091 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2093 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
2095 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2097 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
2098 (aarch64_pseudo_write_1): Likewise.
2099 (aarch64_pseudo_read_value): Use helper.
2100 (aarch64_pseudo_write): Likewise.
2102 2018-06-04 Pedro Alves <palves@redhat.com>
2104 * darwin-nat.c (darwin_ops): Delete.
2105 (darwin_attach_pid): Use get_native_target.
2107 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2109 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
2110 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
2112 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2114 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
2115 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
2116 (aarch64_gdbarch_init): Check for SVE.
2117 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
2119 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2121 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
2122 * aarch64-tdep.h (aarch64_read_description): Likewise.
2123 * arch/aarch64.c (aarch64_create_target_description): Likewise.
2124 * arch/aarch64.h (aarch64_create_target_description): Likewise.
2125 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
2126 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
2127 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
2129 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
2131 * value.c (value_fetch_lazy_bitfield): New.
2132 (value_fetch_lazy_memory): New.
2133 (value_fetch_lazy_register): New.
2134 (value_fetch_lazy): Factor out to smaller functions.
2136 2018-06-01 Tom Tromey <tom@tromey.com>
2138 * cp-name-parser.y (backslashable, represented): Now const.
2140 2018-06-01 Tom Tromey <tom@tromey.com>
2142 * cp-name-parser.y: Include parser-defs.h.
2143 (parser_fprintf): Remove declaration.
2145 2018-06-01 Tom Tromey <tom@tromey.com>
2147 * cp-name-parser.y: Use %pure-parser, %lex-param, and
2149 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
2150 (global_result): Remove globals.
2151 (struct cpname_state): New.
2152 (yyparse): Don't declare.
2153 (yylex, yyerror): Move declarations after %union.
2154 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
2155 (make_name): Add state parameter.
2157 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
2159 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
2161 (yylex): Add lvalp, state parameters.
2162 (yyerror): Add state parameter.
2163 (cp_demangled_name_to_comp): Update.
2165 2018-06-01 Tom Tromey <tom@tromey.com>
2167 * cp-name-parser.y (parser_fprintf): Declare.
2168 (GDB_YY_REMAP_PREFIX): Define.
2169 Include yy-remap.h. Don't redefine yy* identifiers.
2171 2018-06-01 Tom Tromey <tom@tromey.com>
2173 * python/py-type.c (typy_legacy_template_argument): Update.
2174 * cp-support.h (cp_demangled_name_to_comp): Update.
2175 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
2176 parameter to be a "std::string *".
2179 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
2181 * ada-lex.l: Include "diagnostics.h" instead of
2182 "common/diagnostics.h".
2183 * unittests/environ-selftests.c: Likewise.
2184 * common/diagnostics.h: Moved to ../include.
2186 2018-06-01 Joel Brobecker <brobecker@adacore.com>
2188 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
2189 to language_mode_manual while calling breakpoint_re_set_one.
2191 2018-06-01 Tom Tromey <tom@tromey.com>
2193 * valops.c (value_cast_structs, destructor_name_p): Update.
2194 * symtab.c (gdb_mangle_name): Update.
2195 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
2197 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
2198 (pascal_object_print_value_fields, pascal_object_print_value):
2200 * p-typeprint.c (pascal_type_print_derivation_info): Update.
2201 * linespec.c (find_methods): Update.
2202 * gdbtypes.h (type_name_no_tag): Remove.
2203 (type_name_or_error): Rename from type_name_no_tag_or_error.
2204 * gdbtypes.c (type_name_no_tag): Remove.
2205 (type_name_or_error): Rename from type_name_no_tag_or_error.
2206 (lookup_struct_elt_type, check_typedef): Update.
2207 * expprint.c (print_subexp_standard): Update.
2208 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
2209 * d-namespace.c (d_lookup_nested_symbol): Update.
2210 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
2211 (cp_print_class_member): Update.
2212 * cp-namespace.c (cp_lookup_nested_symbol): Update.
2213 * completer.c (add_struct_fields): Update.
2214 * c-typeprint.c (cp_type_print_derivation_info)
2215 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
2217 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
2218 (ada_prefer_type, ada_is_exception_sym): Update.
2220 2018-06-01 Tom Tromey <tom@tromey.com>
2222 * valops.c (enum_constant_from_type, value_namespace_elt)
2223 (value_maybe_namespace_elt): Update.
2224 * valarith.c (find_size_for_pointer_math): Update.
2225 * target-descriptions.c (make_gdb_type): Update.
2226 * symmisc.c (print_symbol): Update.
2227 * stabsread.c (define_symbol, read_type)
2228 (complain_about_struct_wipeout, add_undefined_type)
2229 (cleanup_undefined_types_1): Update.
2230 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
2231 (rust_range_type_p, val_print_struct, rust_print_struct_def)
2232 (rust_internal_print_type, rust_composite_type)
2233 (rust_evaluate_funcall, rust_evaluate_subexp)
2234 (rust_inclusive_range_type_p): Update.
2235 * python/py-type.c (typy_get_tag): Update.
2236 * p-typeprint.c (pascal_type_print_base): Update.
2237 * mdebugread.c (parse_symbol, parse_type): Update.
2238 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
2240 * guile/scm-type.c (gdbscm_type_tag): Update.
2241 * go-lang.c (sixg_string_p): Update.
2242 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
2244 * gdbtypes.h (struct main_type) <tag_name>: Remove.
2245 (TYPE_TAG_NAME): Remove.
2246 * gdbtypes.c (type_name_no_tag): Simplify.
2247 (check_typedef, check_types_equal, recursive_dump_type)
2248 (copy_type_recursive, arch_composite_type): Update.
2249 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
2250 in summary mode when needed.
2251 * eval.c (evaluate_funcall): Update.
2252 * dwarf2read.c (fixup_go_packaging, read_structure_type)
2253 (process_structure_scope, read_enumeration_type)
2254 (read_namespace_type, read_module_type, determine_prefix): Update.
2255 * cp-support.c (inspect_type): Update.
2256 * coffread.c (process_coff_symbol, decode_base_type): Update.
2257 * c-varobj.c (c_is_path_expr_parent): Update.
2258 * c-typeprint.c (c_type_print_base_struct_union): Update.
2259 (c_type_print_base_1): Update. Print struct/class/union/enum in
2260 summary when using C language.
2261 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
2262 (gen_maybe_namespace_elt): Update.
2263 * ada-lang.c (ada_type_name): Simplify.
2264 (empty_record, ada_template_to_fixed_record_type_1)
2265 (template_to_static_fixed_type)
2266 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
2268 2018-06-01 Tom Tromey <tom@tromey.com>
2270 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
2272 * c-typeprint.c (c_print_type_1): Add "language" parameter.
2273 (c_print_type): Update.
2274 (c_print_type): New overload.
2275 (c_type_print_varspec_prefix, c_type_print_args)
2276 (c_type_print_varspec_suffix, c_print_type_no_offsets)
2277 (c_type_print_base_struct_union, c_type_print_base_1)
2278 (cp_type_print_method_args): Add "language" parameter.
2279 (c_type_print_base): Update.
2280 * c-lang.h (c_print_type): Add new overload.
2282 2018-06-01 Tom Tromey <tom@tromey.com>
2284 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
2285 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
2287 2018-06-01 Alan Hayward <alan.hayward@arm.com>
2289 * aarch64-tdep.c (aarch64_sve_register_names): New const
2291 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
2292 (AARCH64_SVE_Z_REGS_NUM): New define.
2293 (AARCH64_SVE_P_REGS_NUM): Likewise.
2294 (AARCH64_SVE_NUM_REGS): Likewise.
2296 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
2298 * nat/linux-ptrace.h [__alpha__]
2299 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
2302 2018-05-31 Maciej W. Rozycki <macro@mips.com>
2304 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
2305 the endianness selected.
2306 * NEWS: Document `set endian auto' mode operation update.
2308 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2310 * Makefile.in: Add new header.
2311 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
2312 (sve_vl_from_vg): Likewise.
2313 (sve_vq_from_vl): Likewise.
2314 (sve_vl_from_vq): Likewise.
2315 (sve_vq_from_vg): Likewise.
2316 (sve_vg_from_vq): Likewise.
2317 * configure.nat: Add new c file.
2318 * nat/aarch64-sve-linux-ptrace.c: New file.
2319 * nat/aarch64-sve-linux-ptrace.h: New file.
2321 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2323 * aarch64-linux-nat.c (aarch64_linux_read_description):
2325 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
2327 * aarch64-tdep.c (tdesc_aarch64_list): Add.
2328 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
2329 (aarch64_gdbarch_init): Add parmeter zero.
2330 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
2331 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
2332 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
2334 * doc/gdb.texinfo: Describe SVE feature
2335 * features/aarch64-sve.c: New file.
2337 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
2340 * gdbarch.sh (significant_addr_bit): Default to zero when
2341 not set by target architecture.
2342 * gdbarch.c: Re-generated.
2343 * utils.c (address_significant): Update.
2345 2018-05-30 Joel Brobecker <brobecker@adacore.com>
2347 * stack.c (func_command): Remove trailing newline in call to error.
2349 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2351 * regcache.h (regcache_raw_collect): Remove, update callers to
2352 use regcache::raw_collect.
2353 * regcache.c (regcache_raw_collect): Remove.
2355 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2357 * regcache.h (regcache_raw_supply): Remove, update callers to
2358 use detached_regcache::raw_supply.
2359 * regcache.c (regcache_raw_supply): Remove.
2361 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2363 * regcache.h (regcache_cooked_write_part): Remove, update
2364 callers to use regcache::cooked_write_part.
2365 * regcache.c (regcache_cooked_write_part): Remove.
2367 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2369 * regcache.h (regcache_cooked_read_part): Remove, update callers
2370 to use readable_regcache::cooked_read_part.
2371 * regcache.c (regcache_cooked_read_part): Remove.
2373 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2375 * regcache.h (regcache_cooked_read_value): Remove, update
2376 callers to use readable_regcache::cooked_read_value.
2377 * regcache.c (regcache_cooked_read_value): Remove.
2379 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2381 * regcache.h (regcache_cooked_write): Remove, update callers to
2382 use regcache::cooked_write.
2383 * regcache.c (regcache_cooked_write): Remove.
2385 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2387 * regcache.h (regcache_invalidate): Remove, update callers to
2388 use detached_regcache::invalidate instead.
2389 * regcache.c (regcache_invalidate): Remove.
2391 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2393 * regcache.h (regcache_raw_write_part): Remove, update callers
2394 to use regcache::raw_write_part instead.
2395 * regcache.c (regcache_raw_write_part): Remove.
2397 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2399 * regcache.h (regcache_raw_read_part): Remove, update callers to
2400 use readable_regcache::raw_read_part instead.
2401 * regcache.c (regcache_raw_read_part): Remove.
2403 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2405 * regcache.h (regcache_cooked_read): Remove, update callers to
2406 use readable_regcache::cooked_read instead.
2407 * regcache.c (regcache_cooked_read): Remove.
2409 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2411 * regcache.h (regcache_raw_write): Remove, update callers to use
2412 regcache::raw_write instead.
2413 * regcache.c (regcache_raw_write): Remove.
2415 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2417 * regcache.h (regcache_raw_read): Remove, update callers to use
2418 readable_regcache::raw_read instead.
2419 * regcache.c (regcache_raw_read): Remove.
2421 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2423 * regcache.h (regcache_raw_update): Remove, update callers to
2424 use readable_regcache::raw_update instead.
2425 * regcache.c (regcache_raw_update): Remove.
2427 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2429 * regcache.h (regcache_register_status): Remove, update callers
2430 to use reg_buffer::get_register_status directly instead.
2431 * regcache.c (regcache_register_status): Remove.
2433 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2435 * regcache.h (regcache_get_ptid): Remove, update all callers to
2436 call regcache::ptid instead.
2437 * regcache.c (regcache_get_ptid): Remove.
2439 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2441 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
2443 2018-05-30 Pedro Alves <palves@redhat.com>
2445 * common/common-exceptions.h (exception_rethrow): Use
2448 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
2450 * breakpoint.c (print_solib_event, check_status_catch_solib):
2451 Remove struct keyword in range-based for loops.
2452 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
2453 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
2455 * linespec.c (find_superclass_methods, search_minsyms_for_name):
2457 * symfile.c (addr_info_make_relative): Likewise.
2458 * thread.c (value_in_thread_stack_temporaries): Likewise.
2460 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
2463 * valops.c (value_struct_elt_for_reference): Call check_typedef on
2464 aggregate type to get its real type before accessing it.
2466 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
2468 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
2469 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
2470 * coff-pe-read.c (add_pe_forwarded_sym): Replace
2471 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
2472 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
2473 * jit.c (jit_breakpoint_re_set_internal): Likewise.
2474 * printcmd.c (info_address_command): Likewise.
2476 2018-05-29 Tom Tromey <tom@tromey.com>
2478 * windows-nat.c (handle_exception): Update fall-through comment.
2480 2018-05-29 Tom Tromey <tom@tromey.com>
2482 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
2483 (struct program_space) <added_solibs>: Now a std::vector.
2484 * breakpoint.c (print_solib_event): Update.
2485 (check_status_catch_solib): Update.
2486 * progspace.c (clear_program_space_solib_cache): Update.
2487 * solib.c (update_solib_list): Update.
2489 2018-05-29 Tom Tromey <tom@tromey.com>
2491 * python/py-type.c (typy_richcompare): Update.
2492 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
2493 * gdbtypes.h (types_deeply_equal): Return bool.
2494 (types_equal): Likewise.
2495 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
2497 (check_types_equal): Change worklist to std::vector. Return
2499 (struct type_equality_entry): Add constructor.
2500 (compare_maybe_null_strings): Return bool.
2501 (check_types_worklist): Return bool. Change worklist to
2503 (types_deeply_equal): Use std::vector.
2504 (types_equal): Return bool.
2505 (compare_maybe_null_strings): Simplify.
2507 2018-05-29 Tom Tromey <tom@tromey.com>
2509 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
2511 2018-05-29 Tom Tromey <tom@tromey.com>
2513 * objc-lang.h: Don't include cp-support.h.
2514 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
2517 2018-05-27 Tom Tromey <tom@tromey.com>
2519 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
2521 2018-05-25 Tom Tromey <tom@tromey.com>
2523 * value.c (value::location): Initialize.
2525 2018-05-25 Tom Tromey <tom@tromey.com>
2527 * dbxread.c (init_bincl_list): Remove.
2528 (bincl_list): Now a std::vector.
2529 (bincls_allocated, next_bincl): Remove.
2530 (free_bincl_list, do_free_bincl_list_cleanup)
2531 (make_cleanup_free_bincl_list): Remove.
2532 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
2534 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
2535 (struct header_file_location): Add constructor.
2536 (add_bincl_to_list): Remove.
2538 2018-05-25 Tom Tromey <tom@tromey.com>
2540 * tui/tui.c (tui_enable): Update.
2541 * mi/mi-interp.c (mi_interp::init): Update.
2542 * interps.h (class interp) <name>: New method.
2543 <m_name>: Rename from name.
2544 (~scoped_restore_interp): Update.
2545 * interps.c (interp::interp): Update.
2546 (interp_add, interp_set, interp_lookup_existing)
2547 (current_interp_named_p): Update.
2549 2018-05-25 Tom Tromey <tom@tromey.com>
2551 * interps.c (interp_name): Remove.
2552 * mi/mi-interp.c (mi_interp::init): Update.
2553 * interps.h (interp_name): Remove.
2554 (~scoped_restore_interp): Update.
2555 * tui/tui.c (tui_enable): Update.
2557 2018-05-25 Tom Tromey <tom@tromey.com>
2559 * utils.c (fputs_maybe_filtered): Update.
2560 * linespec.c (decode_line_full): Update.
2561 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
2562 (mi_print_breakpoint_for_event, mi_solib_loaded)
2563 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
2564 (mi_user_selected_context_changed): Update.
2565 * mi/mi-main.c (mi_execute_command): Update.
2566 * cli/cli-script.c (execute_control_command): Update.
2567 * python/python.c (execute_gdb_command): Update.
2568 * solib.c (info_sharedlibrary_command): Update.
2569 * interps.c (interp_ui_out): Remove.
2570 * interps.h (interp_ui_out): Remove.
2572 2018-05-25 Tom Tromey <tom@tromey.com>
2574 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
2575 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
2576 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
2578 2018-05-25 Tom Tromey <tom@tromey.com>
2580 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
2581 * interps.c (interp_exec): Use scoped_restore.
2583 2018-05-25 Tom Tromey <tom@tromey.com>
2585 * remote.c (remote_target::remote_file_get): Use
2587 (remote_target::remote_file_put): Likewise.
2589 2018-05-25 Tom Tromey <tom@tromey.com>
2591 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
2593 (get_pe_section_index, add_pe_exported_sym): Update.
2594 (read_pe_exported_syms): Use gdb::def_vector.
2596 2018-05-25 Tom Tromey <tom@tromey.com>
2598 * frame.c (remove_prev_frame): Remove.
2599 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
2601 2018-05-25 Maciej W. Rozycki <macro@mips.com>
2603 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
2605 * mips-linux-nat.c (supply_fpregset): Always call
2606 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
2607 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
2608 `mips_fill_fpregset'.
2609 * mips-linux-tdep.c (mips_supply_fpregset)
2610 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
2611 (mips_fill_fpregset_wrapper): Remove functions.
2612 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
2613 (mips_linux_fpregset): Remove variable.
2614 (mips_linux_iterate_over_regset_sections): Use
2615 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
2616 (mips_linux_o32_sigframe_init): Remove comment.
2618 2018-05-25 Pedro Alves <palves@redhat.com>
2620 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
2621 (struct readahead_cache, struct packet_reg, struct
2622 remote_arch_state, class remote_state): Move higher up in the
2624 (remote_target::m_remote_state): Now an object instead of a pointer.
2625 (remote_target::get_remote_state): Adjust.
2627 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2629 * stack.c (select_and_print_frame): Delete.
2630 (struct function_bounds): Move struct within function.
2631 (func_command): Most content moved into new function
2632 find_frame_for_function, use new function, print result, add
2634 (find_frame_for_function): New function, now returns a result.
2636 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2638 * stack.c (iterate_over_block_arg_vars): Fix comment.
2639 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
2641 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2645 (scoped_restore_selected_frame::scoped_restore_selected_frame):
2647 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
2649 * frame.h (class scoped_restore_selected_frame): New class.
2650 * stack.c (print_frame_local_vars): Remove catching and rethrowing
2651 of any exception, use scoped_restore_selected_frame to restore the
2654 2018-05-24 Pedro Alves <palves@redhat.com>
2656 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
2659 2018-05-23 Tom Tromey <tom@tromey.com>
2661 * complaints.c (struct complaints): Remove.
2662 (symfile_complaint_book): Remove.
2663 (series): New global.
2664 (complaint_internal): Update.
2665 (clear_complaints): Update.
2667 2018-05-23 Tom Tromey <tom@tromey.com>
2669 * complaints.c (counters): New global.
2670 (struct complain): Remove.
2671 (struct complaints) <root>: Remove.
2672 (complaint_sentinel): Remove.
2673 (symfile_complaint_book): Update.
2674 (find_complaint) Remove.
2675 (complaint_internal, clear_complaints): Update.
2677 2018-05-23 Tom Tromey <tom@tromey.com>
2679 * complaints.c (struct complain) <file, line>: Remove.
2680 (find_complaint): Remove file, line parameters.
2681 (complaint_internal): Update.
2683 2018-05-23 Tom Tromey <tom@tromey.com>
2685 * complaints.c (vcomplaint): Remove.
2686 (complaint_internal) Merge in contents of vcomplaint.
2688 2018-05-23 Tom Tromey <tom@tromey.com>
2690 * complaints.c (struct complaints) <explanation>: Remove.
2691 (symfile_explanations): Remove.
2692 (symfile_complaint_book): Update.
2693 (vcomplaint): Update.
2694 (struct explanation): Remove.
2696 2018-05-23 Tom Tromey <tom@tromey.com>
2698 * complaints.c (symfile_complaints): Remove.
2699 (complaint_internal): Remove "complaints" parameter.
2700 (clear_complaints, vcomplaint): Remove "c" parameter.
2701 (get_complaints): Remove.
2702 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
2703 (dwarf2_debug_line_missing_file_complaint)
2704 (dwarf2_debug_line_missing_end_sequence_complaint)
2705 (dwarf2_complex_location_expr_complaint)
2706 (dwarf2_const_value_length_mismatch_complaint)
2707 (dwarf2_section_buffer_overflow_complaint)
2708 (dwarf2_macro_malformed_definition_complaint)
2709 (dwarf2_invalid_attrib_class_complaint)
2710 (create_addrmap_from_index, dw2_symtab_iter_next)
2711 (dw2_expand_marked_cus)
2712 (dw2_debug_names_iterator::find_vec_in_debug_names)
2713 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
2714 (create_debug_type_hash_table, init_cutu_and_read_dies)
2715 (partial_die_parent_scope, add_partial_enumeration)
2716 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
2717 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
2718 (read_import_statement, read_file_scope, create_dwo_cu_reader)
2719 (create_cus_hash_table, create_dwp_hash_table)
2720 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
2721 (dwarf2_rnglists_process, dwarf2_ranges_process)
2722 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
2723 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
2724 (handle_struct_member_die, process_structure_scope)
2725 (read_array_type, read_common_block, read_module_type)
2726 (read_tag_pointer_type, read_typedef, read_base_type)
2727 (read_subrange_type, load_partial_dies, partial_die_info::read)
2728 (partial_die_info::read, partial_die_info::read)
2729 (partial_die_info::read, read_checked_initial_length_and_offset)
2730 (dwarf2_string_attr, read_formatted_entries)
2731 (dwarf_decode_line_header)
2732 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2733 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
2734 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
2735 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
2736 (get_signatured_type, get_DW_AT_signature_type)
2737 (decode_locdesc, file_file_name, consume_improper_spaces)
2738 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
2739 (dwarf_decode_macro_bytes, dwarf_decode_macros)
2740 (dwarf2_symbol_mark_computed, set_die_type)
2741 (read_attribute_value): Update.
2742 * stap-probe.c (handle_stap_probe, get_stap_base_address):
2744 * dbxread.c (unknown_symtype_complaint)
2745 (lbrac_mismatch_complaint, repeated_header_complaint)
2746 (set_namestring, function_outside_compilation_unit_complaint)
2747 (read_dbx_symtab, process_one_symbol): Update.
2748 * gdbtypes.c (stub_noname_complaint): Update.
2749 * windows-nat.c (handle_unload_dll): Update.
2750 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
2751 (decode_base_type): Update.
2752 * xcoffread.c (bf_notfound_complaint, ef_complaint)
2753 (eb_complaint, record_include_begin, record_include_end)
2754 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
2755 (process_xcoff_symbol, read_symbol)
2756 (function_outside_compilation_unit_complaint)
2757 (scan_xcoff_symtab): Update.
2758 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
2759 * buildsym.c (finish_block_internal, make_blockvector)
2760 (end_symtab_get_static_block, augment_type_symtab): Update.
2761 * dtrace-probe.c (dtrace_process_dof)
2762 (dtrace_static_probe_ops::get_probes): Update.
2763 * complaints.h (struct complaint): Don't declare.
2764 (symfile_complaints): Remove.
2765 (complaint_internal): Remove "complaints" parameter.
2766 (complaint): Likewise.
2767 (clear_complaints): Likewise.
2768 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2769 (reread_symbols): Update.
2770 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2771 (dwarf2_frame_cache, decode_frame_entry): Update.
2772 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
2773 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2774 (info_selectors_command): Update.
2775 * macrotab.c (macro_include, check_for_redefinition)
2776 (macro_undef): Update.
2777 * objfiles.c (filter_overlapping_sections): Update.
2778 * stabsread.c (invalid_cpp_abbrev_complaint)
2779 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
2780 (define_symbol, error_type, read_type, rs6000_builtin_type)
2781 (stabs_method_name_from_physname, read_member_functions)
2782 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
2783 (attach_fields_to_type, complain_about_struct_wipeout)
2784 (read_range_type, read_args, common_block_start)
2785 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
2787 * mdebugread.c (index_complaint, unknown_ext_complaint)
2788 (basic_type_complaint, bad_tag_guess_complaint)
2789 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
2790 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
2791 (parse_procedure, parse_lines)
2792 (function_outside_compilation_unit_complaint)
2793 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
2794 (bad_tag_guess_complaint, reg_value_complaint): Update.
2795 * cp-support.c (demangled_name_complaint): Update.
2796 * macroscope.c (sal_macro_scope): Update.
2797 * dwarf-index-write.c (class debug_names): Update.
2799 2018-05-23 Tom Tromey <tom@tromey.com>
2801 * complaints.c (clear_complaints): Remove "noisy" parameter.
2802 * complaints.h (clear_complaints): Update.
2803 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2804 (reread_symbols): Update.
2806 2018-05-23 Tom Tromey <tom@tromey.com>
2808 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
2810 (vcomplaint, clear_complaints): Update.
2811 (symfile_explanations): Remove some messages.
2813 2018-05-23 Tom Tromey <tom@tromey.com>
2815 * complaints.c (internal_complaint): Remove.
2816 * complaints.h (internal_complaint): Remove.
2818 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2820 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
2822 2018-05-22 Pedro Alves <palves@redhat.com>
2824 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
2825 (remote_fileio_badfd, remote_fileio_return_errno)
2826 (remote_fileio_return_success, remote_fileio_func_open)
2827 (remote_fileio_func_open, remote_fileio_func_close)
2828 (remote_fileio_func_read, remote_fileio_func_write)
2829 (remote_fileio_func_lseek, remote_fileio_func_rename)
2830 (remote_fileio_func_unlink, remote_fileio_func_stat)
2831 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
2832 (remote_fileio_func_isatty, remote_fileio_func_system): Add
2833 remote_target parameter.
2834 (remote_fio_func_map) <func>: Add remote_target parameter.
2835 (do_remote_fileio_request, remote_fileio_request):
2836 * remote-fileio.h (remote_fileio_request):
2837 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
2838 remote_target parameter.
2839 (remote_notif_process, handle_notification): Adjust to pass down
2841 (remote_notif_state_allocate): Add remote_target parameter. Save
2843 * remote-notif.h (struct remote_target): Forward declare.
2844 (struct notif_client) <parse, ack, can_get_pending_events>: Add
2845 remote_target parameter.
2846 (struct remote_notif_state) <remote>: New field.
2847 (remote_notif_ack, remote_notif_parse): Add remote_target
2849 (remote_notif_state_allocate, remote_notif_state_allocate): Add
2850 remote_target parameter.
2851 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
2852 (threads_listing_context, rmt_thread_action, protocol_feature)
2853 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
2854 (packet_result, struct threads_listing_context, remote_state):
2855 Move definitions and declarations higher up.
2856 (remote_target) <~remote_target>: Declare.
2857 (remote_download_command_source, remote_file_put, remote_file_get)
2858 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
2859 (remote_hostio_pread_vFile, remote_hostio_send_command)
2860 (remote_hostio_set_filesystem, remote_hostio_open)
2861 (remote_hostio_close, remote_hostio_unlink, remote_state)
2862 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
2863 (get_memory_write_packet_size, get_memory_read_packet_size)
2864 (append_pending_thread_resumptions, remote_detach_1)
2865 (append_resumption, remote_resume_with_vcont)
2866 (add_current_inferior_and_thread, wait_ns, wait_as)
2867 (process_stop_reply, remote_notice_new_inferior)
2868 (process_initial_stop_replies, remote_add_thread)
2869 (btrace_sync_conf, remote_btrace_maybe_reopen)
2870 (remove_new_fork_children, kill_new_fork_children)
2871 (discard_pending_stop_replies, stop_reply_queue_length)
2872 (check_pending_events_prevent_wildcard_vcont)
2873 (discard_pending_stop_replies_in_queue, stop_reply)
2874 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
2875 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
2876 (remote_interrupt_as, remote_interrupt_ns)
2877 (remote_get_noisy_reply, remote_query_attached)
2878 (remote_add_inferior, remote_current_thread, get_current_thread)
2879 (set_thread, set_general_thread, set_continue_thread)
2880 (set_general_process, write_ptid)
2881 (remote_unpack_thread_info_response, remote_get_threadinfo)
2882 (parse_threadlist_response, remote_get_threadlist)
2883 (remote_threadlist_iterator, remote_get_threads_with_ql)
2884 (remote_get_threads_with_qxfer)
2885 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
2886 (get_offsets, remote_check_symbols, remote_supported_packet)
2887 (remote_query_supported, remote_packet_size)
2888 (remote_serial_quit_handler, remote_detach_pid)
2889 (remote_vcont_probe, remote_resume_with_hc)
2890 (send_interrupt_sequence, interrupt_query)
2891 (remote_notif_get_pending_events, fetch_register_using_p)
2892 (send_g_packet, process_g_packet, fetch_registers_using_g)
2893 (store_register_using_P, store_registers_using_G)
2894 (set_remote_traceframe, check_binary_download)
2895 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
2896 (remote_xfer_live_readonly_partial, remote_read_bytes)
2897 (remote_send_printf, remote_flash_write, readchar)
2898 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
2899 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
2900 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
2901 (extended_remote_disable_randomization, extended_remote_run)
2902 (send_environment_packet, extended_remote_environment_support)
2903 (extended_remote_set_inferior_cwd, remote_write_qxfer)
2904 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
2905 (packet_command): Now methods of ...
2906 (remote_target): ... this class.
2907 (m_remote_state) <remote_target>: New field.
2908 (struct remote_state) <stop_reply_queue,
2909 remote_async_inferior_event_token, wait_forever_enabled_p>: New
2911 (remote_state::remote_state): Allocate stop_reply_queue.
2912 (remote_state): Delete global.
2913 (get_remote_state_raw): Delete.
2914 (remote_target::get_remote_state): Allocate m_remote_state on
2916 (get_current_remote_target): New.
2917 (remote_ops, extended_remote_ops): Delete.
2918 (wait_forever_enabled_p, remote_async_inferior_event_token):
2919 Delete, moved to struct remote_state.
2920 (remote_target::close): Delete self. Destruction bits split to
2922 (remote_target::~remote_target): ... this.
2923 (show_memory_packet_size): Adjust to use
2924 get_current_remote_target.
2925 (struct protocol_feature) <func>: Add remote_target parameter.
2926 All callers adjusted.
2927 (curr_quit_handler_target): New.
2928 (remote_serial_quit_handler): Reimplement.
2929 (remote_target::open_1): Adjust to use get_current_remote_target.
2930 Heap-allocate remote_target/extended_remote_target instances.
2931 (vcont_builder::vcont_builder): Add remote_target parameter, and
2932 save it in m_remote. All callers adjusted.
2933 (vcont_builder::m_remote): New field.
2934 (vcont_builder::restart, vcont_builder::flush)
2935 (vcont_builder::push_action): Use it.
2936 (remote_target::commit_resume): Use it.
2937 (struct queue_iter_param) <remote>: New field.
2938 (remote_target::remove_new_fork_children): Fill in 'remote' field.
2939 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
2940 (check_pending_event_prevents_wildcard_vcont_callback)
2941 (remote_target::check_pending_events_prevent_wildcard_vcont)
2942 (remote_target::discard_pending_stop_replies)
2943 (remote_target::discard_pending_stop_replies_in_queue)
2944 (remote_target::remote_notif_remove_queued_reply): Fill in
2946 (remote_notif_get_pending_events): New.
2947 (remote_target::readchar, remote_target::remote_serial_write):
2948 Save/restore curr_quit_handler_target.
2950 (kill_new_fork_children): Fill in 'remote' field.
2951 (packet_command): Use get_current_remote_target, defer to
2952 remote_target method of same name.
2953 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
2954 parameter, and save it in m_remote. All callers adjusted.
2955 (scoped_remote_fd::release): Use m_remote.
2956 (scoped_remote_fd::m_remote): New field.
2957 (remote_file_put, remote_file_get, remote_file_delete): Use
2958 get_current_remote_target, defer to remote_target method of same
2960 (remote_btrace_reset): Add remote_state paremeter. Update all
2962 (remote_async_inferior_event_handler). Pass down 'data'.
2963 (remote_new_objfile): Use get_current_remote_target.
2964 (remote_target::vcont_r_supported): New.
2965 (set_range_stepping): Use get_current_remote_target and
2966 remote_target::vcont_r_supported.
2967 (_initialize_remote): Don't allocate 'remote_state' and
2968 'stop_reply_queue' globals.
2969 * remote.h (struct remote_target): Forward declare.
2970 (getpkt, putpkt, remote_notif_get_pending_events): Add
2971 'remote_target' parameter.
2973 2018-05-22 Pedro Alves <palves@redhat.com>
2975 * remote.c (vcont_builder): Now a class. Make all data members
2977 (vcont_builder) <vcont_builder, restart, flush, push_action>:
2979 (vcont_builder_restart): Rename to ...
2980 (vcont_builder::restart): ... this.
2981 (vcont_builder_flush): Rename to ...
2982 (vcont_builder::flush): ... this.
2983 (vcont_builder_push_action): Rename to ...
2984 (vcont_builder::push_action): ... this.
2985 (remote_target::commit_resume): Adjust.
2987 2018-05-22 Pedro Alves <palves@redhat.com>
2989 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
2990 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
2991 (get_fixed_memory_packet_size): New.
2992 (get_memory_packet_size): Use it.
2993 (set_memory_packet_size): Don't override the config size with
2994 DEFAULT_MAX_MEMORY_PACKET_SIZE.
2995 (show_memory_packet_size): Use get_fixed_memory_packet_size.
2996 Don't refer to get_memory_packet_size if not connected to a remote
2997 target. Show "(default)" if configured size is 0.
2999 2018-05-22 Pedro Alves <palves@redhat.com>
3001 * remote.c (remote_target::mourn_inferior): Move
3002 discard_pending_stop_replies call here from ...
3003 (_initialize_remote): ... here.
3005 2018-05-22 Pedro Alves <palves@redhat.com>
3007 * remote.c (compare_section_command): Remove set_general_process
3010 2018-05-22 Pedro Alves <palves@redhat.com>
3012 * remote.c (struct packet_reg, struct remote_arch_state):
3013 Move higher up in the file.
3014 (remote_state) <m_arch_states>: Store remote_arch_state values
3015 instead of remote_arch_state pointers.
3016 (remote_state::get_remote_arch_state): Adjust.
3018 2018-05-22 Pedro Alves <palves@redhat.com>
3020 * remote.c: Include <unordered_map>.
3021 (remote_state): Now a class.
3022 (remote_state) <get_remote_arch_state>: Declare method.
3023 <get_remote_arch_state>: New field.
3024 (remote_arch_state) <remote_arch_state>: Declare ctor.
3025 <regs>: Now a unique_ptr.
3026 (remote_gdbarch_data_handle): Delete.
3027 (get_remote_arch_state): Delete.
3028 (remote_state::get_remote_arch_state): New.
3029 (get_remote_state): Adjust to call remote_state's
3030 get_remote_arch_state method.
3031 (init_remote_state): Delete, bits factored out to ...
3032 (remote_arch_state::remote_arch_state): ... this new method.
3033 (get_remote_packet_size, get_memory_packet_size)
3034 (process_g_packet, remote_target::fetch_registers)
3035 (remote_target::prepare_to_store, store_registers_using_G)
3036 (remote_target::store_registers, remote_target::get_trace_status):
3037 Adjust to call remote_state's method.
3038 (_initialize_remote): Remove reference to
3039 remote_gdbarch_data_handle.
3041 2018-05-22 Pedro Alves <palves@redhat.com>
3043 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
3044 pread>: New method declarations.
3045 (remote_target::open_1): Adjust.
3046 (readahead_cache_invalidate): Rename to ...
3047 (readahead_cache::invalidate): ... this, and adjust to be a class
3049 (readahead_cache_invalidate_fd): Rename to ...
3050 (readahead_cache::invalidate_fd): ... this, and adjust to be a
3052 (remote_hostio_pwrite): Adjust.
3053 (remote_hostio_pread_from_cache): Rename to ...
3054 (readahead_cache::pread): ... this, and adjust to be a class
3056 (remote_hostio_close): Adjust.
3058 2018-05-22 Pedro Alves <palves@redhat.com>
3060 * remote.c (remote_hostio_close_cleanup): Delete.
3061 (class scoped_remote_fd): New.
3062 (remote_file_put, remote_file_get): Use it.
3064 2018-05-22 Pedro Alves <palves@redhat.com>
3066 (struct vCont_action_support): Use bool and initialize all fields.
3067 (struct readahead_cache): Initialize all fields.
3068 (remote_state): Use bool and initialize all fields.
3069 (remote_state::remote_state, remote_state::~remote_state): New.
3070 (new_remote_state): Delete.
3071 (_initialize_remote): Use new to allocate remote_state.
3073 2018-05-22 Pedro Alves <palves@redhat.com>
3077 * c-exp.y: Include "c-support.h".
3078 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
3079 of tolower. Use c_ident_is_alpha to scan names.
3080 * c-lang.c: Include "c-support.h".
3081 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
3082 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
3083 * c-support.h: New file, with bits factored out from ...
3084 * cp-name-parser.y: ... this file.
3085 Include "c-support.h".
3086 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
3087 c-support.h and renamed.
3088 (symbol_end, yylex): Adjust.
3090 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3092 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
3093 parameter type to CORE_ADDR.
3094 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
3095 parameter type in declaration to CORE_ADDR.
3096 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
3097 target_auxv_search to get AT_HWCAP and use the result to get the
3099 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
3100 to CORE_ADDR. Remove the cast of the return value to unsigned
3101 long. Fix error predicate of target_auxv_search.
3102 (ppc_linux_nat_target::read_description): Change the type of the
3103 hwcap variable to CORE_ADDR.
3105 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3107 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
3108 if the size of fpscr is larger than 32 bits.
3110 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3112 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
3113 (ppc32_linux_vsxregmap): New global.
3114 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
3115 regcache_supply_regset, and regcache_collect_regset.
3116 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
3117 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
3118 (fetch_vsx_register, store_vsx_register): Remove.
3119 (fetch_vsx_registers): Add regno parameter. Get regset using
3120 ppc_linux_vsxregset. Use regset to supply registers.
3121 (store_vsx_registers): Add regno parameter. Get regset using
3122 ppc_linux_vsxregset. Use regset to collect registers.
3123 (fetch_register): Call fetch_vsx_registers instead of
3125 (store_register): Call store_vsx_registers instead of
3127 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
3128 new regno parameter.
3129 (store_ppc_registers): Call store_vsx_registers with -1 for the
3130 new regno parameter.
3131 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
3132 (ppc_collect_vsxregset): Remove.
3134 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3136 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
3138 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
3139 for vector register offset fields.
3140 (ppc64_fbsd_reg_offsets): Likewise.
3141 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3142 to vector register offset fields.
3143 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3144 to vector register offset fields.
3145 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
3146 vector register offset fields.
3147 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
3148 initializers for vector register offset fields.
3149 (rs6000_aix64_reg_offsets): Likewise.
3150 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
3151 (ppc_supply_vrregset): Remove.
3152 (ppc_collect_vrregset): Remove.
3153 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
3154 (ppc_linux_vrregset) : New function.
3155 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
3156 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
3157 (ppc32_linux_vrregset): Remove.
3158 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
3159 and use result instead of ppc32_linux_vrregset.
3160 (ppc32_linux_reg_offsets): Remove initializers for vector register
3162 (ppc64_linux_reg_offsets): Likewise.
3163 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
3164 * ppc-linux-nat.c: Include regset.h.
3165 (gdb_vrregset_t): Adjust comment to account for little-endian
3167 (supply_vrregset, fill_vrregset): Remove.
3168 (fetch_altivec_register, store_altivec_register): Remove.
3169 (fetch_altivec_registers): Add regno parameter. Get regset using
3170 ppc_linux_vrregset. Use regset to supply registers.
3171 (store_altivec_registers): Add regno parameter. Get regset using
3172 ppc_linux_vrregset. Use regset to collect registers.
3173 (fetch_register): Call fetch_altivec_registers instead of
3174 fetch_altivec_register.
3175 (store_register): Call store_altivec_registers instead of
3176 store_altivec_register.
3177 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
3178 the new regno parameter.
3179 (store_ppc_registers): Call store_altivec_registers with -1 for
3180 the new regno parameter.
3182 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3184 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
3185 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
3186 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3187 (gdb_vrregset_t): Change array type size to
3188 PPC_LINUX_SIZEOF_VRREGSET.
3189 (gdb_vsxregset_t): Change array type size to
3190 PPC_LINUX_SIZEOF_VSXREGSET.
3191 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
3192 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
3193 PPC_LINUX_SIZEOF_VSXREGSET.
3195 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3197 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
3198 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
3200 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
3201 ppc_linux_target_wordsize with tid.
3202 (ppc_linux_nat_target::read_description): Call ppc_linux_target
3204 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
3205 (ppc64_64bit_inferior_p): Add static and inline specifiers.
3206 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
3207 tid parameter. Remove static specifier.
3208 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
3209 (ppc_linux_target_wordsize): New declaration.
3211 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3213 * arch/ppc-linux-common.c: New file.
3214 * arch/ppc-linux-common.h: New file.
3215 * arch/ppc-linux-tdesc.h: New file.
3216 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
3217 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
3218 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
3219 arch/ppc-linux-tdesc.h.
3220 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
3221 arch/ppc-linux-tdesc.h.
3222 (ppc_linux_nat_target::read_description): Remove target
3223 description matching code. Fill a ppc_linux_features struct and
3224 call ppc_linux_match_description with it. Move comment about ISA
3225 2.05 to ppc-linux-common.c.
3226 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
3227 arch/ppc-linux-tdesc.h.
3228 (ppc_linux_core_read_description): Remove target description
3229 matching code. Fill a ppc_linux_features struct and call
3230 ppc_linux_match_description with it.
3231 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3232 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3233 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3234 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3235 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3236 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3237 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3238 (tdesc_powerpc_e500l): Remove.
3240 2018-05-22 Joel Brobecker <brobecker@adacore.com>
3242 * ada-lang.c (catch_assert_command): Pass empty string instead
3243 of NULL for excep_string argument.
3245 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3247 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
3248 the width of the requested register exceeds the width of the
3251 2018-05-21 Tom Tromey <tom@tromey.com>
3253 * printcmd.c (output_command): Remove.
3254 (output_command_const): Rename to output_command.
3255 * valprint.h (output_command): Rename from output_command_const.
3256 * tracepoint.c (trace_dump_actions): Call output_command.
3258 2018-05-21 Tom Tromey <tom@tromey.com>
3260 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3261 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
3262 * ada-lang.h (create_ada_exception_catchpoint): Update.
3263 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
3265 (create_excep_cond_exprs, ~ada_catchpoint)
3266 (should_stop_exception, print_one_exception)
3267 (print_mention_exception, print_recreate_exception): Update.
3268 (ada_get_next_arg): Remove.
3269 (catch_ada_exception_command_split): Use std::string. Change type
3270 of "excep_string", "cond_string".
3271 (catch_ada_exception_command): Update.
3272 (create_ada_exception_catchpoint): Change type of excep_string.
3273 (ada_exception_sal): Remove excep_string parameter.
3274 (~ada_catchpoint): Remove.
3276 2018-05-21 Tom Tromey <tom@tromey.com>
3278 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
3281 2018-05-21 Tom Tromey <tom@tromey.com>
3283 * ada-lang.c (ada_exception_message_1, ada_exception_message):
3284 Return unique_xmalloc_ptr.
3285 (print_it_exception): Update.
3287 2018-05-21 Tom Tromey <tom@tromey.com>
3289 * tracepoint.c (trace_dump_actions): Use std::string.
3291 2018-05-21 Tom Tromey <tom@tromey.com>
3293 * symfile.c (reread_symbols): Use std::string for original_name.
3295 2018-05-21 Tom Tromey <tom@tromey.com>
3297 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
3298 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
3301 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
3303 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
3305 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
3306 * objfiles.c (get_objfile_bfd_data): Allocate
3307 objfile_per_bfd_storage with obstack_new when allocating on
3310 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3312 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
3314 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
3315 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
3316 * mdebugread.c (mdebug_build_psymtabs): Likewise.
3317 (add_pending): Likewise.
3318 (parse_symbol): Likewise.
3319 (parse_partial_symbols): Likewise.
3320 (psymtab_to_symtab_1): Likewise.
3321 (new_psymtab): Likewise.
3322 (elfmdebug_build_psymtabs): Likewise.
3323 * minsyms.c (terminate_minimal_symbol_table): Likewise.
3324 * objfiles.c (get_objfile_bfd_data): Likewise.
3325 (objfile_register_static_link): Likewise.
3326 * psymtab.c (allocate_psymtab): Likewise.
3327 * stabsread.c (read_member_functions): Likewise.
3328 * xcoffread.c (xcoff_end_psymtab): Likewise.
3330 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3332 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
3333 compiler supports std::is_trivially_constructible.
3334 * common/poison.h: Include obstack.h.
3335 (IsMallocable): Define to is_trivially_constructible if the
3336 compiler supports it, define to true_type otherwise.
3340 (XOBNEWVEC): Redefine.
3341 * gdb_obstack.h (obstack_zalloc): New.
3342 (OBSTACK_ZALLOC): Redefine.
3343 (obstack_calloc): New.
3344 (OBSTACK_CALLOC): Redefine.
3346 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
3347 (gdbarch_obstack): New declaration in gdbarch.h, definition in
3349 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
3350 obstack_calloc/obstack_zalloc.
3351 (gdbarch_obstack_zalloc): Remove.
3352 * target-descriptions.c (tdesc_data_init): Use obstack_new.
3354 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3356 * stack.c (backtrace_command_1): Remove useless variable int i.
3358 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3360 * stack.c (print_frame_info): Fix comment.
3362 2018-05-18 Tom Tromey <tom@tromey.com>
3364 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
3365 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
3366 (~dwarf2_per_objfile): Update
3367 (dwarf2_get_dwz_file): Use new.
3368 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
3371 2018-05-18 Tom Tromey <tom@tromey.com>
3373 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
3375 * dwarf2read.c (struct dwp_file): Add constructor and
3377 (open_and_init_dwp_file): Return a unique_ptr.
3378 (dwarf2_per_objfile, create_dwp_hash_table)
3379 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
3380 (lookup_dwo_unit_in_dwp): Update.
3381 (open_and_init_dwp_file, get_dwp_file): Update.
3383 2018-05-18 Tom Tromey <tom@tromey.com>
3385 * dwarf2read.c (dwarf2_per_objfile): Update.
3386 (struct mapped_index): Add initializers.
3387 (dwarf2_read_index): Use new.
3388 (dw2_symtab_iter_init): Update.
3389 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
3392 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3394 * dwarf2read.c (mapped_index) <total_size>: Remove.
3396 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3398 * unittests/format_pieces-selftests.c (test_format_specifier):
3401 2018-05-18 Tom Tromey <tom@tromey.com>
3403 * c-typeprint.c (maybe_print_hole): New function.
3404 (c_print_type_struct_field_offset): Update.
3405 (c_type_print_base_struct_union): Call maybe_print_hole.
3407 2018-05-17 Keith Seitz <keiths@redhat.com>
3409 * breakpoint.c (build_bpstat_chain): New function, moved from
3411 (bpstat_stop_status): Add optional parameter, `stop_chain'.
3412 If no stop chain is passed, call build_bpstat_chain to build it.
3413 * breakpoint.h (build_bpstat_chain): Declare.
3414 (bpstat_stop_status): Move documentation here from breakpoint.c.
3415 * infrun.c (handle_signal_stop): Before eliding inlined frames,
3416 build the stop chain and pass it to skip_inline_frames.
3417 Pass this stop chain to bpstat_stop_status.
3418 * inline-frame.c: Include breakpoint.h.
3419 (stopped_by_user_bp_inline_frame): New function.
3420 (skip_inline_frames): Add parameter `stop_chain'.
3421 Move documention to inline-frame.h.
3422 If non-NULL, use stopped_by_user_bp_inline_frame to determine
3423 whether the frame should be elided.
3424 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
3425 Add moved documentation and update for new parameter.
3427 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3430 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3431 unittests/format_pieces-selftests.c.
3432 * common/format.h (format_piece) <operator==>: New.
3433 (format_pieces) <operator[]>: Remove.
3434 * common/format.c (format_pieces::format_pieces): Handle \e.
3435 * unittests/format_pieces-selftests.c: New.
3437 2018-05-17 Tom Tromey <tom@tromey.com>
3440 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
3441 (dw2_instantiate_symtab): Add skip_partial parameter.
3442 (dw2_find_last_source_symtab, dw2_map_expand_apply)
3443 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
3444 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
3445 (dw2_expand_symtabs_matching_one)
3446 (dw2_find_pc_sect_compunit_symtab)
3447 (dw2_debug_names_lookup_symbol)
3448 (dw2_debug_names_expand_symtabs_for_function): Update.
3449 (init_cutu_and_read_dies): Add skip_partial parameter.
3450 (process_psymtab_comp_unit, build_type_psymtabs_1)
3451 (process_skeletonless_type_unit, load_partial_comp_unit)
3452 (psymtab_to_symtab_1): Update.
3453 (load_full_comp_unit): Add skip_partial parameter.
3454 (process_imported_unit_die, dwarf2_read_addr_index)
3455 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
3456 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
3457 (read_signatured_type): Update.
3459 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3461 * value.c (release_value): Remove unused variable.
3462 (record_latest_value): Likewise.
3463 (access_value_history): Likewise.
3464 (preserve_values): Likewise.
3466 2018-05-17 Tom Tromey <tom@tromey.com>
3468 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
3471 2018-05-16 Maciej W. Rozycki <macro@mips.com>
3474 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
3475 Also handle registers whose width is not a multiple of
3477 (linux_nat_trad_target::store_register): Likewise.
3479 2018-05-16 Tom Tromey <tom@tromey.com>
3481 * gdbcore.h (core_bfd): Redefine.
3482 * corelow.c (core_target::close): Update.
3483 (core_target_open): Update.
3484 * progspace.h (struct program_space) <cbfd>: Now a
3487 2018-05-16 Tom Tromey <tom@tromey.com>
3490 * symfile-add-flags.h (enum symfile_add_flags)
3491 <SYMFILE_NOT_FILENAME>: New constant.
3492 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
3493 objfile name from BFD.
3494 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
3495 * minidebug.c (find_separate_debug_file_in_section): Put
3496 ".gnu_debugdata" into BFD's file name.
3498 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
3500 * regcache.c (regcache_read_ftype, regcache_write_ftype):
3503 2018-05-15 Tamar Christina <tamar.christina@arm.com>
3506 * aarch64-tdep.c (aarch64_analyze_prologue,
3507 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
3508 Indicate not interested in errors.
3510 2018-05-15 Maciej W. Rozycki <macro@mips.com>
3512 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
3513 Supply the MIPS_ZERO_REGNUM register.
3515 2018-05-15 Maciej W. Rozycki <macro@mips.com>
3517 * mips-tdep.c (mask_address_var): Make variable static.
3519 2018-05-14 Tom Tromey <tom@tromey.com>
3521 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
3523 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
3525 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
3526 FXSAVE_ADDR for the mxcsr register.
3528 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
3530 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
3532 2018-05-11 Pedro Alves <palves@redhat.com>
3534 * corelow.c (core_target) <core_target>: No longer inline.
3535 Initialize m_core_gdbarch, m_core_vec and build the section table
3537 <~core_target>: New.
3538 <core_gdbarch, get_core_register_section>: New methods.
3539 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
3540 factored out from ...
3541 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
3543 (sniff_core_bfd): Add gdbarch parameter.
3544 (core_close): Delete, merged into ...
3545 (core_target::close): ... here. Delete self.
3546 (core_close_cleanup): Delete.
3547 (core_target_open): Allocate a core_target on the heap. Use a
3548 unique_ptr instead of a cleanup. Bits moved into the core_target
3549 ctor. Adjust to use core_target methods instead of globals.
3550 (get_core_register_section): Rename to ...
3551 (core_target::get_core_register_section): ... this and adjust.
3552 (struct get_core_registers_cb_data): New.
3553 (get_core_registers_cb): Use it. Use bool.
3554 (core_target::fetch_registers, core_target::files_info)
3555 (core_target::xfer_partial, core_target::read_description)
3556 (core_target::pid_to, core_target::thread_name): Adjust to
3557 reference class fields instead of globals.
3558 * target.h (struct target_ops_deleter, target_ops_up): New.
3560 2018-05-11 Pedro Alves <palves@redhat.com>
3562 * corefile.c (core_file_command): Move to corelow.c.
3563 * corelow.c (the_core_target): Delete.
3564 (core_file_command): Moved from corefile.c. Check exec_bfd
3565 instead of the_core_target. Use target_detach instead of calling
3566 into the_core_target directly.
3567 (maybe_say_no_core_file_now): New.
3568 (core_target::detach): Use it.
3569 (_initialize_corelow): Remove references to the_core_target.
3570 * gdbcore.h (the_core_target): Delete.
3572 2018-05-11 Tom Tromey <tromey@redhat.com>
3573 Pedro Alves <palves@redhat.com>
3575 * corefile.c (core_bfd): Remove.
3576 * gdbcore.h (core_bfd): Now a macro.
3577 * progspace.h (struct program_space) <cbfd>: New field.
3579 2018-05-11 Tom Tromey <tom@tromey.com>
3581 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
3584 2018-05-10 Tom Tromey <tom@tromey.com>
3586 * configure: Rebuild.
3587 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
3589 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3592 * regformats/regdat.sh: Adjust script, following the addition
3593 of the new expedite_regs parameter to init_target_desc.
3595 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
3598 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
3599 set_gdbarch_significant_addr_bit.
3600 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
3601 set_gdbarch_significant_addr_bit.
3602 * utils.c (address_significant): Update to sign extend addr.
3604 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
3606 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
3607 (xtensa_linux_init_abi): Limit tdep->num_regs by
3608 tdep->num_nopriv_regs.
3609 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
3610 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
3613 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
3615 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
3617 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3619 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
3620 (I387_MXCSR_INIT_VAL): New constant.
3621 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
3622 buffer if it was supplied by the inferior.
3623 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
3624 (i387_xsave_get_clear_bv): New function.
3625 (i387_supply_xsave): Only read x87 control registers from the
3626 xsave buffer if the feature is enabled, and the state will have
3627 been written, otherwise, provide a suitable default.
3628 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
3629 including x87 control registers. Update control registers if they
3630 have changed from the default value, and mark features as enabled
3632 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
3634 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
3636 * spu-tdep.c (info_spu_event_command): Fix output formatting.
3638 2018-05-07 Tom Tromey <tom@tromey.com>
3640 * configure: Rebuild.
3641 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
3643 2018-05-07 Tom Tromey <tom@tromey.com>
3646 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
3647 bit. Use correct value for VDIV.
3649 2018-05-04 Tom Tromey <tom@tromey.com>
3651 * configure: Rebuild.
3652 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
3654 2018-05-04 Tom Tromey <tom@tromey.com>
3656 * linux-record.c (record_linux_system_call) <case
3657 RECORD_SYS_RECVFROM>: Add "break".
3659 2018-05-04 Tom Tromey <tom@tromey.com>
3661 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
3662 Add missing "break".
3663 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
3664 Add missing "break".
3666 2018-05-04 Tom Tromey <tom@tromey.com>
3668 * rs6000-tdep.c (ppc_process_record_op4)
3669 (ppc_process_record_op63): Add fall-through comment.
3671 2018-05-04 Tom Tromey <tom@tromey.com>
3673 * i386-tdep.c (i386_process_record): Add fall-through comment.
3675 2018-05-04 Tom Tromey <tom@tromey.com>
3677 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
3680 2018-05-04 Tom Tromey <tom@tromey.com>
3682 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
3683 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
3684 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
3686 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
3688 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
3691 2018-05-04 Tom Tromey <tom@tromey.com>
3693 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
3695 2018-05-04 Tom Tromey <tom@tromey.com>
3697 * s390-tdep.c (s390_process_record): Fix fall-through comments.
3698 * xcoffread.c (scan_xcoff_symtab): Move comment later.
3699 * symfile.c (section_is_mapped): Fix fall-through comment.
3700 * stabsread.c (define_symbol, read_member_functions): Fix
3701 fall-through comment.
3702 * s390-linux-tdep.c (s390_process_record): Fix fall-through
3704 * remote.c (remote_wait_as): Fix fall-through comment.
3705 * p-exp.y (yylex): Fix fall-through comment.
3706 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
3708 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
3709 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
3710 * jv-exp.y (yylex): Fix fall-through comment.
3711 * go-exp.y (lex_one_token): Fix fall-through comment.
3712 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
3713 fall-through comment.
3714 * f-exp.y (yylex): Fix fall-through comment.
3715 * dwarf2read.c (process_die): Fix fall-through comments.
3716 * dbxread.c (process_one_symbol): Fix fall-through comment.
3717 * d-exp.y (lex_one_token): Fix fall-through comment.
3718 * cp-name-parser.y (yylex): Fix fall-through comment.
3719 * coffread.c (coff_symtab_read): Fix fall-through comment.
3720 * c-exp.y (lex_one_token): Fix fall-through comment.
3721 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
3723 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
3726 2018-05-04 Tom Tromey <tom@tromey.com>
3729 * NEWS: Mention gdb.execute change.
3730 * gdbcmd.h (execute_control_command): Don't declare.
3731 * python/python.c (execute_gdb_command): Use read_command_lines_1,
3732 execute_control_commands, execute_control_commands_to_string.
3733 * cli/cli-script.h (execute_control_commands)
3734 (execute_control_commands_to_string): Declare.
3735 (execute_control_command): Add from_tty parameter.
3736 * cli/cli-script.c (execute_control_commands)
3737 (execute_control_commands_to_string): New functions.
3738 (execute_user_command): Use execute_control_commands.
3739 (execute_control_command_1): Add "from_tty" parameter. Update.
3740 (execute_control_command): Likewise.
3742 2018-05-04 Tom Tromey <tom@tromey.com>
3745 * NEWS: Mention that breakpoint commands are writable.
3746 * python/py-breakpoint.c (bppy_set_commands): New function.
3747 (breakpoint_object_getset) <"commands">: Use it.
3749 2018-05-04 Tom Tromey <tom@tromey.com>
3751 * tracepoint.c (actions_command): Update.
3752 * mi/mi-cmd-break.c (mi_command_line_array)
3753 (mi_command_line_array_cnt, mi_command_line_array_ptr)
3754 (mi_read_next_line): Remove.
3755 (mi_cmd_break_commands): Update.
3756 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
3758 * cli/cli-script.c (get_command_line): Update.
3759 (process_next_line): Use function_view. Constify.
3760 (recurse_read_control_structure, read_command_lines)
3761 (read_command_lines_1): Change argument types to function_view.
3762 (do_define_command, document_command): Update.
3763 * breakpoint.h (check_tracepoint_command): Don't declare.
3764 * breakpoint.c (check_tracepoint_command): Remove.
3765 (commands_command_1, create_tracepoint_from_upload): Update.
3767 2018-05-04 Tom Tromey <tom@tromey.com>
3770 * cli/cli-script.h (enum command_control_type) <define_control>:
3772 * cli/cli-script.c (multi_line_command_p): Handle define_control.
3773 (build_command_line, execute_control_command_1)
3774 (process_next_line): Likewise.
3775 (do_define_command): New function, extracted from define_command.
3776 (define_command): Use it.
3778 2018-05-04 Tom Tromey <tom@tromey.com>
3780 * tracepoint.c (actions_command): Update.
3781 * cli/cli-script.h (read_command_lines): Update.
3782 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
3783 (MAX_TMPBUF): Remove define.
3784 (define_command): Use string_printf.
3785 (document_command): Likewise.
3786 * breakpoint.c (commands_command_1): Update.
3788 2018-05-04 Tom Tromey <tom@tromey.com>
3790 * top.c (execute_command): Update.
3791 * cli/cli-script.h (print_command_lines): Now varargs.
3792 * cli/cli-script.c (print_command_lines): Now varargs.
3793 (execute_control_command_1) <case while_control, case if_control>:
3796 2018-05-04 Tom Tromey <tom@tromey.com>
3798 * tracepoint.c (all_tracepoint_actions): Rename from
3799 all_tracepoint_actions_and_cleanup. Change return type.
3800 (actions_command, encode_actions_1, encode_actions)
3801 (trace_dump_actions, tdump_command): Update.
3802 * remote.c (remote_download_command_source): Update.
3803 * python/python.c (gdbpy_eval_from_control_command)
3804 (python_command, python_interactive_command): Update.
3805 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
3806 * guile/guile.c (guile_command)
3807 (gdbscm_eval_from_control_command, guile_command): Update.
3808 * compile/compile.c (compile_code_command)
3809 (compile_print_command, compile_to_object): Update.
3810 * cli/cli-script.h (struct command_lines_deleter): New.
3811 (counted_command_line): New typedef.
3812 (struct command_line): Add constructor, destructor.
3813 <body_list>: Remove.
3814 <body_list_0, body_list_1>: New members.
3815 (command_line_up): Remove typedef.
3816 (read_command_lines, read_command_lines_1, get_command_line):
3818 (copy_command_lines): Don't declare.
3819 * cli/cli-script.c (build_command_line): Use "new".
3820 (get_command_line): Return counted_command_line.
3821 (print_command_lines, execute_user_command)
3822 (execute_control_command_1, while_command, if_command): Update.
3823 (realloc_body_list): Remove.
3824 (process_next_line, recurse_read_control_structure): Update.
3825 (read_command_lines, read_command_lines_1): Return counted_command_line.
3826 (free_command_lines): Use "delete".
3827 (copy_command_lines): Remove.
3828 (define_command, document_command, show_user_1): Update.
3829 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
3830 a counted_command_line.
3831 * breakpoint.h (counted_command_line): Remove typedef.
3832 (breakpoint_set_commands): Update.
3833 * breakpoint.c (check_no_tracepoint_commands)
3834 (validate_commands_for_breakpoint): Update.
3835 (breakpoint_set_commands): Change commands to be a
3836 counted_command_line.
3837 (commands_command_1, update_dprintf_command_list)
3838 (create_tracepoint_from_upload): Update.
3840 2018-05-04 Tom Tromey <tom@tromey.com>
3842 * cli/cli-decode.h (cmd_list_element): New constructor.
3843 (~cmd_list_element): New destructor.
3844 (struct cmd_list_element): Add initializers.
3845 * cli/cli-decode.c (do_add_cmd): Use "new".
3846 (delete_cmd): Use "delete".
3848 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3849 Pedro Alves <palves@redhat.com>
3851 PR breakpoints/19806 and support for PR external/20207.
3852 * NEWS: Mention Aarch64 watchpoint improvements.
3853 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
3854 watchpoints and PR external/20207 watchpoints.
3855 * nat/aarch64-linux-hw-point.c
3856 (kernel_supports_any_contiguous_range): New.
3857 (aarch64_watchpoint_offset): New.
3858 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
3859 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
3860 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
3861 (aarch64_align_watchpoint): New parameters aligned_offset_p and
3862 next_addr_orig_p. Support PR external/20207 watchpoints.
3863 (aarch64_downgrade_regs): New.
3864 (aarch64_dr_state_insert_one_point): New parameters offset and
3866 (aarch64_dr_state_remove_one_point): Likewise.
3867 (aarch64_handle_breakpoint): Update caller.
3868 (aarch64_handle_aligned_watchpoint): Likewise.
3869 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
3871 (aarch64_linux_set_debug_regs): Remove const from state. Call
3872 aarch64_downgrade_regs.
3873 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
3874 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
3875 (DR_CONTROL_MASK): ... this.
3876 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
3877 (unsigned int aarch64_watchpoint_offset): New prototype.
3878 (aarch64_linux_set_debug_regs): Remove const from state.
3879 * utils.c (align_up, align_down): Move to ...
3880 * common/common-utils.c (align_up, align_down): ... here.
3881 * utils.h (align_up, align_down): Move to ...
3882 * common/common-utils.h (align_up, align_down): ... here.
3884 2018-05-04 Joel Brobecker <brobecker@adacore.com>
3886 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
3887 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
3888 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
3889 Re-implement to match the ABI as summarized in GCC's
3890 gcc/config/sparc/sparc.c. All callers updated.
3891 (sparc32_store_arguments): Remove assertion.
3893 2018-05-04 Tom Tromey <tom@tromey.com>
3895 * printcmd.c: Don't include tui.h.
3896 (decode_format): Use skip_spaces.
3898 2018-05-04 Tom Tromey <tom@tromey.com>
3901 * printcmd.c (last_count): New global.
3902 (x_command): Use saved count when repeating.
3904 2018-05-04 Tom Tromey <tom@tromey.com>
3906 * nto-procfs.c (do_closedir_cleanup): Remove.
3907 (procfs_pidlist): Use gdb_dir_up.
3908 * procfs.c (do_closedir_cleanup): Remove.
3909 (proc_update_threads): Use gdb_dir_up.
3910 * common/filestuff.h (struct gdb_dir_deleter): New.
3911 (gdb_dir_up): New typedef.
3913 2018-05-04 Tom Tromey <tom@tromey.com>
3915 * ada-lang.c (print_mention_exception): Use std::string.
3917 2018-05-04 Tom Tromey <tom@tromey.com>
3919 * ada-lang.c (create_excep_cond_exprs): Update.
3920 (ada_exception_catchpoint_cond_string): Use std::string.
3922 2018-05-04 Tom Tromey <tom@tromey.com>
3924 * ada-lang.c (xget_renaming_scope): Return std::string.
3925 (old_renaming_is_invisible): Update.
3927 2018-05-04 Tom Tromey <tom@tromey.com>
3929 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
3930 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
3932 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
3934 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
3936 2018-05-04 Tom Tromey <tom@tromey.com>
3938 * remote.c (remote_query_supported_append): Change type.
3939 (remote_check_symbols): Update.
3941 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
3944 * configure.ac: Prepend libpython.
3945 * python/python-config.py: Likewise.
3946 * configure: Regenerate.
3948 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
3950 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
3952 2018-05-03 Pedro Alves <palves@redhat.com>
3955 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
3956 override. Write 'true' instead of '1'.
3957 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
3960 2018-05-02 Pedro Alves <palves@redhat.com>
3962 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
3963 add_inf_child_target.
3964 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
3965 add_inf_child_target.
3966 * aix-thread.c (aix_thread_target_info): New.
3967 (aix_thread_target) <shortname, longname, doc>: Delete.
3969 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
3970 add_inf_child_target.
3971 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
3972 add_inf_child_target.
3973 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
3974 add_inf_child_target.
3975 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
3976 add_inf_child_target.
3977 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
3978 add_inf_child_target.
3979 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
3980 add_inf_child_target.
3981 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
3982 add_inf_child_target.
3983 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
3984 add_inf_child_target.
3985 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
3986 add_inf_child_target.
3987 * bfd-target.c (target_bfd_target_info): New.
3988 (target_bfd) <shortname, longname, doc>: Delete.
3990 * bsd-kvm.c (bsd_kvm_target_info): New.
3991 (bsd_kvm_target) <shortname, longname, doc>: Delete.
3993 (bsd_kvm_target::open): Rename to ...
3994 (bsd_kvm_target_open): ... this. Adjust.
3995 * bsd-uthread.c (bsd_uthread_target_info): New.
3996 (bsd_uthread_target) <shortname, longname, doc>: Delete.
3998 * corefile.c (core_file_command): Adjust.
3999 * corelow.c (core_target_info): New.
4000 (core_target) <shortname, longname, doc>: Delete.
4002 (core_target::open): Rename to ...
4003 (core_target_open): ... this. Adjust.
4004 * ctf.c (ctf_target_info): New.
4005 (ctf_target) <shortname, longname, doc>: Delete.
4007 (ctf_target::open): Rename to ...
4008 (ctf_target_open): ... this.
4009 (_initialize_ctf): Adjust.
4010 * exec.c (exec_target_info): New.
4011 (exec_target) <shortname, longname, doc>: Delete.
4013 (exec_target::open): Rename to ...
4014 (exec_target_open): ... this.
4015 * gdbcore.h (core_target_open): Declare.
4016 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
4017 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
4018 add_inf_child_target.
4019 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
4020 add_inf_child_target.
4021 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
4022 add_inf_child_target.
4023 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
4024 add_inf_child_target.
4025 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
4026 add_inf_child_target.
4027 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
4028 add_inf_child_target.
4029 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
4030 add_inf_child_target.
4031 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
4032 add_inf_child_target.
4033 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
4034 add_inf_child_target.
4035 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
4036 add_inf_child_target.
4037 * inf-child.c (inf_child_target_info): New.
4038 (inf_child_target::info): New.
4039 (inf_child_open_target): Remove 'target' parameter. Use
4040 get_native_target instead.
4041 (inf_child_target::open): Delete.
4042 (add_inf_child_target): New.
4043 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
4046 (add_inf_child_target): Declare.
4047 (inf_child_open_target): Declare.
4048 * linux-thread-db.c (thread_db_target_info): New.
4049 (thread_db_target) <shortname, longname, doc>: Delete.
4051 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
4052 add_inf_child_target.
4053 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
4054 add_inf_child_target.
4055 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
4056 add_inf_child_target.
4057 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
4058 add_inf_child_target.
4059 * make-target-delegates (print_class): Adjust.
4060 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
4061 add_inf_child_target.
4062 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
4063 add_inf_child_target.
4064 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
4065 add_inf_child_target.
4066 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
4067 add_inf_child_target.
4068 * nto-procfs.c (nto_native_target_info): New.
4069 (nto_procfs_target_native) <shortname, longname, doc>:
4072 (nto_procfs_target_info): New.
4073 (nto_procfs_target_procfs) <shortname, longname, doc>:
4076 (init_procfs_targets): Adjust.
4077 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
4078 add_inf_child_target.
4079 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
4080 add_inf_child_target.
4081 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
4082 add_inf_child_target.
4083 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
4084 add_inf_child_target.
4085 * ravenscar-thread.c (ravenscar_target_info): New.
4086 (ravenscar_thread_target) <shortname, longname, doc>:
4089 * record-btrace.c (record_btrace_target_info):
4090 (record_btrace_target) <shortname, longname, doc>: Delete.
4092 (record_btrace_target::open): Rename to ...
4093 (record_btrace_target_open): ... this. Adjust.
4094 * record-full.c (record_longname, record_doc): New.
4095 (record_full_base_target) <shortname, longname, doc>: Delete.
4097 (record_full_target_info): New.
4098 (record_full_target): <shortname>: Delete.
4100 (record_full_core_open_1, record_full_open_1): Update comments.
4101 (record_full_base_target::open): Rename to ...
4102 (record_full_open): ... this.
4103 (cmd_record_full_restore): Update.
4104 (_initialize_record_full): Update.
4105 * remote-sim.c (remote_sim_target_info): New.
4106 (gdbsim_target) <shortname, longname, doc>: Delete.
4108 (gdbsim_target::open): Rename to ...
4109 (gdbsim_target_open): ... this.
4110 (_initialize_remote_sim): Adjust.
4111 * remote.c (remote_doc): New.
4112 (remote_target_info): New.
4113 (remote_target) <shortname, longname, doc>: Delete.
4115 (extended_remote_target_info): New.
4116 (extended_remote_target) <shortname, longname, doc>: Delete.
4118 (remote_target::open_1): Make static. Adjust.
4119 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
4120 * s390-linux-nat.c (_initialize_s390_nat): Use
4121 add_inf_child_target.
4122 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
4123 add_inf_child_target.
4124 * sol-thread.c (thread_db_target_info): New.
4125 (sol_thread_target) <shortname, longname, doc>: Delete.
4127 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
4128 add_inf_child_target.
4129 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
4130 add_inf_child_target.
4131 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
4132 add_inf_child_target.
4133 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
4134 add_inf_child_target.
4135 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
4136 add_inf_child_target.
4137 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
4138 add_inf_child_target.
4139 * spu-linux-nat.c (_initialize_spu_nat): Use
4140 add_inf_child_target.
4141 * spu-multiarch.c (spu_multiarch_target_info): New.
4142 (spu_multiarch_target) <shortname, longname, doc>: Delete.
4144 * target-delegates.c: Regenerate.
4145 * target.c: Include <unordered_map>.
4146 (target_ops_p): Delete.
4147 (DEF_VEC_P(target_ops_p)): Delete.
4148 (target_factories): New.
4149 (test_target_info): New.
4150 (test_target_ops::info): New.
4151 (open_target): Adjust to use target_factories.
4152 (add_target_with_completer): Rename to ...
4153 (add_target): ... this. Change prototype. Register target_info
4154 and open callback in target_factories. Register target_info in
4155 command context instead of target_ops.
4156 (add_target): Delete old implementation.
4157 (add_deprecated_target_alias): Change prototype. Adjust.
4158 (the_native_target): New.
4159 (set_native_target, get_native_target): New.
4160 (find_default_run_target): Use the_native_target.
4161 (find_attach_target, find_run_target): Simplify.
4162 (target_ops::open): Delete.
4163 (dummy_target_info): New.
4164 (dummy_target::shortname, dummy_target::longname)
4165 (dummy_target::doc): Delete.
4166 (dummy_target::info): New.
4167 (debug_target::shortname, debug_target::longname)
4168 (debug_target::doc): Delete.
4169 (debug_target::info): New.
4170 * target.h (struct target_info): New.
4171 (target_ops::~target_ops): Add comment.
4172 (target_ops::info): New.
4173 (target_ops::shortname, target_ops::longname, target_ops::doc): No
4174 longer virtual. Implement in terms of target_info.
4175 (set_native_target, get_native_target): Declare.
4176 (target_open_ftype): New.
4177 (add_target, add_target_with_completer)
4178 (add_deprecated_target_alias): Change prototype.
4179 (test_target) <shortname, longname, doc>: Delete.
4181 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
4182 add_inf_child_target.
4183 * tracefile-tfile.c (tfile_target_info): New.
4184 (tfile_target) <shortname, longname, doc>: Delete.
4186 (tfile_target::open): Rename to ...
4187 (tfile_target_open): ... this.
4188 (_initialize_tracefile_tfile): Adjust.
4189 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
4190 add_inf_child_target.
4191 * windows-nat.c (_initialize_windows_nat): Use
4192 add_inf_child_target.
4193 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
4194 add_inf_child_target.
4196 2018-05-02 Pedro Alves <palves@redhat.com>
4198 * linux-nat.h (linux_nat_target) <low_new_thread,
4199 low_delete_thread, low_new_fork, low_forget_process,
4200 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
4201 New virtual methods.
4202 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4203 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
4204 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
4205 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4206 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
4208 * linux-fork.c (delete_fork): Adjust to call low method.
4209 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
4210 (linux_nat_new_fork, linux_nat_forget_process_hook)
4211 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
4212 (linux_nat_status_is_event):
4213 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
4214 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
4216 (sigtrap_is_event): Rename to ...
4217 (linux_nat_target::low_status_is_event): ... this.
4218 (linux_nat_set_status_is_event): Delete.
4219 (save_stop_reason, linux_nat_wait_1)
4220 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
4222 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4223 (linux_nat_set_new_fork, linux_nat_set_forget_process)
4224 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4225 (linux_nat_set_prepare_to_resume): Delete.
4226 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
4227 low virtual methods.
4228 * amd64-linux-nat.c: Likewise.
4229 * arm-linux-nat.c: Likewise.
4230 * i386-linux-nat.c: Likewise.
4231 * ia64-linux-nat.c: Likewise.
4232 * mips-linux-nat.c: Likewise.
4233 * ppc-linux-nat.c: Likewise.
4234 * s390-linux-nat.c: Likewise.
4235 * sparc64-linux-nat.c: Likewise.
4236 * x86-linux-nat.c: Likewise.
4237 * x86-linux-nat.h: Include "nat/x86-linux.h".
4238 (x86_linux_nat_target) <low_new_fork, low_forget_process,
4239 low_prepare_to_resume, low_new_thread, low_delete_thread>:
4242 2018-05-02 Pedro Alves <palves@redhat.com>
4244 * target.h (target_ops)
4245 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
4246 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
4247 stopped_by_watchpoint, have_continuable_watchpoint,
4248 stopped_data_address, watchpoint_addr_within_range,
4249 can_accel_watchpoint_condition, can_run, thread_alive,
4250 has_all_memory, has_memory, has_stack, has_registers,
4251 has_execution, can_async_p, is_async_p, supports_non_stop,
4252 always_non_stop_p, can_execute_reverse, supports_multi_process,
4253 supports_enable_disable_tracepoint,
4254 supports_disable_randomization, supports_string_tracing,
4255 supports_evaluation_of_breakpoint_conditions,
4256 can_run_breakpoint_commands, filesystem_is_local,
4257 can_download_tracepoint, get_trace_state_variable_value,
4258 set_trace_notes, get_tib_address, use_agent, can_use_agent,
4259 record_is_replaying, record_will_replay,
4260 augmented_libraries_svr4_read>: Adjust to return bool.
4261 * aarch64-linux-nat.c: All implementations adjusted.
4262 * aix-thread.c: All implementations adjusted.
4263 * arm-linux-nat.c: All implementations adjusted.
4264 * breakpoint.c: All implementations adjusted.
4265 * bsd-kvm.c: All implementations adjusted.
4266 * bsd-uthread.c: All implementations adjusted.
4267 * corelow.c: All implementations adjusted.
4268 * ctf.c: All implementations adjusted.
4269 * darwin-nat.c: All implementations adjusted.
4270 * darwin-nat.h: All implementations adjusted.
4271 * exec.c: All implementations adjusted.
4272 * fbsd-nat.c: All implementations adjusted.
4273 * fbsd-nat.h: All implementations adjusted.
4274 * gnu-nat.c: All implementations adjusted.
4275 * gnu-nat.h: All implementations adjusted.
4276 * go32-nat.c: All implementations adjusted.
4277 * ia64-linux-nat.c: All implementations adjusted.
4278 * inf-child.c: All implementations adjusted.
4279 * inf-child.h: All implementations adjusted.
4280 * inf-ptrace.c: All implementations adjusted.
4281 * inf-ptrace.h: All implementations adjusted.
4282 * linux-nat.c: All implementations adjusted.
4283 * linux-nat.h: All implementations adjusted.
4284 * mips-linux-nat.c: All implementations adjusted.
4285 * nto-procfs.c: All implementations adjusted.
4286 * ppc-linux-nat.c: All implementations adjusted.
4287 * procfs.c: All implementations adjusted.
4288 * ravenscar-thread.c: All implementations adjusted.
4289 * record-btrace.c: All implementations adjusted.
4290 * record-full.c: All implementations adjusted.
4291 * remote-sim.c: All implementations adjusted.
4292 * remote.c: All implementations adjusted.
4293 * s390-linux-nat.c: All implementations adjusted.
4294 * sol-thread.c: All implementations adjusted.
4295 * spu-multiarch.c: All implementations adjusted.
4296 * target-delegates.c: All implementations adjusted.
4297 * target.c: All implementations adjusted.
4298 * target.h: All implementations adjusted.
4299 * tracefile-tfile.c: All implementations adjusted.
4300 * tracefile.c: All implementations adjusted.
4301 * tracefile.h: All implementations adjusted.
4302 * windows-nat.c: All implementations adjusted.
4303 * x86-linux-nat.h: All implementations adjusted.
4304 * x86-nat.h: All implementations adjusted.
4306 2018-05-02 Pedro Alves <palves@redhat.com>
4308 * make-target-delegates (scan_target_h): Don't trim lines here.
4309 Replace sequences of tabs and/or whitespace with a single
4311 (top level, parsing methods): Trim each line before processing it
4314 2018-05-02 Pedro Alves <palves@redhat.com>
4315 John Baldwin <jhb@freebsd.org>
4317 * target.h (enum strata) <debug_stratum>: New.
4318 (struct target_ops) <all delegation methods>: Replace by C++
4319 virtual methods, and drop "to_" prefix. All references updated
4321 <to_shortname, to_longname, to_doc, to_data,
4322 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
4323 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
4324 virtual methods. All references updated throughout.
4325 <can_attach, supports_terminal_ours, can_create_inferior,
4326 get_thread_control_capabilities, attach_no_wait>: New
4328 <insert_breakpoint, remove_breakpoint>: Now
4329 TARGET_DEFAULT_NORETURN methods.
4330 <info_proc>: Now returns bool.
4332 (OPS_MAGIC): Delete.
4333 (current_target): Delete. All references replaced by references
4335 (target_stack): ... this. New.
4336 (target_shortname, target_longname): Adjust.
4337 (target_can_run): Now a function declaration.
4338 (default_child_has_all_memory, default_child_has_memory)
4339 (default_child_has_stack, default_child_has_registers)
4340 (default_child_has_execution): Remove target_ops parameter.
4341 (complete_target_initialization): Delete.
4342 (memory_breakpoint_target): New template class.
4343 (test_target_ops): Refactor as a C++ class with virtual methods.
4344 * make-target-delegates (NAME_PART): Tighten.
4345 (POINTER_PART, CP_SYMBOL): New.
4346 (SIMPLE_RETURN_PART): Reimplement.
4347 (VEC_RETURN_PART): Expect less.
4348 (RETURN_PART, VIRTUAL_PART): New.
4349 (METHOD): Adjust to C++ virtual methods.
4350 (scan_target_h): Remove reference to C99.
4351 (dname): Output "target_ops::" prefix.
4352 (write_function_header): Adjust to output a C++ class method.
4353 (write_declaration): New.
4354 (write_delegator): Adjust to output a C++ class method.
4355 (tdname): Output "dummy_target::" prefix.
4356 (write_tdefault, write_debugmethod): Adjust to output a C++ class
4358 (tdefault_names, debug_names): Delete.
4359 (return_types, tdefaults, styles, argtypes_array): New.
4360 (top level): All methods are delegators.
4362 (top level): Print dummy_target and debug_target classes.
4363 * target-delegates.c: Regenerate.
4364 * target-debug.h (target_debug_print_enum_info_proc_what)
4365 (target_debug_print_thread_control_capabilities)
4366 (target_debug_print_thread_info_p): New.
4367 * target.c (dummy_target): Delete.
4368 (the_dummy_target, the_debug_target): New.
4369 (target_stack): Now extern.
4370 (set_targetdebug): Push/unpush debug target.
4371 (default_child_has_all_memory, default_child_has_memory)
4372 (default_child_has_stack, default_child_has_registers)
4373 (default_child_has_execution): Remove target_ops parameter.
4374 (complete_target_initialization): Delete.
4375 (add_target_with_completer): No longer call
4376 complete_target_initialization.
4377 (target_supports_terminal_ours): Use regular delegation.
4378 (update_current_target): Delete.
4379 (push_target): No longer check magic number. Don't call
4380 update_current_target.
4381 (unpush_target): Don't call update_current_target.
4382 (target_is_pushed): No longer check magic number.
4383 (target_require_runnable): Skip for all stratums over
4385 (target_ops::info_proc): New.
4386 (target_info_proc): Use find_target_at and
4387 find_default_run_target.
4388 (target_supports_disable_randomization): Use regular delegation.
4389 (target_get_osdata): Use find_target_at.
4390 (target_ops::open, target_ops::close, target_ops::can_attach)
4391 (target_ops::attach, target_ops::can_create_inferior)
4392 (target_ops::create_inferior, target_ops::can_run)
4393 (target_can_run): New.
4394 (default_fileio_target): Use regular delegation.
4395 (target_ops::fileio_open, target_ops::fileio_pwrite)
4396 (target_ops::fileio_pread, target_ops::fileio_fstat)
4397 (target_ops::fileio_close, target_ops::fileio_unlink)
4398 (target_ops::fileio_readlink): New.
4399 (target_fileio_open_1, target_fileio_unlink)
4400 (target_fileio_readlink): Always call the target method. Handle
4402 (return_zero, return_zero_has_execution): Delete.
4403 (init_dummy_target): Delete.
4404 (dummy_target::dummy_target, dummy_target::shortname)
4405 (dummy_target::longname, dummy_target::doc)
4406 (debug_target::debug_target, debug_target::shortname)
4407 (debug_target::longname, debug_target::doc): New.
4408 (target_supports_delete_record): Use regular delegation.
4409 (setup_target_debug): Delete.
4410 (maintenance_print_target_stack): Skip debug_stratum.
4411 (initialize_targets): Instantiate the_dummy_target and
4413 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
4415 (target_auxv_search, fprint_target_auxv): Adjust.
4416 (info_auxv_command): Adjust to use target_stack.
4417 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
4418 * exceptions.c (print_flush): Handle a NULL target_stack.
4419 * regcache.c (target_ops_no_register): Refactor as class with
4422 * exec.c (exec_target): New class.
4423 (exec_ops): Now an exec_target.
4424 (exec_open, exec_close_1, exec_get_section_table)
4425 (exec_xfer_partial, exec_files_info, exec_has_memory)
4426 (exec_make_note_section): Refactor as exec_target methods.
4427 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
4429 (exec_target::find_memory_regions): New.
4430 (_initialize_exec): Don't call init_exec_ops.
4431 * gdbcore.h (exec_file_clear): Delete.
4433 * corefile.c (core_target): Delete.
4434 (core_file_command): Adjust.
4435 * corelow.c (core_target): New class.
4436 (the_core_target): New.
4437 (core_close): Remove target_ops parameter.
4438 (core_close_cleanup): Adjust.
4439 (core_target::close): New.
4440 (core_open, core_detach, get_core_registers, core_files_info)
4441 (core_xfer_partial, core_thread_alive, core_read_description)
4442 (core_pid_to_str, core_thread_name, core_has_memory)
4443 (core_has_stack, core_has_registers, core_info_proc): Rework as
4444 core_target methods.
4445 (ignore, core_remove_breakpoint, init_core_ops): Delete.
4446 (_initialize_corelow): Initialize the_core_target.
4447 * gdbcore.h (core_target): Delete.
4448 (the_core_target): New.
4450 * ctf.c: (ctf_target): New class.
4451 (ctf_ops): Now a ctf_target.
4452 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
4453 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
4454 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
4456 (init_ctf_ops): Delete.
4457 (_initialize_ctf): Don't call it.
4458 * tracefile-tfile.c (tfile_target): New class.
4459 (tfile_ops): Now a tfile_target.
4460 (tfile_open, tfile_close, tfile_files_info)
4461 (tfile_get_tracepoint_status, tfile_trace_find)
4462 (tfile_fetch_registers, tfile_xfer_partial)
4463 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
4464 Refactor as tfile_target methods.
4465 (tfile_xfer_partial_features): Remove target_ops parameter.
4466 (init_tfile_ops): Delete.
4467 (_initialize_tracefile_tfile): Don't call it.
4468 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
4469 (tracefile_has_stack, tracefile_has_registers)
4470 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
4471 tracefile_target methods.
4472 (init_tracefile_ops): Delete.
4473 (tracefile_target::tracefile_target): New.
4474 * tracefile.h: Include "target.h".
4475 (tracefile_target): New class.
4476 (init_tracefile_ops): Delete.
4478 * spu-multiarch.c (spu_multiarch_target): New class.
4479 (spu_ops): Now a spu_multiarch_target.
4480 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
4481 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
4482 (spu_search_memory, spu_mourn_inferior): Refactor as
4483 spu_multiarch_target methods.
4484 (init_spu_ops): Delete.
4485 (_initialize_spu_multiarch): Remove references to init_spu_ops,
4486 complete_target_initialization.
4488 * ravenscar-thread.c (ravenscar_thread_target): New class.
4489 (ravenscar_ops): Now a ravenscar_thread_target.
4490 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
4491 (ravenscar_thread_alive, ravenscar_pid_to_str)
4492 (ravenscar_fetch_registers, ravenscar_store_registers)
4493 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
4494 (ravenscar_stopped_by_hw_breakpoint)
4495 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
4496 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
4497 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
4499 (init_ravenscar_thread_ops): Delete.
4500 (_initialize_ravenscar): Remove references to
4501 init_ravenscar_thread_ops and complete_target_initialization.
4503 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
4504 (bsd_uthread_target): New class.
4505 (bsd_uthread_ops): Now a bsd_uthread_target.
4506 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
4507 (bsd_uthread_close, bsd_uthread_mourn_inferior)
4508 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
4509 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
4510 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
4511 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
4512 (bsd_uthread_target): Delete function.
4513 (_initialize_bsd_uthread): Remove reference to
4514 complete_target_initialization.
4516 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
4517 (target_bfd): ... this new class.
4518 (target_bfd_xfer_partial, target_bfd_get_section_table)
4519 (target_bfd_close): Refactor as target_bfd methods.
4520 (target_bfd::~target_bfd): New.
4521 (target_bfd_reopen): Adjust.
4522 (target_bfd::close): New.
4524 * record-btrace.c (record_btrace_target): New class.
4525 (record_btrace_ops): Now a record_btrace_target.
4526 (record_btrace_open, record_btrace_stop_recording)
4527 (record_btrace_disconnect, record_btrace_close)
4528 (record_btrace_async, record_btrace_info)
4529 (record_btrace_insn_history, record_btrace_insn_history_range)
4530 (record_btrace_insn_history_from, record_btrace_call_history)
4531 (record_btrace_call_history_range)
4532 (record_btrace_call_history_from, record_btrace_record_method)
4533 (record_btrace_is_replaying, record_btrace_will_replay)
4534 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
4535 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
4536 (record_btrace_store_registers, record_btrace_prepare_to_store)
4537 (record_btrace_to_get_unwinder)
4538 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
4539 (record_btrace_commit_resume, record_btrace_wait)
4540 (record_btrace_stop, record_btrace_can_execute_reverse)
4541 (record_btrace_stopped_by_sw_breakpoint)
4542 (record_btrace_supports_stopped_by_sw_breakpoint)
4543 (record_btrace_stopped_by_hw_breakpoint)
4544 (record_btrace_supports_stopped_by_hw_breakpoint)
4545 (record_btrace_update_thread_list, record_btrace_thread_alive)
4546 (record_btrace_goto_begin, record_btrace_goto_end)
4547 (record_btrace_goto, record_btrace_stop_replaying_all)
4548 (record_btrace_execution_direction)
4549 (record_btrace_prepare_to_generate_core)
4550 (record_btrace_done_generating_core): Refactor as
4551 record_btrace_target methods.
4552 (init_record_btrace_ops): Delete.
4553 (_initialize_record_btrace): Remove reference to
4554 init_record_btrace_ops.
4555 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
4556 the execution_direction global.
4557 (record_full_base_target, record_full_target)
4558 (record_full_core_target): New classes.
4559 (record_full_ops): Now a record_full_target.
4560 (record_full_core_ops): Now a record_full_core_target.
4561 (record_full_target::detach, record_full_target::disconnect)
4562 (record_full_core_target::disconnect)
4563 (record_full_target::mourn_inferior, record_full_target::kill):
4565 (record_full_open, record_full_close, record_full_async): Refactor
4566 as methods of the record_full_base_target class.
4567 (record_full_resume, record_full_commit_resume): Refactor
4568 as methods of the record_full_target class.
4569 (record_full_wait, record_full_stopped_by_watchpoint)
4570 (record_full_stopped_data_address)
4571 (record_full_stopped_by_sw_breakpoint)
4572 (record_full_supports_stopped_by_sw_breakpoint)
4573 (record_full_stopped_by_hw_breakpoint)
4574 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
4575 methods of the record_full_base_target class.
4576 (record_full_store_registers, record_full_xfer_partial)
4577 (record_full_insert_breakpoint, record_full_remove_breakpoint):
4578 Refactor as methods of the record_full_target class.
4579 (record_full_can_execute_reverse, record_full_get_bookmark)
4580 (record_full_goto_bookmark, record_full_execution_direction)
4581 (record_full_record_method, record_full_info, record_full_delete)
4582 (record_full_is_replaying, record_full_will_replay)
4583 (record_full_goto_begin, record_full_goto_end, record_full_goto)
4584 (record_full_stop_replaying): Refactor as methods of the
4585 record_full_base_target class.
4586 (record_full_core_resume, record_full_core_kill)
4587 (record_full_core_fetch_registers)
4588 (record_full_core_prepare_to_store)
4589 (record_full_core_store_registers, record_full_core_xfer_partial)
4590 (record_full_core_insert_breakpoint)
4591 (record_full_core_remove_breakpoint)
4592 (record_full_core_has_execution): Refactor
4593 as methods of the record_full_core_target class.
4594 (record_full_base_target::supports_delete_record): New.
4595 (init_record_full_ops): Delete.
4596 (init_record_full_core_ops): Delete.
4597 (record_full_save): Refactor as method of the
4598 record_full_base_target class.
4599 (_initialize_record_full): Remove references to
4600 init_record_full_ops and init_record_full_core_ops.
4602 * remote.c (remote_target, extended_remote_target): New classes.
4603 (remote_ops): Now a remote_target.
4604 (extended_remote_ops): Now an extended_remote_target.
4605 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
4606 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
4607 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
4608 (remote_pass_signals, remote_set_syscall_catchpoint)
4609 (remote_program_signals, )
4610 (remote_thread_always_alive): Remove target_ops parameter.
4611 (remote_thread_alive, remote_thread_name)
4612 (remote_update_thread_list, remote_threads_extra_info)
4613 (remote_static_tracepoint_marker_at)
4614 (remote_static_tracepoint_markers_by_strid)
4615 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
4616 (remote_open): Refactor as methods of remote_target.
4617 (extended_remote_open, extended_remote_detach)
4618 (extended_remote_attach, extended_remote_post_attach):
4619 (extended_remote_supports_disable_randomization)
4620 (extended_remote_create_inferior): : Refactor as method of
4621 extended_remote_target.
4622 (remote_set_permissions, remote_open_1, remote_detach)
4623 (remote_follow_fork, remote_follow_exec, remote_disconnect)
4624 (remote_resume, remote_commit_resume, remote_stop)
4625 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
4626 (remote_terminal_ours, remote_wait, remote_fetch_registers)
4627 (remote_prepare_to_store, remote_store_registers)
4628 (remote_flash_erase, remote_flash_done, remote_files_info)
4629 (remote_kill, remote_mourn, remote_insert_breakpoint)
4630 (remote_remove_breakpoint, remote_insert_watchpoint)
4631 (remote_watchpoint_addr_within_range)
4632 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
4633 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
4634 (remote_supports_stopped_by_sw_breakpoint)
4635 (remote_stopped_by_hw_breakpoint)
4636 (remote_supports_stopped_by_hw_breakpoint)
4637 (remote_stopped_by_watchpoint, remote_stopped_data_address)
4638 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
4639 (remote_verify_memory): Refactor as methods of remote_target.
4640 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
4642 (remote_xfer_partial, remote_get_memory_xfer_limit)
4643 (remote_search_memory, remote_rcmd, remote_memory_map)
4644 (remote_pid_to_str, remote_get_thread_local_address)
4645 (remote_get_tib_address, remote_read_description): Refactor as
4646 methods of remote_target.
4647 (remote_target::fileio_open, remote_target::fileio_pwrite)
4648 (remote_target::fileio_pread, remote_target::fileio_close): New.
4649 (remote_hostio_readlink, remote_hostio_fstat)
4650 (remote_filesystem_is_local, remote_can_execute_reverse)
4651 (remote_supports_non_stop, remote_supports_disable_randomization)
4652 (remote_supports_multi_process, remote_supports_cond_breakpoints)
4653 (remote_supports_enable_disable_tracepoint)
4654 (remote_supports_string_tracing)
4655 (remote_can_run_breakpoint_commands, remote_trace_init)
4656 (remote_download_tracepoint, remote_can_download_tracepoint)
4657 (remote_download_trace_state_variable, remote_enable_tracepoint)
4658 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
4659 (remote_trace_start, remote_get_trace_status)
4660 (remote_get_tracepoint_status, remote_trace_stop)
4661 (remote_trace_find, remote_get_trace_state_variable_value)
4662 (remote_save_trace_data, remote_get_raw_trace_data)
4663 (remote_set_disconnected_tracing, remote_core_of_thread)
4664 (remote_set_circular_trace_buffer, remote_traceframe_info)
4665 (remote_get_min_fast_tracepoint_insn_len)
4666 (remote_set_trace_buffer_size, remote_set_trace_notes)
4667 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
4668 (remote_disable_btrace, remote_teardown_btrace)
4669 (remote_read_btrace, remote_btrace_conf)
4670 (remote_augmented_libraries_svr4_read, remote_load)
4671 (remote_pid_to_exec_file, remote_can_do_single_step)
4672 (remote_execution_direction, remote_thread_handle_to_thread_info):
4673 Refactor as methods of remote_target.
4674 (init_remote_ops, init_extended_remote_ops): Delete.
4675 (remote_can_async_p, remote_is_async_p, remote_async)
4676 (remote_thread_events, remote_upload_tracepoints)
4677 (remote_upload_trace_state_variables): Refactor as methods of
4679 (_initialize_remote): Remove references to init_remote_ops and
4680 init_extended_remote_ops.
4682 * remote-sim.c (gdbsim_target): New class.
4683 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
4684 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
4685 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
4686 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
4687 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
4688 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
4689 Refactor as methods of gdbsim_target.
4690 (gdbsim_ops): Now a gdbsim_target.
4691 (init_gdbsim_ops): Delete.
4692 (gdbsim_cntrl_c): Adjust.
4693 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
4695 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
4696 (the_amd64_linux_nat_target): New.
4697 (amd64_linux_fetch_inferior_registers)
4698 (amd64_linux_store_inferior_registers): Refactor as methods of
4699 amd64_linux_nat_target.
4700 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
4701 * i386-linux-nat.c: Don't include "linux-nat.h".
4702 (i386_linux_nat_target): New class.
4703 (the_i386_linux_nat_target): New.
4704 (i386_linux_fetch_inferior_registers)
4705 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
4706 as methods of i386_linux_nat_target.
4707 (_initialize_i386_linux_nat): Adjust. Set linux_target.
4708 * inf-child.c (inf_child_ops): Delete.
4709 (inf_child_fetch_inferior_registers)
4710 (inf_child_store_inferior_registers): Delete.
4711 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
4712 methods of inf_child_target.
4713 (inf_child_target::supports_terminal_ours)
4714 (inf_child_target::terminal_init)
4715 (inf_child_target::terminal_inferior)
4716 (inf_child_target::terminal_ours_for_output)
4717 (inf_child_target::terminal_ours, inf_child_target::interrupt)
4718 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
4720 (inf_child_open, inf_child_disconnect, inf_child_close)
4721 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
4722 (inf_child_post_startup_inferior, inf_child_can_run)
4723 (inf_child_pid_to_exec_file): Refactor as methods of
4725 (inf_child_follow_fork): Delete.
4726 (inf_child_target::can_create_inferior)
4727 (inf_child_target::can_attach): New.
4728 (inf_child_target::has_all_memory, inf_child_target::has_memory)
4729 (inf_child_target::has_stack, inf_child_target::has_registers)
4730 (inf_child_target::has_execution): New.
4731 (inf_child_fileio_open, inf_child_fileio_pwrite)
4732 (inf_child_fileio_pread, inf_child_fileio_fstat)
4733 (inf_child_fileio_close, inf_child_fileio_unlink)
4734 (inf_child_fileio_readlink, inf_child_use_agent)
4735 (inf_child_can_use_agent): Refactor as methods of
4737 (return_zero, inf_child_target): Delete.
4738 (inf_child_target::inf_child_target): New.
4739 * inf-child.h: Include "target.h".
4740 (inf_child_target): Delete function prototype.
4741 (inf_child_target): New class.
4742 (inf_child_open_target, inf_child_mourn_inferior)
4743 (inf_child_maybe_unpush_target): Delete.
4744 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
4745 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
4746 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
4747 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
4748 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
4749 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
4750 (inf_ptrace_wait, inf_ptrace_xfer_partial)
4751 (inf_ptrace_thread_alive, inf_ptrace_files_info)
4752 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
4753 methods of inf_ptrace_target.
4754 (inf_ptrace_target): Delete function.
4755 * inf-ptrace.h: Include "inf-child.h".
4756 (inf_ptrace_target): Delete function declaration.
4757 (inf_ptrace_target): New class.
4758 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
4759 * linux-nat.c (linux_target): New.
4760 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
4761 (linux_nat_target::~linux_nat_target): New.
4762 (linux_child_post_attach, linux_child_post_startup_inferior)
4763 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
4764 (linux_child_remove_fork_catchpoint)
4765 (linux_child_insert_vfork_catchpoint)
4766 (linux_child_remove_vfork_catchpoint)
4767 (linux_child_insert_exec_catchpoint)
4768 (linux_child_remove_exec_catchpoint)
4769 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
4770 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
4771 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
4772 (linux_nat_stopped_data_address)
4773 (linux_nat_stopped_by_sw_breakpoint)
4774 (linux_nat_supports_stopped_by_sw_breakpoint)
4775 (linux_nat_stopped_by_hw_breakpoint)
4776 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
4777 (linux_nat_kill, linux_nat_mourn_inferior)
4778 (linux_nat_xfer_partial, linux_nat_thread_alive)
4779 (linux_nat_update_thread_list, linux_nat_pid_to_str)
4780 (linux_nat_thread_name, linux_child_pid_to_exec_file)
4781 (linux_child_static_tracepoint_markers_by_strid)
4782 (linux_nat_is_async_p, linux_nat_can_async_p)
4783 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
4784 (linux_nat_supports_multi_process)
4785 (linux_nat_supports_disable_randomization, linux_nat_async)
4786 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
4787 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
4788 (linux_nat_fileio_open, linux_nat_fileio_readlink)
4789 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
4790 methods of linux_nat_target.
4791 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
4792 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
4794 (check_stopped_by_watchpoint): Adjust.
4795 (linux_xfer_partial): Delete.
4796 (linux_target_install_ops, linux_target, linux_nat_add_target):
4798 (linux_nat_target::linux_nat_target): New.
4799 * linux-nat.h: Include "inf-ptrace.h".
4800 (linux_nat_target): New.
4801 (linux_target, linux_target_install_ops, linux_nat_add_target):
4802 Delete function declarations.
4803 (linux_target): Declare global.
4804 * linux-thread-db.c (thread_db_target): New.
4805 (thread_db_target::thread_db_target): New.
4806 (thread_db_ops): Delete.
4807 (the_thread_db_target): New.
4808 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
4809 (thread_db_update_thread_list, thread_db_pid_to_str)
4810 (thread_db_extra_thread_info)
4811 (thread_db_thread_handle_to_thread_info)
4812 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
4813 (thread_db_resume): Refactor as methods of thread_db_target.
4814 (init_thread_db_ops): Delete.
4815 (_initialize_thread_db): Remove reference to init_thread_db_ops.
4816 * x86-linux-nat.c: Don't include "linux-nat.h".
4817 (super_post_startup_inferior): Delete.
4818 (x86_linux_nat_target::~x86_linux_nat_target): New.
4819 (x86_linux_child_post_startup_inferior)
4820 (x86_linux_read_description, x86_linux_enable_btrace)
4821 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
4822 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
4823 methods of x86_linux_nat_target.
4824 (x86_linux_create_target): Delete. Bits folded ...
4825 (x86_linux_add_target): ... here. Now takes a linux_nat_target
4827 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
4828 (x86_linux_nat_target): New class.
4829 (x86_linux_create_target): Delete.
4830 (x86_linux_add_target): Now takes a linux_nat_target pointer.
4831 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
4832 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
4833 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
4834 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
4835 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
4837 (x86_use_watchpoints): Delete.
4838 * x86-nat.h: Include "breakpoint.h" and "target.h".
4839 (x86_use_watchpoints): Delete.
4840 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
4841 (x86_stopped_by_watchpoint, x86_stopped_data_address)
4842 (x86_insert_watchpoint, x86_remove_watchpoint)
4843 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
4844 (x86_stopped_by_hw_breakpoint): New declarations.
4845 (x86_nat_target): New template class.
4847 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
4848 (the_ppc_linux_nat_target): New.
4849 (ppc_linux_fetch_inferior_registers)
4850 (ppc_linux_can_use_hw_breakpoint)
4851 (ppc_linux_region_ok_for_hw_watchpoint)
4852 (ppc_linux_ranged_break_num_registers)
4853 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
4854 (ppc_linux_insert_mask_watchpoint)
4855 (ppc_linux_remove_mask_watchpoint)
4856 (ppc_linux_can_accel_watchpoint_condition)
4857 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
4858 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
4859 (ppc_linux_watchpoint_addr_within_range)
4860 (ppc_linux_masked_watch_num_registers)
4861 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
4862 (ppc_linux_read_description): Refactor as methods of
4863 ppc_linux_nat_target.
4864 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
4866 * procfs.c (procfs_xfer_partial): Delete forward declaration.
4867 (procfs_target): New class.
4868 (the_procfs_target): New.
4869 (procfs_target): Delete function.
4870 (procfs_auxv_parse, procfs_attach, procfs_detach)
4871 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
4872 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
4873 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
4874 (procfs_create_inferior, procfs_update_thread_list)
4875 (procfs_thread_alive, procfs_pid_to_str)
4876 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
4877 (procfs_stopped_data_address, procfs_insert_watchpoint)
4878 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
4879 (proc_find_memory_regions, procfs_info_proc)
4880 (procfs_make_note_section): Refactor as methods of procfs_target.
4881 (_initialize_procfs): Adjust.
4882 * sol-thread.c (sol_thread_target): New class.
4883 (sol_thread_ops): Now a sol_thread_target.
4884 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
4885 (sol_thread_fetch_registers, sol_thread_store_registers)
4886 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
4887 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
4888 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
4889 (init_sol_thread_ops): Delete.
4890 (_initialize_sol_thread): Adjust. Remove references to
4891 init_sol_thread_ops and complete_target_initialization.
4893 * windows-nat.c (windows_nat_target): New class.
4894 (windows_fetch_inferior_registers)
4895 (windows_store_inferior_registers, windows_resume, windows_wait)
4896 (windows_attach, windows_detach, windows_pid_to_exec_file)
4897 (windows_files_info, windows_create_inferior)
4898 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
4899 (windows_close, windows_pid_to_str, windows_xfer_partial)
4900 (windows_get_tib_address, windows_get_ada_task_ptid)
4901 (windows_thread_name, windows_thread_alive): Refactor as
4902 windows_nat_target methods.
4903 (do_initial_windows_stuff): Adjust.
4904 (windows_target): Delete function.
4905 (_initialize_windows_nat): Adjust.
4907 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
4908 (darwin_mourn_inferior, darwin_kill_inferior)
4909 (darwin_create_inferior, darwin_attach, darwin_detach)
4910 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
4911 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
4912 (darwin_supports_multi_process): Refactor as darwin_nat_target
4914 (darwin_resume_to, darwin_files_info): Delete.
4915 (_initialize_darwin_inferior): Rename to ...
4916 (_initialize_darwin_nat): ... this. Adjust to C++ification.
4917 * darwin-nat.h: Include "inf-child.h".
4918 (darwin_nat_target): New class.
4919 (darwin_complete_target): Delete.
4920 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
4921 (darwin_target): New.
4922 (i386_darwin_fetch_inferior_registers)
4923 (i386_darwin_store_inferior_registers): Refactor as methods of
4925 (darwin_complete_target): Delete, with ...
4926 (_initialize_i386_darwin_nat): ... bits factored out here.
4928 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
4929 (the_alpha_linux_nat_target): New.
4930 (alpha_linux_register_u_offset): Refactor as
4931 alpha_linux_nat_target method.
4932 (_initialize_alpha_linux_nat): Adjust.
4933 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
4934 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
4935 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
4936 methods of linux_nat_trad_target.
4937 (linux_trad_target): Delete.
4938 * linux-nat-trad.h (linux_trad_target): Delete function.
4939 (linux_nat_trad_target): New class.
4940 * mips-linux-nat.c (mips_linux_nat_target): New class.
4941 (super_fetch_registers, super_store_registers, super_close):
4943 (the_mips_linux_nat_target): New.
4944 (mips64_linux_regsets_fetch_registers)
4945 (mips64_linux_regsets_store_registers)
4946 (mips64_linux_fetch_registers, mips64_linux_store_registers)
4947 (mips_linux_register_u_offset, mips_linux_read_description)
4948 (mips_linux_can_use_hw_breakpoint)
4949 (mips_linux_stopped_by_watchpoint)
4950 (mips_linux_stopped_data_address)
4951 (mips_linux_region_ok_for_hw_watchpoint)
4952 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
4953 (mips_linux_close): Refactor as methods of mips_linux_nat.
4954 (_initialize_mips_linux_nat): Adjust to C++ification.
4956 * aix-thread.c (aix_thread_target): New class.
4957 (aix_thread_ops): Now an aix_thread_target.
4958 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
4959 (aix_thread_fetch_registers, aix_thread_store_registers)
4960 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
4961 (aix_thread_thread_alive, aix_thread_pid_to_str)
4962 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
4963 Refactor as methods of aix_thread_target.
4964 (init_aix_thread_ops): Delete.
4965 (_initialize_aix_thread): Remove references to init_aix_thread_ops
4966 and complete_target_initialization.
4967 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
4968 (rs6000_nat_target): New class.
4969 (the_rs6000_nat_target): New.
4970 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
4971 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
4972 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
4973 (super_create_inferior): Delete.
4974 (_initialize_rs6000_nat): Adjust to C++ification.
4976 * arm-linux-nat.c (arm_linux_nat_target): New class.
4977 (the_arm_linux_nat_target): New.
4978 (arm_linux_fetch_inferior_registers)
4979 (arm_linux_store_inferior_registers, arm_linux_read_description)
4980 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
4981 (arm_linux_remove_hw_breakpoint)
4982 (arm_linux_region_ok_for_hw_watchpoint)
4983 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
4984 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
4985 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
4986 arm_linux_nat_target.
4987 (_initialize_arm_linux_nat): Adjust to C++ification.
4989 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
4990 (the_aarch64_linux_nat_target): New.
4991 (aarch64_linux_fetch_inferior_registers)
4992 (aarch64_linux_store_inferior_registers)
4993 (aarch64_linux_child_post_startup_inferior)
4994 (aarch64_linux_read_description)
4995 (aarch64_linux_can_use_hw_breakpoint)
4996 (aarch64_linux_insert_hw_breakpoint)
4997 (aarch64_linux_remove_hw_breakpoint)
4998 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
4999 (aarch64_linux_region_ok_for_hw_watchpoint)
5000 (aarch64_linux_stopped_data_address)
5001 (aarch64_linux_stopped_by_watchpoint)
5002 (aarch64_linux_watchpoint_addr_within_range)
5003 (aarch64_linux_can_do_single_step): Refactor as methods of
5004 aarch64_linux_nat_target.
5005 (super_post_startup_inferior): Delete.
5006 (_initialize_aarch64_linux_nat): Adjust to C++ification.
5008 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
5009 (the_hppa_linux_nat_target): New.
5010 (hppa_linux_fetch_inferior_registers)
5011 (hppa_linux_store_inferior_registers): Refactor as methods of
5012 hppa_linux_nat_target.
5013 (_initialize_hppa_linux_nat): Adjust to C++ification.
5015 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
5016 (the_ia64_linux_nat_target): New.
5017 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
5018 (ia64_linux_stopped_data_address)
5019 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
5020 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
5021 ia64_linux_nat_target methods.
5022 (super_xfer_partial): Delete.
5023 (_initialize_ia64_linux_nat): Adjust to C++ification.
5025 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
5026 (the_m32r_linux_nat_target): New.
5027 (m32r_linux_fetch_inferior_registers)
5028 (m32r_linux_store_inferior_registers): Refactor as
5029 m32r_linux_nat_target methods.
5030 (_initialize_m32r_linux_nat): Adjust to C++ification.
5032 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
5033 (the_m68k_linux_nat_target): New.
5034 (m68k_linux_fetch_inferior_registers)
5035 (m68k_linux_store_inferior_registers): Refactor as
5036 m68k_linux_nat_target methods.
5037 (_initialize_m68k_linux_nat): Adjust to C++ification.
5039 * s390-linux-nat.c (s390_linux_nat_target): New class.
5040 (the_s390_linux_nat_target): New.
5041 (s390_linux_fetch_inferior_registers)
5042 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
5043 (s390_insert_watchpoint, s390_remove_watchpoint)
5044 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
5045 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
5046 (s390_auxv_parse, s390_read_description): Refactor as methods of
5047 s390_linux_nat_target.
5048 (_initialize_s390_nat): Adjust to C++ification.
5050 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
5051 (the_sparc_linux_nat_target): New.
5052 (_initialize_sparc_linux_nat): Adjust to C++ification.
5053 * sparc-nat.c (sparc_fetch_inferior_registers)
5054 (sparc_store_inferior_registers): Remove target_ops parameter.
5055 * sparc-nat.h (sparc_fetch_inferior_registers)
5056 (sparc_store_inferior_registers): Remove target_ops parameter.
5057 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
5058 (the_sparc64_linux_nat_target): New.
5059 (_initialize_sparc64_linux_nat): Adjust to C++ification.
5061 * spu-linux-nat.c (spu_linux_nat_target): New class.
5062 (the_spu_linux_nat_target): New.
5063 (spu_child_post_startup_inferior, spu_child_post_attach)
5064 (spu_child_wait, spu_fetch_inferior_registers)
5065 (spu_store_inferior_registers, spu_xfer_partial)
5066 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
5068 (_initialize_spu_nat): Adjust to C++ification.
5070 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
5071 (the_tilegx_linux_nat_target): New.
5072 (fetch_inferior_registers, store_inferior_registers):
5073 Refactor as methods.
5074 (_initialize_tile_linux_nat): Adjust to C++ification.
5076 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
5077 (the_xtensa_linux_nat_target): New.
5078 (xtensa_linux_fetch_inferior_registers)
5079 (xtensa_linux_store_inferior_registers): Refactor as
5080 xtensa_linux_nat_target methods.
5081 (_initialize_xtensa_linux_nat): Adjust to C++ification.
5083 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
5084 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
5085 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
5086 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
5087 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
5088 (fbsd_stopped_by_sw_breakpoint)
5089 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
5090 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
5091 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
5092 (fbsd_post_startup_inferior, fbsd_post_attach)
5093 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
5094 (fbsd_set_syscall_catchpoint)
5095 (super_xfer_partial, super_resume, super_wait)
5096 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
5097 (fbsd_handle_debug_trap): Remove target_ops parameter.
5098 (fbsd_nat_add_target): Delete.
5099 * fbsd-nat.h: Include "inf-ptrace.h".
5100 (fbsd_nat_add_target): Delete.
5101 (USE_SIGTRAP_SIGINFO): Define.
5102 (fbsd_nat_target): New class.
5104 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
5105 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
5106 (amd64bsd_target): Delete.
5107 * amd64-bsd-nat.h: New file.
5108 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
5110 (amd64_fbsd_nat_target): New class.
5111 (the_amd64_fbsd_nat_target): New.
5112 (amd64fbsd_read_description): Refactor as method of
5113 amd64_fbsd_nat_target.
5114 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5115 (_initialize_amd64fbsd_nat): Adjust to C++ification.
5116 * amd64-nat.h (amd64bsd_target): Delete function declaration.
5117 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
5118 (i386bsd_store_inferior_registers): Remove target_ops parameter.
5119 (i386bsd_target): Delete.
5120 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
5121 (i386bsd_fetch_inferior_registers)
5122 (i386bsd_store_inferior_registers): Declare.
5123 (i386_bsd_nat_target): New class.
5124 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
5125 (the_i386_fbsd_nat_target): New.
5126 (i386fbsd_resume, i386fbsd_read_description): Refactor as
5127 i386_fbsd_nat_target methods.
5128 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5129 (_initialize_i386fbsd_nat): Adjust to C++ification.
5130 * x86-bsd-nat.c (super_mourn_inferior): Delete.
5131 (x86bsd_mourn_inferior, x86bsd_target): Delete.
5132 (_initialize_x86_bsd_nat): Adjust to C++ification.
5133 * x86-bsd-nat.h: Include "x86-nat.h".
5134 (x86bsd_target): Delete declaration.
5135 (x86bsd_nat_target): New class.
5137 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
5138 (the_aarch64_fbsd_nat_target): New.
5139 (aarch64_fbsd_fetch_inferior_registers)
5140 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
5141 aarch64_fbsd_nat_target.
5142 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
5143 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
5144 (the_alpha_bsd_nat_target): New.
5145 (alphabsd_fetch_inferior_registers)
5146 (alphabsd_store_inferior_registers): Refactor as
5147 alpha_bsd_nat_target methods.
5148 (_initialize_alphabsd_nat): Refactor as methods of
5149 alpha_bsd_nat_target.
5150 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
5151 (the_amd64_nbsd_nat_target): New.
5152 (_initialize_amd64nbsd_nat): Adjust to C++ification.
5153 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
5154 (the_amd64_obsd_nat_target): New.
5155 (_initialize_amd64obsd_nat): Adjust to C++ification.
5156 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
5157 (the_arm_fbsd_nat_target): New.
5158 (arm_fbsd_fetch_inferior_registers)
5159 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
5160 (_initialize_arm_fbsd_nat): Refactor as methods of
5161 arm_fbsd_nat_target.
5162 (_initialize_arm_fbsd_nat): Adjust to C++ification.
5163 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
5164 (the_arm_netbsd_nat_target): New.
5165 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
5166 arm_netbsd_nat_target.
5167 (_initialize_arm_netbsd_nat): Adjust to C++ification.
5168 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
5169 (the_hppa_nbsd_nat_target): New.
5170 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
5171 hppa_nbsd_nat_target methods.
5172 (_initialize_hppanbsd_nat): Adjust to C++ification.
5173 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
5174 (the_hppa_obsd_nat_target): New.
5175 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
5176 methods of hppa_obsd_nat_target.
5177 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
5179 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
5180 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
5182 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
5183 (_initialize_i386obsd_nat): Use add_target.
5184 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
5185 (the_m68k_bsd_nat_target): New.
5186 (m68kbsd_fetch_inferior_registers)
5187 (m68kbsd_store_inferior_registers): Refactor as methods of
5188 m68k_bsd_nat_target.
5189 (_initialize_m68kbsd_nat): Adjust to C++ification.
5190 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
5191 (the_mips_fbsd_nat_target): New.
5192 (mips_fbsd_fetch_inferior_registers)
5193 (mips_fbsd_store_inferior_registers): Refactor as methods of
5194 mips_fbsd_nat_target.
5195 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
5197 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
5198 (the_mips_nbsd_nat_target): New.
5199 (mipsnbsd_fetch_inferior_registers)
5200 (mipsnbsd_store_inferior_registers): Refactor as methods of
5201 mips_nbsd_nat_target.
5202 (_initialize_mipsnbsd_nat): Adjust to C++ification.
5203 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
5204 (the_mips64_obsd_nat_target): New.
5205 (mips64obsd_fetch_inferior_registers)
5206 (mips64obsd_store_inferior_registers): Refactor as methods of
5207 mips64_obsd_nat_target.
5208 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
5210 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
5212 * nbsd-nat.h: Include "inf-ptrace.h".
5213 (nbsd_nat_target): New class.
5214 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
5215 (obsd_wait): Refactor as methods of obsd_nat_target.
5216 (obsd_add_target): Delete.
5217 * obsd-nat.h: Include "inf-ptrace.h".
5218 (obsd_nat_target): New class.
5219 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
5220 (the_ppc_fbsd_nat_target): New.
5221 (ppcfbsd_fetch_inferior_registers)
5222 (ppcfbsd_store_inferior_registers): Refactor as methods of
5223 ppc_fbsd_nat_target.
5224 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
5226 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
5227 (the_ppc_nbsd_nat_target): New.
5228 (ppcnbsd_fetch_inferior_registers)
5229 (ppcnbsd_store_inferior_registers): Refactor as methods of
5230 ppc_nbsd_nat_target.
5231 (_initialize_ppcnbsd_nat): Adjust to C++ification.
5232 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
5233 (the_ppc_obsd_nat_target): New.
5234 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
5235 methods of ppc_obsd_nat_target.
5236 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
5238 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
5239 (the_sh_nbsd_nat_target): New.
5240 (shnbsd_fetch_inferior_registers)
5241 (shnbsd_store_inferior_registers): Refactor as methods of
5243 (_initialize_shnbsd_nat): Adjust to C++ification.
5244 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
5245 (inf_ptrace_xfer_partial): Delete.
5246 (sparc_xfer_partial, sparc_target): Delete.
5247 * sparc-nat.h (sparc_fetch_inferior_registers)
5248 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
5249 (sparc_target): Delete function declaration.
5250 (sparc_target): New template class.
5251 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
5252 (_initialize_sparcnbsd_nat): Adjust to C++ification.
5253 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
5254 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
5256 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
5257 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
5258 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
5259 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
5261 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
5262 (the_vax_bsd_nat_target): New.
5263 (vaxbsd_fetch_inferior_registers)
5264 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
5266 (_initialize_vaxbsd_nat): Adjust to C++ification.
5268 * bsd-kvm.c (bsd_kvm_target): New class.
5269 (bsd_kvm_ops): Now a bsd_kvm_target.
5270 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
5271 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
5272 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
5274 (bsd_kvm_return_one): Delete.
5275 (bsd_kvm_add_target): Adjust to C++ification.
5277 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
5278 (nto_procfs_target_procfs): New classes.
5279 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
5280 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
5281 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
5282 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
5283 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
5284 (procfs_remove_hw_breakpoint, procfs_resume)
5285 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
5286 (procfs_kill_inferior, procfs_store_registers)
5287 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
5288 as methods of nto_procfs_target.
5289 (nto_procfs_ops): Now an nto_procfs_target_procfs.
5290 (nto_native_ops): Delete.
5291 (procfs_open, procfs_native_open): Delete.
5292 (nto_native_ops): Now an nto_procfs_target_native.
5293 (init_procfs_targets): Adjust to C++ification.
5294 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
5295 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
5296 Refactor as methods of nto_procfs_target.
5298 * go32-nat.c (go32_nat_target): New class.
5299 (the_go32_nat_target): New.
5300 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
5301 (go32_store_registers, go32_xfer_partial, go32_files_info)
5302 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
5303 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
5304 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
5305 (go32_pid_to_str): Refactor as methods of go32_nat_target.
5306 (go32_target): Delete.
5307 (_initialize_go32_nat): Adjust to C++ification.
5309 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
5310 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
5311 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
5312 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
5314 (gnu_target): Delete.
5315 * gnu-nat.h (gnu_target): Delete.
5316 (gnu_nat_target): New class.
5317 * i386-gnu-nat.c (gnu_base_target): New.
5318 (i386_gnu_nat_target): New class.
5319 (the_i386_gnu_nat_target): New.
5320 (_initialize_i386gnu_nat): Adjust to C++ification.
5322 2018-05-02 Pedro Alves <palves@redhat.com>
5324 * bfd-target.c (target_bfd_xclose): Rename to ...
5325 (target_bfd_close): ... this.
5326 (target_bfd_reopen): Adjust.
5327 * target.c (target_close): Remove references to to_xclose.
5328 * target.h (target_ops::to_xclose): Delete.
5329 (target_ops::to_close): Update comments.
5331 2018-05-02 Pedro Alves <palves@redhat.com>
5333 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
5335 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
5336 * inf-ptrace.c (inf_ptrace_register_u_offset)
5337 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
5338 (inf_ptrace_store_register, inf_ptrace_store_registers)
5339 (inf_ptrace_trad_target): Move to ...
5340 * linux-nat-trad.c: ... this new file.
5341 * linux-nat-trad.h: New file.
5342 * linux-nat.c (linux_target_install_ops): Make extern.
5343 (linux_trad_target): Delete.
5344 * linux-nat.h (linux_trad_target): Delete declaration.
5345 (linux_target_install_ops): Declare.
5346 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
5349 2018-05-02 Pedro Alves <palves@redhat.com>
5351 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5352 procfs_target/add_target here.
5353 * procfs.c (procfs_target): Make static.
5354 (_initialize_procfs): Call add_target here.
5355 * procfs.h (struct target_ops): Remove forward declaration.
5356 (procfs_target): Remove declaration.
5357 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
5359 2018-05-02 Pedro Alves <palves@redhat.com>
5361 * procfs.c (procfs_stopped_by_watchpoint)
5362 (procfs_insert_watchpoint, procfs_remove_watchpoint)
5363 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
5365 (procfs_use_watchpoints): Delete, move contents...
5366 (procfs_target): ... here.
5367 * procfs.h (procfs_use_watchpoints): Delete declaration.
5368 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5369 procfs_use_watchpoints.
5370 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
5371 procfs_use_watchpoints.
5373 2018-05-02 Tom Tromey <tom@tromey.com>
5376 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
5377 and var_zuinteger_unlimited.
5378 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
5379 and PARAM_ZUINTEGER_UNLIMITED.
5380 (set_parameter_value): Handle var_zuinteger and
5381 var_zuinteger_unlimited.
5382 (add_setshow_generic): Likewise.
5383 (parmpy_init): Likewise.
5385 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
5388 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
5389 pointer is not null before dereferencing it.
5391 2018-04-30 Tom Tromey <tom@tromey.com>
5393 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
5396 2018-04-30 Tom Tromey <tom@tromey.com>
5398 * breakpoint.c (mention): Remove use of is_mi_like_p.
5399 (print_mention_ranged_breakpoint): Likewise.
5400 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
5403 2018-04-30 Tom Tromey <tom@tromey.com>
5405 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
5407 2018-04-30 Tom Tromey <tom@tromey.com>
5409 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
5410 (info_spu_event_command): Remove some uses of is_mi_like_p.
5412 2018-04-30 Tom Tromey <tom@tromey.com>
5414 * python/py-framefilter.c (py_print_single_arg)
5415 (enumerate_locals, py_print_args, py_print_frame): Remove some
5416 uses of is_mi_like_p.
5418 2018-04-30 Tom Tromey <tom@tromey.com>
5421 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
5422 * ui-out.h (ui_out::is_mi_like_p): Now const.
5423 (ui_out::do_is_mi_like_p): Now const.
5424 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
5426 2018-04-30 Tom Tromey <tom@tromey.com>
5428 * varobj.c (varobj_set_visualizer): Use new_reference.
5429 * python/python.c (gdbpy_decode_line): Use new_reference.
5430 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
5433 2018-04-30 Tom Tromey <tom@tromey.com>
5435 * varobj.c (install_new_value): Use new_reference.
5436 * value.h (value_incref): Return void. Swap intro comment with
5438 * value.c (set_value_parent): Use new_reference.
5439 (value_incref): Return void. Update intro comment.
5440 (release_value): Use new_reference.
5441 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
5443 2018-04-30 Tom Tromey <tom@tromey.com>
5445 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
5446 * gdb_bfd.h (new_bfd_ref): Remove.
5447 (gdb_bfd_open): Update comment.
5448 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
5449 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
5450 (gdb_bfd_fdopenr): Use new_reference.
5451 * exec.c (exec_file_attach): Use new_reference.
5453 2018-04-30 Tom Tromey <tom@tromey.com>
5455 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
5458 2018-04-30 Tom Tromey <tom@tromey.com>
5460 * jit.c (jit_read_code_entry): Use type_align.
5461 * i386-tdep.c (i386_gdbarch_init): Don't call
5462 set_gdbarch_long_long_align_bit.
5463 * gdbarch.sh: Remove long_long_align_bit.
5464 * gdbarch.c, gdbarch.h: Rebuild.
5465 * arc-tdep.c (arc_type_align): New function.
5466 (arc_gdbarch_init): Use arc_type_align. Don't call
5467 set_gdbarch_long_long_align_bit.
5469 2018-04-30 Tom Tromey <tom@tromey.com>
5471 * rust-lang.c (rust_type_alignment): Remove.
5472 (rust_composite_type): Use type_align.
5474 2018-04-30 Tom Tromey <tom@tromey.com>
5476 * NEWS: Mention Type.align.
5477 * python/py-type.c (typy_get_alignof): New function.
5478 (type_object_getset): Add "alignof".
5480 2018-04-30 Tom Tromey <tom@tromey.com>
5484 * std-operator.def (UNOP_ALIGNOF): New operator.
5485 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
5487 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
5488 * c-lang.c (c_op_print_tab): Add alignof.
5489 * c-exp.y (ALIGNOF): New token.
5490 (exp): Add "ALIGNOF" production.
5491 (ident_tokens): Add _Alignof and alignof.
5493 2018-04-30 Tom Tromey <tom@tromey.com>
5495 * i386-tdep.c (i386_type_align): New function.
5496 (i386_gdbarch_init): Update.
5497 * gdbarch.sh (type_align): New method.
5498 * gdbarch.c, gdbarch.h: Rebuild.
5499 * arch-utils.h (default_type_align): Declare.
5500 * arch-utils.c (default_type_align): New function.
5501 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
5502 (struct type) <align_log2>: New field.
5503 <instance_flags>: Now a bitfield.
5504 (TYPE_RAW_ALIGN): New macro.
5505 (type_align, type_raw_align, set_type_align): Declare.
5506 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
5508 * dwarf2read.c (quirk_rust_enum): Set type alignment.
5509 (get_alignment, maybe_set_alignment): New functions.
5510 (read_structure_type, read_enumeration_type, read_array_type)
5511 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
5512 (read_subrange_type, read_base_type): Set type alignment.
5514 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
5516 * dwarf2read.c (read_index_from_section): Use bool.
5518 2018-04-29 Fabian Groffen <grobian@gentoo.org>
5521 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
5524 2018-04-29 John Reiser <jreiser@BitWagon.com>
5527 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
5528 last step, and do it atomically.
5530 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
5532 * compile/compile-c-types.c (convert_int, convert_float):
5535 2018-04-27 Tom Tromey <tom@tromey.com>
5538 * rust-lang.c (rust_inclusive_range_type_p): New function.
5539 (rust_range): Handle inclusive ranges.
5540 (rust_compute_range): Likewise.
5541 * rust-exp.y (struct rust_op) <inclusive>: New field.
5542 (DOTDOTEQ): New constant.
5543 (range_expr): Add "..=" productions.
5544 (operator_tokens): Add "..=" token.
5545 (ast_range): Add "inclusive" parameter.
5546 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
5548 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
5550 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
5551 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
5553 * expprint.c (print_subexp_standard): Handle new bounds values.
5554 (dump_subexp_body_standard): Likewise.
5556 2018-04-27 Tom Tromey <tom@tromey.com>
5558 * configure: Rebuild.
5559 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
5560 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
5562 (class symbol_needs_eval_context): Likewise.
5563 * dwarf2read.c (mock_mapped_index::symbol_name_count)
5564 (mock_mapped_index::symbol_name_at): Use "override". Remove
5566 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
5568 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
5569 * aarch64-tdep.c (instruction_reader::read): Use "override".
5570 (instruction_reader_test::read): Likewise.
5571 * arm-tdep.c (instruction_reader::read): Use "override".
5572 (instruction_reader_thumb::read): Likewise.
5574 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
5577 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
5578 instead of remote_send.
5579 (remote_send): Remove.
5581 2018-04-26 Pedro Alves <palves@redhat.com>
5583 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
5584 find_function_start_sal instead of find_pc_line.
5586 2018-04-26 Pedro Alves <palves@redhat.com>
5588 * breakpoint.c (set_breakpoint_location_function): Handle
5590 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
5591 * elfread.c (elf_symtab_read): Give data symbols with
5592 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
5593 (elf_rel_plt_read): Update comment.
5594 * linespec.c (convert_linespec_to_sals): Handle
5596 (minsym_found): Handle mst_data_gnu_ifunc.
5597 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
5598 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
5599 * parse.c (find_minsym_type_and_address): Handle
5601 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
5602 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
5603 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
5605 <mst_data_gnu_ifunc>: New enumerator.
5607 2018-04-26 Pedro Alves <palves@redhat.com>
5609 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
5610 (lookup_minimal_symbol_by_pc_section): ... this. Replace
5611 'want_trampoline' parameter by a lookup_msym_prefer parameter.
5613 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
5614 (lookup_minimal_symbol_by_pc): Adjust.
5615 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
5616 (lookup_solib_trampoline_symbol_by_pc): Adjust.
5617 * minsyms.h (lookup_msym_prefer): New enum.
5618 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5619 parameter by a lookup_msym_prefer parameter.
5621 2018-04-26 Pedro Alves <palves@redhat.com>
5623 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
5624 ends in "@plt" instead of looking at the symbol's section.
5626 2018-04-26 Pedro Alves <palves@redhat.com>
5628 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
5630 (find_pc_partial_function_gnu_ifunc): Rename to ...
5631 (find_pc_partial_function): ... this, and remove references to
5633 (find_pc_partial_function): Delete old implementation.
5634 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
5636 2018-04-26 Pedro Alves <palves@redhat.com>
5638 * linespec.c (struct bound_minimal_symbol_search_key): New.
5639 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
5640 skip first line if we found a GNU ifunc minimal symbol by name.
5641 (compare_msymbols): Change parameters to work with a destructured
5643 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
5646 2018-04-26 Pedro Alves <palves@redhat.com>
5648 * breakpoint.c (set_breakpoint_location_function): Don't resolve
5649 ifunc targets here. Instead, if we have an ifunc minsym, use its
5651 (add_location_to_breakpoint): Store the minsym and the objfile in
5652 the breakpoint location.
5653 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
5654 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
5655 Record the minsym in the sal.
5656 * symtab.h (symtab_and_line) <msymbol>: New field.
5658 2018-04-26 Pedro Alves <palves@redhat.com>
5660 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
5661 unless we actually resolved the ifunc.
5663 2018-04-26 Pedro Alves <palves@redhat.com>
5665 * c-exp.y (variable production): Prefer ifunc minsyms over
5666 regular function symbols.
5667 * symtab.c (find_gnu_ifunc): New function.
5668 * minsyms.h (lookup_msym_prefer): New enum.
5669 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5670 parameter by a lookup_msym_prefer parameter.
5671 * symtab.h (find_gnu_ifunc): New declaration.
5673 2018-04-26 Pedro Alves <palves@redhat.com>
5675 * blockframe.c (find_gnu_ifunc_target_type): New function.
5676 (find_function_type): New.
5677 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
5678 return a value with a memory address.
5679 (eval_call): For calls to GNU ifunc functions, try to find the
5680 type of the target function from the type that the resolver
5682 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
5684 * infcall.c (find_function_return_type): Delete.
5685 (find_function_addr): Add 'function_type' parameter. For calls to
5686 GNU ifunc functions, try to find the type of the target function
5687 from the type that the resolver returns, and return it via
5689 (call_function_by_hand_dummy): Adjust to use the function type
5690 returned by find_function_addr.
5691 (find_function_addr): Add 'function_type' parameter and move
5693 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
5696 2018-04-26 Pedro Alves <palves@redhat.com>
5698 * c-exp.y (variable production): Skip finding an alias for ifunc
5701 2018-04-26 Pedro Alves <palves@redhat.com>
5703 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
5705 2018-04-25 Pedro Alves <palves@redhat.com>
5707 * infcmd.c (kill_command): Print the pid as string, not the whole
5708 thread's ptid. Add comment. s/has been killed/killed/ in output
5710 * remote.c (remote_detach_1): Print the pid as string, not the
5711 whole thread's ptid.
5713 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5714 Sergio Durigan Junior <sergiodj@redhat.com>
5715 Pedro Alves <palves@redhat.com>
5717 * infcmd.c (kill_command): Print message when inferior has
5719 * inferior.c (print_inferior_events): Remove 'static'. Set as
5721 (add_inferior): Improve message printed when
5722 'print_inferior_events' is on.
5723 (exit_inferior): Remove message printed when
5724 'print_inferior_events' is on.
5725 (detach_inferior): Improve message printed when
5726 'print_inferior_events' is on.
5727 (initialize_inferiors): Use 'add_inferior_silent' to set
5728 'current_inferior_'.
5729 * inferior.h (print_inferior_events): Declare here as
5731 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
5732 '[Detaching...]' messages when 'print_inferior_events' is on.
5733 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
5734 as prefix/suffix for messages. Remove periods. Fix erroneous
5735 'Detaching after fork from child...', replace it by '... from
5737 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
5738 prefix/suffix when printing 'Detaching...' messages. Print
5739 them when 'print_inferior_events' is on.
5740 * remote.c (remote_detach_1): Print message when detaching
5741 from inferior and '!is_fork_parent'.
5743 2018-04-24 Tom Tromey <tom@tromey.com>
5745 * cli-out.h: Reindent.
5747 2018-04-24 Tom Tromey <tom@tromey.com>
5749 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
5750 (cli_ui_out::do_field_string): Use fputs_filtered.
5751 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
5753 2018-04-23 Tom Tromey <tom@tromey.com>
5755 * guile/scm-frame.c (gdbscm_frame_read_var): Use
5756 gdb::unique_xmalloc_ptr.
5758 2018-04-23 Tom Tromey <tom@tromey.com>
5760 * configure: Rebuild.
5762 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
5765 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
5766 prepare_for_testing. Set normal_bp to r_debug_state if target
5769 2018-04-21 Pedro Alves <palves@redhat.com>
5770 Rajendra SY <rajendra.sy@gmail.com>
5772 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
5773 * remote.c (extended_remote_attach): In all-stop mode, mark the
5774 thread as executing.
5776 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5778 * thread.c (thread_apply_all_command): Fix comment.
5779 (thread_command): Fix comment.
5781 2018-04-10 Alan Hayward <alan.hayward@arm.com>
5783 * common/tdesc.h (tdesc_create_feature): Remove xml filename
5785 * features/aarch64-core.c (create_feature_aarch64_core):
5787 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
5789 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
5791 * features/i386/32bit-avx512.c
5792 (create_feature_i386_32bit_avx512): Likewise.
5793 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
5795 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
5797 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
5799 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
5801 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
5803 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
5805 * features/i386/64bit-avx512.c
5806 (create_feature_i386_64bit_avx512): Likewise.
5807 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
5809 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
5811 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
5813 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
5815 * features/i386/64bit-segments.c
5816 (create_feature_i386_64bit_segments): Likewise.
5817 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
5819 * features/i386/x32-core.c
5820 (create_feature_i386_x32_core): Likewise.
5821 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
5822 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
5823 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
5824 * target-descriptions.c: In generated code, don't pass xml
5827 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5829 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
5830 (print_xml_feature::visit_post): Likewise.
5831 (print_xml_feature::visit): Likewise.
5832 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
5833 (print_xml_feature): Add new class.
5834 * regformats/regdat.sh: Null xmltarget on feature targets.
5835 * target-descriptions.c (struct target_desc): Add xmltarget.
5836 (maintenance_check_tdesc_xml_convert): Add unittest function.
5837 (tdesc_get_features_xml): Add function to get xml.
5838 (maintenance_check_xml_descriptions): Test xml generation.
5839 * xml-tdesc.c (string_read_description_xml): Add function.
5840 * xml-tdesc.h (string_read_description_xml): Add declaration.
5842 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5844 * features/Makefile: Add feature marker to targets with new style
5845 target descriptions.
5846 * regformats/aarch64.dat: Regenerate.
5847 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
5848 * regformats/i386/amd64-avx-linux.dat: Likewise.
5849 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
5850 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
5851 * regformats/i386/amd64-linux.dat: Likewise.
5852 * regformats/i386/amd64-mpx-linux.dat: Likewise.
5853 * regformats/i386/amd64.dat: Likewise.
5854 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
5855 * regformats/i386/i386-avx-linux.dat: Likewise.
5856 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
5857 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
5858 * regformats/i386/i386-linux.dat: Likewise.
5859 * regformats/i386/i386-mmx-linux.dat: Likewise.
5860 * regformats/i386/i386-mpx-linux.dat: Likewise.
5861 * regformats/i386/i386.dat: Likewise.
5862 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
5863 * regformats/i386/x32-avx-linux.dat: Likewise.
5864 * regformats/i386/x32-linux.dat: Likewise.
5865 * regformats/tic6x-c62x-linux.dat: Likewise.
5866 * regformats/tic6x-c64x-linux.dat: Likewise.
5867 * regformats/tic6x-c64xp-linux.dat: Likewise.
5868 * regformats/regdat.sh: Parse feature marker.
5870 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5872 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
5873 (tdesc_osabi_name): Likewise.
5874 * target-descriptions.c (tdesc_architecture_name): Add new
5876 (tdesc_osabi_name): Likewise.
5878 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5880 * common/tdesc.c (tdesc_predefined_type): Move to here.
5881 (tdesc_named_type): Likewise.
5882 (tdesc_create_vector): Likewise.
5883 (tdesc_create_struct): Likewise.
5884 (tdesc_set_struct_size): Likewise.
5885 (tdesc_create_union): Likewise.
5886 (tdesc_create_flags): Likewise.
5887 (tdesc_create_enum): Likewise.
5888 (tdesc_add_field): Likewise.
5889 (tdesc_add_typed_bitfield): Likewise.
5890 (tdesc_add_bitfield): Likewise.
5891 (tdesc_add_flag): Likewise.
5892 (tdesc_add_enum_value): Likewise.
5893 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
5894 (struct tdesc_type_vector): Likewise.
5895 (struct tdesc_type_field): Likewise.
5896 (struct tdesc_type_with_fields): Likewise.
5897 (tdesc_create_enum): Add declaration.
5898 (tdesc_add_typed_bitfield): Likewise.
5899 (tdesc_add_enum_value): Likewise.
5900 * target-descriptions.c (tdesc_type_field): Move from here.
5901 (tdesc_type_builtin): Likewise.
5902 (tdesc_type_vector): Likewise.
5903 (tdesc_type_with_fields): Likewise.
5904 (tdesc_predefined_types): Likewise.
5905 (tdesc_named_type): Likewise.
5906 (tdesc_create_vector): Likewise.
5907 (tdesc_create_struct): Likewise.
5908 (tdesc_set_struct_size): Likewise.
5909 (tdesc_create_union): Likewise.
5910 (tdesc_create_flags): Likewise.
5911 (tdesc_create_enum): Likewise.
5912 (tdesc_add_field): Likewise.
5913 (tdesc_add_typed_bitfield): Likewise.
5914 (tdesc_add_bitfield): Likewise.
5915 (tdesc_add_flag): Likewise.
5916 (tdesc_add_enum_value): Likewise.
5917 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
5918 (tdesc_add_typed_bitfield): Likewise.
5919 (tdesc_add_enum_value): Likewise.
5921 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5923 * common/tdesc.c (tdesc_feature::accept): Move to here.
5924 (tdesc_feature::operator==): Likewise.
5925 (tdesc_create_reg): Likewise.
5926 * common/tdesc.h (tdesc_type_kind): Likewise.
5927 (struct tdesc_type): Likewise.
5928 (struct tdesc_feature): Likewise.
5929 * regformats/regdat.sh: Create a feature.
5930 * target-descriptions.c (tdesc_type_kind): Move from here.
5931 (tdesc_type): Likewise.
5932 (tdesc_type_up): Likewise.
5933 (tdesc_feature): Likewise.
5934 (tdesc_create_reg): Likewise.
5936 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5938 * Makefile.in: Add arch/tdesc.c
5939 * common/tdesc.c: New file.
5940 * common/tdesc.h (tdesc_element_visitor): Move to here.
5941 (tdesc_element): Likewise.
5942 (tdesc_reg): Likewise.
5943 (tdesc_reg_up): Likewise.
5944 * regformats/regdef.h (reg): Add offset to constructors.
5945 * target-descriptions.c (tdesc_element_visitor): Move from here.
5946 (tdesc_element): Likewise.
5947 (tdesc_reg): Likewise.
5948 (tdesc_reg_up): Likewise.
5950 2018-04-17 Tom Tromey <tom@tromey.com>
5952 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
5955 2018-04-17 Tom Tromey <tom@tromey.com>
5957 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
5959 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
5961 * symtab.c (print_symbol_info): Skip printing filename and line
5962 number when `last' is NULL.
5963 (symtab_symbol_info): Use empty string instead of NULL for first
5964 invocation of print_symbol_info.
5965 (rbreak_command): Pass NULL to `last' parameter of
5968 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
5970 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
5973 2018-04-16 Pedro Alves <palves@redhat.com>
5975 * MAINTAINERS (sh): Remove.
5976 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
5977 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
5978 (ALLDEPFILES): Remove sh64-tdep.c.
5979 * NEWS: Mentions that support for SH-5/SH64 is removed.
5980 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
5981 (sh*-*-openbsd*): Ditto.
5982 (sh64-*-elf*): Remove.
5984 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
5985 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
5986 * sh-tdep.c: No longer include "sh64-tdep.h".
5987 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
5988 * sh64-tdep.c, sh64-tdep.h: Remove files.
5990 2018-04-16 Pedro Alves <palves@redhat.com>
5992 * MAINTAINERS: Remove m88k.
5993 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
5994 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
5995 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
5996 * NEWS: Mention that support for m88k was removed.
5997 * configure.host (m88*-*-*): Remove support.
5998 * configure.nat (m88k-*-*): Remove support.
5999 * configure.tgt (m88*-*-openbsd*): Remove.
6000 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
6002 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
6004 * configure.tgt (x86_tobjs): New variable.
6005 (amd64_tobjs, i386_tobjs): Use it.
6007 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6009 * symtab.c (print_symbol_info): Precede the symbol definition by
6010 the line number when available.
6011 * NEWS: Advertise this enhancement.
6013 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6015 * NEWS (New options): announce set/show record btrace cpu.
6016 * btrace.c: Include record-btrace.h.
6017 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
6018 the vendor is unknown.
6019 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
6020 Maybe overwrite the btrace configuration's cpu.
6021 (btrace_compute_ftrace): Add cpu parameter. Update callers.
6022 (btrace_fetch): Add cpu parameter. Update callers.
6023 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
6024 Maybe overwrite the btrace configuration's cpu. Skip enabling
6025 errata workarounds if the vendor is unknown.
6026 * python/py-record-btrace.c: Include record-btrace.h.
6027 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
6028 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
6029 * record-btrace.c (record_btrace_cpu_state_kind): New.
6030 (record_btrace_cpu): New.
6031 (set_record_btrace_cpu_cmdlist): New.
6032 (record_btrace_get_cpu): New.
6033 (require_btrace_thread, record_btrace_info)
6034 (record_btrace_resume_thread): Call record_btrace_get_cpu.
6035 (cmd_set_record_btrace_cpu_none): New.
6036 (cmd_set_record_btrace_cpu_auto): New.
6037 (cmd_set_record_btrace_cpu): New.
6038 (cmd_show_record_btrace_cpu): New.
6039 (_initialize_record_btrace): Initialize set/show record btrace cpu
6041 * record-btrace.h (record_btrace_get_cpu): New.
6043 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6045 * record.c (set_record_command): Fix typo in message.
6047 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6049 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
6051 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6053 * infrun.c (process_event_stop_test): Call
6054 gdbarch_in_indirect_branch_thunk.
6055 * gdbarch.sh (in_indirect_branch_thunk): New.
6056 * gdbarch.c: Regenerated.
6057 * gdbarch.h: Regenerated.
6060 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
6061 (HFILES_NO_SRCDIR): Add x86-tdep.h.
6062 (ALLDEPFILES): Add x86-tdep.c.
6063 * arch-utils.h (default_in_indirect_branch_thunk): New.
6064 * arch-utils.c (default_in_indirect_branch_thunk): New.
6065 * i386-tdep: Include x86-tdep.h.
6066 (i386_in_indirect_branch_thunk): New.
6067 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
6069 * amd64-tdep: Include x86-tdep.h.
6070 (amd64_in_indirect_branch_thunk): New.
6071 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
6073 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
6076 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
6077 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
6078 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
6081 2018-04-12 Tom Tromey <tom@tromey.com>
6083 * rust-lang.c (rust_print_struct_def): Remove univariant code.
6084 (rust_evaluate_subexp): Likewise.
6086 2018-04-12 Pedro Alves <palves@redhat.com>
6088 * procfs.c (procfs_detach): Make forward declaration's prototype
6089 match definition's protototype.
6090 (proc_get_LDT_entry): Remove stale do_cleanups call.
6092 2018-04-12 Pedro Alves <palves@redhat.com>
6094 * target.h (target_ops::to_has_exited): Delete.
6095 (target_has_exited): Delete.
6096 * target-delegates.c: Regenerate.
6098 2018-04-11 Pedro Alves <palves@redhat.com>
6100 * target.c (fileio_fh_t::t): Add comment.
6101 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6102 (target_fileio_close): Handle a NULL target.
6103 (invalidate_fileio_fh): New.
6104 (target_close): Call it.
6105 * remote.c (remote_hostio_send_command): No longer check whether
6106 remote_desc is open.
6108 2018-04-11 Pedro Alves <palves@redhat.com>
6110 * target.c (fileio_fh_t): Make it a named struct instead of a
6112 (fileio_fh_t::is_closed): New method.
6113 (DEF_VEC_O (fileio_fh_t)): Remove.
6114 (fileio_fhandles): Now a std::vector.
6115 (is_closed_fileio_fh): Delete.
6116 (acquire_fileio_fd): Adjust. Rename parameters.
6117 (release_fileio_fd): Adjust.
6118 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
6119 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6120 (target_fileio_close): Adjust.
6122 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
6124 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
6127 2018-04-10 Pedro Alves <palves@redhat.com>
6129 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
6130 (scoped_finish_thread_state): New class.
6131 * infcmd.c (run_command_1): Use it instead of finish_thread_state
6133 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
6134 (fetch_inferior_event, normal_stop): Likewise.
6135 * thread.c (finish_thread_state_cleanup): Delete.
6137 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6138 Pedro Alves <palves@redhat.com>
6140 * value.c: Include "selftest.h" and "common/array-view.h".
6141 (struct range) <operator ==>: New.
6142 (test_ranges_contain): New.
6143 (check_ranges_vector): New.
6144 (test_insert_into_bit_range_vector): New.
6145 (_initialize_values): Register selftests.
6146 * common/array-view.h (operator==, operator!=): New.
6148 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6150 * common/gdb_vecs.h (unordered_remove): Add overload that takes
6152 * inline-frame.c: Include <algorithm>.
6153 (struct inline_state): Add constructor.
6154 (inline_state_s): Remove.
6155 (DEF_VEC_O(inline_state_s)): Remove.
6156 (inline_states): Change type to std::vector.
6157 (find_inline_frame_state): Adjust to std::vector.
6158 (allocate_inline_frame_state): Remove.
6159 (clear_inline_frame_state): Adjust to std::vector.
6160 (skip_inline_frames): Adjust to std::vector.
6162 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6164 * tracepoint.h (struct trace_state_variable): Add constructor.
6165 <name>: Change type to std::string.
6166 * tracepoint.c (tsv_s): Remove.
6167 (DEF_VEC_O(tsv_s)): Remove.
6168 (tvariables): Change to std::vector.
6169 (create_trace_state_variable): Adjust to std::vector.
6170 (find_trace_state_variable): Likewise.
6171 (find_trace_state_variable_by_number): Likewise.
6172 (delete_trace_state_variable): Likewise.
6173 (trace_variable_command): Adjust to std::string.
6174 (delete_trace_variable_command): Likewise.
6175 (tvariables_info_1): Adjust to std::vector.
6176 (save_trace_state_variables): Likewise.
6177 (start_tracing): Likewise.
6178 (merge_uploaded_trace_state_variables): Adjust to std::vector
6180 * target.h (struct target_ops)
6181 <to_download_trace_state_variable>: Pass reference to
6182 trace_state_variable.
6183 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
6184 * target-delegates.c: Re-generate.
6185 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
6186 (mi_tsv_deleted): Likewise.
6187 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
6188 * remote.c (remote_download_trace_state_variable): Change
6189 pointer to reference and adjust.
6190 * make-target-delegates (parse_argtypes): Handle references.
6191 (write_function_header): Likewise.
6192 (munge_type): Likewise.
6194 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6196 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6197 string_view-selftests.c.
6198 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
6200 * unittests/basic_string_view/cons/char/1.cc: Likewise.
6201 * unittests/basic_string_view/cons/char/2.cc: Likewise.
6202 * unittests/basic_string_view/cons/char/3.cc: Likewise.
6203 * unittests/basic_string_view/element_access/char/1.cc:
6205 * unittests/basic_string_view/element_access/char/empty.cc:
6207 * unittests/basic_string_view/element_access/char/front_back.cc:
6209 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
6210 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
6212 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
6214 * unittests/basic_string_view/modifiers/swap/char/1.cc:
6216 * unittests/basic_string_view/operations/compare/char/1.cc:
6218 * unittests/basic_string_view/operations/compare/char/13650.cc:
6220 * unittests/basic_string_view/operations/copy/char/1.cc:
6222 * unittests/basic_string_view/operations/data/char/1.cc:
6224 * unittests/basic_string_view/operations/find/char/1.cc:
6226 * unittests/basic_string_view/operations/find/char/2.cc:
6228 * unittests/basic_string_view/operations/find/char/3.cc:
6230 * unittests/basic_string_view/operations/find/char/4.cc:
6232 * unittests/basic_string_view/operations/rfind/char/1.cc:
6234 * unittests/basic_string_view/operations/rfind/char/2.cc:
6236 * unittests/basic_string_view/operations/rfind/char/3.cc:
6238 * unittests/basic_string_view/operations/substr/char/1.cc:
6240 * unittests/basic_string_view/operators/char/2.cc: Likewise.
6241 * unittests/string_view-selftests.c: New file.
6243 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6245 * unittests/basic_string_view/capacity/1.cc: New file.
6246 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
6247 * unittests/basic_string_view/cons/char/1.cc: New file.
6248 * unittests/basic_string_view/cons/char/2.cc: New file.
6249 * unittests/basic_string_view/cons/char/3.cc: New file.
6250 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
6251 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
6252 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
6253 * unittests/basic_string_view/element_access/char/1.cc: New file.
6254 * unittests/basic_string_view/element_access/char/2.cc: New file.
6255 * unittests/basic_string_view/element_access/char/empty.cc: New file.
6256 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
6257 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
6258 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
6259 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
6260 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
6261 * unittests/basic_string_view/include.cc: New file.
6262 * unittests/basic_string_view/inserters/char/1.cc: New file.
6263 * unittests/basic_string_view/inserters/char/2.cc: New file.
6264 * unittests/basic_string_view/inserters/char/3.cc: New file.
6265 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
6266 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
6267 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
6268 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
6269 * unittests/basic_string_view/literals/types.cc: New file.
6270 * unittests/basic_string_view/literals/values.cc: New file.
6271 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
6272 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
6273 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
6274 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
6275 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
6276 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
6277 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
6278 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
6279 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
6280 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
6281 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
6282 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
6283 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
6284 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
6285 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
6286 * unittests/basic_string_view/operations/data/char/1.cc: New file.
6287 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
6288 * unittests/basic_string_view/operations/find/char/1.cc: New file.
6289 * unittests/basic_string_view/operations/find/char/2.cc: New file.
6290 * unittests/basic_string_view/operations/find/char/3.cc: New file.
6291 * unittests/basic_string_view/operations/find/char/4.cc: New file.
6292 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
6293 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
6294 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
6295 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
6296 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
6297 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
6298 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
6299 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
6300 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
6301 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
6302 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
6303 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
6304 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
6305 * unittests/basic_string_view/operators/char/2.cc: New file.
6306 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
6307 * unittests/basic_string_view/range_access/char/1.cc: New file.
6308 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
6309 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
6310 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
6311 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
6312 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
6313 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
6314 * unittests/basic_string_view/requirements/typedefs.cc: New file.
6315 * unittests/basic_string_view/typedefs.cc: New file.
6316 * unittests/basic_string_view/types/1.cc: New file.
6318 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6320 * common/gdb_string_view.h: Remove libstdc++ implementation
6321 details, adjust to gdb reality.
6322 * common/gdb_string_view.tcc: Likewise.
6323 * cli/cli-script.c (struct string_view): Remove.
6324 (user_args) <m_args>: Change element type to gdb::string_view.
6325 (user_args::insert_args): Adjust.
6327 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6329 * common/gdb_string_view.h: New file.
6330 * common/gdb_string_view.tcc: New file.
6332 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6334 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
6335 * configure: Re-generate.
6337 2018-04-09 Pedro Alves <palves@redhat.com>
6339 * gdbarch.sh: Include "observable.h" instead of "observer.h".
6340 (set_target_gdbarch): Call
6341 gdb::observers::architecture_changed.notify instead of
6342 observer_notify_architecture_changed.
6344 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6346 * tracepoint.c (struct current_traceframe_cleanup): Remove.
6347 (do_restore_current_traceframe_cleanup): Remove.
6348 (restore_current_traceframe_cleanup_dtor): Remove.
6349 (make_cleanup_restore_current_traceframe): Remove.
6350 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
6352 * tracepoint.h (struct scoped_restore_current_traceframe): New.
6353 * infrun.c (fetch_inferior_event): Use
6354 scoped_restore_current_traceframe.
6356 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6358 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
6360 <n_allocated_type_units>: Remove.
6361 <all_type_units>: Change to std::vector.
6362 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6363 to std::vector change.
6364 (dwarf2_per_objfile::get_cutu): Likewise.
6365 (dwarf2_per_objfile::get_tu): Likewise.
6366 (create_signatured_type_table_from_index): Likewise.
6367 (create_signatured_type_table_from_debug_names): Likewise.
6368 (dw2_symtab_iter_next): Likewise.
6369 (dw2_print_stats): Likewise.
6370 (dw2_expand_all_symtabs): Likewise.
6371 (dw2_expand_marked_cus): Likewise.
6372 (dw2_debug_names_iterator::next): Likewise.
6373 (dwarf2_initialize_objfile): Likewise.
6374 (add_signatured_type_cu_to_table): Likewise.
6375 (create_all_type_units): Likewise.
6376 (add_type_unit): Likewise.
6377 (struct tu_abbrev_offset): Add constructor.
6378 (build_type_psymtabs_1): Adjust to std::vector change.
6379 (print_tu_stats): Likewise.
6380 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6381 (write_debug_names): Likewise.
6383 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6385 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
6386 Make an std::vector.
6387 <n_comp_units>: Remove.
6388 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6389 to std::vector change.
6390 (dwarf2_per_objfile::get_cutu): Likewise.
6391 (dwarf2_per_objfile::get_cu): Likewise.
6392 (create_cus_from_index): Likewise.
6393 (create_addrmap_from_index): Likewise.
6394 (create_addrmap_from_aranges): Likewise.
6395 (dwarf2_read_index): Likewise.
6396 (dw2_find_last_source_symtab): Likewise.
6397 (dw2_map_symtabs_matching_filename): Likewise.
6398 (dw2_symtab_iter_next): Likewise.
6399 (dw2_print_stats): Likewise.
6400 (dw2_expand_all_symtabs): Likewise.
6401 (dw2_expand_symtabs_with_fullname): Likewise.
6402 (dw2_expand_marked_cus): Likewise.
6403 (dw2_map_symbol_filenames): Likewise.
6404 (create_cus_from_debug_names): Likewise.
6405 (dwarf2_read_debug_names): Likewise.
6406 (dw2_debug_names_iterator::next): Likewise.
6407 (dwarf2_initialize_objfile): Likewise.
6408 (set_partial_user): Likewise.
6409 (dwarf2_build_psymtabs_hard): Likewise.
6410 (read_comp_units_from_section): Remove arguments, adjust to
6412 (create_all_comp_units): Adjust to std::vector and
6413 read_comp_units_from_section changes.
6414 (dwarf2_find_containing_comp_unit): Adjust to std::vector
6416 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6417 (psyms_seen_size): Likewise.
6418 (write_gdbindex): Likewise.
6419 (write_debug_names): Likewise.
6421 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6423 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
6424 with dwarf2_per_objfile.
6425 (create_cus_from_index): Likewise.
6426 (create_signatured_type_table_from_index): Likewise.
6427 (dwarf2_read_index): Likewise.
6428 (dwarf2_initialize_objfile): Likewise.
6429 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
6430 per_cu rather than get_dwarf2_per_objfile.
6432 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6434 * dwarf2read.h (struct signatured_type): Forward declare.
6435 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
6437 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
6438 (dw2_get_cutu): ...this.
6439 (dwarf2_per_objfile::get_cu): Rename from...
6440 (dw2_get_cu): ...this.
6441 (dwarf2_per_objfile::get_tu): New.
6442 (create_addrmap_from_index): Adjust.
6443 (create_addrmap_from_aranges): Adjust.
6444 (dw2_find_last_source_symtab): Adjust.
6445 (dw2_map_symtabs_matching_filename): Adjust.
6446 (dw2_symtab_iter_next): Adjust.
6447 (dw2_print_stats): Adjust.
6448 (dw2_expand_all_symtabs): Adjust.
6449 (dw2_expand_symtabs_with_fullname): Adjust.
6450 (dw2_expand_marked_cus): Adjust.
6451 (dw_expand_symtabs_matching_file_matcher): Adjust.
6452 (dw2_map_symbol_filenames): Adjust.
6453 (dw2_debug_names_iterator::next): Adjust.
6454 (dwarf2_initialize_objfile): Adjust.
6455 (set_partial_user): Adjust.
6456 (dwarf2_build_psymtabs_hard): Adjust.
6458 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6460 * dwarf2read.c (create_signatured_type_table_from_debug_names):
6461 Remove unused variables.
6462 (dw2_map_symtabs_matching_filename): Likewise.
6463 (dwarf2_record_block_ranges): Likewise.
6464 (dwarf2_read_addr_index): Likewise.
6465 (follow_die_offset): Likewise.
6467 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6469 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
6470 to symbol_file_add_main.
6472 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6475 * mi/mi-console.c (do_fputc_async_safe): New.
6476 (mi_console_file::write_async_safe): New.
6477 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
6478 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
6480 * ui-file.c (ui_file::putstrn): Adjust call to
6481 fputstrn_unfiltered.
6482 * utils.c (printchar): Replace do_fputs and do_fprintf
6483 parameters by do_fputc.
6484 (fputstr_filtered): Adjust call to printchar.
6485 (fputstr_unfiltered): Likewise.
6486 (fputstrn_filtered): Likewise.
6487 (fputstrn_unfiltered): Add do_fputc parameter, pass to
6489 * utils.h (do_fputc_ftype): New typedef.
6490 (fputstrn_unfiltered): Add do_fputc parameter.
6492 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6494 * regformats/i386/i386-avx.dat: Remove.
6496 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6499 * amd64-tdep.c (amd64_none_init_abi): New function.
6500 (amd64_x32_none_init_abi): New function.
6501 (_initialize_amd64_tdep): Register handlers for x86-64 and
6502 x64_32 with GDB_OSABI_NONE.
6503 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
6504 GDB_OSABI_NONE osabi.
6506 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6509 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
6511 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
6512 * osabi.c (gdb_osabi_names): Add "unknown" entry.
6514 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6516 * common/byte-vector.h (char_vector): New type.
6517 * target.h (target_read_alloc): Return
6518 gdb::optional<byte_vector>.
6519 (target_read_stralloc): Return gdb::optional<char_vector>.
6520 (target_get_osdata): Return gdb::optional<char_vector>.
6521 * target.c (target_read_alloc_1): Templatize. Replacement
6522 manual memory management with vector.
6523 (target_read_alloc): Change return type, adjust.
6524 (target_read_stralloc): Change return type, adjust.
6525 (target_get_osdata): Change return type, adjust.
6526 * auxv.c (struct auxv_info) <length>: Remove.
6527 <data>: Change type to gdb::optional<byte_vector>.
6528 (auxv_inferior_data_cleanup): Free auxv_info with delete.
6529 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
6530 (target_auxv_search): Adjust.
6531 (fprint_target_auxv): Adjust.
6532 * avr-tdep.c (avr_io_reg_read_command): Adjust.
6533 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
6534 (linux_make_corefile_notes): Adjust.
6535 * osdata.c (get_osdata): Adjust.
6536 * remote.c (remote_get_threads_with_qxfer): Adjust.
6537 (remote_memory_map): Adjust.
6538 (remote_traceframe_info): Adjust.
6539 (btrace_read_config): Adjust.
6540 (remote_read_btrace): Adjust.
6541 (remote_pid_to_exec_file): Adjust.
6542 * solib-aix.c (solib_aix_get_library_list): Adjust.
6543 * solib-dsbt.c (decode_loadmap): Don't free buf.
6544 (dsbt_get_initial_loadmaps): Adjust.
6545 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
6546 * solib-target.c (solib_target_current_sos): Adjust.
6547 * tracepoint.c (sdata_make_value): Adjust.
6548 * xml-support.c (xinclude_start_include): Adjust.
6549 (xml_fetch_content_from_file): Adjust.
6550 * xml-support.h (xml_fetch_another): Change return type.
6551 (xml_fetch_content_from_file): Change return type.
6552 * xml-syscall.c (xml_init_syscalls_info): Adjust.
6553 * xml-tdesc.c (file_read_description_xml): Adjust.
6554 (fetch_available_features_from_target): Change return type.
6555 (target_fetch_description_xml): Adjust.
6556 (target_read_description_xml): Adjust.
6558 2018-04-06 Tom Tromey <tom@tromey.com>
6560 * value.c (~value): Update.
6561 (struct value) <contents>: Now unique_xmalloc_ptr.
6562 (value_contents_bits_eq, allocate_value_contents)
6563 (value_contents_raw, value_contents_all_raw)
6564 (value_contents_for_printing, value_contents_for_printing_const)
6565 (set_value_enclosing_type): Update.
6567 2018-04-06 Tom Tromey <tom@tromey.com>
6569 * value.c (range_s): Remove typedef, VEC.
6570 (struct range): Add operator<.
6571 (range_lessthan): Remove.
6572 (ranges_contain): Change type.
6574 (struct value) <unavailable, optimized_out>: Now std::vector.
6575 (value_entirely_available)
6576 (value_entirely_covered_by_range_vector)
6577 (value_entirely_unavailable, value_entirely_optimized_out):
6579 (insert_into_bit_range_vector): Change argument type.
6580 (find_first_range_overlap): Likewise.
6581 (struct ranges_and_idx, value_contents_bits_eq)
6582 (require_not_optimized_out, require_available): Update.
6583 (ranges_copy_adjusted): Change argument types.
6584 (value_optimized_out, value_copy, value_fetch_lazy): Update.
6586 2018-04-06 Tom Tromey <tom@tromey.com>
6588 * value.c (~value): Update.
6589 (struct value) <parent>: Now a value_ref_ptr.
6590 (value_parent, set_value_parent, value_address, value_copy):
6593 2018-04-06 Tom Tromey <tom@tromey.com>
6595 * value.c (struct value): Add constructor, destructor, and member
6597 (allocate_value_lazy, value_decref): Update.
6599 2018-04-06 Tom Tromey <tom@tromey.com>
6601 * value.c (struct value) <released, next>: Remove.
6602 (all_values): Now a std::vector.
6603 (allocate_value_lazy): Update.
6604 (value_next): Remove.
6605 (value_mark, value_free_to_mark, release_value)
6606 (value_release_to_mark): Update.
6608 2018-04-06 Tom Tromey <tom@tromey.com>
6610 * value.h (fetch_subexp_value, value_release_to_mark): Update.
6611 (free_value_chain): Remove.
6612 * value.c (free_value_chain): Remove.
6613 (value_release_to_mark): Return a std::vector.
6614 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
6616 (check_condition): Update.
6617 * eval.c (fetch_subexp_value): Change "val_chain" to a
6619 * breakpoint.c (update_watchpoint): Update.
6620 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
6622 2018-04-06 Tom Tromey <tom@tromey.com>
6624 * value.h (free_all_values): Remove.
6625 * value.c (free_all_values): Remove.
6627 2018-04-06 Tom Tromey <tom@tromey.com>
6629 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
6630 (value_history_chain, value_history_count): Remove.
6631 (value_history): New global.
6632 (record_latest_value, access_value_history, show_values)
6633 (preserve_values): Update.
6635 2018-04-06 Tom Tromey <tom@tromey.com>
6637 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
6638 * varobj.c (varobj_set_display_format, varobj_set_value)
6639 (install_default_visualizer, construct_visualizer)
6640 (install_new_value, ~varobj, varobj_get_value_type)
6641 (my_value_of_variable, varobj_editable_p): Update.
6642 * c-varobj.c (c_describe_child, c_value_of_variable)
6643 (cplus_number_of_children, cplus_describe_child): Update.
6644 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
6645 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
6646 (ada_value_of_variable, ada_value_is_changeable_p): Update.
6648 2018-04-06 Tom Tromey <tom@tromey.com>
6650 * printcmd.c (last_examine_address): Change type to
6652 (do_examine, x_command): Update.
6654 2018-04-06 Tom Tromey <tom@tromey.com>
6656 * value.c (release_value): Update.
6657 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
6658 (struct bpstats) <val>: Now a value_ref_ptr.
6659 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6660 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6661 (~watchpoint, print_it_watchpoint, watch_command_1)
6662 (invalidate_bp_value_on_memory_change): Update.
6664 2018-04-06 Tom Tromey <tom@tromey.com>
6666 * varobj.c (varobj_clear_saved_item)
6667 (update_dynamic_varobj_children, install_new_value, ~varobj):
6669 * value.h (value_incref): Move declaration earlier.
6670 (value_decref): Rename from value_free.
6671 (struct value_ref_policy): New.
6672 (value_ref_ptr): New typedef.
6673 (struct value_deleter): Remove.
6674 (gdb_value_up): Remove typedef.
6675 (release_value): Change return type.
6676 (release_value_or_incref): Remove.
6677 * value.c (set_value_parent): Update.
6678 (value_incref): Change return type.
6679 (value_decref): Rename from value_free.
6680 (value_free_to_mark, free_all_values, free_value_chain): Update.
6681 (release_value): Return value_ref_ptr.
6682 (release_value_or_incref): Remove.
6683 (record_latest_value, set_internalvar, clear_internalvar):
6685 * stack.c (info_frame_command): Don't call value_free.
6686 * python/py-value.c (valpy_dealloc, valpy_new)
6687 (value_to_value_object): Update.
6688 * printcmd.c (do_examine): Update.
6689 * opencl-lang.c (lval_func_free_closure): Update.
6690 * mi/mi-main.c (register_changed_p): Don't call value_free.
6691 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
6692 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
6693 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
6695 * guile/scm-value.c (vlscm_free_value_smob)
6696 (vlscm_scm_from_value): Update.
6697 * frame.c (frame_register_unwind, frame_unwind_register_signed)
6698 (frame_unwind_register_unsigned, get_frame_register_bytes)
6699 (put_frame_register_bytes): Don't call value_free.
6700 * findvar.c (address_from_register): Don't call value_free.
6701 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
6702 * dwarf2loc.c (entry_data_value_free_closure)
6703 (value_of_dwarf_reg_entry, free_pieced_value_closure)
6704 (dwarf2_evaluate_loc_desc_full): Update.
6705 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6706 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6707 (~watchpoint, watch_command_1)
6708 (invalidate_bp_value_on_memory_change): Update.
6709 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
6711 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
6714 * warning.m4: Add -Wno-error=deprecated-register.
6715 * configure: Re-generate.
6717 2018-04-05 Tom Tromey <tom@tromey.com>
6719 * linespec.h: Remove include of "vec.h".
6721 2018-04-05 Tom Tromey <tom@tromey.com>
6723 * linespec.c (typep): Remove typedef.
6724 (find_methods, find_superclass_methods): Take a std::vector.
6725 (find_method): Use std::vector.
6727 2018-04-05 Tom Tromey <tom@tromey.com>
6729 * utils.c (compare_strings): Remove.
6730 * utils.h (compare_strings): Remove.
6731 * objc-lang.h (find_imps): Update.
6732 * objc-lang.c (find_methods): Take a std::vector.
6733 (uniquify_strings, find_imps): Likewise.
6734 * linespec.c (find_methods): Take a std::vector.
6735 (decode_objc): Use std::vector.
6736 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
6738 (find_method, find_function_symbols): Use std::vector.
6740 2018-04-05 Tom Tromey <tom@tromey.com>
6742 * completer.c (completion_tracker::completion_tracker): Remove
6744 (completion_tracker::discard_completions): Likewise.
6745 * breakpoint.c (ambiguous_names_p): Remove cast.
6746 * ada-lang.c (_initialize_ada_language): Remove cast.
6747 * utils.h (streq): Update.
6748 (streq_hash): Add new declaration.
6749 * utils.c (streq): Return bool.
6750 (streq_hash): New function.
6752 2018-04-05 Tom Tromey <tom@tromey.com>
6754 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
6755 Remove a string copy.
6757 2018-04-05 Tom Tromey <tom@tromey.com>
6759 * linespec.c (filter_results): Use std::vector.
6760 (decode_line_2, decode_line_full): Update.
6762 2018-04-05 Tom Tromey <tom@tromey.com>
6764 * linespec.c (canonical_to_fullform): Return std::string.
6765 (filter_results): Update.
6766 (struct decode_line_2_item): Add constructor.
6767 <fullform, displayform>: Now std::string.
6768 (decode_line_2_compare_items): Now a std::sort comparator.
6769 (decode_line_2): Update.
6771 2018-04-05 Tom Tromey <tom@tromey.com>
6773 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
6774 (unexpected_linespec_error): Update.
6775 (linespec_parse_basic, parse_linespec): Update.
6777 2018-04-05 Tom Tromey <tom@tromey.com>
6779 * linespec.c (linespec_parse_basic): Reindent.
6781 2018-04-05 Tom Tromey <tom@tromey.com>
6783 * minsyms.h (iterate_over_minimal_symbols): Update.
6784 * minsyms.c (iterate_over_minimal_symbols): Take a
6786 * linespec.c (struct collect_minsyms): Remove.
6787 (compare_msyms): Now a std::sort comparator.
6788 (add_minsym): Add parameters.
6789 (search_minsyms_for_name): Update. Use std::vector.
6791 2018-04-03 Tom Tromey <tom@tromey.com>
6793 * mipsread.c (read_alphacoff_dynamic_symtab): Use
6796 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
6798 * MAINTAINERS (Write After Approval): Add Weimin Pan.
6800 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
6803 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
6804 printing static type.
6806 2018-04-01 Tom Tromey <tom@tromey.com>
6808 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
6809 (rs6000_xfer_shared_libraries): Update.
6811 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
6813 * common/gdb_vecs.h (char_ptr): Remove.
6814 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
6816 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6818 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
6820 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
6822 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6824 * tracepoint.h (struct uploaded_tp): Initialize fields.
6825 <actions, step_actions, cmd_strings>: Change type to
6826 std::vector<char *>.
6827 * tracepoint.c (get_uploaded_tp): Allocate with new.
6828 (free_uploaded_tps): Free with delete.
6829 (parse_tracepoint_definition): Adjust to std::vector change.
6830 * breakpoint.c (read_uploaded_action): Likewise.
6831 (create_tracepoint_from_upload): Likewise.
6832 * ctf.c (ctf_write_uploaded_tp): Likewise.
6833 (SET_ARRAY_FIELD): Likewise.
6834 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
6836 2018-03-30 Tom Tromey <tom@tromey.com>
6838 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
6840 (svr4_keep_data_in_core): Update.
6841 (svr4_read_so_list): Update.
6843 2018-03-30 Tom Tromey <tom@tromey.com>
6845 * windows-nat.c (handle_output_debug_string, handle_exception):
6847 * target.h (target_read_string): Update.
6848 * target.c (target_read_string): Change "string" to
6850 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
6852 * solib-frv.c (frv_current_sos): Update.
6853 * solib-dsbt.c (dsbt_current_sos): Update.
6854 * solib-darwin.c (darwin_current_sos): Update.
6855 * linux-thread-db.c (inferior_has_bug): Update.
6856 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
6857 Update. Remove alloca.
6858 * ada-lang.c (ada_main_name): Update.
6860 2018-03-30 Tom Tromey <tom@tromey.com>
6862 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
6863 (struct dwo_file_deleter): New.
6864 (dwo_file_up): New typedef.
6865 (open_and_init_dwo_file): Use dwo_file_up.
6866 (free_dwo_file_cleanup): Remove.
6868 2018-03-30 Tom Tromey <tom@tromey.com>
6870 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
6871 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
6873 2018-03-30 Tom Tromey <tom@tromey.com>
6875 * dwarf2read.c (class free_cached_comp_units): New class.
6876 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
6877 (free_cached_comp_units): Remove function.
6879 2018-03-30 Tom Tromey <tom@tromey.com>
6881 * utils.h (make_cleanup_unpush_target): Remove.
6882 * inf-ptrace.c (struct target_unpusher): New.
6883 (target_unpush_up) New typedef.
6884 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
6886 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
6888 2018-03-27 Tom Tromey <tom@tromey.com>
6890 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
6892 2018-03-27 Pedro Alves <palves@redhat.com>
6893 Tom Tromey <tom@tromey.com>
6895 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
6896 destructor. Now a class.
6897 (gdb_readline_wrapper_cleanup): Remove function.
6898 (gdb_readline_wrapper): Remove cleanups.
6900 2018-03-27 Tom Tromey <tom@tromey.com>
6902 * typeprint.h (struct type_print_options) <local_typedefs,
6903 global_typedefs>: Remove "struct" keyword.
6904 (class typedef_hash_table): New class.
6905 (recursively_update_typedef_hash, add_template_parameters)
6906 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
6907 (find_typedef_in_hash): Don't declare.
6908 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
6909 (typedef_hash_table::recursively_update): Rename from
6910 recursively_update_typedef_hash. Now a member.
6911 (typedef_hash_table::add_template_parameters): Rename from
6912 add_template_parameters. Now a member.
6913 (typedef_hash_table::typedef_hash_table): Now a constructor;
6914 rename from create_typedef_hash.
6915 (typedef_hash_table::~typedef_hash_table): Now a destructor;
6916 rename from free_typedef_hash.
6917 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
6918 (do_free_global_table): Remove.
6919 (typedef_hash_table::typedef_hash_table): New constructor; renamed
6920 from copy_type_recursive.
6921 (create_global_typedef_table): Remove.
6922 (typedef_hash_table::find_global_typedef): Now a member of
6924 (typedef_hash_table::find_typedef): Rename from
6925 find_typedef_in_hash; now a member.
6926 (whatis_exp): Update.
6927 * extension.h (struct ext_lang_type_printers): Add constructor and
6929 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
6931 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
6932 Now a constructor; rename from start_ext_lang_type_printers.
6933 (ext_lang_type_printers): Now a destructor; rename from
6934 free_ext_lang_type_printers.
6935 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
6937 (c_type_print_base_struct_union): Update. Remove cleanups.
6939 2018-03-27 Tom Tromey <tom@tromey.com>
6941 * dwarf-index-write.c: Include <cmath>.
6943 2018-03-27 Joel Brobecker <brobecker@adacore.com>
6945 * NEWS: Add entry describing new "set|show varsize-limit" command.
6946 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
6948 * printcmd.c (_initialize_printcmd): Add "set var" alias of
6951 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
6953 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
6955 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
6956 * dwarf-index-common.c: New file.
6957 * dwarf-index-common.h: New file.
6958 * dwarf-index-write.c: New file.
6959 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
6960 (struct dwarf2_section_info): Move from here.
6961 (dwarf2_section_info_def): Likewise.
6962 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
6963 (offset_type): Likewise.
6964 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
6965 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
6966 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
6967 (byte_swap): Likewise.
6968 (MAYBE_SWAP): Likewise.
6969 (dwarf2_per_cu_ptr): Likewise.
6970 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
6971 (struct tu_stats): Likewise.
6972 (struct dwarf2_per_objfile): Likewise.
6973 (struct dwarf2_per_cu_data): Likewise.
6974 (struct signatured_type): Likewise.
6975 (sig_type_ptr): Likewise.
6976 (DEF_VEC_P (sig_type_ptr)): Likewise.
6977 (INDEX4_SUFFIX): Likewise.
6978 (INDEX5_SUFFIX): Likewise.
6979 (DEBUG_STR_SUFFIX): Likewise.
6980 (dwarf2_read_section): Make non-static.
6981 (mapped_index_string_hash): Move from here.
6982 (dwarf5_djb_hash): Likewise.
6983 (file_write): Likewise.
6984 (class data_buf): Likewise.
6985 (struct symtab_index_entry): Likewise.
6986 (struct mapped_symtab): Likewise.
6987 (find_slot): Likewise.
6988 (hash_expand): Likewise.
6989 (add_index_entry): Likewise.
6990 (uniquify_cu_indices): Likewise.
6991 (class c_str_view): Likewise.
6992 (class c_str_view_hasher): Likewise.
6993 (class vector_hasher): Likewise.
6994 (write_hash_table): Likewise.
6995 (psym_index_map): Likewise.
6996 (struct addrmap_index_data): Likewise.
6997 (add_address_entry): Likewise.
6998 (add_address_entry_worker): Likewise.
6999 (write_address_map): Likewise.
7000 (symbol_kind): Likewise.
7001 (write_psymbols): Likewise.
7002 (struct signatured_type_index_data): Likewise.
7003 (write_one_signatured_type): Likewise.
7004 (recursively_count_psymbols): Likewise.
7005 (recursively_write_psymbols): Likewise.
7006 (class debug_names): Likewise.
7007 (check_dwarf64_offsets): Likewise.
7008 (psyms_seen_size): Likewise.
7009 (write_gdbindex): Likewise.
7010 (write_debug_names): Likewise.
7011 (assert_file_size): Likewise.
7012 (write_psymtabs_to_index): Likewise.
7013 (save_gdb_index_command): Likewise.
7014 (_initialize_dwarf2_read): Don't register the "save gdb-index"
7016 * dwarf2read.h: New file.
7018 2018-03-27 Joel Brobecker <brobecker@adacore.com>
7021 * dwarf2read.c (dwarf2_physname): Do not return the demangled
7022 symbol name if the CU's language stores symbol names in linkage
7024 * language.h (struct language_defn)
7025 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
7026 all instances of this struct.
7028 2018-03-26 Tom Tromey <tom@tromey.com>
7030 * stack.c (backtrace_command_1): Remove verbose code.
7032 2018-03-26 Tom Tromey <tom@tromey.com>
7034 * python/py-framefilter.c (py_print_type): Don't catch
7035 exceptions. Return void.
7036 (py_print_value): Likewise.
7037 (py_print_single_arg): Likewise.
7038 (enumerate_args): Don't catch exceptions.
7039 (py_print_args): Likewise.
7040 (py_print_frame): Likewise.
7041 (gdbpy_apply_frame_filter): Catch exceptions here.
7043 2018-03-26 Tom Tromey <tom@tromey.com>
7045 * stack.c (_initialize_stack): Remove trailing newlines from help
7046 text. Add "Usage" line to "backtrace" help.
7048 2018-03-26 Tom Tromey <tom@tromey.com>
7051 * python/py-framefilter.c (py_print_args): Call wrap_hint.
7053 2018-03-26 Tom Tromey <tom@tromey.com>
7055 * python/py-framefilter.c (py_print_single_arg): Return
7056 EXT_LANG_BT_ERROR from catch.
7058 2018-03-26 Tom Tromey <tom@tromey.com>
7061 * stack.c (backtrace_command_1): Move some code into no-filters
7064 2018-03-26 Tom Tromey <tom@tromey.com>
7066 * python/py-framefilter.c (throw_quit_or_print_exception): New
7068 (gdbpy_apply_frame_filter): Use it.
7070 2018-03-26 Tom Tromey <tom@tromey.com>
7073 * python/py-framefilter.c (py_print_type, py_print_value)
7074 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
7077 2018-03-26 Tom Tromey <tom@tromey.com>
7079 * python/py-framefilter.c (enumerate_args): Use
7080 gdb::unique_xmalloc_ptr.
7082 2018-03-26 Tom Tromey <tom@tromey.com>
7084 * python/py-framefilter.c (py_print_frame): Return
7086 (gdbpy_apply_frame_filter): Update comment.
7087 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
7089 <EXT_LANG_BT_NO_FILTERS>: Change value.
7091 2018-03-26 Tom Tromey <tom@tromey.com>
7094 * stack.c (backtrace_command): Parse "hide" argument.
7095 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
7096 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
7099 2018-03-26 Tom Tromey <tom@tromey.com>
7101 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
7103 (backtrace_command): Remove "fulltrace", add "flags".
7105 2018-03-26 Tom Tromey <tom@tromey.com>
7107 * stack.c (backtrace_command): Rewrite command line parsing.
7109 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7111 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
7113 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7115 * filename-seen-cache.h: Add include guard.
7117 2018-03-26 Keith Seitz <keiths@redhat.com>
7119 * symfile.c (place_section): Remove "struct" from section_addr_info
7121 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
7122 "struct" keyword from section_addr_info.
7124 2018-03-26 Alan Hayward <alan.hayward@arm.com>
7126 * regformats/regdef.h (reg): Add constructors.
7128 2018-03-25 Pedro Alves <palves@redhat.com>
7130 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
7131 if then/else bodies in var_func_name extraction.
7133 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
7135 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
7136 lookup_minimal_symbol() to find symbol entry.
7137 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
7139 2018-03-23 Keith Seitz <keiths@redhat.com>
7142 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
7143 nested type definitions for C++, too.
7145 2018-03-23 Tom Tromey <tom@tromey.com>
7147 * machoread.c (struct oso_el): Add a constructor. Don't define as
7149 (macho_register_oso): Remove.
7150 (macho_symtab_read): Take a std::vector.
7151 (oso_el_compare_name): Now a std::sort comparator.
7152 (macho_symfile_read_all_oso): Take a std::vector.
7153 (macho_symfile_read): Use std::vector. Remove cleanups.
7155 2018-03-22 Tom Tromey <tom@tromey.com>
7157 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
7158 (record_full_goto_bookmark): Use std::string.
7160 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7163 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
7166 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7168 * rs6000-tdep.c (store_insn_p): New function.
7169 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
7170 and cr_reg to their unshifted values. Use store_insn_p to
7171 match LR saves using either R1 or fdata->alloca_reg. Use
7172 store_insn_p to match CR saves. Set alloca_reg_offset
7173 when alloca_reg and framep are set. Remove lr_reg shift
7174 when assigning to fdata->lr_register.
7176 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
7178 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
7179 command line args instead of emitting a warning.
7181 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7183 * tracepoint.h (struct static_tracepoint_marker): Initialize
7184 fields, define default constructor, move constructor and move
7185 assignment, disable the rest.
7186 <str_id, extra>: Make std::string.
7187 (release_static_tracepoint_marker): Remove.
7188 (free_current_marker): Remove.
7189 * tracepoint.c (free_current_marker): Remove.
7190 (parse_static_tracepoint_marker_definition): Adjust to
7191 std::string, use new hex2str overload.
7192 (release_static_tracepoint_marker): Remove.
7193 (print_one_static_tracepoint_marker): Get marker by reference
7194 and adjust to std::string.
7195 (info_static_tracepoint_markers_command): Adjust to std::vector
7197 * target.h (static_tracepoint_marker_p): Remove typedef.
7198 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
7199 (struct target_ops) <to_static_tracepoint_marker_at>: Return
7201 <to_static_tracepoint_markers_by_strid>: Return std::vector.
7203 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
7204 (target_debug_print_std_vector_static_tracepoint_marker): New.
7205 (target_debug_print_struct_static_tracepoint_marker_p): Rename
7207 (target_debug_print_static_tracepoint_marker_p): ... this.
7208 * target-delegates.c: Re-generate.
7209 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
7211 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
7212 (decode_static_tracepoint_spec): Adjust to std::vector.
7213 (tracepoint_print_one_detail): Adjust to std::string.
7214 (strace_marker_decode_location): Adjust to std::string.
7215 (update_static_tracepoint): Adjust to std::string, remove call
7216 to release_static_tracepoint_marker.
7217 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
7218 Adjust to std::vector.
7219 * remote.c (remote_static_tracepoint_marker_at): Return bool.
7220 (remote_static_tracepoint_markers_by_strid): Adjust to
7222 * common/rsp-low.h (hex2str): New overload with explicit count
7224 * common/rsp-low.c (hex2str): New overload with explicit count
7226 * unittests/rsp-low-selftests.c (test_hex2str): New function.
7227 (_initialize_rsp_low_selftests): Add test_hex2str test.
7228 * unittests/tracepoint-selftests.c
7229 (test_parse_static_tracepoint_marker_definition): Adjust to
7232 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7234 * tracepoint.c (parse_static_tracepoint_marker_definition):
7235 Consider case where the definition is followed by more
7237 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7238 tracepoint-selftests.c.
7239 * unittests/tracepoint-selftests.c: New.
7241 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7243 * MAINTAINERS (Write After Approval): Add Pedro Franco de
7246 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7248 * symtab.c (find_pc_sect_line): fixed indentation.
7250 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7252 * symtab.c (find_pc_sect_line): now uses binary search.
7254 2018-03-19 Tom Tromey <tom@tromey.com>
7256 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
7259 2018-03-19 Pedro Alves <palves@redhat.com>
7260 Tom Tromey <tom@tromey.com>
7262 * unittests/observable-selftests.c: New file.
7263 * common/observable.h: New file.
7264 * observable.h: New file.
7265 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
7266 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
7267 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
7268 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
7269 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
7270 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
7271 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
7272 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
7273 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
7274 python/py-breakpoint.c, python/py-finishbreakpoint.c,
7275 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
7276 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
7277 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
7278 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
7279 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
7280 tui/tui-interp.c, valops.c: Update all users.
7281 * tui/tui-hooks.c (tui_bp_created_observer)
7282 (tui_bp_deleted_observer, tui_bp_modified_observer)
7283 (tui_inferior_exit_observer, tui_before_prompt_observer)
7284 (tui_normal_stop_observer, tui_register_changed_observer):
7286 (tui_observers_token): New global.
7287 (attach_or_detach, tui_attach_detach_observers): New functions.
7288 (tui_install_hooks, tui_remove_hooks): Use
7289 tui_attach_detach_observers.
7290 * record-btrace.c (record_btrace_thread_observer): Remove.
7291 (record_btrace_thread_observer_token): New global.
7292 * observer.sh: Remove.
7293 * observer.c: Rename to observable.c.
7294 * observable.c (namespace gdb_observers): Define new objects.
7295 (observer_debug): Move into gdb_observers namespace.
7296 (struct observer, struct observer_list, xalloc_observer_list_node)
7297 (xfree_observer_list_node, generic_observer_attach)
7298 (generic_observer_detach, generic_observer_notify): Remove.
7299 (_initialize_observer): Update.
7300 Don't include observer.inc.
7301 * Makefile.in (generated_files): Remove observer.h, observer.inc.
7302 (clean mostlyclean): Likewise.
7303 (observer.h, observer.inc): Remove targets.
7304 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
7305 (COMMON_SFILES): Use observable.c, not observer.c.
7306 * .gitignore: Remove observer.h.
7308 2018-03-18 Tom Tromey <tom@tromey.com>
7310 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
7312 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
7314 2018-03-17 Tom Tromey <tom@tromey.com>
7316 * auto-load.c (auto_load_objfile_script_1): Use std::string.
7318 2018-03-17 Tom Tromey <tom@tromey.com>
7320 * target.c (class scoped_target_fd): New.
7321 (target_fileio_close_cleanup): Remove.
7322 (target_fileio_read_alloc_1): Use scoped_target_fd.
7324 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
7326 * silent-rules.mk: New.
7327 * Makefile.in: Include silent-rules.mk
7328 (srcdir, VPATH, top_srcdir): Move up.
7329 (COMPILE): Add ECHO_CXX.
7330 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
7331 (init.c): Add ECHO_INIT_C.
7332 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
7333 (version.c): Add ECHO_GEN.
7334 (printcmd.o): Add ECHO_CXX.
7335 (target-float.o): Add ECHO_CXX.
7336 (ada-exp.o): Add ECHO_CXX.
7337 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
7338 (insight$(EXEEXT)): Add ECHO_CXXLD.
7339 * gnulib/configure.ac: Add AM_SILENT_RULES.
7340 * gnulib/aclocal.m4: Re-generate.
7341 * gnulib/configure: Re-generate.
7342 * gnulib/import/Makefile.in: Re-generate.
7344 2018-03-16 Tom Tromey <tom@tromey.com>
7346 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
7347 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
7348 * utils.c (do_free_section_addr_info)
7349 (make_cleanup_free_section_addr_info): Remove.
7350 * symfile.h (struct other_sections): Add constructor.
7351 (struct section_addr_info): Remove.
7352 (section_addr_info): New typedef.
7353 (struct sym_fns) <sym_offsets>: Change type of parameter.
7354 (build_section_addr_info_from_objfile)
7355 (relative_addr_info_to_section_offsets, addr_info_make_relative)
7356 (default_symfile_offsets, symbol_file_add)
7357 (symbol_file_add_from_bfd)
7358 (build_section_addr_info_from_section_table): Update.
7359 (alloc_section_addr_info, free_section_addr_info): Don't declare.
7360 * symfile.c (alloc_section_addr_info): Remove.
7361 (build_section_addr_info_from_section_table): Change return type.
7363 (build_section_addr_info_from_bfd)
7364 (build_section_addr_info_from_objfile): Likewise.
7365 (free_section_addr_info): Remove.
7366 (relative_addr_info_to_section_offsets): Change type of "addrs".
7367 (addrs_section_compar): Now a std::sort comparator.
7368 (addrs_section_sort): Change return type.
7369 (addr_info_make_relative): Change type of "addrs". Update.
7370 (default_symfile_offsets, syms_from_objfile_1)
7371 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
7372 (symbol_file_add_separate): Update.
7373 (symbol_file_add): Change type of "addrs". Update.
7374 (add_symbol_file_command): Update. Remove cleanups.
7375 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
7377 * symfile-debug.c (debug_sym_offsets): Change type of "info".
7378 * solib.c (solib_read_symbols): Update.
7379 * objfiles.c (objfile_relocate): Update. Remove cleanups.
7380 * machoread.c (macho_symfile_offsets): Update.
7381 * jit.c (jit_bfd_try_read_symtab): Update.
7383 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
7385 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7386 unittests/utils-selftests.c.
7387 * unittests/utils-selftests.c: New file.
7389 2018-03-14 Tom Tromey <tom@tromey.com>
7392 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
7395 2018-03-14 Tom Tromey <tom@tromey.com>
7398 * printcmd.c (printf_pointer): Allow "-" in format.
7400 2018-03-14 Tom Tromey <tom@tromey.com>
7402 * printcmd.c (_initialize_printcmd): Add usage to printf.
7404 2018-03-14 Yao Qi <qiyao@sourceware.org>
7406 * MAINTAINERS: Update my email address.
7408 2018-03-13 Tom Tromey <tom@tromey.com>
7410 * machoread.c (macho_check_dsym): Change filenamep to a
7412 (macho_symfile_read): Update.
7413 * symfile.c (load_command): Use std::string.
7415 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
7417 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
7418 to error message string.
7419 (riscv_register_name): Use xsnprintf instead of sprintf.
7420 (riscv_insn::fetch_instruction): Use gdb_assert instead of
7422 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
7424 (riscv_push_dummy_call): Likewise.
7426 2018-03-12 Tom Tromey <tom@tromey.com>
7428 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
7429 Use gdb::byte_vector.
7430 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
7432 2018-03-12 Yao Qi <yao.qi@linaro.org>
7434 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
7435 parameter type to readable_regcache.
7436 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
7439 2018-03-11 Tom Tromey <tom@tromey.com>
7441 * dwarf2read.c (struct nextfield): Add initializers.
7442 (struct nextfnfield): Remove.
7443 (struct fnfieldlist): Add initializers. Remove "length" and
7444 "head", use std::vector.
7445 (struct decl_field_list): Remove.
7446 (struct field_info): Add initializers.
7447 <fields, baseclasses>: Now std::vector.
7448 <nbaseclasses, nfnfields, typedef_field_list_count,
7449 nested_types_list_count>: Remove.
7450 (dwarf2_add_field, dwarf2_add_type_defn)
7451 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
7452 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
7453 (process_structure_scope): Update.
7455 2018-03-11 Tom Tromey <tom@tromey.com>
7457 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
7458 for use by std::sort.
7459 (build_type_psymtabs_1): Use std::vector.
7461 2018-03-09 Eli Zaretskii <eliz@gnu.org>
7463 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
7464 and LIBMPFR in the printed configuration.
7466 2018-03-08 Tom Tromey <tom@tromey.com>
7468 * source.c (get_filename_and_charpos): Use scoped_fd.
7469 * nto-procfs.c (procfs_open_1): Use scoped_fd.
7470 (procfs_pidlist): Likewise.
7471 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
7472 (iterate_over_mappings): Likewise.
7474 2018-03-08 Tom Tromey <tom@tromey.com>
7476 * infcall.c (struct call_return_meta_info)
7477 <stack_temporaries_enabled>: Remove.
7478 (get_call_return_value, call_function_by_hand_dummy): Update.
7479 * thread.c (disable_thread_stack_temporaries): Remove.
7480 (enable_thread_stack_temporaries): Remove.
7481 (thread_stack_temporaries_enabled_p): Return bool.
7482 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
7483 (get_last_thread_stack_temporary): Update.
7484 * eval.c (evaluate_subexp): Update.
7485 * gdbthread.h (class enable_thread_stack_temporaries): Now a
7486 class, not a function.
7487 (value_ptr, value_vec): Remove typedefs.
7488 (class thread_info) <stack_temporaries_enabled>: Now bool.
7489 <stack_temporaries>: Now a std::vector.
7490 (thread_stack_temporaries_enabled_p)
7491 (value_in_thread_stack_temporaries): Return bool.
7493 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
7495 * remote.c (putpkt_binary): Fix omitted bytes reporting.
7496 (getpkt_or_notif_sane_1): Likewise.
7498 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7500 * build-id.c (build_id_to_debug_bfd): Use std::string.
7502 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7504 * build-id.c (find_separate_debug_file_by_buildid): Return
7506 * build-id.h (find_separate_debug_file_by_buildid): Return
7508 * coffread.c (coff_symfile_read): Adjust to std::string.
7509 * elfread.c (elf_symfile_read): Adjust to std::string.
7510 * symfile.c (separate_debug_file_exists): Change parameter to
7512 (find_separate_debug_file): Return std::string.
7513 (find_separate_debug_file_by_debuglink): Return std::string.
7514 * symfile.h (find_separate_debug_file_by_debuglink): Return
7517 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7519 * common/xml-utils.c (xml_escape_text): Move code to...
7520 (xml_escape_text_append): ... this new function.
7521 * common/xml-utils.h (xml_escape_text_append): New declaration.
7522 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
7524 (_initialize_xml_utils): register test_xml_escape_text_append as
7527 2018-03-07 Alan Hayward <alan.hayward@arm.com>
7529 * defs.h: Remove MAX_REGISTER_SIZE.
7530 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
7532 * python/py-unwind.c (pyuw_sniffer): Likewise.
7534 2018-03-07 Tom Tromey <tom@tromey.com>
7536 * linux-tdep.c (linux_info_proc): Update.
7537 * target.h (struct target_ops) <to_fileio_readlink>: Return
7539 (target_fileio_readlink): Return optional<string>.
7540 * remote.c (remote_hostio_readlink): Return optional<string>.
7541 * inf-child.c (inf_child_fileio_readlink): Return
7543 * target.c (target_fileio_readlink): Return optional<string>.
7545 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
7547 * regcache.c (cooked_read_test): Add riscv to the list of
7548 architectures that have a save_reggroup.
7550 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
7552 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
7553 value is not a dynamic class object.
7555 2018-03-06 Tom Tromey <tom@tromey.com>
7557 * rust-exp.y: Formatting fixes.
7559 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7561 * riscv-tdep.c (riscv_register_name): Remove target description
7563 (riscv_gdbarch_init): Remove target description check.
7565 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7567 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
7569 * riscv-tdep.h: Likewise.
7571 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7573 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
7574 (riscv_pseudo_register_write): Delete.
7575 (riscv_gdbarch_init): Remove all use of pseudo registers.
7577 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7579 * record-btrace.c (btrace_print_lines): Replace cleanup
7580 parameter with RAII equivalents.
7581 (btrace_insn_history): Replace cleanup with RAII equivalents.
7582 * ui-out.h (make_cleanup_ui_out_list_begin_end,
7583 make_cleanup_ui_out_tuple_begin_end): Remove.
7584 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
7585 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
7586 make_cleanup_ui_out_list_begin_end): Remove.
7588 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7590 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
7591 parameter types to std::vector. Use bool.
7592 (record_btrace_wait): Replace VEC(tp_t) with
7593 std::vector<thread_info *>.
7594 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
7596 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7598 * record-btrace.c (record_btrace_disable_callback): Remove.
7599 (struct scoped_btrace_disable): New.
7600 (record_btrace_open): Use scoped_btrace_disable.
7602 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7604 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
7605 reading values from registers.
7607 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7609 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
7612 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7614 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
7615 change parameter type. Use GDB's print functions, and use
7616 core_addr_to_string where appropriate.
7617 (riscv_push_dummy_call): Use core_addr_to_string where
7618 appropriate, update call to riscv_print_arg_location, and reindent
7620 (riscv_return_value): Update call to riscv_print_arg_location.
7622 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7623 Tim Newsome <tim@sifive.com>
7624 Albert Ou <a0u@eecs.berkeley.edu>
7625 Darius Rad <darius@bluespec.com>
7627 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
7628 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
7629 (ALLDEPFILES): Add riscv-tdep.c
7630 * configure.tgt: Add riscv support.
7631 * riscv-tdep.c: New file.
7632 * riscv-tdep.h: New file.
7633 * NEWS: Mention new target.
7634 * MAINTAINERS: Add entry for riscv.
7636 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7638 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
7639 fields within aggregates.
7641 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
7643 * record-btrace.c (btrace_print_lines): Change type of flags to
7644 gdb_disassembly_flags.
7646 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7648 * fbsd-nat.c: Include "inf-ptrace.h".
7649 (USE_SIGTRAP_SIGINFO): Conditionally define.
7650 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
7651 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
7652 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
7654 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
7656 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
7658 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
7659 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
7660 "supports_stopped_by_hw_breakpoint" target methods.
7662 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7664 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
7665 * fbsd-nat.c (debug_fbsd_nat): New variable.
7666 (show_fbsd_nat_debug): New function.
7667 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
7668 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
7670 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7672 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
7673 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
7675 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
7676 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
7679 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7681 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
7682 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
7684 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7686 * charset.c (struct charset_vector): New.
7687 (charsets): Change type to charset_vector.
7688 (find_charset_names): Adjust.
7690 (_initialize_charset): Adjust.
7692 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7694 * progspace.h (struct program_space) <deleted_solibs>: Change
7695 type to std::vector<std::string>.
7696 * progspace.c (clear_program_space_solib_cache): Adjust.
7697 * breakpoint.c (print_solib_event): Adjust.
7698 (check_status_catch_solib): Adjust.
7699 * solib.c (update_solib_list): Adjust.
7700 * ui-out.h (class ui_out) <field_string>: New overload.
7701 * ui-out.c (ui_out::field_string): New overload.
7703 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7705 * progspace.h (struct program_space): Add constructor and
7706 destructor, initialize fields.
7707 (add_program_space): Remove.
7708 * progspace.c (add_program_space): Rename to...
7709 (program_space::program_space): ... this.
7710 (release_program_space): Rename to...
7711 (program_space::~program_space): ... this.
7712 (delete_program_space): Use delete to delete program_space.
7713 (initialize_progspace): Use new to allocate program_space.
7714 * inferior.c (add_inferior_with_spaces): Likewise.
7715 (clone_inferior_command): Likewise.
7716 * infrun.c (follow_fork_inferior): Likewise.
7717 (handle_vfork_child_exec_or_exit): Likewise.
7719 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7721 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
7722 (delim_string_to_char_ptr_vec): Return std::vector of
7723 gdb::unique_xmalloc_ptr.
7724 (dirnames_to_char_ptr_vec_append): Take std::vector of
7725 gdb::unique_xmalloc_ptr.
7726 (dirnames_to_char_ptr_vec): Return std::vector of
7727 gdb::unique_xmalloc_ptr.
7728 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
7729 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
7730 (delim_string_to_char_ptr_vec): Return an std::vector of
7731 gdb::unique_xmalloc_ptr, adjust the code.
7732 (dirnames_to_char_ptr_vec_append): Take an std::vector of
7733 gdb::unique_xmalloc_ptr, adjust the code.
7734 (dirnames_to_char_ptr_vec): Return an std::vector of
7735 gdb::unique_xmalloc_ptr, adjust the code.
7736 * auto-load.c (auto_load_safe_path_vec): Change type to
7737 std::vector of gdb::unique_xmalloc_ptr.
7738 (auto_load_expand_dir_vars): Return an std::vector of
7739 gdb::unique_xmalloc_ptr, adjust the code.
7740 (auto_load_safe_path_vec_update): Adjust.
7741 (filename_is_in_auto_load_safe_path_vec): Adjust.
7742 (auto_load_objfile_script_1): Adjust.
7743 * build-id.c (build_id_to_debug_bfd): Adjust.
7744 * linux-thread-db.c (thread_db_load_search): Adjust.
7745 * source.c (add_path): Adjust.
7747 * symfile.c (find_separate_debug_file): Adjust.
7748 * utils.c (do_free_char_ptr_vec): Remove.
7749 (make_cleanup_free_char_ptr_vec): Remove.
7751 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
7754 * common/pathstuff.c: Conditionally include "<windows.h>".
7756 2018-03-01 Georg Sauthoff <mail@georg.so>
7759 * gcore.in: Quote variables and switch interpreter to bash.
7761 2018-03-01 Tom Tromey <tom@tromey.com>
7763 * dwarf2read.c (alloc_discriminant_info): Fix default_index
7764 assertion. Add assertion for discriminant_index.
7765 (quirk_rust_enum): Use correct base type name in univariant case.
7767 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
7769 * record.c (get_call_history_modifiers): Return a
7771 (cmd_record_call_history): Adjust.
7772 * record-btrace.c (record_btrace_call_history): Adjust.
7773 (record_btrace_call_history_range): Adjust.
7774 (record_btrace_call_history_from): Adjust.
7775 * target-debug.h (target_debug_print_record_print_flags): New.
7776 * target-delegates.c: Re-generate.
7777 * target.c (target_call_history): Change flags type.
7778 (target_call_history_from): Likewise.
7779 (target_call_history_range): Likewise.
7780 * target.h (struct target_ops) <target_call_history>: Likewise.
7781 (target_call_history_from): Likewise.
7782 (target_call_history_range): Likewise.
7784 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7785 Simon Marchi <simon.marchi@polymtl.ca>
7787 * common/common-utils.c: Include "sys/stat.h".
7788 (is_regular_file): Move here from "source.c"; change return
7790 * common/common-utils.h (is_regular_file): New prototype.
7791 * common/pathstuff.c (contains_dir_separator): New function.
7792 * common/pathstuff.h (contains_dir_separator): New prototype.
7793 * source.c: Don't include "sys/stat.h".
7794 (is_regular_file): Move to "common/common-utils.c".
7796 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7798 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
7799 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
7800 * auto-load.c: Include "common/pathstuff.h".
7801 * common/common-def.h (current_directory): Move here.
7802 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
7804 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
7806 * common/pathstuff.c: New file.
7807 * common/pathstuff.h: New file.
7808 * compile/compile.c: Include "common/pathstuff.h".
7809 * defs.h (current_directory): Move to "common/common-defs.h".
7810 * dwarf2read.c: Include "common/pathstuff.h".
7812 * guile/scm-safe-call.c: Likewise.
7813 * linux-thread-db.c: Likewise.
7815 * nto-tdep.c: Likewise.
7816 * objfiles.c: Likewise.
7817 * source.c: Likewise.
7818 * symtab.c: Likewise.
7819 * utils.c: Include "common/pathstuff.h".
7820 (gdb_realpath): Move to "common/pathstuff.c".
7821 (gdb_realpath_keepfile): Likewise.
7822 (gdb_abspath): Likewise.
7823 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
7824 (gdb_realpath_keepfile): Likewise.
7825 (gdb_abspath): Likewise.
7827 2018-02-28 John Baldwin <jhb@FreeBSD.org>
7829 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
7830 wildcard process pid for super_resume for kernels with a
7833 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
7835 * compile/compile.c (get_args): Add additional comments
7836 explaining function.
7838 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
7839 Tom Tromey <tom@tromey.com>
7841 * target.h (memory_write_request_s): Remove typedef. Don't define
7843 (target_write_memory_blocks): Change argument to std::vector.
7844 (struct memory_write_request): Add constructor.
7845 * target-memory.c (compare_block_starting_address): Return bool.
7846 Change argument types.
7847 (claim_memory): Change arguments to use std::vector.
7848 (split_regular_and_flash_blocks, blocks_to_erase)
7849 (compute_garbled_blocks): Likewise.
7850 (cleanup_request_data, cleanup_write_requests_vector): Remove.
7851 (target_write_memory_blocks): Change argument to std::vector.
7852 * symfile.c (struct load_section_data): Add constructor and
7853 destructor. Use std::vector for "requests".
7854 (struct load_progress_data): Add initializers.
7855 (load_section_callback): Update. Use "new".
7856 (clear_memory_write_data): Remove.
7857 (generic_load): Update.
7859 2018-02-27 Alan Hayward <alan.hayward@arm.com>
7861 * arch/aarch64.h: Use common/tdesc.h.
7863 2018-02-26 Maciej W. Rozycki <macro@mips.com>
7865 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
7866 architecture with a 64-bit ABI.
7868 2018-02-26 Maciej W. Rozycki <macro@mips.com>
7870 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
7871 ahead of target description loading.
7873 2018-02-26 Tom Tromey <tom@tromey.com>
7875 * stack.c (backtrace_command_1): Update.
7876 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
7878 * python/py-framefilter.c (py_print_frame)
7879 (gdbpy_apply_frame_filter): Change type of "flags".
7880 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
7882 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
7883 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
7884 * extension.h (enum frame_filter_flag): Rename from
7886 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
7887 (apply_ext_lang_frame_filter): Change type of "flags".
7888 * extension.c (apply_ext_lang_frame_filter): Change type of
7890 * extension-priv.h (struct extension_language_ops)
7891 <apply_frame_filter>: Change type of "flags".
7893 2018-02-26 Tom Tromey <tom@tromey.com>
7896 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
7897 off-by-one in py_end computation.
7898 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
7900 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
7903 2018-02-26 Tom Tromey <tom@tromey.com>
7905 * dwarf2read.c (struct variant_field): New.
7906 (struct nextfield) <variant>: New field.
7907 (dwarf2_add_field): Handle DW_TAG_variant_part.
7908 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
7909 discriminated union.
7910 (read_structure_type): Handle DW_TAG_variant_part.
7911 (handle_struct_member_die): New function, extracted from
7912 process_structure_scope. Handle DW_TAG_variant.
7913 (process_structure_scope): Handle discriminated unions. Call
7914 handle_struct_member_die.
7916 2018-02-26 Tom Tromey <tom@tromey.com>
7918 * rust-lang.h (rust_last_path_segment): Declare.
7919 * rust-lang.c (rust_last_path_segment): Now public. Change
7921 (struct disr_info): Remove.
7922 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
7923 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
7924 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
7925 (rust_enum_p, rust_enum_variant): New function.
7926 (rust_underscore_fields): Remove "offset" parameter.
7927 (rust_print_enum): New function.
7928 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
7929 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
7930 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
7932 (rust_internal_print_type): New function, from rust_print_type.
7934 (rust_print_type): Call rust_internal_print_type.
7935 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
7936 Update enum handling.
7937 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
7938 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
7939 (rust_union_quirks): New functions.
7940 (process_full_comp_unit, process_full_type_unit): Call
7942 (process_structure_scope): Update rust_unions if necessary.
7944 2018-02-26 Tom Tromey <tom@tromey.com>
7946 * value.h (value_union_variant): Declare.
7947 * valops.c (value_union_variant): New function.
7948 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
7949 (struct discriminant_info): New.
7950 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
7952 (struct main_type) <flag_discriminated_union>: New field.
7954 2018-02-26 Tom Tromey <tom@tromey.com>
7956 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7957 unittests/unpack-selftests.c.
7958 * unittests/unpack-selftests.c: New file.
7959 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
7961 2018-02-26 Yao Qi <yao.qi@linaro.org>
7963 * dwarf2read.c (struct partial_die_info) <read>: New method.
7964 (read_partial_die): Remove the declaration.
7965 (load_partial_dies): Update.
7966 (partial_die_info::partial_die_info):
7967 (read_partial_die): Change it to partial_die_info::read.
7969 2018-02-26 Yao Qi <yao.qi@linaro.org>
7971 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
7972 (fixup_partial_die): Remove declaration.
7973 (scan_partial_symbols): Update.
7974 (partial_die_parent_scope): Likewise.
7975 (partial_die_full_name): Likewise.
7976 (fixup_partial_die): Change it to partial_die_info::fixup.
7978 2018-02-26 Yao Qi <yao.qi@linaro.org>
7980 * dwarf2read.c (read_partial_die): Update the declaration.
7981 (load_partial_dies): Caller update.
7982 (read_partial_die): Remove one argument abbrev_len.
7984 2018-02-26 Yao Qi <yao.qi@linaro.org>
7986 * dwarf2read.c (struct partial_die_info): Add ctor, delete
7987 assignment operator.
7988 (load_partial_dies): Use ctor and copy ctor.
7989 (read_partial_die): Update.
7990 (dwarf2_cu::find_partial_die): Use ctor.
7992 2018-02-26 Yao Qi <yao.qi@linaro.org>
7994 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
7995 (find_partial_die_in_comp_unit): Change it to
7996 dwarf2_cu::find_partial_die.
7997 (find_partial_die): Update.
7999 2018-02-26 Yao Qi <yao.qi@linaro.org>
8001 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
8004 2018-02-26 Yao Qi <yao.qi@linaro.org>
8006 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
8008 2018-02-26 Alan Hayward <alan.hayward@arm.com>
8010 * arch/amd64.h: Use common/tdesc.h.
8011 * arch/i386.c: Likewise.
8012 * arch/i386.h: Likewise.
8013 * arch/tic6x.c: Likewise.
8014 * arch/tdesc.h: Move file from here...
8015 * common/tdesc.h: ...to here.
8016 * features/aarch64-core.c: Regenerate.
8017 * features/aarch64-fpu.c: Regenerate.
8018 * features/i386/32bit-avx.c: Regenerate.
8019 * features/i386/32bit-avx512.c: Regenerate.
8020 * features/i386/32bit-core.c: Regenerate.
8021 * features/i386/32bit-linux.c: Regenerate.
8022 * features/i386/32bit-mpx.c: Regenerate.
8023 * features/i386/32bit-pkeys.c: Regenerate.
8024 * features/i386/32bit-sse.c: Regenerate.
8025 * features/i386/64bit-avx.c: Regenerate.
8026 * features/i386/64bit-avx512.c: Regenerate.
8027 * features/i386/64bit-core.c: Regenerate.
8028 * features/i386/64bit-linux.c: Regenerate.
8029 * features/i386/64bit-mpx.c: Regenerate.
8030 * features/i386/64bit-pkeys.c: Regenerate.
8031 * features/i386/64bit-segments.c: Regenerate.
8032 * features/i386/64bit-sse.c: Regenerate.
8033 * features/i386/x32-core.c: Regenerate.
8034 * features/tic6x-c6xp.c: Regenerate.
8035 * features/tic6x-core.c: Regenerate.
8036 * features/tic6x-gp.c: Regenerate.
8037 * target-descriptions.c: Use common/tdesc.h.
8038 * target-descriptions.h: Likewise.
8040 2018-02-24 Tom Tromey <tom@tromey.com>
8042 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
8043 (try_thread_db_load_from_dir, thread_db_load_search): Use
8045 (info_auto_load_libthread_db_compare): Return bool. Change
8047 (info_auto_load_libthread_db): Use std::vector, std::string.
8050 2018-02-24 Tom Tromey <tom@tromey.com>
8052 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
8054 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
8056 * gdbarch.c: Rebuild.
8057 * gdbarch.h: Rebuild.
8058 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
8059 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
8060 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
8063 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
8065 * gdbtypes.h (sect_offset): Change type to uint64_t.
8066 (sect_offset_str): New function.
8067 * dwarf2read.c (create_addrmap_from_aranges): Use
8069 (error_check_comp_unit_head): Likewise.
8070 (create_debug_type_hash_table): Likewise.
8071 (read_cutu_die_from_dwo): Likewise.
8072 (init_cutu_and_read_dies): Likewise.
8073 (init_cutu_and_read_dies_no_follow): Likewise.
8074 (process_psymtab_comp_unit_reader): Likewise.
8075 (partial_die_parent_scope): Likewise.
8076 (peek_die_abbrev): Likewise.
8077 (process_queue): Likewise.
8078 (dwarf2_physname): Likewise.
8079 (read_namespace_alias): Likewise.
8080 (read_import_statement): Likewise.
8081 (create_dwo_cu_reader): Likewise.
8082 (create_cus_hash_table): Likewise.
8083 (lookup_dwo_cutu): Likewise.
8084 (inherit_abstract_dies): Likewise.
8085 (read_func_scope): Likewise.
8086 (read_call_site_scope): Likewise.
8087 (dwarf2_add_member_fn): Likewise.
8088 (read_common_block): Likewise.
8089 (read_module_type): Likewise.
8090 (read_typedef): Likewise.
8091 (read_subrange_type): Likewise.
8092 (load_partial_dies): Likewise.
8093 (read_partial_die): Likewise.
8094 (find_partial_die): Likewise.
8095 (read_str_index): Likewise.
8096 (dwarf2_string_attr): Likewise.
8097 (build_error_marker_type): Likewise.
8098 (lookup_die_type): Likewise.
8099 (dump_die_shallow): Likewise.
8100 (follow_die_ref): Likewise.
8101 (dwarf2_fetch_die_loc_sect_off): Likewise.
8102 (dwarf2_fetch_constant_bytes): Likewise.
8103 (follow_die_sig): Likewise.
8104 (get_signatured_type): Likewise.
8105 (get_DW_AT_signature_type): Likewise.
8106 (dwarf2_find_containing_comp_unit): Likewise.
8107 (set_die_type): Likewise.
8109 2018-02-21 John Baldwin <jhb@FreeBSD.org>
8111 * arch/aarch64.c: Include "common-defs.h".
8112 * arch/amd64.c: Likewise.
8113 * arch/i386.c: Likewise.
8115 2018-02-21 Tom Tromey <tom@tromey.com>
8117 * value.h: (extract_field_op): Update.
8118 * eval.c (extract_field_op): Return a const char *.
8119 * expression.h (parse_expression_for_completion): Update.
8120 * completer.c (complete_expression): Update.
8121 (add_struct_fields): Make fieldname const.
8122 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
8123 (mark_completion_tag, parse_exp_in_context_1): Update.
8124 (parse_expression_for_completion): Change "name" to
8125 unique_xmalloc_ptr*.
8127 2018-02-21 Tom Tromey <tom@tromey.com>
8129 * infcall.c (call_function_by_hand_dummy): Use std::vector.
8131 2018-02-21 Yao Qi <yao.qi@linaro.org>
8133 * avr-tdep.c (avr_read_pc): Change parameter type to
8135 * gdbarch.sh (read_pc): Likewise.
8136 * gdbarch.c: Re-generated.
8137 * gdbarch.h: Re-generated.
8138 * hppa-tdep.c (hppa_read_pc): Change parameter type to
8140 * ia64-tdep.c (ia64_read_pc): Likewise.
8141 * mips-tdep.c (mips_read_pc): Likewise.
8142 * spu-tdep.c (spu_read_pc): Likewise.
8144 2018-02-21 Yao Qi <yao.qi@linaro.org>
8146 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
8147 * regcache-dump.c: New file.
8148 * regcache.c: Move register_dump to regcache-dump.c.
8149 (maintenance_print_registers): Likewise.
8150 (maintenance_print_raw_registers): Likewise.
8151 (maintenance_print_cooked_registers): Likewise.
8152 (maintenance_print_register_groups): Likewise.
8153 (maintenance_print_remote_registers): Likewise.
8154 (_initialize_regcache): Likewise.
8155 * regcache.h (register_dump): Moved from regcache.c.
8157 2018-02-21 Yao Qi <yao.qi@linaro.org>
8159 * regcache.c (regcache::regcache): Update.
8160 (regcache::invalidate): Move it to detached_regcache::invalidate.
8161 (get_thread_arch_aspace_regcache): Update.
8162 (regcache::raw_update): Update.
8163 (regcache::cooked_read): Remove some code.
8164 (regcache::cooked_read_value): Likewise.
8165 (regcache::raw_write): Remove assert on m_readonly_p.
8166 (regcache::raw_supply_integer): Move it to
8167 detached_regcache::raw_supply_integer.
8168 (regcache::raw_supply_zeroed): Likewise.
8169 * regcache.h (detached_regcache) <raw_supply_integer>: New
8171 <raw_supply_zeroed, invalidate>: Likewise.
8172 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
8173 <invalidate>: Likewise.
8174 <m_readonly_p>: Removed.
8176 2018-02-21 Yao Qi <yao.qi@linaro.org>
8178 * infcmd.c (get_return_value): Let stop_regs point to
8179 get_current_regcache.
8180 * regcache.c (regcache::regcache): Remove.
8181 (register_dump_reg_buffer): New class.
8182 (regcache_print): Adjust.
8183 * regcache.h (regcache): Remove constructors.
8185 2018-02-21 Yao Qi <yao.qi@linaro.org>
8187 * regcache.c (class register_dump): New class.
8188 (register_dump_regcache, register_dump_none): New class.
8189 (register_dump_remote, register_dump_groups): New class.
8190 (regcache_print): Update.
8191 * regcache.h (regcache_dump_what): Move it to regcache.c.
8192 (regcache) <dump>: Remove.
8194 2018-02-21 Yao Qi <yao.qi@linaro.org>
8196 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
8198 (jit_unwind_reg_set_impl): Call raw_supply.
8199 (jit_frame_sniffer): Use reg_buffer_rw.
8200 * record-full.c (record_full_core_regbuf): Change its type.
8201 (record_full_core_open_1): Use reg_buffer_rw.
8202 (record_full_close): Likewise.
8203 (record_full_core_fetch_registers): Use regcache->raw_supply.
8204 (record_full_core_store_registers): Likewise.
8205 * regcache.c (regcache::get_register_status): Move it to
8207 (regcache_raw_set_cached_value): Remove.
8208 (regcache::raw_set_cached_value): Remove.
8209 (regcache::raw_write): Call raw_supply.
8210 (regcache::raw_supply): Move it to reg_buffer_rw.
8211 * regcache.h (regcache_raw_set_cached_value): Remove.
8212 (reg_buffer_rw): New class.
8214 2018-02-21 Yao Qi <yao.qi@linaro.org>
8216 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
8217 readonly_detached_regcache.
8218 (dummy_frame_prev_register): Use regcache->cooked_read.
8219 * frame.c (frame_save_as_regcache): Change return type.
8220 (frame_pop): Update.
8221 * frame.h (frame_save_as_regcache): Update declaration.
8222 * inferior.h (get_infcall_suspend_state_regcache): Update
8224 * infrun.c (infcall_suspend_state) <registers>: use
8225 readonly_detached_regcache.
8226 (save_infcall_suspend_state): Don't use regcache_dup.
8227 (get_infcall_suspend_state_regcache): Change return type.
8228 * linux-fork.c (struct fork_info) <savedregs>: Change to
8229 readonly_detached_regcache.
8231 (fork_save_infrun_state): Don't use regcache_dup.
8232 (info_checkpoints_command): Adjust.
8233 * mi/mi-main.c (register_changed_p): Update declaration.
8234 (mi_cmd_data_list_changed_registers): Use
8235 readonly_detached_regcache.
8236 (register_changed_p): Change parameter type to
8237 readonly_detached_regcache.
8238 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
8239 readonly_detached_regcache.
8240 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
8241 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
8243 (regcache::save): Move it to reg_buffer.
8244 (regcache::restore): Change parameter type.
8245 (regcache_dup): Remove.
8246 * regcache.h (reg_buffer) <save>: New method.
8247 (readonly_detached_regcache): New class.
8248 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
8249 readonly_detached_regcache.
8250 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
8252 2018-02-21 Yao Qi <yao.qi@linaro.org>
8254 * frame.c (frame_save_as_regcache): Use regcache method save.
8255 (frame_pop): Use regcache method restore.
8256 * infrun.c (restore_infcall_suspend_state): Likewise.
8257 * linux-fork.c (fork_load_infrun_state): Likewise.
8258 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
8260 * regcache.c (regcache_save): Remove.
8261 (regcache::restore): More asserts.
8262 (regcache_cpy): Remove.
8263 * regcache.h (regcache_save): Remove the declaration.
8264 (regcache::restore): Move from private to public.
8265 Remove the friend declaration of regcache_cpy.
8266 (regcache_cpy): Remove declaration.
8268 2018-02-21 Yao Qi <yao.qi@linaro.org>
8270 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
8271 parameter type to 'readable_regcache *'.
8272 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
8273 * arm-tdep.c (arm_neon_quad_read): Likewise.
8274 (arm_pseudo_read): Likewise.
8275 * avr-tdep.c (avr_pseudo_register_read): Likewise.
8276 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
8277 * frv-tdep.c (frv_pseudo_register_read): Likewise.
8278 * gdbarch.c: Re-generated.
8279 * gdbarch.h: Re-generated.
8280 * gdbarch.sh (pseudo_register_read): Change parameter type to
8281 'readable_regcache *'.
8282 (pseudo_register_read_value): Likewise.
8283 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
8284 (h8300_pseudo_register_read): Likewise.
8285 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
8286 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
8287 (i386_pseudo_register_read_into_value): Likewise.
8288 (i386_pseudo_register_read_value): Likewise.
8289 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
8291 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
8292 * m32c-tdep.c (m32c_raw_read): Likewise.
8293 (m32c_read_flg): Likewise.
8294 (m32c_banked_register): Likewise.
8295 (m32c_banked_read): Likewise.
8296 (m32c_sb_read): Likewise.
8297 (m32c_part_read): Likewise.
8298 (m32c_cat_read): Likewise.
8299 (m32c_r3r2r1r0_read): Likewise.
8300 (m32c_pseudo_register_read): Likewise.
8301 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
8302 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
8303 (mep_pseudo_cr64_read): Likewise.
8304 (mep_pseudo_register_read): Likewise.
8305 * mips-tdep.c (mips_pseudo_register_read): Likewise.
8306 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
8307 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
8308 * regcache.c (regcache::raw_read): Move it to readable_regcache.
8309 (regcache::cooked_read): Likewise.
8310 (regcache::cooked_read_value): Likewise.
8311 (regcache_cooked_read_signed):
8312 (regcache::cooked_read): Likewise.
8313 * regcache.h (readable_regcache): New class.
8314 (regcache): Inherit readable_regcache. Move some methods to
8316 * rl78-tdep.c (rl78_pseudo_register_read): Change
8317 parameter type to 'readable_regcache *'.
8318 * rs6000-tdep.c (do_regcache_raw_read): Remove.
8319 (e500_pseudo_register_read): Change parameter type to
8320 'readable_regcache *'.
8321 (dfp_pseudo_register_read): Likewise.
8322 (vsx_pseudo_register_read): Likewise.
8323 (efpr_pseudo_register_read): Likewise.
8324 * s390-tdep.c (s390_pseudo_register_read): Likewise.
8325 * sh-tdep.c (sh_pseudo_register_read): Likewise.
8326 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
8327 (sh64_pseudo_register_read): Likewise.
8328 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
8329 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
8330 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
8331 (spu_pseudo_register_read): Likewise.
8332 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
8333 (xtensa_pseudo_register_read): Likewise.
8335 2018-02-21 Yao Qi <yao.qi@linaro.org>
8337 * regcache.c (regcache::regcache): Call reg_buffer ctor.
8338 (regcache::arch): Move it to reg_buffer::arch.
8339 (regcache::register_buffer): Likewise.
8340 (regcache::assert_regnum): Likewise.
8341 (regcache::num_raw_registers): Likewise.
8342 * regcache.h (reg_buffer): New class.
8343 (regcache): Inherit reg_buffer.
8345 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
8347 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
8348 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
8350 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
8352 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
8354 2018-02-19 Alan Hayward <alan.hayward@arm.com>
8356 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
8357 (SFILES): Remove common/*.c files.
8358 (COMMON_OBS): Remove some *.o files built from common/*.c files.
8359 * common/common.host: Add common reference.
8360 * configure.ac: Likewise.
8361 * configure: Regenerate.
8363 2018-02-16 Yao Qi <yao.qi@linaro.org>
8365 * block.c (block_namespace_info): Inherit allocate_on_obstack.
8366 (block_initialize_namespace): Use new.
8367 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
8368 (dwarf2_free_objfile): Use delete.
8369 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
8370 (copy_type_recursive): Use new.
8371 * gdb_obstack.h (allocate_on_obstack): New.
8373 2018-02-15 Yao Qi <yao.qi@linaro.org>
8376 * inferior.c (exit_inferior_1): Reset inf->control.
8378 2018-02-15 Joel Brobecker <brobecker@adacore.com>
8380 * ada-lang.c (ada_to_fixed_value_create): Delete advance
8383 2018-02-14 Pedro Alves <palves@redhat.com>
8385 * frame-unwind.c (frame_unwind_try_unwinder): Always call
8386 frame_cleanup_after_sniffer on exception.
8388 2018-02-14 Tom Tromey <tom@tromey.com>
8390 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
8392 (solib_bfd_open): Make pathname const.
8393 * solib.c (solib_bfd_open): Make pathname const.
8394 * solib-spu.c (spu_bfd_fopen): Make name const.
8395 (spu_bfd_open): Make pathname const.
8396 * solib-darwin.c (darwin_bfd_open): Make pathname const.
8397 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
8399 2018-02-14 Tom Tromey <tom@tromey.com>
8401 * symfile.c (symfile_bfd_open): Update.
8402 * source.h (openp, source_full_path_of, find_and_open_source):
8403 Change argument type to unique_xmalloc_ptr.
8404 * source.c (openp): Take a unique_xmalloc_ptr.
8405 (source_full_path_of, find_and_open_source): Likewise.
8406 (open_source_file, symtab_to_fullname): Update.
8407 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
8409 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
8410 (exec_file_find): Update.
8411 * psymtab.c (psymtab_to_fullname): Update.
8412 * nto-tdep.h (nto_find_and_open_solib): Update.
8413 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
8415 * exec.c (exec_file_attach): Update.
8416 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
8417 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
8419 2018-02-14 Tom Tromey <tom@tromey.com>
8421 * solib.c: Include source.h.
8422 * nto-tdep.c: Include source.h.
8423 * mi/mi-cmd-env.c: Include source.h.
8424 * infcmd.c: Include source.h.
8425 * exec.c: Include source.h.
8426 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
8427 (add_path, directory_switch, source_path, init_source_path): Move
8429 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
8430 (add_path, directory_switch, source_path, init_source_path):
8433 2018-02-14 Tom Tromey <tom@tromey.com>
8435 * solist.h (exec_file_find, solib_find): Return
8437 (solib_bfd_fopen): Take a const char *.
8438 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
8439 (exec_file_find, solib_find): Likewise.
8440 (solib_bfd_fopen): Do not take ownership of "pathname".
8441 (solib_bfd_open): Use unique_xmalloc_ptr.
8442 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
8443 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
8444 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
8445 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
8447 2018-02-14 Joel Brobecker <brobecker@adacore.com>
8449 * ada-lang.c (name_match_type_from_name): Remove reference to
8450 ada_name_for_lookup in function's documentation.
8451 * ada-lang.h (ada_name_for_lookup): Delete declaration.
8453 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8455 * defs.h (enum openp_flags): New enum.
8456 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
8457 Move to enum openp_flags.
8458 (openp_flags): New enum flags.
8459 (openp): Change parameter type to openp_flags.
8460 * source.c (openp): Change parameter type to openp_flags.
8461 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
8462 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
8464 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8466 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
8469 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
8471 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
8473 (class dwarf2_queue_guard): ...the destructor of this new class.
8474 (dw2_do_instantiate_symtab): Create instance of the new class
8475 dwarf2_queue_guard, remove cleanup.
8477 2018-02-09 Tom Tromey <tom@tromey.com>
8479 * source.c (find_source_lines): Don't reference past the end of
8482 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8484 * remote.c (remote_btrace_maybe_reopen): Change error message.
8485 * btrace.c (btrace_enable): Likewise.
8486 (parse_xml_btrace): Likewise.
8487 (parse_xml_btrace_conf): Likewise.
8489 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8491 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
8492 (linux_enable_pt, linux_enable_bts): Call
8493 diagnose_perf_event_open_fail.
8495 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8497 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
8498 Remove parameter and change return type. Update callers. Move it.
8499 (linux_enable_bts, linux_enable_pt): Improve error message.
8500 (linux_enable_pt): Remove zero buffer size check.
8501 (linux_enable_btrace): Improve error messages. Remove NULL return
8504 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8506 * btrace.c (btrace_enable): Remove target_supports_btrace call.
8507 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
8508 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
8509 (linux_supports_pt, linux_supports_btrace): Remove.
8510 (linux_enable_bts): Call cpu_supports_bts.
8511 * nat/linux-btrace.h (linux_supports_btrace): Remove.
8512 * remote.c (remote_supports_btrace): Remove.
8513 (init_remote_ops): Remove remote_supports_btrace.
8514 * target-delegates.c: Regenerated.
8515 * target.c (target_supports_btrace): Remove.
8516 * target.h (target_ops) <to_supports_btrace>: Remove
8517 (target_supports_btrace): Remove.
8518 * x86-linux-nat.c (x86_linux_create_target): Remove
8519 linux_supports_btrace.
8521 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8523 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
8525 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
8526 exception and use message in own exception.
8528 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8530 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
8531 (perf_event_pt_event_type): Use gdb_file_up.
8532 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
8533 scoped_fd, and scoped_mmap.
8535 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8537 * common/scoped_mmap.h: New.
8538 * unittests/scoped_mmap-selftest.c: New.
8539 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8540 unittests/scoped_mmap-selftest.c.
8542 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8544 * common/scoped_fd.h: New.
8545 * unittests/scoped_fd-selftest.c: New.
8546 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8547 unittests/scoped_fd-selftest.c.
8549 2018-02-09 Tom Tromey <tom@tromey.com>
8551 * auto-load.c (auto_load_section_scripts): Use
8552 gdb::unique_xmalloc_ptr.
8554 2018-02-09 Tom Tromey <tom@tromey.com>
8556 * auto-load.c (execute_script_contents): Use std::string.
8558 2018-02-09 Joel Brobecker <brobecker@adacore.com>
8560 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
8561 Python function, rather than a new command.
8563 2018-02-08 Tom Tromey <tom@tromey.com>
8565 * solib.c (solib_find_1): Use std::string.
8566 (solib_bfd_fopen): Use unique_xmalloc_ptr.
8568 2018-02-08 Tom Tromey <tom@tromey.com>
8570 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
8572 2018-02-08 Tom Tromey <tom@tromey.com>
8574 * source.c (find_source_lines): Use gdb::def_vector.
8576 2018-02-08 Tom Tromey <tom@tromey.com>
8578 * macrocmd.c (struct temporary_macro_definition): New.
8579 (macro_define_command): Use temporary_macro_definition. Remove
8581 (free_macro_definition_ptr): Remove.
8583 2018-02-08 Tom Tromey <tom@tromey.com>
8585 * macroexp.c (maybe_expand): Use std::string.
8587 2018-02-08 Tom Tromey <tom@tromey.com>
8589 * macroexp.c (struct macro_buffer): Add initializers for some
8591 (init_buffer, init_shared_buffer, free_buffer)
8592 (free_buffer_return_text): Remove.
8593 (macro_buffer): New constructors.
8594 (~macro_buffer): New destructor.
8595 (macro_buffer::set_shared): New method.
8596 (macro_buffer::resize_buffer, macro_buffer::appendc)
8597 (macro_buffer::appendmem): Now methods, not free functions.
8598 (set_token, append_tokens_without_splicing, stringify)
8599 (macro_stringify): Update.
8600 (gather_arguments): Change return type. Remove argc_p argument,
8601 add args_ptr argument. Use std::vector.
8602 (substitute_args): Remove argc argument. Accept std::vector.
8603 (expand): Update. Use std::vector.
8604 (scan, macro_expand, macro_expand_next): Update.
8606 2018-02-08 Tom Tromey <tom@tromey.com>
8608 * symtab.c (default_collect_symbol_completion_matches_break_on):
8609 Use unique_xmalloc_ptr.
8610 * macroscope.h: (sal_macro_scope, user_macro_scope)
8611 (default_macro_scope): Return unique_xmalloc_ptr.
8612 * macroscope.c (sal_macro_scope, user_macro_scope)
8613 (default_macro_scope): Return unique_xmalloc_ptr.
8614 * macroexp.h (macro_expand, macro_expand_once): Return
8616 * macroexp.c (macro_expand, macro_expand_once): Return
8618 * macrocmd.c (macro_expand_command, macro_expand_once_command)
8619 (info_macro_command, info_macros_command): Use
8621 * compile/compile-c-support.c (write_macro_definitions): Use
8623 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
8625 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
8627 * value.c (value_static_field): Assign field type instead of
8628 containing type when returning an optimized out value.
8630 2018-02-06 Yao Qi <yao.qi@linaro.org>
8632 * ft32-tdep.c (ft32_read_pc): Remove.
8633 (ft32_write_pc): Remove.
8634 (ft32_gdbarch_init): Update.
8635 * m32r-tdep.c (m32r_read_pc): Remove.
8636 (m32r_gdbarch_init): Update.
8637 * mep-tdep.c (mep_read_pc): Remove.
8638 (mep_gdbarch_init): Update.
8639 * microblaze-tdep.c (microblaze_write_pc): Remove.
8640 (microblaze_gdbarch_init): Update.
8641 * mn10300-tdep.c (mn10300_read_pc): Remove.
8642 (mn10300_write_pc): Remove.
8643 (mn10300_gdbarch_init): Update.
8644 * moxie-tdep.c (moxie_read_pc): Remove.
8645 (moxie_write_pc): Remove.
8646 (moxie_gdbarch_init): Update.
8648 2018-02-06 Yao Qi <yao.qi@linaro.org>
8650 * expprint.c (print_subexp_standard): Handle
8651 OP_F77_UNDETERMINED_ARGLIST.
8652 (dump_subexp_body_standard): Likewise.
8654 2018-02-05 Alan Hayward <alan.hayward@arm.com>
8656 * target-descriptions.c (tdesc_element_visitor) Add empty
8658 (tdesc_type): Move make_gdb_type from here.
8659 (tdesc_type_builtin): Likewise.
8660 (tdesc_type_vector): Likewise.
8661 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
8662 (make_gdb_type_struct): Move from tdesc_type_with_fields.
8663 (make_gdb_type_union): Likewise.
8664 (make_gdb_type_flags): Likewise.
8665 (make_gdb_type_enum): Likewise.
8666 (make_gdb_type): New function.
8667 (tdesc_register_type): Use static make_gdb_type.
8669 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
8671 * infcmd.c (default_print_one_register_info): Align natural-format
8672 column values consistently one under another.
8673 (pad_to_column): New function.
8675 2018-02-05 Joel Brobecker <brobecker@adacore.com>
8677 * dwarf2read.c (dwarf2_physname): Move commment.
8679 2018-02-01 Leszek Swirski <leszeks@google.com>
8681 * varobj.c (varobj_formatted_print_options): Allow recursive
8682 pretty printing if pretty printing is enabled.
8684 2018-02-01 Leszek Swirski <leszeks@google.com>
8686 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
8687 names after a structop as a filename.
8689 2018-02-01 Yao Qi <yao.qi@linaro.org>
8691 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
8692 (arm_record_coproc_data_proc): Likewise.
8694 2018-02-01 Yao Qi <yao.qi@linaro.org>
8696 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
8698 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
8700 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
8701 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
8703 2018-01-31 Pedro Alves <palves@redhat.com>
8705 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
8706 * inflow.c (child_terminal_save_inferior): Wrap reference to
8707 tcgetpgrp in HAVE_TERMIOS_H.
8708 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
8710 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
8711 always iterate over all inferiors.
8712 (gdbsim_cntrl_c): Adjust.
8713 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
8715 2018-01-31 Joel Brobecker <brobecker@adacore.com>
8717 * gdbtypes.c (lookup_array_range_type): Make sure the array's
8718 index type is objfile-owned if the element type is as well.
8720 2018-01-31 Joel Brobecker <brobecker@adacore.com>
8724 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
8726 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
8727 "features/s390x-linux64.c".
8728 (_initialize_s390_linux_tdep): Remove initialization of tdescs
8729 s390_linux32 and s390x_linux64.
8730 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
8732 * s390-tdep.c: Include "features/s390-linux32.c" and
8733 "features/s390x-linux64.c".
8734 (s390_tdesc_valid): Add check for tdesc_has_registers.
8735 (s390_gdbarch_init): Make sure there is always a valid tdesc.
8736 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
8737 tdesc_s390x_linux64.
8738 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
8739 tdesc_s390x_linux64 to...
8740 * s390-tdep.h: ...here.
8742 2018-01-30 Pedro Alves <palves@redhat.com>
8745 * config.in, configure: Regenerate.
8746 * configure.ac: Check for getpgid.
8747 * go32-nat.c (go32_pass_ctrlc): New.
8748 (go32_target): Install it.
8749 * inf-child.c (inf_child_target): Install
8750 child_terminal_save_inferior, child_pass_ctrlc and
8752 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
8753 (inf_ptrace_target): No longer install it.
8754 * infcmd.c (interrupt_target_1): Adjust.
8755 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
8756 (child_interrupt): Declare.
8757 (inferior::terminal_state): New.
8758 * inflow.c (struct terminal_info): Update comments.
8759 (inferior_process_group): Delete.
8760 (terminal_is_ours): Delete.
8761 (gdb_tty_state): New.
8762 (child_terminal_init): Adjust.
8763 (is_gdb_terminal, sharing_input_terminal_1)
8764 (sharing_input_terminal): New functions.
8765 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
8766 Set the process's actual process group in the foreground if
8767 possible. Handle is_ours_for_output/is_ours distinction. Don't
8768 mark terminal as the inferior's if not sharing GDB's terminal.
8769 Don't check attach_flag.
8770 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
8771 pass down a target_terminal_state.
8772 (child_terminal_save_inferior): New, factored out from ...
8773 (child_terminal_ours_1): ... this. Handle
8774 target_terminal_state::is_ours_for_output.
8775 (child_interrupt, child_pass_ctrlc): New.
8776 (inflow_inferior_exit): Clear the inferior's terminal_state.
8777 (copy_terminal_info): Copy the inferior's terminal state.
8778 (_initialize_inflow): Remove reference to terminal_is_ours.
8779 * inflow.h (inferior_process_group): Delete.
8780 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
8781 * procfs.c (procfs_target): Don't install procfs_interrupt.
8782 (procfs_interrupt): Delete.
8783 * remote.c (remote_serial_quit_handler): Adjust.
8784 (remote_interrupt): Remove ptid parameter. Adjust.
8785 * target-delegates.c: Regenerate.
8786 * target.c: Include "terminal.h".
8787 (target_terminal::terminal_state): Rename to ...
8788 (target_terminal::m_terminal_state): ... this.
8789 (target_terminal::init): Adjust.
8790 (target_terminal::inferior): Adjust to per-inferior
8792 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
8793 (target_terminal::ours, target_terminal::ours_for_output): Use
8794 target_terminal_is_ours_kind.
8795 (target_interrupt): Remove ptid parameter. Adjust.
8796 (default_target_pass_ctrlc): Adjust.
8797 * target.h (target_ops::to_terminal_save_inferior): New field.
8798 (target_ops::to_interrupt): Remove ptid_t parameter.
8799 (target_interrupt): Remove ptid_t parameter. Update comment.
8800 (target_pass_ctrlc): Update comment.
8801 * target/target.h (target_terminal_state): New scoped enum,
8803 (target_terminal::terminal_state): ... here.
8804 (target_terminal::inferior): Update comments.
8805 (target_terminal::restore_inferior): New.
8806 (target_terminal::is_inferior, target_terminal::is_ours)
8807 (target_terminal::is_ours_for_output): Adjust.
8808 (target_terminal::scoped_restore_terminal_state): Adjust to
8809 rename, and call restore_inferior() instead of inferior().
8810 (target_terminal::scoped_restore_terminal_state::m_state): Change
8812 (target_terminal::terminal_state): Rename to ...
8813 (target_terminal::m_terminal_state): ... this and change type.
8815 2018-01-30 Pedro Alves <palves@redhat.com>
8817 * linux-nat.c (wait_for_signal): New function.
8818 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
8820 (async_terminal_is_ours)
8821 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
8822 (linux_nat_add_target): Don't override
8823 to_terminal_inferior/to_terminal_ours.
8825 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
8827 * remote.c (remote_follow_fork): Don't call "detach_inferior".
8829 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
8831 * dwarf2read.c (free_dwo_files): Add forward-declaration.
8832 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
8833 dwarf2_per_objfile_free here.
8834 (dwarf2_per_objfile_free): Remove.
8835 (_initialize_dwarf2_read): Don't register
8836 dwarf2_per_objfile_free as a registry cleanup.
8838 2018-01-27 Eli Zaretskii <eliz@gnu.org>
8840 Avoid compilation errors in MinGW native builds
8842 The error is triggered by including python-internal.h, and the
8845 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
8846 from build-gnulib/import/math.h:27,
8847 from d:/usr/Python26/include/pyport.h:235,
8848 from d:/usr/Python26/include/Python.h:58,
8849 from python/python-internal.h:94,
8850 from python/py-arch.c:24:
8851 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
8855 This happens because Python headers define 'hypot' to expand t
8856 '_hypot' in the Windows builds.
8857 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
8858 'hypoth'. This avoids a compilation error.
8860 2018-01-26 Alan Hayward <alan.hayward@arm.com>
8862 * MAINTAINERS (Write After Approval): Fix ordering.
8864 2018-01-26 Alan Hayward <alan.hayward@arm.com>
8866 * MAINTAINERS (Write After Approval): Add Alan Hayward.
8868 2018-01-26 Alan Modra <amodra@gmail.com>
8870 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
8871 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
8872 Remove nop. Make const. Comment.
8873 (powerpc32_plt_stub_so_2): New.
8874 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
8875 Correct count. Update uses.
8876 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
8877 Move common code reading PLT entry word. Correct
8878 powerpc32_plt_stub PLT address calculation.
8879 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
8880 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
8881 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
8882 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
8883 (ppc64_standard_linkage8): Likewise.
8884 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
8885 Correct insns description.
8886 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
8888 2018-01-24 Pedro Alves <palves@redhat.com>
8890 GCC PR libstdc++/83906
8891 * gdbtypes.c (operator==(const dynamic_prop &,
8892 const dynamic_prop &)): New.
8893 (operator==(const range_bounds &, const range_bounds &)): New.
8894 (check_types_equal): Use them instead of memcmp.
8895 * gdbtypes.h (operator==(const dynamic_prop &,
8896 const dynamic_prop &)): Declare.
8897 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
8898 (operator==(const range_bounds &, const range_bounds &)): Declare.
8899 (operator!=(const range_bounds &, const range_bounds &)): Declare.
8901 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8903 * s390-linux-tdep.c (s390_record_address_mask)
8904 (s390_record_calc_disp_common, s390_record_calc_disp)
8905 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8906 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8907 (s390_process_record): Move to s390-tdep.c.
8908 (s390_linux_init_abi_any): Adjust.
8909 * s390-tdep.c (s390_record_address_mask)
8910 (s390_record_calc_disp_common, s390_record_calc_disp)
8911 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8912 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8913 (s390_process_record): Moved from s390-linux-tdep.c
8914 (s390_gdbarch_init): Adjust.
8916 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8918 * s390-linux-nat.c (s390-tdep.h): New include.
8919 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
8920 (HFILES_NO_SRCDIR): Add s390-tdep.h.
8921 (ALLDEPFILES): Add s390-tdep.c.
8922 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
8923 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
8924 * s390-tdep.h: ...this. New file.
8925 * s390-linux-tdep.c (s390-tdep.h): New include.
8926 (_initialize_s390_tdep): Rename to...
8927 (_initialize_s390_linux_tdep): ...this and adjust.
8928 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
8929 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
8931 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
8932 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
8933 (s390_is_partial_instruction, s390_software_single_step)
8934 (is_non_branch_ril, s390_displaced_step_copy_insn)
8935 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
8936 (s390_prologue_data, s390_addr, s390_store, s390_load)
8937 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
8938 (s390_register_call_saved, s390_guess_tracepoint_registers)
8939 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
8940 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
8941 (s390_pseudo_register_name, s390_pseudo_register_type)
8942 (s390_pseudo_register_read, s390_pseudo_register_write)
8943 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
8944 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
8945 (s390_addr_bits_remove, s390_address_class_type_flags)
8946 (s390_address_class_type_flags_to_name)
8947 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
8948 (s390_function_arg_float, s390_function_arg_vector)
8949 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
8950 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
8951 (s390_frame_align, s390_register_return_value, s390_return_value)
8952 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
8953 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
8954 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
8955 (s390_trad_frame_prev_register, s390_unwind_cache)
8956 (s390_prologue_frame_unwind_cache)
8957 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
8958 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
8959 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
8960 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
8961 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
8962 (s390_frame_base_address, s390_local_base_address)
8963 (s390_frame_base, s390_gcc_target_options)
8964 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
8965 (s390_validate_reg_range, s390_tdesc_valid)
8966 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
8967 * s390-tdep.c: ...this. New file.
8969 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8971 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
8972 (s390_process_record, s390_gdbarch_tdep_alloc)
8973 (s390_linux_init_abi_any): Use/set new hook.
8975 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8977 * s390-linux-tdep.c (osabi.h): New include.
8978 (s390_linux_init_abi_31, s390_linux_init_abi_64)
8979 (s390_linux_init_abi_any): New functions.
8980 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
8982 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8984 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
8985 tdesc_has_registers check
8987 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8989 * s390-linux-tdep.c (s390_tdesc_valid): New function.
8990 (s390_validate_reg_range): New macro.
8991 (s390_gdbarch_init): Adjust.
8993 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8995 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
8996 (s390_gdbarch_tdep_alloc): Adjust.
8997 (s390_gdbarch_init): Adjust.
8999 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9001 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
9002 <have_tdb>: Change type to bool.
9003 (s390_gdbarch_tdep_alloc): Adjust.
9004 (s390_gdbarch_init): Adjust.
9006 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9008 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
9009 (gdbarch_tdep) <have_upper, have_vx>: New fields.
9010 (s390_gdbarch_tdep_alloc): New function.
9011 (s390_gdbarch_init): Allocate tdep at start and use its fields
9012 instead of separate variables.
9014 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9016 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
9017 when looking for cached gdbarch and add comment for remaining.
9019 2018-01-22 Pedro Alves <palves@redhat.com>
9020 Sergio Durigan Junior <sergiodj@redhat.com>
9022 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
9025 2018-01-22 Maciej W. Rozycki <macro@mips.com>
9027 * MAINTAINERS: Update my company e-mail address.
9029 2018-01-22 Yao Qi <yao.qi@linaro.org>
9031 * regcache.c (cooked_write_test): New function.
9032 (_initialize_regcache): Register the test.
9034 2018-01-22 Yao Qi <yao.qi@linaro.org>
9036 * ia64-tdep.c (ia64_pseudo_register_read): Call
9037 regcache->cooked_read instead of regcache_cooked_read_unsigned.
9038 * m32c-tdep.c (m32c_cat_read): Likewise.
9039 (m32c_r3r2r1r0_read): Likewise.
9040 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9041 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9043 2018-01-22 Yao Qi <yao.qi@linaro.org>
9045 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
9046 method raw_read instead of regcache_raw_read.
9047 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9048 * arm-tdep.c (arm_neon_quad_read): Likewise.
9049 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9050 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9051 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9052 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
9053 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9054 (i386_pseudo_register_read_into_value): Likewise.
9055 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9056 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9057 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9058 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
9059 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
9060 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9061 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9062 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9063 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
9065 2018-01-22 Yao Qi <yao.qi@linaro.org>
9067 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
9068 * configure.tgt: Remove target mt.
9069 * mt-tdep.c: Remove.
9070 * regcache.c (cooked_read_test): Remove the check for mt.
9072 2018-01-22 Yao Qi <yao.qi@linaro.org>
9074 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
9075 instead of gdbarch_pseudo_register_read_value.
9077 2018-01-22 Joel Brobecker <brobecker@adacore.com>
9079 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
9082 2018-01-22 Joel Brobecker <brobecker@adacore.com>
9084 * linespec.c (create_sals_line_offset): Remove code that preserved
9085 the symtab_and_line's line number.
9087 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9089 * varobj.c (varobj_create): Don't set valid_block when creating a
9092 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9094 * varobj.c (varobj_create): Remove out of date comment.
9096 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9099 * ada-exp.y (write_var_from_sym): Pass extra parameter when
9100 updating innermost block.
9101 * parse.c (innermost_block_tracker::update): Take extra type
9102 parameter, and check types match before updating innermost block.
9103 (write_dollar_variable): Update innermost block for registers.
9104 * parser-defs.h (enum innermost_block_tracker_type): New enum.
9105 (innermost_block_tracker::innermost_block_tracker): Initialise
9107 (innermost_block_tracker::reset): Take type parameter.
9108 (innermost_block_tracker::update): Take type parameter, and pass
9109 type through as needed.
9110 (innermost_block_tracker::m_types): New member.
9111 * varobj.c (varobj_create): Pass type when reseting innermost
9114 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9116 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
9117 * ada-lang.c (resolve_subexp): Likewise.
9118 * breakpoint.c (set_breakpoint_condition) Likewise.
9119 (watch_command_1) Likewise.
9120 * c-exp.y (variable): Likewise.
9121 * d-exp.y (PrimaryExpression): Likewise.
9122 * f-exp.y (variable): Likewise.
9123 * go-exp.y (variable): Likewise.
9124 * m2-exp.y (variable): Likewise.
9125 * objfiles.c (objfile::~objfile): Likewise.
9126 * p-exp.y (variable): Likewise.
9127 * parse.c (innermost_block): Change type.
9128 * parser-defs.h (class innermost_block_tracker): New.
9129 (innermost_block): Change to innermost_block_tracker.
9130 * printcmd.c (display_command): Switch to innermost_block API.
9131 (do_one_display): Likewise.
9132 * rust-exp.y (do_one_display): Likewise.
9133 * symfile.c (clear_symtab_users): Likewise.
9134 * varobj.c (varobj_create): Switch to innermost_block API, replace
9135 use of innermost_block with block stored on varobj object.
9137 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9139 * expression.h (innermost_block): Remove declaration.
9140 * varobj.c: Add 'parser-defs.h' include.
9142 2018-01-19 Tom Tromey <tom@tromey.com>
9144 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
9145 symbols in the static and global blocks.
9147 2018-01-19 James Clarke <jrtc27@jrtc27.com>
9149 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
9150 gdb_ptrace.h, and move including gdb_wait.h ...
9151 * nat/linux-ptrace.h: ... to here.
9153 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9155 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
9156 inf_ptrace_detach_success.
9157 (inf_ptrace_detach_success): Add inferior parameter, use it
9158 instead of inferior_ptid, pass it to detach_inferior.
9159 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
9161 * inferior.c (detach_inferior): Add overload that takes an
9163 * inferior.h (detach_inferior): Likewise.
9164 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
9165 use inferior_ptid, adjust call to inf_ptrace_detach_success.
9166 * linux-thread-db.c (thread_db_detach): Use inf parameter.
9168 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9170 * target.h (struct target_ops) <to_detach>: Add inferior
9172 (target_detach): Likewise.
9173 * target.c (dispose_inferior): Pass inferior down.
9174 (target_detach): Pass inferior down. Assert that it is equal to
9175 the current inferior.
9176 * aix-thread.c (aix_thread_detach): Pass inferior down.
9177 * corefile.c (core_file_command): Pass current_inferior() down.
9178 * corelow.c (core_detach): Add inferior parameter.
9179 * darwin-nat.c (darwin_detach): Likewise.
9180 * gnu-nat.c (gnu_detach): Likewise.
9181 * inf-ptrace.c (inf_ptrace_detach): Likewise.
9182 * infcmd.c (detach_command): Pass current_inferior() down to
9184 * infrun.c (follow_fork_inferior): Pass parent_inf to
9186 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
9188 * linux-nat.c (linux_nat_detach): Add inferior parameter.
9189 * linux-thread-db.c (thread_db_detach): Likewise.
9190 * nto-procfs.c (procfs_detach): Likewise.
9191 * procfs.c (procfs_detach): Likewise.
9192 * record.c (record_detach): Likewise.
9193 * record.h (struct inferior): Forward-declare.
9194 (record_detach): Add inferior parameter.
9195 * remote-sim.c (gdbsim_detach): Likewise.
9196 * remote.c (remote_detach_1): Likewise.
9197 (remote_detach): Likewise.
9198 (extended_remote_detach): Likewise.
9199 * sol-thread.c (sol_thread_detach): Likewise.
9200 * target-debug.h (target_debug_print_inferior_p): New macro.
9201 * target-delegates.c: Re-generate.
9202 * top.c (kill_or_detach): Pass inferior down to target_detach.
9203 * windows-nat.c (windows_detach): Add inferior parameter.
9205 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9207 * target.h (struct target_ops) <to_detach>: Remove args
9209 (target_detach): Likewise.
9210 * target.c (dispose_inferior): Adjust.
9211 (target_detach): Remove args parameter, adjust.
9212 * aix-thread.c (aix_thread_detach): Adjust.
9213 * corefile.c (core_file_command): Adjust.
9214 * corelow.c (core_detach): Adjust.
9215 * darwin-nat.c (darwin_detach): Adjust.
9216 * gnu-nat.c (gnu_detach): Adjust.
9217 * inf-ptrace.c (inf_ptrace_detach): Adjust.
9218 * infcmd.c (detach_command): Adjust
9219 * infrun.c (follow_fork_inferior): Adjust.
9220 (handle_vfork_child_exec_or_exit): Adjust.
9221 * linux-fork.c (linux_fork_detach): Remove args parameter.
9222 * linux-fork.h (linux_fork_detach): Likewise.
9223 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
9224 * linux-thread-db.c (thread_db_detach): Likewise.
9225 * nto-procfs.c (procfs_detach): Likewise.
9226 * procfs.c (procfs_detach): Likewise.
9227 (do_detach): Remove signo parameter.
9228 * record.c (record_detach): Remove args parameter.
9229 * record.h (record_detach): Likewise.
9230 * remote-sim.c (gdbsim_detach): Likewise.
9231 * remote.c (remote_detach_1): Likewise.
9232 (remote_detach): Likewise.
9233 (extended_remote_detach): Likewise.
9234 * sol-thread.c (sol_thread_detach): Likewise.
9235 * target-delegates.c: Re-generate.
9236 * top.c (struct qt_args) <args>: Remove field.
9237 (kill_or_detach): Don't pass args.
9238 (quit_force): Don't set args.
9239 * windows-nat.c (windows_detach): Remove args parameter.
9241 2018-01-19 Yao Qi <yao.qi@linaro.org>
9243 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
9244 (arm_linux_init_abi): Install it.
9246 2018-01-19 Yao Qi <yao.qi@linaro.org>
9248 * osabi.c (gdb_osabi_names): Extend the regexp for
9249 arm-linux-gnueabihf.
9251 2018-01-18 Yao Qi <yao.qi@linaro.org>
9253 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
9255 (abbrev_table::add_abbrev): Update.
9256 (abbrev_table::lookup_abbrev): Update.
9258 2018-01-18 Yao Qi <yao.qi@linaro.org>
9260 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
9262 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
9264 * compile/compile.c (compile_to_object): Convert "triplet_rx"
9267 2018-01-17 Tom Tromey <tom@tromey.com>
9269 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
9271 2018-01-17 Tom Tromey <tom@tromey.com>
9273 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
9274 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
9275 (create_array_type_with_stride): Update.
9276 * dwarf2read.c (set_die_type): Update.
9278 2018-01-17 Tom Tromey <tom@tromey.com>
9280 * dwarf2read.c (delayed_method_info): Remove typedef.
9281 (dwarf2_cu::method_info): Now a std::vector.
9282 (add_to_method_list): Update.
9283 (free_delayed_list): Remove.
9284 (compute_delayed_physnames): Update.
9285 (process_full_comp_unit, process_full_type_unit): Clear the method
9286 list. Remove cleanups.
9287 (psymtab_include_file_name): Add name_holder parameter. Use
9289 (dwarf_decode_lines): Update.
9291 2018-01-17 Tom Tromey <tom@tromey.com>
9292 Simon Marchi <simon.marchi@ericsson.com>
9294 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
9295 (dwarf2_per_objfile::free_cached_comp_units)
9296 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9297 (init_cutu_and_read_dies_no_follow): Update.
9298 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
9299 (dwarf2_cu::~dwarf2_cu): New.
9300 (free_heap_comp_unit, free_stack_comp_unit): Remove.
9301 (age_cached_comp_units, free_one_cached_comp_unit): Update.
9303 2018-01-17 Tom Tromey <tom@tromey.com>
9304 Simon Marchi <simon.marchi@ericsson.com>
9306 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
9307 (struct die_reader_specs) <abbrev_table>: New member.
9308 (struct abbrev_table): Add constructor.
9309 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
9310 <abbrev_obstack>: Now an auto_obstack.
9311 (abbrev_table_up): New typedef.
9312 (init_cu_die_reader): Add abbrev_table parameter.
9313 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
9314 Add result_dwo_abbrev_table.
9315 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9316 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
9318 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
9320 (skip_children): Update.
9321 (abbrev_table::alloc_abbrev): Rename from
9322 abbrev_table_alloc_abbrev.
9323 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
9324 (abbrev_table::lookup_abbrev): Rename from
9325 abbrev_table_lookup_abbrev.
9326 (abbrev_table_read_table): Return abbrev_table_up.
9327 (abbrev_table_free, abbrev_table_free_cleanup)
9328 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
9329 (load_partial_dies): Update.
9331 2018-01-17 Tom Tromey <tom@tromey.com>
9333 * dwarf2read.c (dwarf2_compute_name): Update comment.
9334 (read_func_scope, read_variable): Update.
9335 (new_symbol): Remove.
9336 (new_symbol_full): Rename to new_symbol.
9338 2018-01-17 Mike Gulick <mgulick@mathworks.com>
9341 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
9342 a warning instead of throwing an error, set section size to 0 and return
9344 * gdb_bfd.h (gdb_bfd_map_section): Update description.
9346 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9348 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
9350 (linux_ptrace_attach_fail_reason_string): Likewise.
9351 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
9353 (linux_ptrace_attach_fail_reason_string): Likewise.
9354 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
9356 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9358 * linux-nat.c (linux_nat_attach): Remove xstrdup.
9360 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
9363 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
9364 checking for fs_base/gs_base fields in struct user_regs_struct.
9365 * configure: Regenerate.
9367 2018-01-17 Yao Qi <yao.qi@linaro.org>
9369 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
9371 (aarch64_linux_init_abi): Install it to gdbarch hook
9374 2018-01-15 Pedro Alves <palves@redhat.com>
9376 * common/signals-state-save-restore.c
9377 (save_original_signals_state): Fix typos.
9379 2017-01-12 Tom Tromey <tom@tromey.com>
9380 Sergio Durigan Junior <sergiodj@redhat.com>
9382 * Makefile.in (install-only): Install gdb-add-index.
9384 2018-01-12 John Baldwin <jhb@FreeBSD.org>
9386 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
9388 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9390 * infrun.c (keep_going_pass_signal): Clear step-over info when
9391 insert_breakpoints fails.
9393 2018-01-11 Pedro Alves <palves@redhat.com>
9396 * infrun.c (resume): Rename to ...
9397 (resume_1): ... this.
9398 (resume): Reimplement as wrapper around resume_1.
9400 2018-01-11 Pedro Alves <palves@redhat.com>
9403 * remote.c (remote_parse_stop_reply): Default to the last-set
9404 general thread instead of to 'magic_null_ptid'.
9406 2018-01-10 Pedro Alves <palves@redhat.com>
9408 * language.h (language_get_symbol_name_matcher): Rename ...
9409 (get_symbol_name_matcher): ... this.
9410 * language.c (language_get_symbol_name_matcher): Ditto.
9411 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
9414 2018-01-10 Pedro Alves <palves@redhat.com>
9418 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
9419 Adjust to use language_get_symbol_name_matcher instead of
9420 language_defn::la_get_symbol_name_matcher.
9421 * language.c (language_get_symbol_name_matcher): If in Ada mode
9422 and the lookup name is a verbatim match, return Ada's matcher.
9423 * language.h (language_get_symbol_name_matcher): Adjust comment.
9424 (ada_lookup_name_info::verbatim_p):: New method.
9426 2018-01-10 Pedro Alves <palves@redhat.com>
9429 * ada-lang.c (ada_collect_symbol_completion_matches): If the
9430 minsym's language is language_auto or language_cplus, pass down
9431 language_ada instead.
9432 * symtab.c (compare_symbol_name): Don't frob symbol language here.
9434 2018-01-10 Pedro Alves <palves@redhat.com>
9437 * minsyms.c (linkage_name_str): New function.
9438 (iterate_over_minimal_symbols): Use it.
9440 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9442 * NEWS: Document that 'info proc' now works on FreeBSD.
9444 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9446 * configure.ac: Check for kinfo_getfile in libutil.
9447 * configure: Regenerate.
9448 * config.in: Regenerate.
9449 * fbsd-nat.c: Include "fbsd-tdep.h".
9450 (fbsd_fetch_cmdline): New.
9451 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
9452 rather than calling error.
9453 (fbsd_info_proc): New.
9454 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
9455 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
9456 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
9458 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9460 * fbsd-nat.c (struct free_deleter): Remove.
9461 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
9463 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9465 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
9466 NULL for an empty pathname.
9468 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9470 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
9471 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
9472 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
9473 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
9474 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
9475 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
9476 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
9477 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
9478 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
9479 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
9480 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
9481 (fbsd_core_fetch_timeval, fbsd_print_sigset)
9482 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
9483 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
9484 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
9486 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
9488 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
9489 (gnu_xfer_auxv): New function.
9490 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
9493 2018-01-08 Yao Qi <yao.qi@linaro.org>
9494 Simon Marchi <simon.marchi@ericsson.com>
9496 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
9498 (COMMON_OBS): Remove selftest.o.
9499 * configure.ac: Append selftest-arch.c and common/selftest.c to
9500 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
9501 * configure: Re-generated.
9502 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
9504 (maintenance_info_selftests): Likewise.
9506 2018-01-08 Xavier Roirand <roirand@adacore.com>
9508 * ada-valprint.c (val_print_packed_array_elements): Use
9509 proper number of elements when printing an array indexed
9510 by an enumeration type.
9512 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9514 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
9515 (dw2_get_file_names_reader): Adjust.
9516 (lookup_dwo_signatured_type): Adjust.
9517 (lookup_dwp_signatured_type): Adjust.
9518 (lookup_signatured_type): Adjust.
9519 (create_type_unit_group): Adjust.
9520 (get_type_unit_group): Adjust.
9521 (process_psymtab_comp_unit_reader): Adjust.
9522 (build_type_psymtabs_reader): Adjust.
9523 (scan_partial_symbols): Adjust.
9524 (add_partial_symbol): Adjust.
9525 (add_partial_subprogram): Adjust.
9526 (peek_die_abbrev): Adjust.
9527 (fixup_go_packaging): Adjust.
9528 (process_imported_unit_die): Adjust.
9529 (dwarf2_compute_name): Adjust.
9530 (dwarf2_physname): Adjust.
9531 (read_import_statement): Adjust.
9532 (handle_DW_AT_stmt_list): Adjust.
9533 (read_file_scope): Adjust.
9534 (read_func_scope): Adjust.
9535 (read_lexical_block_scope): Adjust.
9536 (read_call_site_scope): Adjust.
9537 (read_variable): Adjust.
9538 (dwarf2_rnglists_process): Adjust.
9539 (dwarf2_ranges_process): Adjust.
9540 (dwarf2_ranges_read): Adjust.
9541 (dwarf2_get_pc_bounds): Adjust.
9542 (dwarf2_record_block_ranges): Adjust.
9543 (dwarf2_add_field): Adjust.
9544 (dwarf2_add_member_fn): Adjust.
9545 (read_structure_type): Adjust.
9546 (process_structure_scope): Adjust.
9547 (read_enumeration_type): Adjust.
9548 (read_array_type): Adjust.
9549 (mark_common_block_symbol_computed): Adjust.
9550 (read_common_block): Adjust.
9551 (read_namespace_type): Adjust.
9552 (read_namespace): Adjust.
9553 (read_module_type): Adjust.
9554 (read_tag_pointer_type): Adjust.
9555 (read_tag_ptr_to_member_type): Adjust.
9556 (read_tag_string_type): Adjust.
9557 (read_subroutine_type): Adjust.
9558 (read_typedef): Adjust.
9559 (read_base_type): Adjust.
9560 (attr_to_dynamic_prop): Adjust.
9561 (read_subrange_type): Adjust.
9562 (read_unspecified_type): Adjust.
9563 (dwarf2_read_abbrevs): Adjust.
9564 (load_partial_dies): Adjust.
9565 (read_partial_die): Adjust.
9566 (find_partial_die): Adjust.
9567 (guess_partial_die_structure_name): Adjust.
9568 (fixup_partial_die): Adjust.
9569 (read_attribute_value): Adjust.
9570 (read_addr_index): Adjust.
9571 (read_addr_index_from_leb128): Adjust.
9572 (read_str_index): Adjust.
9573 (dwarf2_string_attr): Adjust.
9574 (get_debug_line_section): Adjust.
9575 (dwarf_decode_line_header): Adjust.
9576 (lnp_state_machine::check_line_address): Adjust.
9577 (dwarf_decode_lines_1): Adjust.
9578 (dwarf_decode_lines): Adjust.
9579 (dwarf2_start_symtab): Adjust.
9580 (var_decode_location): Adjust.
9581 (new_symbol_full): Adjust.
9582 (dwarf2_const_value_data): Adjust.
9583 (dwarf2_const_value_attr): Adjust.
9584 (dwarf2_const_value): Adjust.
9586 (die_containing_type): Adjust.
9587 (build_error_marker_type): Adjust.
9588 (lookup_die_type): Adjust.
9589 (guess_full_die_structure_name): Adjust.
9590 (anonymous_struct_prefix): Adjust.
9591 (determine_prefix): Adjust.
9592 (dwarf2_name): Adjust.
9593 (follow_die_ref_or_sig): Adjust.
9594 (follow_die_offset): Adjust.
9595 (follow_die_ref): Adjust.
9596 (follow_die_sig_1): Adjust.
9597 (follow_die_sig): Adjust.
9598 (get_signatured_type): Adjust.
9599 (get_DW_AT_signature_type): Adjust.
9600 (decode_locdesc): Adjust.
9601 (dwarf_decode_macros): Adjust.
9602 (cu_debug_loc_section): Adjust.
9603 (fill_in_loclist_baton): Adjust.
9604 (dwarf2_symbol_mark_computed): Adjust.
9605 (init_one_comp_unit): Don't assign
9606 dwarf2_cu::dwarf2_per_objfile.
9607 (set_die_type): Adjust.
9609 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9611 * dwarf2read.c (struct mapped_debug_names): Add constructor.
9612 <dwarf2_per_objfile>: New field.
9613 (dwarf2_per_objfile): Remove global.
9614 (get_dwarf2_per_objfile): New function.
9615 (set_dwarf2_per_objfile): New function.
9616 (dwarf2_build_psymtabs_hard): Change objfile parameter to
9618 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9619 (read_abbrev_offset): Likewise.
9620 (read_indirect_string): Likewise.
9621 (read_indirect_line_string): Likewise.
9622 (read_indirect_string_at_offset): Likewise.
9623 (read_indirect_string_from_dwz): Likewise.
9624 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9626 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9627 (create_all_comp_units): Change objfile parameter to
9629 (create_all_type_units): Likewise.
9630 (process_queue): Add dwarf2_per_objfile parameter.
9631 (read_and_check_comp_unit_head): Likewise.
9632 (lookup_dwo_unit_in_dwp): Likewise.
9633 (get_dwp_file): Likewise.
9634 (process_cu_includes): Likewise.
9635 (struct free_dwo_file_cleanup_data): New struct.
9636 (dwarf2_has_info): Use get_dwarf2_per_objfile and
9637 set_dwarf2_per_objfile.
9638 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
9639 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
9640 context, adjust calls.
9641 (dw2_instantiate_symtab): Likewise.
9642 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
9643 (dw2_get_cu): Likewise.
9644 (create_cu_from_index_list): Change objfile parameter to
9646 (create_cus_from_index_list): Get dwarf2_per_objfile from
9647 context, adjust calls.
9648 (create_cus_from_index): Likewise.
9649 (create_signatured_type_table_from_index): Change objfile
9650 parameter to dwarf2_per_objfile.
9651 (create_signatured_type_table_from_debug_names): Change objfile
9652 parameter to dwarf2_per_objfile.
9653 (create_addrmap_from_index): Likewise.
9654 (create_addrmap_from_aranges): Likewise.
9655 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
9656 (dw2_setup): Remove.
9657 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
9659 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
9660 get_dwarf2_per_objfile.
9661 (dw2_forget_cached_source_info): Likewise.
9662 (dw2_map_symtabs_matching_filename): Likewise.
9663 (struct dw2_symtab_iterator) <index>: Remove.
9664 <dwarf2_per_objfile>: New field.
9665 (dw2_symtab_iter_init): Replace index parameter with
9667 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
9668 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
9669 (dw2_print_stats): Likewise.
9670 (dw2_dump): Likewise.
9671 (dw2_expand_symtabs_for_function): Likewise.
9672 (dw2_expand_all_symtabs): Likewise.
9673 (dw2_expand_symtabs_with_fullname): Likewise.
9674 (dw2_expand_marked_cus): Replace index and objfile parameters
9675 with dwarf2_per_objfile.
9676 (dw_expand_symtabs_matching_file_matcher): Add
9677 dwarf2_per_objfile parameter and adjust calls.
9678 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
9680 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
9681 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
9683 (create_cus_from_debug_names_list): Replace objfile parameter
9684 with dwarf2_per_objfile and adjust calls.
9685 (create_cus_from_debug_names): Likewise.
9686 (dwarf2_read_debug_names): Likewise.
9687 (mapped_debug_names::namei_to_name): Adjust call.
9688 (dw2_debug_names_iterator::next): Likewise.
9689 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
9690 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
9691 (dw2_debug_names_dump): Likewise.
9692 (dw2_debug_names_expand_symtabs_for_function): Likewise.
9693 (dw2_debug_names_expand_symtabs_matching): Likewise.
9694 (dwarf2_initialize_objfile): Likewise.
9695 (dwarf2_build_psymtabs): Likewise.
9696 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
9698 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
9699 (read_and_check_comp_unit_head): Likewise.
9700 (read_abbrev_offset): Likewise.
9701 (create_debug_type_hash_table): Likewise.
9702 (create_debug_types_hash_table): Likewise.
9703 (create_all_type_units): Replace objfile parameter with
9705 (add_type_unit): Add dwarf2_per_objfile parameter.
9706 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
9707 with dwarf2_per_objfile.
9708 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
9709 (lookup_dwp_signatured_type): Likewise.
9710 (lookup_signatured_type): Likewise.
9711 (read_cutu_die_from_dwo): Likewise.
9712 (init_tu_and_read_dwo_dies): Likewise.
9713 (init_cutu_and_read_dies): Likewise.
9714 (init_cutu_and_read_dies_no_follow): Likewise.
9715 (allocate_type_unit_groups_table): Add objfile parameter.
9716 (create_type_unit_group): Use dwarf2_per_objfile from cu.
9717 (get_type_unit_group): Likewise.
9718 (process_psymtab_comp_unit): Update call.
9719 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
9720 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
9721 (print_tu_stats): Likewise.
9722 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
9724 (build_type_psymtabs): Change objfile parameter to
9726 (process_skeletonless_type_unit): Use dwarf2_per_objfile
9727 passed in void* parameter.
9728 (process_skeletonless_type_units): Change objfile parameter to
9730 (set_partial_user): Likewise.
9731 (dwarf2_build_psymtabs_hard): Likewise.
9732 (read_comp_units_from_section): Likewise.
9733 (create_all_comp_units): Likewise.
9734 (scan_partial_symbols): Update calls.
9735 (add_partial_symbol): Likewise.
9736 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
9737 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
9738 (process_queue): Add dwarf2_per_objfile parameter.
9739 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
9740 (compute_compunit_symtab_includes): Likewise.
9741 (process_cu_includes): Add dwarf2_per_objfile parameter.
9742 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
9743 (process_full_type_unit): Likewise.
9744 (process_imported_unit_die): Update call.
9745 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
9746 (read_file_scope): Likewise.
9747 (allocate_dwo_file_hash_table): Add objfile parameter.
9748 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
9749 (create_cus_hash_table): Likewise.
9750 (create_dwp_hash_table): Likewise.
9751 (create_dwo_unit_in_dwp_v1): Likewise.
9752 (create_dwp_v2_section): Likewise.
9753 (create_dwo_unit_in_dwp_v2): Likewise.
9754 (lookup_dwo_unit_in_dwp): Likewise.
9755 (try_open_dwop_file): Likewise.
9756 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
9757 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
9758 cleanup to include a reference to dwarf2_per_objfile.
9759 (open_dwp_file): Add dwarf2_per_objfile parameter.
9760 (open_and_init_dwp_file): Likewise.
9761 (get_dwp_file): Likewise.
9762 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
9763 (queue_and_load_all_dwo_tus): Update call.
9764 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
9766 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
9767 (dwarf2_ranges_process): Likewise.
9768 (dwarf2_get_pc_bounds): Likewise.
9769 (mark_common_block_symbol_computed): Likewise.
9770 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9771 (dwarf2_read_abbrevs): Update call.
9772 (read_partial_die): Use dwarf2_per_objfile from cu.
9773 (find_partial_die): Likewise.
9774 (fixup_partial_die): Likewise.
9775 (read_attribute_value): Likewise.
9776 (read_indirect_string_at_offset_from): Add objfile parameter.
9777 (read_indirect_string_at_offset): Add dwarf2_per_objfile
9779 (read_indirect_string_from_dwz): Add objfile parameter.
9780 (read_indirect_string): Add objfile parameter.
9781 (read_addr_index_1): Add dwarf2_per_objfile parameter.
9782 (read_addr_index): Use dwarf2_per_objfile from cu.
9783 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
9785 (read_str_index): Use dwarf2_per_objfile from cu.
9786 (get_debug_line_section): Likewise.
9787 (read_formatted_entries): Add dwarf2_per_objfile parameter.
9788 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
9789 (new_symbol_full): Use dwarf2_per_objfile from cu.
9790 (build_error_marker_type): Likewise.
9791 (lookup_die_type): Likewise.
9792 (determine_prefix): Likewise.
9793 (follow_die_offset): Likewise.
9794 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
9795 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
9796 (dwarf2_fetch_die_type_sect_off): Likewise.
9797 (dwarf2_get_die_type): Likewise.
9798 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
9799 (get_signatured_type): Likewise.
9800 (get_DW_AT_signature_type): Likewise.
9801 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
9802 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
9803 (cu_debug_loc_section): Likewise.
9804 (fill_in_loclist_baton): Likewise.
9805 (dwarf2_symbol_mark_computed): Likewise.
9806 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9808 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
9810 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9811 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
9812 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
9813 (set_die_type): Use dwarf2_free_objfile from cu.
9814 (get_die_type_at_offset): Likewise.
9815 (dwarf2_per_objfile_free): Don't assign global variable.
9816 (debug_names) <constructor>: Add dwarf2_per_objfile
9817 parameter, update m_debugstrlookup construction.
9818 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
9820 <m_dwarf2_per_objfile>: New field.
9821 <lookup>: Use m_dwarf2_per_objfile.
9822 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
9823 (psyms_seen_size): Likewise.
9824 (write_gdbindex): Replace objfile parameter with
9826 (write_debug_names): Likewise.
9827 (write_psymtabs_to_index): Likewise.
9828 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
9831 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9833 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
9834 <dwarf2_per_objfile>: New field.
9835 (struct dwarf2_per_cu_data) <objfile>: Remove.
9836 <dwarf2_per_objfile>: New field.
9837 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
9839 (create_signatured_type_table_from_index): Likewise.
9840 (create_debug_type_hash_table): Likewise.
9841 (fill_in_sig_entry_from_dwo_entry): Likewise.
9842 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
9843 (create_type_unit_group): Assign dwarf2_per_objfile instead of
9845 (create_partial_symtab): Access objfile through
9847 (process_psymtab_comp_unit_reader): Likewise.
9848 (read_comp_units_from_section): Likewise.
9849 (scan_partial_symbols): Likewise.
9850 (add_partial_symbol): Likewise.
9851 (add_partial_subprogram): Likewise.
9852 (peek_die_abbrev): Likewise.
9853 (fixup_go_packaging): Likewise.
9854 (process_full_comp_unit): Likewise.
9855 (process_full_type_unit): Likewise.
9856 (process_imported_unit_die): Likewise.
9857 (dwarf2_compute_name): Likewise.
9858 (dwarf2_physname): Likewise.
9859 (read_import_statement): Likewise.
9860 (create_cus_hash_table): Assign dwarf2_physname instead of
9862 (read_func_scope): Access objfile through dwarf2_per_objfile.
9863 (read_lexical_block_scope): Likewise.
9864 (read_call_site_scope): Likewise.
9865 (read_variable): Likewise.
9866 (dwarf2_rnglists_process): Likewise.
9867 (dwarf2_ranges_process): Likewise.
9868 (dwarf2_ranges_read): Likewise.
9869 (dwarf2_record_block_ranges): Likewise.
9870 (dwarf2_add_field): Likewise.
9871 (dwarf2_add_member_fn): Likewise.
9872 (read_structure_type): Likewise.
9873 (process_structure_scope): Likewise.
9874 (read_enumeration_type): Likewise.
9875 (read_array_type): Likewise.
9876 (read_common_block): Likewise.
9877 (read_namespace_type): Likewise.
9878 (read_namespace): Likewise.
9879 (read_module_type): Likewise.
9880 (read_tag_pointer_type): Likewise.
9881 (read_tag_ptr_to_member_type): Likewise.
9882 (read_tag_string_type): Likewise.
9883 (read_subroutine_type): Likewise.
9884 (read_typedef): Likewise.
9885 (read_base_type): Likewise.
9886 (attr_to_dynamic_prop): Likewise.
9887 (read_subrange_type): Likewise.
9888 (read_unspecified_type): Likewise.
9889 (load_partial_dies): Likewise.
9890 (read_partial_die): Likewise.
9891 (find_partial_die): Likewise.
9892 (guess_partial_die_structure_name): Likewise.
9893 (fixup_partial_die): Likewise.
9894 (read_attribute_value): Likewise.
9895 (read_addr_index_from_leb128): Likewise.
9896 (dwarf2_read_addr_index): Likewise.
9897 (dwarf2_string_attr): Likewise.
9898 (lnp_state_machine::check_line_address): Likewise.
9899 (dwarf_decode_lines_1): Likewise.
9900 (dwarf_decode_lines): Likewise.
9901 (dwarf2_start_symtab): Likewise.
9902 (var_decode_location): Likewise.
9903 (new_symbol_full): Likewise.
9904 (dwarf2_const_value_data): Likewise.
9905 (dwarf2_const_value_attr): Likewise.
9906 (dwarf2_const_value): Likewise.
9907 (die_type): Likewise.
9908 (die_containing_type): Likewise.
9909 (lookup_die_type): Likewise.
9910 (guess_full_die_structure_name): Likewise.
9911 (anonymous_struct_prefix): Likewise.
9912 (dwarf2_name): Likewise.
9913 (follow_die_ref_or_sig): Likewise.
9914 (follow_die_offset): Likewise.
9915 (follow_die_ref): Likewise.
9916 (dwarf2_fetch_die_loc_sect_off): Likewise.
9917 (dwarf2_fetch_constant_bytes): Likewise.
9918 (dwarf2_fetch_die_type_sect_off): Likewise.
9919 (dwarf2_get_die_type): Likewise.
9920 (follow_die_sig): Likewise.
9921 (decode_locdesc): Likewise.
9922 (dwarf2_per_cu_objfile): Likewise.
9923 (dwarf2_per_cu_text_offset): Likewise.
9924 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
9926 (set_die_type): Access objfile through
9929 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9931 * valprint.c (converted_character_d): Remove typedef.
9932 (DEF_VEC_O (converted_character_d)): Remove.
9933 (count_next_character): Use std::vector.
9934 (print_converted_chars_to_obstack): Likewise.
9935 (generic_printstr): Likewise.
9937 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9939 * xml-support.h (struct gdb_xml_value): Add constructor.
9940 <value>: Change type to unique_xmalloc_ptr.
9941 (gdb_xml_value_s): Remove typedef.
9942 (DEF_VEC_O (gdb_xml_value_s)): Remove.
9943 (gdb_xml_element_start_handler): Change parameter type to
9945 (xml_find_attribute): Likewise.
9946 * xml-support.c (xml_find_attribute): Change parameter type to
9947 std::vector and adjust.
9948 (gdb_xml_values_cleanup): Remove.
9949 (gdb_xml_parser::start_element): Adjust to std::vector.
9950 (xinclude_start_include): Change paraeter type to std::vector
9952 * btrace.c (check_xml_btrace_version): Likewise.
9953 (parse_xml_btrace_block): Likewise.
9954 (parse_xml_btrace_pt_config_cpu): Likewise.
9955 (parse_xml_btrace_pt): Likewise.
9956 (parse_xml_btrace_conf_bts): Likewise.
9957 (parse_xml_btrace_conf_pt): Likewise.
9958 * memory-map.c (memory_map_start_memory): Likewise.
9959 (memory_map_start_property): Likewise.
9960 * osdata.c (osdata_start_osdata): Likewise.
9961 (osdata_start_item): Likewise.
9962 (osdata_start_column): Likewise.
9963 * remote.c (start_thread): Likewise.
9964 * solib-aix.c (library_list_start_library): Likewise.
9965 (library_list_start_list): Likewise.
9966 * solib-svr4.c (library_list_start_library): Likewise.
9967 (svr4_library_list_start_list): Likewise.
9968 * solib-target.c (library_list_start_segment): Likewise.
9969 (library_list_start_section): Likewise.
9970 (library_list_start_library): Likewise.
9971 (library_list_start_list): Likewise.
9972 * tracepoint.c (traceframe_info_start_memory): Likewise.
9973 (traceframe_info_start_tvar): Likewise.
9974 * xml-syscall.c (syscall_start_syscall): Likewise.
9975 * xml-tdesc.c (tdesc_start_target): Likewise.
9976 (tdesc_start_feature): Likewise.
9977 (tdesc_start_reg): Likewise.
9978 (tdesc_start_union): Likewise.
9979 (tdesc_start_struct): Likewise.
9980 (tdesc_start_flags): Likewise.
9981 (tdesc_start_enum): Likewise.
9982 (tdesc_start_field): Likewise.
9983 (tdesc_start_enum_value): Likewise.
9984 (tdesc_start_vector): Likewise.
9986 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9988 * extension.h (struct xmethod_worker) <clone>: Remove.
9989 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
9991 (python_xmethod_worker::clone): Remove.
9992 * valops.c (find_overload_match): Use std::move instead of
9995 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9997 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
9998 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
9999 <free_xmethod_worker_data>: Remove.
10000 <get_matching_xmethod_workers>: Chance VEC to std::vector.
10001 <get_xmethod_arg_types>: Remove.
10002 <get_xmethod_result_type>: Remove.
10003 <invoke_xmethod>: Remove.
10004 * extension.c (new_xmethod_worker): Remove.
10005 (clone_xmethod_worker): Remove.
10006 (get_matching_xmethod_workers): Return void, pass std::vector by
10008 (get_xmethod_arg_types): Rename to...
10009 (xmethod_worker::get_arg_types): ... this, and adjust.
10010 (get_xmethod_result_type): Rename to...
10011 (xmethod_worker::get_result_type): ... this, and adjust.
10012 (invoke_xmethod): Remove.
10013 (free_xmethod_worker): Remove.
10014 (free_xmethod_worker_vec): Remove.
10015 * extension.h (enum ext_lang_rc): Move here from
10017 (struct xmethod_worker): Add constructor and destructor.
10020 <invoke, clone, do_get_result_type, do_get_arg_types>: New
10021 virtual pure methods.
10022 <get_arg_types, get_result_type>: New methods.
10023 (xmethod_worker_ptr): Remove typedef.
10024 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
10025 (xmethod_worker_vec): Remove typedef.
10026 (xmethod_worker_up): New typedef.
10027 (invoke_xmethod): Remove.
10028 (clone_xmethod_worker): Remove.
10029 (free_xmethod_worker): Remove.
10030 (free_xmethod_worker_vec): Remove.
10031 (get_xmethod_arg_types): Remove.
10032 (get_xmethod_result_type): Remove.
10033 * valops.c (find_method_list): Use std::vector, don't use
10034 intermediate vector.
10035 (value_find_oload_method_list): Use std::vector.
10036 (find_overload_match): Use std::vector.
10037 (find_oload_champ): Use std::vector.
10038 * value.c (value_free): Use operator delete.
10039 (value_of_xmethod): Rename to...
10040 (value_from_xmethod): ... this. Don't assign
10041 xmethod_worker::value, take rvalue-reference.
10042 (result_type_of_xmethod): Adjust.
10043 (call_xmethod): Adjust.
10044 * value.h: Include extension.h.
10045 (struct xmethod_worker): Don't forward-declare.
10046 (value_of_xmethod): Rename to...
10047 (value_from_xmethod): ... this, take rvalue-reference.
10048 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
10049 (struct python_xmethod_worker): ... this, add constructor and
10051 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
10052 (gdbpy_free_xmethod_worker_data): Rename to...
10053 (python_xmethod_worker::~python_xmethod_worker): ... this and
10055 (gdbpy_clone_xmethod_worker_data): Rename to...
10056 (python_xmethod_worker::clone): ... this and adjust.
10057 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
10059 (gdbpy_get_xmethod_arg_types): Rename to...
10060 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
10061 (gdbpy_get_xmethod_result_type): Rename to...
10062 (python_xmethod_worker::do_get_result_type): ... this and
10064 (gdbpy_invoke_xmethod): Rename to...
10065 (python_xmethod_worker::invoke): ... this and adjust.
10066 (new_python_xmethod_worker): Rename to...
10067 (python_xmethod_worker::python_xmethod_worker): ... this and
10069 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
10071 (gdbpy_free_xmethod_worker_data): Remove.
10072 (gdbpy_get_matching_xmethod_workers): Use std::vector.
10073 (gdbpy_get_xmethod_arg_types): Remove.
10074 (gdbpy_get_xmethod_result_type): Remove.
10075 (gdbpy_invoke_xmethod): Remove.
10076 * python/python.c (python_extension_ops): Remove obsolete
10079 2018-01-05 Pedro Alves <palves@redhat.com>
10082 * common/signals-state-save-restore.c
10083 (save_original_signals_state): New parameter 'quiet'. Warn if we
10084 find a custom handler preinstalled, instead of internal erroring.
10085 But only warn if !quiet.
10086 * common/signals-state-save-restore.h
10087 (save_original_signals_state): New parameter 'quiet'.
10088 * main.c (captured_main_1): Move save_original_signals_state call
10089 after option handling, and pass QUIET.
10091 2018-01-05 Pedro Alves <palves@redhat.com>
10093 * spu-tdep.c (spu_catch_start): Pass
10094 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
10096 2018-01-05 Pedro Alves <palves@redhat.com>
10099 * ada-lang.c (literal_symbol_name_matcher): New function.
10100 (ada_get_symbol_name_matcher): Use it for
10101 symbol_name_match_type::SEARCH_NAME.
10102 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
10103 it down instead of assuming symbol_name_match_type::FULL.
10104 * block.h (block_lookup_symbol): New parameter 'match_type'.
10105 * c-valprint.c (print_unpacked_pointer): Use
10106 lookup_symbol_search_name instead of lookup_symbol.
10107 * compile/compile-object-load.c (get_out_value_type): Pass down
10108 symbol_name_match_type::SEARCH_NAME.
10109 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
10110 symbol_name_match_type::FULL.
10111 * cp-support.c (cp_get_symbol_name_matcher): Handle
10112 symbol_name_match_type::SEARCH_NAME.
10113 * infrun.c (insert_exception_resume_breakpoint): Use
10114 lookup_symbol_search_name.
10115 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
10116 * psymtab.c (maintenance_check_psymtabs): Use
10117 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
10118 * stack.c (print_frame_args): Use lookup_symbol_search_name and
10119 SYMBOL_SEARCH_NAME.
10120 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
10121 if symbol_name_match_type::SEARCH_NAME.
10122 (lookup_symbol_in_language): Pass down
10123 symbol_name_match_type::FULL.
10124 (lookup_symbol_search_name): New.
10125 (lookup_language_this): Pass down
10126 symbol_name_match_type::SEARCH_NAME.
10127 (lookup_symbol_aux, lookup_local_symbol): New parameter
10128 'match_type'. Pass it down.
10129 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
10130 (lookup_symbol_search_name): New declaration.
10131 (lookup_symbol_in_block): New 'match_type' parameter.
10133 2018-01-05 Pedro Alves <palves@redhat.com>
10136 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
10138 (ada_lookup_symbol): Reimplement in terms of
10139 ada_lookup_symbol_list, bits factored out from
10140 ada_lookup_encoded_symbol.
10142 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10144 * ada-exp.y (write_object_renaming): When subscripting an array
10145 using a symbol as the index, pass the block in call to
10146 ada_lookup_encoded_symbol when looking that symbol up.
10148 2018-01-05 Jerome Guitton <guitton@adacore.com>
10150 * ada-lang.c (ada_array_length): Use ada_index_type instead of
10153 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10155 * ada-lang.c (ada_to_fixed_value_create): Add handling of
10156 the case where VALUE_LVAL (val0) is not lval_memory.
10158 2018-01-05 Xavier Roirand <roirand@adacore.com>
10160 * ada-valprint.c (print_optional_low_bound): Handle
10161 character-indexed array printing like boolean-indexed array
10164 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10166 * NEWS: Create a new section for the next release branch.
10167 Rename the section of the current branch, now that it has
10170 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10172 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
10173 * version.in: Bump version to 8.1.50.DATE-git.
10175 2018-01-03 Xavier Roirand <roirand@adacore.com>
10177 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
10179 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
10181 (default_exception_support_info) <catch_handlers_sym>: Add field.
10182 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
10183 (ada_exception_name_addr_1): Add "catch handlers" handling.
10184 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
10185 Update all callers.
10186 (create_excep_cond_exprs) <ex>: Add parameter.
10187 (re_set_exception): Update create_excep_cond_exprs call.
10188 (print_it_exception, print_one_exception, print_mention_exception)
10189 (print_recreate_exception): Add "catch handler" handling.
10190 (allocate_location_catch_handlers, re_set_catch_handlers)
10191 (check_status_catch_handlers, print_it_catch_handlers)
10192 (print_one_catch_handlers, print_mention_catch_handlers)
10193 (print_recreate_catch_handlers): New function.
10194 (catch_handlers_breakpoint_ops): New variable.
10195 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
10196 Add parameter. Add "catch handler" handling.
10197 (ada_exception_sym_name, ada_exception_breakpoint_ops):
10198 Add "catch handler" handling.
10199 (ada_exception_catchpoint_cond_string): Add "catch handler"
10201 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
10203 (catch_ada_handlers_command): New function.
10204 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
10205 operations structure.
10206 (_initialize_ada_language): Add "catch handlers" command entry.
10207 * NEWS: Document "catch handlers" feature.
10209 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10211 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
10212 account when creating the array type of the slice.
10213 (ada_value_slice): Likewise.
10215 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10217 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
10219 (create_array_type_with_stride): Add byte_stride_prop parameter.
10220 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
10221 New parameter. Update all callers in this file.
10222 (array_type_has_dynamic_stride): New function.
10223 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
10224 of arrays with dynamic byte strides.
10225 * dwarf2read.c (read_array_type): Add support for dynamic
10226 DW_AT_byte_stride attributes.
10228 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10230 * dwarf2read.c (read_unspecified_type): Treat
10231 DW_TAG_enumeration_type DIEs from Ada units as stubs.
10233 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10235 Update copyright year range in all GDB files.
10237 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10239 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
10240 and gdb/testsuite/gdb.base/step-line.c.
10242 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10244 * copyright.py (main): Dump the contents of
10245 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
10246 even if BY_HAND is empty.
10248 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10250 * top.c (print_gdb_version): Update Copyright year in version
10253 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10255 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
10257 For older changes see ChangeLog-2017.
10263 version-control: never